diff options
author | Maxim Monastirsky <momonasmon@gmail.com> | 2018-10-25 16:33:17 +0300 |
---|---|---|
committer | Maxim Monastirsky <momonasmon@gmail.com> | 2018-10-26 00:31:26 +0200 |
commit | 96cf06c947838120e37f3fbb4d0543dd882cb20c (patch) | |
tree | 691edabf98912e73838bfcaaf744b0c47ed9e445 | |
parent | f9acea526b9aeb3cf450cd7ee43bd969385865db (diff) |
tdf#120907 Arrow keys don't work in palette list
For a docking window which reparented to a floating window
via DockingManager, Window::GetParent() won't find the
floating window, because WindowImpl::mpRealParent points
to the previous parent (e.g. the toolbar). What we need is
to check WindowImpl::mpParent instead.
Change-Id: Ibdc5e29b7b8db37f9cbea65b3d7fbe39de334319
Reviewed-on: https://gerrit.libreoffice.org/62361
Tested-by: Jenkins
Reviewed-by: Maxim Monastirsky <momonasmon@gmail.com>
-rw-r--r-- | vcl/source/window/winproc.cxx | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/vcl/source/window/winproc.cxx b/vcl/source/window/winproc.cxx index 7b841781c435..32f52d1df45c 100644 --- a/vcl/source/window/winproc.cxx +++ b/vcl/source/window/winproc.cxx @@ -821,6 +821,13 @@ static vcl::Window* ImplGetKeyInputWindow( vcl::Window* pWindow ) if (static_cast<FloatingWindow *>(pChild)->GrabsFocus()) break; } + else if (pChild->ImplGetWindowImpl()->mbDockWin) + { + vcl::Window* pParent = pChild->GetWindow(GetWindowType::RealParent); + if (pParent && pParent->ImplGetWindowImpl()->mbFloatWin && + static_cast<FloatingWindow *>(pParent)->GrabsFocus()) + break; + } pChild = pChild->GetParent(); } |