exit tab fullscreen on destroy

This commit is contained in:
bridiver 2016-08-26 15:29:39 -07:00
parent 307b504eb4
commit 4532114965

View file

@ -775,6 +775,8 @@ bool WebContents::OnMessageReceived(const IPC::Message& message) {
// be destroyed on close, and WebContentsDestroyed would be called for it, so
// we need to make sure the api::WebContents is also deleted.
void WebContents::WebContentsDestroyed() {
// clear out tab fullscreen state
ExitFullscreenModeForTab(web_contents());
// This event is only for internal use, which is emitted when WebContents is
// being destroyed.
Emit("will-destroy");