Open Bug 1378203 Opened 7 years ago Updated 2 years ago

Expose a property nsIBrowserParent.canPresent, to indicate when a tab has set up enough to paint something

Categories

(Core :: DOM: Content Processes, enhancement, P3)

enhancement

Tracking

()

People

(Reporter: mconley, Assigned: mconley)

References

(Blocks 1 open bug)

Details

Attachments

(2 files, 2 obsolete files)

We currently use this hack in tabbrowser.xml where we check to see if a tab has presented before in order to know if we can force paint and do an async tab switch. If it's not presented (and is still showing the tab throbber) we assume that we can show a blank content area and do a very fast tab switch. This works in a few cases, but falls over when a background tab is showing the throbber for a while and the user clicks on it - this shows a brief but annoying white flash. What I think we should do instead is have a new TabChild inform the parent when it has set itself up, and when the underlying top-level PresShell has enough information to potentially paint were it required. We can then expose that value in nsITabParent as canPresent, and we can use that instead of the hasPresented / throbber hack.
Assignee: nobody → mconley
Summary: Expose a propery nsITabParent.canPresent, to indicate when a tab has set up enough to paint something → Expose a property nsITabParent.canPresent, to indicate when a tab has set up enough to paint something
Attachment #8883611 - Flags: review?(wmccloskey)
Attachment #8883612 - Flags: review?(wmccloskey)
Pretty solid orange streak on try. Will try to clear that up and will then re-request review.
Attachment #8883611 - Flags: review?(wmccloskey)
Comment on attachment 8883612 [details] Bug 1378203 - Use canPresent in tabbrowser.xml to determine if we can blank out a tab before switching to it. https://reviewboard.mozilla.org/r/154552/#review175078 Going to cancel review here since I think we're waiting on Mike. I just want to get this out of my queue for now.
Attachment #8883612 - Flags: review?(wmccloskey)
Attachment #8883611 - Attachment is obsolete: true
Attachment #8883612 - Attachment is obsolete: true
Hey Mike, is P3 good for this bug?
Flags: needinfo?(mconley)
Priority: -- → P3
Yep. I do plan on getting back to this, though.
Flags: needinfo?(mconley)

Bug 1534395 changed the name. Mike, do we still want this?

Flags: needinfo?(mconley)
Summary: Expose a property nsITabParent.canPresent, to indicate when a tab has set up enough to paint something → Expose a property nsIBrowserParent.canPresent, to indicate when a tab has set up enough to paint something

I think this might be nice to have someday to help improve the tab switching performance, since it means we can more aggressively force paint when switching to tabs that the user has never seen before.

Flags: needinfo?(mconley)
Severity: normal → S3
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: