diff options
author | Caolán McNamara <caolanm@redhat.com> | 2016-09-27 15:18:28 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2016-09-27 15:18:28 +0100 |
commit | 0d56cc15803965a1be6991a3630076f7ccf67817 (patch) | |
tree | 919bbb909cad222d54c5e8416f069e88b2ee484e | |
parent | 95a6d24ed7a231c42ccd608fb93cbed989a62e3a (diff) |
detangle code that now looks silly since...
commit 9b7dfb10641ba7978ffcbd1db0507163411ae027
Author: Caolán McNamara <caolanm@redhat.com>
Date: Thu Jun 9 16:52:21 2016 +0100
EndSaveFocus does nothing on the !bRestore case
removed the code that made it look like it made sense
Change-Id: I2e7280fd6643e86d65cba04c8302be099d6f3d0e
-rw-r--r-- | vcl/source/window/menufloatingwindow.cxx | 18 |
1 files changed, 6 insertions, 12 deletions
diff --git a/vcl/source/window/menufloatingwindow.cxx b/vcl/source/window/menufloatingwindow.cxx index 715398d01a41..f4adcf0aada5 100644 --- a/vcl/source/window/menufloatingwindow.cxx +++ b/vcl/source/window/menufloatingwindow.cxx @@ -395,7 +395,6 @@ void MenuFloatingWindow::Execute() pSVData->maAppData.mpActivePopupMenu = static_cast<PopupMenu*>(pMenu.get()); bInExecute = true; -// bCallingSelect = false; while ( bInExecute ) Application::Yield(); @@ -405,19 +404,14 @@ void MenuFloatingWindow::Execute() void MenuFloatingWindow::StopExecute() { - VclPtr<vcl::Window> xFocusId; - // restore focus - // (could have been restored in Select) - if ( xSaveFocusId != nullptr ) + VclPtr<vcl::Window> xFocusId(xSaveFocusId); + // restore focus (could have been restored in Select) + if (xFocusId != nullptr) { - xFocusId = xSaveFocusId; - if ( xFocusId != nullptr ) - { - xSaveFocusId = nullptr; - ImplGetSVData()->maWinData.mbNoDeactivate = false; - } + xSaveFocusId = nullptr; + ImplGetSVData()->maWinData.mbNoDeactivate = false; } - ImplEndPopupMode( FloatWinPopupEndFlags::NONE, xFocusId ); + ImplEndPopupMode(FloatWinPopupEndFlags::NONE, xFocusId); aHighlightChangedTimer.Stop(); bInExecute = false; |