Closed Bug 1345773 Opened 4 years ago Closed 4 years ago

Don't call ctrlTab.updatePreview for TabAttrModified events for the "select" attribute

Categories

(Firefox :: Tabbed Browser, enhancement)

enhancement
Not set
normal

Tracking

()

RESOLVED FIXED
Firefox 55
Tracking Status
firefox55 --- fixed

People

(Reporter: dao, Assigned: subhdeepsaha)

References

Details

(Keywords: good-first-bug, Whiteboard: [good first bug][lang=js])

Attachments

(1 file)

We currently call updatePreview when any of these tab attributes change: label, busy, image, selected

However, a "select" attribute change doesn't really affect previews, so we should remove this from the list.

The code is here: https://hg.mozilla.org/mozilla-central/annotate/58753259bfeb3b818eac7870871b0aae1f8de64a/browser/base/content/browser-ctrlTab.js#l476
Depends on: 1342025
Comment on attachment 8845496 [details]
Bug 1345773 - Don't call updatePreview for TabAttrModified events for the "select" attribute,

https://reviewboard.mozilla.org/r/118646/#review120558

::: commit-message-8fca4:1
(Diff revision 1)
> +Bug:1345773 Removed the 'selected' attribute from list r=dao

Please use this format:

Bug 1345773 - Don't call updatePreview for TabAttrModified events for the "select" attribute, r=dao

::: browser/base/content/browser-ctrlTab.js:477
(Diff revision 1)
>      switch (event.type) {
>        case "SSWindowRestored":
>          this._initRecentlyUsedTabs();
>          break;
>        case "TabAttrModified":
>          // tab attribute modified (i.e. label, busy, image, selected)

Could you please update this comment too?

Looks good otherwise. Thanks!
Attachment #8845496 - Flags: review?(dao+bmo) → review-
Assignee: nobody → subhdeepsaha
Comment on attachment 8845496 [details]
Bug 1345773 - Don't call updatePreview for TabAttrModified events for the "select" attribute,

https://reviewboard.mozilla.org/r/118646/#review120566

Perfect, thanks!
Attachment #8845496 - Flags: review?(dao+bmo) → review+
Pushed by dgottwald@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/c6bc677cfa1a
Don't call updatePreview for TabAttrModified events for the "select" attribute, r=dao
https://hg.mozilla.org/mozilla-central/rev/c6bc677cfa1a
Status: NEW → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 55
You need to log in before you can comment on or make changes to this bug.