mac: Fix accelerators in overlay BrowserView (see #3188)
CefWindowImpl::CanHandleAccelerators was returning false for accelerators triggered in the overlay BrowserView due to IsWindowKey (called from NativeWidgetMac::IsActive) returning false. View::CanHandleAccelerators, on the other hand, only checks IsActive for Aura (non-MacOS) windows. We therefore delegate to the View implementation for consistent handling.
This commit is contained in:
parent
0255c2e7ac
commit
43fc50a89e
|
@ -500,8 +500,8 @@ bool CefWindowImpl::AcceleratorPressed(const ui::Accelerator& accelerator) {
|
|||
}
|
||||
|
||||
bool CefWindowImpl::CanHandleAccelerators() const {
|
||||
if (delegate() && widget_) {
|
||||
return widget_->IsActive();
|
||||
if (delegate() && widget_ && root_view()) {
|
||||
return root_view()->CanHandleAccelerators();
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue