Closed
Bug 1280876
Opened 8 years ago
Closed 8 years ago
Find toolbar influences New Tab page
Categories
(Toolkit :: Find Toolbar, defect)
Tracking
()
Tracking | Status | |
---|---|---|
firefox49 | --- | unaffected |
firefox50 | --- | disabled |
firefox51 | --- | disabled |
firefox52 | --- | verified |
People
(Reporter: annevk, Assigned: mikedeboer)
References
(Blocks 1 open bug)
Details
(Keywords: regression)
Attachments
(2 files)
It seems if you did an inline search, that can influence the thumbnails for the New Tab page.
Reporter | ||
Updated•8 years ago
|
Summary: Find toolbar influence New Tab page → Find toolbar influences New Tab page
Comment 1•8 years ago
|
||
[Tracking Requested - why for this release]: Regression
status-firefox49:
--- → unaffected
status-firefox50:
--- → affected
tracking-firefox50:
--- → ?
Keywords: regression
Version: unspecified → 50 Branch
Comment 2•8 years ago
|
||
Feature has been backed out so not tracking these bugs for 50.
tracking-firefox50:
? → ---
Assignee | ||
Updated•8 years ago
|
Assignee: nobody → mdeboer
Status: NEW → ASSIGNED
Iteration: --- → 50.4 - Aug 1
Points: --- → 1
Assignee | ||
Comment 3•8 years ago
|
||
Review commit: https://reviewboard.mozilla.org/r/67776/diff/#index_header See other reviews: https://reviewboard.mozilla.org/r/67776/
Attachment #8775609 -
Flags: review?(jaws)
Comment 4•8 years ago
|
||
Comment on attachment 8775609 [details] Bug 1280876 - don't take screenshots of pages that have the findbar open. https://reviewboard.mozilla.org/r/67776/#review65108 ::: toolkit/components/thumbnails/PageThumbUtils.jsm:284 (Diff revision 1) > + // Don't take screenshots when the findbar is active. > + if (aDocument.mozFinderHighlightVisible) { > + return false; > + } Can you just query if the findbar is open? Something not as ugly as `gBrowser.getBrowserForDocument(aDocument)._remoteFinder` and something that works for e10s and non-e10s, but similar? ::: toolkit/modules/FinderHighlighter.jsm:234 (Diff revision 1) > > window = window || this.finder._getWindow(); > let anonNode = this._maybeCreateModalHighlightNodes(window); > this._addModalHighlightListeners(window); > > + window.document.mozFinderHighlightVisible = true; I don't particularly like us adding properties to the document. Will they be visible to content? I'm assuming so, since the overlay needed to be added to anonymous content. ::: toolkit/modules/FinderHighlighter.jsm:265 (Diff revision 1) > this._unhookListenersAtIndex(x); > } > } > } > > + delete window.document.mozFinderHighlightVisible; window.document.mozFinderHighlightVisible = false;
Attachment #8775609 -
Flags: review?(jaws) → review-
Assignee | ||
Comment 5•8 years ago
|
||
Thanks for the review! (In reply to Jared Wein [:jaws] (please needinfo? me) from comment #4) > Can you just query if the findbar is open? Aah, yes... why didn't I think of that?
Assignee | ||
Comment 6•8 years ago
|
||
(In reply to Mike de Boer [:mikedeboer] from comment #5) > Aah, yes... why didn't I think of that? Apparently I did, but is complicated due to the fact that the findbar is in the chrome process and the highlighter in the content process. I need to think of something else here.
Assignee | ||
Comment 7•8 years ago
|
||
Comment on attachment 8775609 [details] Bug 1280876 - don't take screenshots of pages that have the findbar open. Review request updated; see interdiff: https://reviewboard.mozilla.org/r/67776/diff/1-2/
Attachment #8775609 -
Attachment description: Bug 1280876 - prevent the background page thumbnail capturer to take shots whilst the finder highlighter is active. → Bug 1280876 - don't take screenshots of pages that have the findbar open.
Attachment #8775609 -
Flags: review?(jaws)
Attachment #8775609 -
Flags: review?(bzbarsky)
Attachment #8775609 -
Flags: review-
Assignee | ||
Comment 8•8 years ago
|
||
https://reviewboard.mozilla.org/r/67776/#review65340 ::: docshell/base/nsDocShell.cpp:819 (Diff revision 2) > , mFrameType(FRAME_TYPE_REGULAR) > , mPrivateBrowsingId(0) > , mParentCharsetSource(0) > , mJSRunToCompletionDepth(0) > , mTouchEventsOverride(nsIDocShell::TOUCHEVENTS_OVERRIDE_NONE) > + , mFindbarOpen(false) Compiler gives a warning here about the order of initialization, but I don't think that matters much in this case...
Comment 9•8 years ago
|
||
> Compiler gives a warning here about the order of initialization, but I don't think that matters much in this case...
It matters, both in terms of efficiency and compiler warning spew, and you should fix the warning by ordering your initializers the same as you order your members.
Assignee | ||
Comment 11•8 years ago
|
||
Comment on attachment 8775609 [details] Bug 1280876 - don't take screenshots of pages that have the findbar open. Review request updated; see interdiff: https://reviewboard.mozilla.org/r/67776/diff/2-3/
Assignee | ||
Comment 12•8 years ago
|
||
(In reply to Boris Zbarsky [:bz] from comment #9) > It matters, both in terms of efficiency and compiler warning spew, and you > should fix the warning by ordering your initializers the same as you order > your members. Aha! OK, thanks for the explanation. It's part of the basics, I know, but I learn everyday...
Comment 13•8 years ago
|
||
Comment on attachment 8775609 [details] Bug 1280876 - don't take screenshots of pages that have the findbar open. https://reviewboard.mozilla.org/r/67776/#review65378
Attachment #8775609 -
Flags: review?(jaws) → review+
Comment 14•8 years ago
|
||
mozreview-review |
Comment on attachment 8775609 [details] Bug 1280876 - don't take screenshots of pages that have the findbar open. https://reviewboard.mozilla.org/r/67776/#review67506
Attachment #8775609 -
Flags: review?(bzbarsky)
Comment 15•8 years ago
|
||
mozreview-review |
Comment on attachment 8775609 [details] Bug 1280876 - don't take screenshots of pages that have the findbar open. https://reviewboard.mozilla.org/r/67776/#review67508 Oh, looks like mozreview UI now disappears headers if you don't explicitly save them... What I just _tried_ to say, and what I said a week ago when mozreview _also_ disappeared my comments, is that it's not clear to me why this state needs to live on docshell as opposed to the browser or tabbrowser or some other part of the frontend that the findbar is coordinating with anyway. Is this state going to be relevant to subframes, for example? I don't think so....
Comment 16•8 years ago
|
||
I filed bug 1293565 on the mozreview UI bustage....
Assignee | ||
Comment 17•8 years ago
|
||
(In reply to Boris Zbarsky [:bz] from comment #15) > What I just _tried_ to say, and what I said a week ago when mozreview _also_ > disappeared my comments, is that it's not clear to me why this state needs > to live on docshell as opposed to the browser or tabbrowser or some other > part of the frontend that the findbar is coordinating with anyway. Is this > state going to be relevant to subframes, for example? I don't think so.... Everything but the findbar XUL (and the RemoteFinder.jsm message proxy) live in the content process(es) and there's no `gFindBar` global that can be referenced there to extract state from it. Since the background thumbnailer (the change in PageThumbUtils.jsm is what makes this all work) runs in the content process too, and checks if it should store a content thumbnail synchronously, so adding an async message passing flow there would be a bit problematic. At first I thought about using a JS expando prop on the document object - `mozFindbarOpen = true` whilst the findbar is open - but that'd be visible to the web. Do you see another option? Thanks for checking the bug again!
Flags: needinfo?(bzbarsky)
Comment 18•8 years ago
|
||
> but that'd be visible to the web
Er... no, it wouldn't. The expando would be defined on the Xray; chrome would see it, but web content would not.
A bigger problem for the expando-on-the-document approach is that it would not persist across navigations, but the "findbar is open" state does.
Is there really no chrome object that corresponds to the tab but lives content-side??
Flags: needinfo?(bzbarsky)
Assignee | ||
Comment 19•8 years ago
|
||
(In reply to Boris Zbarsky [:bz] from comment #18) > Is there really no chrome object that corresponds to the tab but lives > content-side?? No, but I can make a new content global... That's probably the best option, thanks for asking.
Comment hidden (mozreview-request) |
Comment 21•8 years ago
|
||
mozreview-review |
Comment on attachment 8775609 [details] Bug 1280876 - don't take screenshots of pages that have the findbar open. https://reviewboard.mozilla.org/r/67776/#review67792 r=me with my nits fixed. Thanks mikedeboer! ::: toolkit/modules/BrowserUtils.jsm:315 (Diff revision 4) > + * @param {nsIDocShell} docShell The docShell instance that a toolbar should > + * be interacting with > + * @param {String} [which] Identifier of a specific toolbar > + * @return {Boolean} > + */ > + isToolbarVisible(docShell, which = null) { Out of curiosity, why are we defaulting this to null? It looks like the null case means "there are no toolbars visible", but is that useful, especially given that we return false if we've never seen the window before? It might be safer to just return toolbars.has(which), unless there's a good reason to care about the "we saw it once, but nothing is currently visible" case. ::: toolkit/modules/BrowserUtils.jsm:334 (Diff revision 4) > + * @param {Boolean} [visible] Whether the toolbar is visible. Optional, > + * defaults to `true`. > + */ > + trackToolbarVisibility(docShell, which, visible = true) { > + if (!this._visibleToolbarsMap) > + this._visibleToolbarsMap = new WeakMap(); I think we can probably just define \_visibleToolbarsMap directly on the BrowserUtils object safely, and be reasonably sure it exists.
Attachment #8775609 -
Flags: review?(mconley) → review+
Assignee | ||
Comment 22•8 years ago
|
||
(In reply to Mike Conley (:mconley) - (Needinfo me!) from comment #21) > Out of curiosity, why are we defaulting this to null? > > It looks like the null case means "there are no toolbars visible", but is > that useful, especially given that we return false if we've never seen the > window before? > > It might be safer to just return toolbars.has(which), unless there's a good > reason to care about the "we saw it once, but nothing is currently visible" > case. Agreed.
Comment hidden (mozreview-request) |
Comment 24•8 years ago
|
||
Pushed by mdeboer@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/0ec1ef348547 don't take screenshots of pages that have the findbar open. r=jaws,mconley
Comment 25•8 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/0ec1ef348547
Status: ASSIGNED → RESOLVED
Closed: 8 years ago
status-firefox51:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla51
Comment 26•8 years ago
|
||
I couldn't reproduce the initial reported issue and can't reproduce it either on the latest Nightly 52.0a1 (Build ID: 20160928030201) - Win10, Mac OS X 10.11 and Ubuntu 16.04, therefore I can't verify it as fixed. Anne, can you please confirm that this issue is indeed fixed?
Flags: needinfo?(annevk)
Reporter | ||
Comment 27•8 years ago
|
||
I haven't seen this recently. The only thing I notice is that search is still super slow and janky (and has some weird painting issues).
Flags: needinfo?(annevk)
Comment 28•8 years ago
|
||
Based on Comment 27, setting the status of this issue to Verified Fixed. Please note that the new Find Toolbar feature is disabled by default on Firefox 51.
Updated•8 years ago
|
You need to log in
before you can comment on or make changes to this bug.
Description
•