summaryrefslogtreecommitdiff
path: root/vcl/source
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2017-11-17 13:08:44 +0000
committerCaolán McNamara <caolanm@redhat.com>2017-11-17 15:03:11 +0100
commitff8722507473328e811cdcd6293f091afe6aa7d3 (patch)
treefe4409c2e867a1d32d9b5d081a619e6715e8ac43 /vcl/source
parent605b01dc591eaa72788be255baf1f9b9dde76414 (diff)
Resolves: tdf#112943 don't close popups on resize if size didn't change
Change-Id: If5331248f69098570c87da060595f5a85721c2d2 Reviewed-on: https://gerrit.libreoffice.org/44882 Tested-by: Xisco Faulí <xiscofauli@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'vcl/source')
-rw-r--r--vcl/source/window/winproc.cxx5
1 files changed, 3 insertions, 2 deletions
diff --git a/vcl/source/window/winproc.cxx b/vcl/source/window/winproc.cxx
index 81cf9f67765f..bed6fcc45854 100644
--- a/vcl/source/window/winproc.cxx
+++ b/vcl/source/window/winproc.cxx
@@ -1574,7 +1574,8 @@ static void KillOwnPopups( vcl::Window const * pWindow )
void ImplHandleResize( vcl::Window* pWindow, long nNewWidth, long nNewHeight )
{
- if( pWindow->GetStyle() & (WB_MOVEABLE|WB_SIZEABLE) )
+ const bool bChanged = (nNewWidth != pWindow->GetOutputWidthPixel()) || (nNewHeight != pWindow->GetOutputHeightPixel());
+ if (bChanged && pWindow->GetStyle() & (WB_MOVEABLE|WB_SIZEABLE))
{
KillOwnPopups( pWindow );
if( pWindow->ImplGetWindow() != ImplGetSVData()->maHelpData.mpHelpWin )
@@ -1586,7 +1587,7 @@ void ImplHandleResize( vcl::Window* pWindow, long nNewWidth, long nNewHeight )
pWindow->ImplGetWindow()->ImplGetWindowImpl()->mbAllResize
)
{
- if ( (nNewWidth != pWindow->GetOutputWidthPixel()) || (nNewHeight != pWindow->GetOutputHeightPixel()) )
+ if (bChanged)
{
pWindow->mnOutWidth = nNewWidth;
pWindow->mnOutHeight = nNewHeight;