From 3acbb63833b8a593f879dbc602046f72c0a0aea9 Mon Sep 17 00:00:00 2001 From: Isamu Mogi Date: Fri, 7 Jun 2013 19:28:14 +0900 Subject: [PATCH] fdo#65450: No GrabFocus() during rollover on MenuBar Calling GrabFocus() by background window's MenuBarWindow seems to be illegal for vcl and also that is not platform's default UI behavior. Change-Id: Icc7f98024e489ed7ec6a9405190cc41b292ba76d --- vcl/source/window/menu.cxx | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/vcl/source/window/menu.cxx b/vcl/source/window/menu.cxx index 9b4b32f..8ac6dbc 100644 --- a/vcl/source/window/menu.cxx +++ b/vcl/source/window/menu.cxx @@ -5515,11 +5515,12 @@ void MenuBarWindow::ChangeHighlightItem( sal_uInt16 n, sal_Bool bSelectEntry, sa pMenu->ImplCallHighlight( nHighlightedItem ); if( mbAutoPopup ) + { ImplCreatePopup( bSelectEntry ); - - // #58935# #73659# Focus, if no popup underneath... - if ( bJustActivated && !pActivePopup ) - GrabFocus(); + // #58935# #73659# Focus, if no popup underneath... + if ( bJustActivated && !pActivePopup ) + GrabFocus(); + } } void MenuBarWindow::HighlightItem( sal_uInt16 nPos, sal_Bool bHighlight ) -- 1.8.1.2