Closed
Bug 881331
Opened 12 years ago
Closed 10 years ago
Popup notifications added in a background window don't show the anchor icon until the window is brought to the front
Categories
(Toolkit Graveyard :: Notifications and Alerts, defect)
Toolkit Graveyard
Notifications and Alerts
Tracking
(firefox22-, firefox23-, firefox24-, firefox38 verified)
VERIFIED
FIXED
mozilla38
People
(Reporter: jsmith, Assigned: florian)
References
Details
(Whiteboard: [getUserMedia][blocking-gum-][CTPDefault:P3])
Attachments
(1 file, 1 obsolete file)
2.40 KB,
patch
|
MattN
:
review+
|
Details | Diff | Splinter Review |
Build: 6/10/2013 Nightly
STR
1. In window #1, go to http://mozilla.github.io/webrtc-landing/gum_test.html
2. Request video
3. Accept permissions
4. In window #2, go to http://mozilla.github.io/webrtc-landing/gum_test.html
5. Request video
6. Accept permissions
Expected
The visible indicator should be present on both windows.
Actual
The visible indicator disappears on the non-focused window. Additionally, Firefox begins to flash in the toolbar.
Reporter | ||
Updated•12 years ago
|
Version: 23 Branch → Trunk
Reporter | ||
Comment 1•12 years ago
|
||
Definitely a recent regression. Easy to recover from though.
Keywords: regression
Whiteboard: [getUserMedia][android-gum+]
Reporter | ||
Updated•12 years ago
|
Whiteboard: [getUserMedia][android-gum+] → [getUserMedia][blocking-gum-]
Comment 2•12 years ago
|
||
Not sure whether this a UI or core bug. A regression window would be useful.
Keywords: regressionwindow-wanted
Comment 3•12 years ago
|
||
Regression window(m-c)
Good:
http://hg.mozilla.org/mozilla-central/rev/993d7aff3109
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:22.0) Gecko/20130228 Firefox/22.0 ID:20130228192921
Bad:
http://hg.mozilla.org/mozilla-central/rev/3362afba690e
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:22.0) Gecko/20130301 Firefox/22.0 ID:20130301154349
Pushlog:
http://hg.mozilla.org/mozilla-central/pushloghtml?fromchange=993d7aff3109&tochange=3362afba690e
Regression window(m-i)
Good:
http://hg.mozilla.org/integration/mozilla-inbound/rev/4e7646d14797
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:22.0) Gecko/20130228 Firefox/22.0 ID:20130301003322
Bad:
http://hg.mozilla.org/integration/mozilla-inbound/rev/7df619463b43
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:22.0) Gecko/20130228 Firefox/22.0 ID:20130301031827
Pushlog:
http://hg.mozilla.org/integration/mozilla-inbound/pushloghtml?fromchange=4e7646d14797&tochange=7df619463b43
regressed by:
da75867527dd Dão Gottwald — Bug 843971 - Update browser-specific indicators when content gains or releases access to devices. r=dolske
Blocks: 843971
tracking-firefox22:
--- → ?
tracking-firefox23:
--- → ?
tracking-firefox24:
--- → ?
Keywords: regressionwindow-wanted
Comment 4•12 years ago
|
||
So the underlying problem (that isn't a recent regression) is that popup notifications added in a background window don't show the icon until the window is brought to the front.
Keywords: regression
Product: Firefox → Toolkit
Comment 5•12 years ago
|
||
Not blocking-gum and specific to gUM, so not tracking.
Comment 6•11 years ago
|
||
The "window starts flashing" part is bug 882188.
Blocks: doorhanger
Summary: Requesting gUM across two different windows causes the visible indicator to be lost and the window to start flashing in the windows toolbar until focus is returned back to the window → Popup notifications added in a background window don't show the anchor icon until the window is brought to the front
Comment 7•11 years ago
|
||
Hmm, I guess perhaps the activeWindow check in show() should be moved into _update, and only influence the popup-opening (and not the anchor-showing). That might throw off some tests that expect backgroundShow to fire in that case, though.
Comment 9•11 years ago
|
||
Gavin, is comment 7 the approach we want? This would be nice to have for CtP plugins.
Flags: needinfo?(gavin.sharp)
Whiteboard: [getUserMedia][blocking-gum-] → [getUserMedia][blocking-gum-][CTPDefault:P3]
Comment 11•11 years ago
|
||
Sankha said he'll try get to it this week.
Assignee: nobody → sankha93
Status: NEW → ASSIGNED
Comment 12•11 years ago
|
||
Attachment #831987 -
Flags: review?(gavin.sharp)
Comment 13•11 years ago
|
||
(In reply to Sankha Narayan Guria [:sankha93] from comment #12)
> Created attachment 831987 [details] [diff] [review]
> patch v1
Hey Sankha, do the tests all pass without modification?
Comment 14•11 years ago
|
||
(In reply to Matthew N. [:MattN] (catching up on reviews) from comment #13)
> Hey Sankha, do the tests all pass without modification?
I just tested browser/base/content/test/general/browser_popupNotification.js, and all tests are passing as long as the browser window of the test is in focus. If the focus is taken to another window, the tests fail, is that normal behavior?
I could push to try to check it once more.
Comment 15•11 years ago
|
||
(In reply to Sankha Narayan Guria [:sankha93] from comment #14)
> (In reply to Matthew N. [:MattN] (catching up on reviews) from comment #13)
> If the focus is taken to another window, the tests fail, is that normal
> behavior?
That's normal for some mochitests like this where panels are involved.
> I could push to try to check it once more.
That would be good since there are other tests which exercise PopupNotifications. I've pushed a run for you:
https://tbpl.mozilla.org/?tree=Try&rev=a125072533ae
Comment 16•11 years ago
|
||
Patch looks good, but can you also write a test to cover this case?
If you find me or Matt on IRC we can give you some pointers.
Comment 17•11 years ago
|
||
Comment on attachment 831987 [details] [diff] [review]
patch v1
Needs a test (per last comments).
Attachment #831987 -
Flags: review?(gavin.sharp)
Comment 20•11 years ago
|
||
Oops, sorry, wrong person. I meant to flag the assignee, not the reporter.
Sankha, any update on tests?
Flags: needinfo?(sankha93)
Comment 21•11 years ago
|
||
Yeah, I had some questions regarding the tests. I'll ping you on IRC for it.
Flags: needinfo?(sankha93)
Comment 22•11 years ago
|
||
Bulk move to Toolkit::Notifications and Alerts
Filter on notifications-and-alerts-component.
Component: General → Notifications and Alerts
Updated•11 years ago
|
Flags: firefox-backlog+
Assignee | ||
Comment 23•10 years ago
|
||
No recent activity here, so I updated the patch (it bitrotted mostly due to the refactoring in bug 1085691) and wrote a test.
https://treeherder.mozilla.org/ui/#/jobs?repo=try&revision=33a89829ac0e
Assignee: sankha93 → florian
Attachment #831987 -
Attachment is obsolete: true
Attachment #8545282 -
Flags: review?(MattN+bmo)
Updated•10 years ago
|
Iteration: --- → 37.3 - 12 Jan
Flags: qe-verify?
Comment 25•10 years ago
|
||
Comment on attachment 8545282 [details] [diff] [review]
Updated patch with test
Review of attachment 8545282 [details] [diff] [review]:
-----------------------------------------------------------------
I get a failure while running the test directory (OS X Debug):
831 INFO TEST-UNEXPECTED-FAIL | browser/base/content/test/popupNotifications/browser_popupNotification_4.js | A promise chain failed to handle a rejection: - at chrome://mochitests/content/browser/browser/base/content/test/popupNotifications/head.js:119 - TypeError: Assert is null
::: toolkit/modules/PopupNotifications.jsm
@@ -314,5 @@
> if (!notification.dismissed) {
> this.window.getAttention();
> }
> - if (notification.anchorElement.parentNode != this.iconBox) {
> - this._updateAnchorIcon(notifications, notification.anchorElement);
Can you explain why the deletion of the `if` fixes this?
Attachment #8545282 -
Flags: review?(MattN+bmo)
Comment 26•10 years ago
|
||
(In reply to Matthew N. [:MattN] (away until Jan. 7) from comment #25)
> I get a failure while running the test directory (OS X Debug):
> 831 INFO TEST-UNEXPECTED-FAIL |
> browser/base/content/test/popupNotifications/browser_popupNotification_4.js
> | A promise chain failed to handle a rejection: - at
> chrome://mochitests/content/browser/browser/base/content/test/
> popupNotifications/head.js:119 - TypeError: Assert is null
Never mind this part since it happens without your patch too :(
Assignee | ||
Comment 27•10 years ago
|
||
Comment on attachment 8545282 [details] [diff] [review]
Updated patch with test
(In reply to Matthew N. [:MattN] from comment #25)
> ::: toolkit/modules/PopupNotifications.jsm
> @@ -314,5 @@
> > if (!notification.dismissed) {
> > this.window.getAttention();
> > }
> > - if (notification.anchorElement.parentNode != this.iconBox) {
> > - this._updateAnchorIcon(notifications, notification.anchorElement);
>
> Can you explain why the deletion of the `if` fixes this?
This test checks that the notification is not attached to the location bar. Another way to phrase this is: "if (SocialAPI) ...". This test was added by Shane in bug 1085691 when we mistakenly thought the issue was SocialAPI-only, and didn't want to change the non-SocialAPI behavior at all to reduce risk for a patch we wanted to uplift.
Attachment #8545282 -
Flags: review?(MattN+bmo)
Assignee | ||
Updated•10 years ago
|
Points: --- → 3
Flags: qe-verify?
Flags: qe-verify+
Flags: needinfo?(florian)
Comment 29•10 years ago
|
||
Comment on attachment 8545282 [details] [diff] [review]
Updated patch with test
Review of attachment 8545282 [details] [diff] [review]:
-----------------------------------------------------------------
(In reply to Florian Quèze [:florian] [:flo] from comment #27)
> Comment on attachment 8545282 [details] [diff] [review]
> Updated patch with test
>
> (In reply to Matthew N. [:MattN] from comment #25)
>
> > ::: toolkit/modules/PopupNotifications.jsm
> > @@ -314,5 @@
> > > if (!notification.dismissed) {
> > > this.window.getAttention();
> > > }
> > > - if (notification.anchorElement.parentNode != this.iconBox) {
> > > - this._updateAnchorIcon(notifications, notification.anchorElement);
> >
> > Can you explain why the deletion of the `if` fixes this?
>
> This test checks that the notification is not attached to the location bar.
> Another way to phrase this is: "if (SocialAPI) ...". This test was added by
> Shane in bug 1085691 when we mistakenly thought the issue was
> SocialAPI-only, and didn't want to change the non-SocialAPI behavior at all
> to reduce risk for a patch we wanted to uplift.
Ah, ok, I'm not surprised that it didn't make sense to me as I wasn't thinking of SocialAPI
Attachment #8545282 -
Flags: review?(MattN+bmo) → review+
Assignee | ||
Comment 30•10 years ago
|
||
Updated•10 years ago
|
Iteration: 37.3 - 12 Jan → 38.1 - 26 Jan
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla38
Comment 32•10 years ago
|
||
Reproduced the initial issue on a nightly before the fix and verified on latest Nightly that the indicator is visible on all opened windows across all platforms, Windows 7 64bit, Mac OS X 10.9.5 and Ubuntu 14.04 32bit.
Status: RESOLVED → VERIFIED
status-firefox38:
--- → verified
Updated•1 year ago
|
Product: Toolkit → Toolkit Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•