14
edits
|  (add e10s content) |  (update content for e10s) | ||
| Line 49: | Line 49: | ||
| ==== Exiting Fullscreen Unexpectedly ==== | ==== Exiting Fullscreen Unexpectedly ==== | ||
| (page closure / fullscreen element removal) | (page closure / navigation / fullscreen element removal) | ||
| # two cases: | # two cases: | ||
| #* for page closure, nsDocument::OnPageHide()   | #* for page closure and navigation, nsDocument::OnPageHide()   | ||
| #* for element removal, Element::UnbindFromTree() | #* for element removal, Element::UnbindFromTree() | ||
| # calls nsIDocument::ExitFullscreenInDocTree() which changes the document state | # calls nsIDocument::ExitFullscreenInDocTree() which changes the document state | ||
| Line 96: | Line 96: | ||
| # in the content process | # in the content process | ||
| ## tab-content.js calls nsIDocument::ExitFullscreenInDocTree() which changes the document state | ## tab-content.js calls nsIDocument::ExitFullscreenInDocTree() which changes the document state | ||
| ==== Exiting Fullscreen by User ==== | |||
| Since user always uses the chrome to exit fullscreen | |||
| * The parent process part is the same as [[#Exiting Fullscreen by User|Non-E10S / Exiting Fullscreen by User]] | |||
| * The content process only has the last step in [[#Exiting Fullscreen by Content 2|E10S / Exiting Fullscreen by Content]] above | |||
| ==== Exiting Fullscreen Unexpectedly ==== | |||
| (navigation / fullscreen element removal) | |||
| # in the content process: | |||
| ## two cases: | |||
| ##* for navigation, nsDocument::OnPageHide()  | |||
| ##* for element removal, Element::UnbindFromTree() | |||
| ## calls nsIDocument::ExitFullscreenInDocTree() which changes the document state | |||
| ##* this step also dispatches '''MozDOMFullscreen:Exited''' to the chrome | |||
| ## tab-content.js sends async message "DOMFullscreen:Exit" | |||
| # in the parent process: | |||
| ## browser-fullScreen.js calls nsDocument::RestorePreviousFullScreenState() | |||
| ## calls nsGlobalWindow::SetFullScreenInternal() | |||
| ## calls widget to leave fullscreen | |||
| ## ''(async)'' triggers nsGlobalWindow::FinishFullscreenChange() when the window exits fullscreen | |||
| ## calls nsIDocument::ExitFullscreenInDocTree() which changes the document state | |||
| === Browser Element === | === Browser Element === | ||
edits