Closed Bug 1247553 Opened 10 years ago Closed 4 months ago

Let the ruler remain appeared after reloading

Categories

(DevTools :: Inspector, enhancement, P3)

enhancement

Tracking

(firefox154 fixed)

RESOLVED FIXED
154 Branch
Tracking Status
firefox154 --- fixed

People

(Reporter: r_kato, Assigned: nchevobbe)

References

(Regressed 1 open bug)

Details

Attachments

(4 external files, 1 obsolete file)

Developer Tool's ruler disappears after we reload a page. If the ruler remained appeared, it would be more useful! ( at least I would be happy ;) )
Status: UNCONFIRMED → NEW
Component: Developer Tools → Developer Tools: Inspector
Ever confirmed: true
Matteo, can you explain what one would have to do to change this behavior?
Flags: needinfo?(zer0)
We made the tool disappeared due the bfcache, that caused issues. Not only the rulers actually, but a others highlighters too. If I recall correctly, it was a problem with the anonymous content, and the fact that we couldn't map the anonymous content to the correct instance of the highlighter object. So, when we navigate, we destroy the highlighter to avoid such thing. The reload is still navigate to the same document, so that's why disappears. We could bound the highlighter to the window instead of the document; so basically if we have such highlighter enabled before on that window, when we load a new document, we recreate such highlighter again; basically using a similar approach we have to "toggle" the command's icon of the rulers, when we change page.
Flags: needinfo?(zer0)
Filter on CLIMBING SHOES
Priority: -- → P3
Product: Firefox → DevTools
Severity: normal → S3

FWIW, I was bitten/frustrated/enraged by this today...

(Nine years in Internet Time feels like forever! «sigh»)

Even adding a keyboard shortcut would be more efficient than having to reach for the mouse and target the ruler icon every time I [Cmd+Shift+R]-eload a page I'm working on... (I propose Ctrl+Shift+R on Windows and Cmd+Opt+R on the Mac; they parallel Cmd+Opt+I for opening the DevTools panel itself.)

Thanks! :-D

just bumping this one since it's been a year since the last comment, i'm another dev who would greatly appreciate the ruler toggle status being saved between reloads of the same tab, or even being saved globally.

Assignee: nobody → nchevobbe
Attachment #9527345 - Attachment description: WIP: Bug 1247553 - [devtools] Restore ruler button highlighters after reload. r=#devtools → Bug 1247553 - [devtools] Restore rulers button highlighters after reload. r=#devtools
Status: NEW → ASSIGNED

While the frontend doesn't need passing the isShown state from the
actor, the tests require to pass it via highlighter's actor's form.
The frontend can derivate the current state by looking at target actor
configuration.

This will later help retrieve the instance created from early server logic
when the frontend queries rulers/measure highlighters.

As rulers/measure highlighters may be shown by server logic,
we need to pass the initial "isShown" state to the client.

It looks like finalize was meant to destroy the highlighter front
and actor, but the actor wasn't destroyed.
Also calling finalize or destroy didn't make much diffence on both
sides.

Stop using "finalize" manually from the frontend, instead rely
on Front's destroy method to emit the oneway+release "finalize"
request, which would destroy both front and actor.

Attachment #9597365 - Attachment description: WIP: Bug 1247553 - [devtools] Cache highlighters per type in HighlightersActor. → Bug 1247553 - [devtools] Cache highlighters per type in HighlightersActor. r=#devtools
Attachment #9597366 - Attachment description: WIP: Bug 1247553 - [devtools] Pass initial isShown highlighter actor state. → Bug 1247553 - [devtools] Pass initial isShown highlighter actor state. r=#devtools
Attachment #9596360 - Attachment description: WIP: Bug 1247553 - [devtools] Use Target Actor configuration to make rulers highlighter global and persist over navigations. → Bug 1247553 - [devtools] Use Target Actor configuration to make rulers highlighter global and persist over navigations. r=#devtools
Attachment #9527345 - Attachment is obsolete: true
Pushed by apoirot@mozilla.com: https://github.com/mozilla-firefox/firefox/commit/7adc111789dd https://hg.mozilla.org/integration/autoland/rev/cfcb6d7b85a6 [devtools] Clarify highlighter destruction. r=devtools-reviewers,devtools-backward-compat-reviewers,nchevobbe https://github.com/mozilla-firefox/firefox/commit/5c3271381aa3 https://hg.mozilla.org/integration/autoland/rev/00b4ac82143a [devtools] Cache highlighters per type in HighlightersActor. r=devtools-reviewers,devtools-backward-compat-reviewers,nchevobbe https://github.com/mozilla-firefox/firefox/commit/abb53471dcc7 https://hg.mozilla.org/integration/autoland/rev/d50654a9c035 [devtools] Pass initial isShown highlighter actor state. r=devtools-reviewers,nchevobbe https://github.com/mozilla-firefox/firefox/commit/0b3488bea7be https://hg.mozilla.org/integration/autoland/rev/df4474eee813 [devtools] Use Target Actor configuration to make rulers highlighter global and persist over navigations. r=devtools-reviewers,nchevobbe
Regressions: 2052856
QA Whiteboard: [qa-triage-done-c155/b154]
Regressions: 2056740
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: