[Libreoffice-commits] core.git: vcl/source
Ras-al-Ghul
dipankar1995 at gmail.com
Sat Jan 9 04:15:00 PST 2016
vcl/source/control/button.cxx | 33 ++++++++++++---------------------
1 file changed, 12 insertions(+), 21 deletions(-)
New commits:
commit 269f953aaa46d7dce26d061ce487d2f76a16a34e
Author: Ras-al-Ghul <dipankar1995 at gmail.com>
Date: Sat Jan 9 02:57:47 2016 +0530
tdf#96888 Kill internal vcl dog-tags ...
This is a cleanup to https://gerrit.libreoffice.org/#/c/21230/
Change-Id: I3999c8af1b906105a448e61353a839237aec7098
Reviewed-on: https://gerrit.libreoffice.org/21276
Tested-by: Jenkins <ci at libreoffice.org>
Reviewed-by: Michael Meeks <michael.meeks at collabora.com>
diff --git a/vcl/source/control/button.cxx b/vcl/source/control/button.cxx
index d831794..fd0beb4 100644
--- a/vcl/source/control/button.cxx
+++ b/vcl/source/control/button.cxx
@@ -2272,15 +2272,12 @@ void RadioButton::ImplUncheckAllOther()
// iterate over radio button group and checked buttons
for (auto aI = aGroup.begin(), aEnd = aGroup.end(); aI != aEnd; ++aI)
{
- RadioButton *pWindow = *aI;
+ VclPtr<RadioButton> pWindow = *aI;
if ( pWindow->IsChecked() )
{
- ImplDelData aDelData;
- pWindow->ImplAddDel( &aDelData );
pWindow->SetState( false );
- if ( aDelData.IsDead() )
+ if ( pWindow->IsDisposed() )
return;
- pWindow->ImplRemoveDel( &aDelData );
}
// not inside if clause to always remove wrongly set WB_TABSTOPS
@@ -2295,24 +2292,22 @@ void RadioButton::ImplCallClick( bool bGrabFocus, GetFocusFlags nFocusFlags )
mpWindowImpl->mnStyle |= WB_TABSTOP;
Invalidate();
Update();
- ImplDelData aDelData;
- ImplAddDel( &aDelData );
+ VclPtr<vcl::Window> xWindow = this;
if ( mbRadioCheck )
ImplUncheckAllOther();
- if ( aDelData.IsDead() )
+ if ( xWindow->IsDisposed() )
return;
if ( bGrabFocus )
ImplGrabFocus( nFocusFlags );
- if ( aDelData.IsDead() )
+ if ( xWindow->IsDisposed() )
return;
if ( mbStateChanged )
Toggle();
- if ( aDelData.IsDead() )
+ if ( xWindow->IsDisposed() )
return;
Click();
- if ( aDelData.IsDead() )
+ if ( xWindow->IsDisposed() )
return;
- ImplRemoveDel( &aDelData );
mbStateChanged = false;
}
@@ -2737,17 +2732,15 @@ void RadioButton::Check( bool bCheck )
if ( mbChecked != bCheck )
{
mbChecked = bCheck;
- ImplDelData aDelData;
- ImplAddDel( &aDelData );
+ VclPtr<vcl::Window> xWindow = this;
CompatStateChanged( StateChangedType::State );
- if ( aDelData.IsDead() )
+ if ( xWindow->IsDisposed() )
return;
if ( bCheck && mbRadioCheck )
ImplUncheckAllOther();
- if ( aDelData.IsDead() )
+ if ( xWindow->IsDisposed() )
return;
Toggle();
- ImplRemoveDel( &aDelData );
}
}
@@ -3231,17 +3224,15 @@ void CheckBox::ImplCheck()
eNewState = TRISTATE_FALSE;
meState = eNewState;
- ImplDelData aDelData;
- ImplAddDel( &aDelData );
+ VclPtr<vcl::Window> xWindow = this;
if( (GetStyle() & WB_EARLYTOGGLE) )
Toggle();
Invalidate();
Update();
if( ! (GetStyle() & WB_EARLYTOGGLE) )
Toggle();
- if ( aDelData.IsDead() )
+ if ( xWindow->IsDisposed() )
return;
- ImplRemoveDel( &aDelData );
Click();
}
More information about the Libreoffice-commits
mailing list