Make modal popup windows behave the same as non-modal popup windows (issue #216).
git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@216 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
This commit is contained in:
parent
7ec29b5d87
commit
0419b51036
|
@ -161,27 +161,10 @@ void BrowserWebViewDelegate::runModal() {
|
||||||
|
|
||||||
show(WebKit::WebNavigationPolicyNewWindow);
|
show(WebKit::WebNavigationPolicyNewWindow);
|
||||||
|
|
||||||
CefContext::BrowserList *list;
|
|
||||||
CefContext::BrowserList::const_iterator i;
|
|
||||||
|
|
||||||
_Context->Lock();
|
|
||||||
list = _Context->GetBrowserList();
|
|
||||||
i = list->begin();
|
|
||||||
for (; i != list->end(); ++i) {
|
|
||||||
if (i->get()->IsPopup())
|
|
||||||
EnableWindow(i->get()->UIT_GetMainWndHandle(), FALSE);
|
|
||||||
}
|
|
||||||
_Context->Unlock();
|
|
||||||
|
|
||||||
browser_->UIT_SetIsModal(true);
|
browser_->UIT_SetIsModal(true);
|
||||||
MessageLoop::current()->Run();
|
|
||||||
|
|
||||||
_Context->Lock();
|
// TODO(CEF): Add a handler notification for modal windows so the client can
|
||||||
list = _Context->GetBrowserList();
|
// make the window behave modally.
|
||||||
i = list->begin();
|
|
||||||
for (; i != list->end(); ++i)
|
|
||||||
EnableWindow(i->get()->UIT_GetMainWndHandle(), TRUE);
|
|
||||||
_Context->Unlock();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// WebPluginPageDelegate ------------------------------------------------------
|
// WebPluginPageDelegate ------------------------------------------------------
|
||||||
|
|
Loading…
Reference in New Issue