Repository navigation
fix/ADFA-411 Remove tooltip debug info button - #84
Conversation
- Removed the tooltip debug info button and its associated functionality. - Cleaned up the layout file by removing the info icon.
fix/ADFA-411 Remove tooltip debug info button
itsaky-adfa
left a comment
There was a problem hiding this comment.
Retrospective review of a merged PR
This PR merged on 2025-04-16, so a merge-blocking verdict would be meaningless; findings are recorded as a comment.
Governing document: REVIEW.md, this repo's code review guide. It is explicitly a coaching doc, not a gate, and states no approve/request-changes rule, so the default applied: MINOR does not block. CLAUDE.md ties a Jira move to QA to "no outstanding critical, high, or medium findings", which this clears.
Ticket alignment: the apparent mismatch is legitimate
ADFA-411 is titled "Add 'info' icon to level 1 and level 2 tooltips" and this PR removes that icon, which reads as a PR undoing its own ticket. It is not. ADFA-411 comments of 2025-04-10 and 2025-04-11 record a decision, after a meeting between Hal, David, Elissa and Jim, to un-merge the work from stage so the stage build could stabilize, and to re-merge it later; the feature did return on 2025-08-13/14. So this is a sanctioned temporary revert, not a dropped requirement, and I am not flagging it as one. My one comment about it concerns the PR description, not the code.
Evidence ledger
Proportional to a 44-line pure deletion, per REVIEW.md.
| Area | Evidence |
|---|---|
| Ticket completeness | ADFA-411 comments read; removal is the sanctioned un-merge of #52 |
| Removal complete | Grepped head a7be126 for icon_info, onInfoButtonClicked, Tooltip Debug Info: zero remaining references, so no dangling findViewById or R.id. setupAndShowTooltipPopup's tooltipItem and context are still read, so no dead parameters. Only the ImageButton import went dead |
| Layout and resources | No other view in ide_tooltip_window.xml constrains to @id/icon_info, so no orphaned constraint; tools: is still used by tools:context. @drawable/ic_info is still referenced by DiagnosticItemAdapter.java, layout_chip_error.xml, layout_chip_warning.xml and FlashbarActivityUtils.kt, so nothing is orphaned |
| Build gate at the time | The base commit has no Spotless block in build.gradle.kts and no allWarningsAsErrors, so the dead import below was a warning, not a build break |
| Tests | None added. Pure deletion of a debug-only affordance owes no coverage, but REVIEW.md §14 asks the description to say so and it does not |
| A11y and font scale | Removal only; the deleted ImageButton carried no contentDescription, so this is a11y-neutral-to-positive and there is no changed screen to re-verify at 1.0/2.0 |
| Not applicable | §1 exceptions, §2 leaks, §3 threading, §10 architecture, §13 plugins: the change adds no failure path, registration, I/O, UI, state, or API surface |
Findings
1 MINOR, 2 NITPICK. No CRITICAL and no IMPORTANT: the deletion itself is clean and complete.
Two findings concern lines outside the diff hunks (TooltipUtils.kt:32 and :154). Each is anchored to the nearest hunk line it concerns and names its true location in the first sentence.
| /** | ||
| * Handles the click on the info icon in the tooltip. | ||
| */ | ||
| private fun onInfoButtonClicked(context: Context, popupWindow: PopupWindow, tooltip: IDETooltipItem) { |
There was a problem hiding this comment.
MINOR: the description presents this as a feature removal, with no record that it is a temporary un-merge expected to be re-applied.
"Remove tooltip debug info button" against a ticket titled "Add 'info' icon to level 1 and level 2 tooltips" reads as a PR reverting its own ticket. The reason lives only in ADFA-411 comments of 2025-04-10 and 2025-04-11: un-merge from stage to stabilize the stage build, re-merge later. From the PR alone a reader cannot tell this deletion is meant to be undone, and it was in fact re-applied in August. QA hit exactly this gap on 2025-04-17, reporting a build as missing the info icon.
REVIEW.md §14 asks the description to say why, and to flag what is intentionally out of scope. Two lines naming the un-merge decision and linking #52 would make the reverse findable later.
| ViewGroup.LayoutParams.WRAP_CONTENT | ||
| ) | ||
|
|
||
| val infoButton = popupView.findViewById<ImageButton>(R.id.icon_info) |
There was a problem hiding this comment.
NITPICK: import android.widget.ImageButton is left behind by this deletion.
The findViewById<ImageButton>(R.id.icon_info) removed on this line was the file's only ImageButton use, so the import at TooltipUtils.kt:32, outside this diff, is now dead. Harmless here: the base commit has no Spotless block and no allWarningsAsErrors, so it is a warning. Under today's ktlint ratchet, no-unused-imports would fail spotlessCheck on this file. PR #52 is the commit that added the import, so dropping it keeps this removal an exact inverse of the addition.
Delete line 32.
| @@ -160,7 +160,6 @@ object TooltipUtils { | |||
| ViewGroup.LayoutParams.WRAP_CONTENT | |||
There was a problem hiding this comment.
NITPICK: currentActivity at TooltipUtils.kt:154, six lines above this one, is bound but never read.
Pre-existing rather than introduced here, but this PR already edits this function, so it is cheap to fold in. In setupAndShowTooltipPopup, val currentActivity = mainActivity ?: return uses only the ?: return half, which is real behaviour: the tooltip silently does not show when MainActivity.getInstance() is null. So the statement cannot simply be deleted, only the name dropped, leaving mainActivity ?: return. Contrast showWebPage at line 63, where the identical binding is genuinely read on the next line.
itsaky-adfa
left a comment
There was a problem hiding this comment.
Approving.
The deletion itself is clean and complete: no residual icon_info or onInfoButtonClicked references at head, no orphaned ConstraintLayout constraint, @drawable/ic_info still in use elsewhere, and no dead parameters left in setupAndShowTooltipPopup.
The one MINOR and two NITPICKs in my review above are non-blocking. Nothing needs to change for this to have merged; the only point that still carries forward is the description one, since TooltipUtils.kt no longer exists on stage, which makes both nitpicks historical.
Approval requested by the reviewer over the computed verdict of COMMENT, which the MINOR would otherwise have produced.
Description
Removed the tooltip debug info button and its associated functionality.
Cleaned up the layout file by removing the info icon.
Details
Ticket
ADFA-411
Observation