mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-06-05 21:39:12 +02:00
chrome: Standardize fullscreen transition behavor/callbacks (fixes #3571)
Use the same code path for all fullscreen transitions so that Chrome UI updates correctly. All user-initiated fullscreen transitions now result in CefWindowDelegate::OnWindowFullscreenTransition callbacks.
This commit is contained in:
@@ -141,10 +141,7 @@ bool CefBrowserViewImpl::HandleKeyboardEvent(
|
||||
}
|
||||
|
||||
// Give the CefWindowDelegate a chance to handle the event.
|
||||
CefRefPtr<CefWindow> window =
|
||||
view_util::GetWindowFor(root_view()->GetWidget());
|
||||
CefWindowImpl* window_impl = static_cast<CefWindowImpl*>(window.get());
|
||||
if (window_impl) {
|
||||
if (auto* window_impl = cef_window()) {
|
||||
CefKeyEvent cef_event;
|
||||
if (browser_util::GetCefKeyEvent(event, cef_event) &&
|
||||
window_impl->OnKeyEvent(cef_event)) {
|
||||
@@ -319,6 +316,12 @@ ChromeBrowserView* CefBrowserViewImpl::chrome_browser_view() const {
|
||||
return static_cast<ChromeBrowserView*>(root_view());
|
||||
}
|
||||
|
||||
CefWindowImpl* CefBrowserViewImpl::cef_window() const {
|
||||
CefRefPtr<CefWindow> window =
|
||||
view_util::GetWindowFor(root_view()->GetWidget());
|
||||
return static_cast<CefWindowImpl*>(window.get());
|
||||
}
|
||||
|
||||
bool CefBrowserViewImpl::HandleAccelerator(
|
||||
const content::NativeWebKeyboardEvent& event,
|
||||
views::FocusManager* focus_manager) {
|
||||
|
Reference in New Issue
Block a user