mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-06-05 21:39:12 +02:00
Add notification for aborted popups (fixes #3776)
Pass a new |popup_id| parameter to OnBeforePopup and call a new OnBeforePopupAborted callback if the popup is aborted before OnAfterCreated is called for the popup browser. Add new CefBrowserHost::GetBrowserByIdentifier and GetOpenerIdentifier methods to assist with retrieval of associated browsers. In cefclient, clean up state when a popup is aborted and close any associated popup browsers when the opener browser is closed. This also works when running with `--use-default-popup`.
This commit is contained in:
@ -174,7 +174,8 @@ class AlloyBrowserHostImpl : public CefBrowserHostBase,
|
||||
DestructionState destruction_state() const { return destruction_state_; }
|
||||
|
||||
// content::WebContentsDelegate methods.
|
||||
void PrintCrossProcessSubframe(content::WebContents* web_contents,
|
||||
void PrintCrossProcessSubframe(
|
||||
content::WebContents* web_contents,
|
||||
const gfx::Rect& rect,
|
||||
int document_cookie,
|
||||
content::RenderFrameHost* subframe_host) const override;
|
||||
@ -317,7 +318,7 @@ class AlloyBrowserHostImpl : public CefBrowserHostBase,
|
||||
void StartAudioCapturer();
|
||||
void OnRecentlyAudibleTimerFired();
|
||||
|
||||
CefWindowHandle opener_;
|
||||
CefWindowHandle opener_window_handle_ = kNullWindowHandle;
|
||||
const bool is_windowless_;
|
||||
CefWindowHandle host_window_handle_ = kNullWindowHandle;
|
||||
|
||||
|
Reference in New Issue
Block a user