diff options
author | Caolán McNamara <caolanm@redhat.com> | 2015-05-07 16:28:42 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2015-05-07 16:30:51 +0100 |
commit | d6e5c52cb20334721acd96b1e550ee6df0714e9e (patch) | |
tree | 1864221e21380627949e3db36ae24e1a87969da3 /vcl | |
parent | da49275807c8cf1dd7362a531f321f9f756e82d1 (diff) |
NoParent condition reversed
regression from...
commit 39078c247d31674544901f8449f5141185f79f7f
Author: Noel Grandin <noel@peralex.com>
Date: Wed May 6 14:07:17 2015 +0200
cleanup DIALOG_NO_PARENT, follow on to tdf#91090
remove the DIALOG_NO_PARENT abomination and replace it with a flags
parameter
Change-Id: I1955531b41b01623ca94155c60794ae1771849ff
Diffstat (limited to 'vcl')
-rw-r--r-- | vcl/source/window/dialog.cxx | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/vcl/source/window/dialog.cxx b/vcl/source/window/dialog.cxx index a2dbdac3ad4e..6f4bb7ec2303 100644 --- a/vcl/source/window/dialog.cxx +++ b/vcl/source/window/dialog.cxx @@ -364,8 +364,9 @@ void Dialog::ImplInit( vcl::Window* pParent, WinBits nStyle, InitFlag eFlag ) // Now, all Dialogs are per default system windows !!! nStyle |= WB_SYSTEMWINDOW; - // parent is NULL: get the default Dialog parent - if ( !pParent ) + if (eFlag == InitFlag::NoParent) + pParent = NULL; + else if (!pParent) // parent is NULL: get the default Dialog parent { pParent = Application::GetDefDialogParent(); if ( !pParent && !(nStyle & WB_SYSTEMWINDOW) ) @@ -392,8 +393,6 @@ void Dialog::ImplInit( vcl::Window* pParent, WinBits nStyle, InitFlag eFlag ) } } } - else if( eFlag == InitFlag::Default ) - pParent = NULL; if ( !pParent || (nStyle & WB_SYSTEMWINDOW) || (pParent->mpWindowImpl->mpFrameData->mbNeedSysWindow && !(nSysWinMode & SystemWindowFlags::NOAUTOMODE)) || |