diff --git a/svx/source/tbxctrls/tbcontrl.cxx b/svx/source/tbxctrls/tbcontrl.cxx index d1c26ba0f28b..2f8a09ee40d1 100644 --- a/svx/source/tbxctrls/tbcontrl.cxx +++ b/svx/source/tbxctrls/tbcontrl.cxx @@ -261,6 +261,7 @@ private: protected: virtual void GetFocus() override; + virtual void KeyInput( const KeyEvent& rKEvt ) override; public: SvxFrameWindow_Impl( svt::ToolboxController& rController, vcl::Window* pParentWindow ); @@ -1660,10 +1661,13 @@ void SvxFrameWindow_Impl::dispose() void SvxFrameWindow_Impl::GetFocus() { if (aFrameSet) - { - aFrameSet->GrabFocus(); aFrameSet->StartSelection(); - } +} + +void SvxFrameWindow_Impl::KeyInput( const KeyEvent& rKEvt ) +{ + aFrameSet->GrabFocus(); + aFrameSet->KeyInput( rKEvt ); } void SvxFrameWindow_Impl::DataChanged( const DataChangedEvent& rDCEvt ) diff --git a/vcl/source/window/dockmgr.cxx b/vcl/source/window/dockmgr.cxx index 497d316de133..cf93ac4b2e5b 100644 --- a/vcl/source/window/dockmgr.cxx +++ b/vcl/source/window/dockmgr.cxx @@ -1089,11 +1089,11 @@ void ImplDockingWindowWrapper::StartPopupMode( ToolBox *pParentToolBox, FloatWin mpFloatWin->StartPopupMode( pParentToolBox, nFlags ); GetWindow()->Show(); - if( bIsToolBox && pParentToolBox->IsKeyEvent() ) + if( pParentToolBox->IsKeyEvent() ) { // send HOME key to subtoolbar in order to select first item KeyEvent aEvent( 0, vcl::KeyCode( KEY_HOME ) ); - mpFloatWin->KeyInput(aEvent); + GetWindow()->KeyInput(aEvent); } }