[Libreoffice-commits] core.git: vcl/source
Ras-al-Ghul
dipankar1995 at gmail.com
Sat Jan 9 12:36:12 PST 2016
vcl/source/window/toolbox.cxx | 24 ++++++++----------------
1 file changed, 8 insertions(+), 16 deletions(-)
New commits:
commit 79af5b389b42284ddea3e486c17ace4776bd8e4c
Author: Ras-al-Ghul <dipankar1995 at gmail.com>
Date: Fri Jan 8 01:42:50 2016 +0530
tdf#96888 Kill internal vcl dog-tags ...
Did some changes to toolbox.cxx file. Patch No. 19
Change-Id: Ia66d208230c8ffeca095af60b311510a826321d8
Reviewed-on: https://gerrit.libreoffice.org/21236
Tested-by: Jenkins <ci at libreoffice.org>
Reviewed-by: Michael Meeks <michael.meeks at collabora.com>
diff --git a/vcl/source/window/toolbox.cxx b/vcl/source/window/toolbox.cxx
index 3cd2cab..0aa3f19 100644
--- a/vcl/source/window/toolbox.cxx
+++ b/vcl/source/window/toolbox.cxx
@@ -3543,12 +3543,10 @@ bool ToolBox::ImplHandleMouseButtonUp( const MouseEvent& rMEvt, bool bCancel )
if ( !(pItem->mnBits & ToolBoxItemBits::REPEAT) )
{
// prevent from being destroyed in the select handler
- ImplDelData aDelData;
- ImplAddDel( &aDelData );
+ VclPtr<vcl::Window> xWindow = this;
Select();
- if ( aDelData.IsDead() )
+ if ( xWindow->IsDisposed() )
return true;
- ImplRemoveDel( &aDelData );
}
}
@@ -4048,18 +4046,16 @@ void ToolBox::MouseButtonUp( const MouseEvent& rMEvt )
void ToolBox::Tracking( const TrackingEvent& rTEvt )
{
- ImplDelData aDelData;
- ImplAddDel( &aDelData );
+ VclPtr<vcl::Window> xWindow = this;
if ( rTEvt.IsTrackingEnded() )
ImplHandleMouseButtonUp( rTEvt.GetMouseEvent(), rTEvt.IsTrackingCanceled() );
else
ImplHandleMouseMove( rTEvt.GetMouseEvent(), rTEvt.IsTrackingRepeat() );
- if ( aDelData.IsDead() )
+ if ( xWindow->IsDisposed() )
// toolbox was deleted
return;
- ImplRemoveDel( &aDelData );
DockingWindow::Tracking( rTEvt );
}
@@ -5044,12 +5040,10 @@ bool ToolBox::ImplActivateItem( vcl::KeyCode aKeyCode )
Click();
// #107776# we might be destroyed in the selecthandler
- ImplDelData aDelData;
- ImplAddDel( &aDelData );
+ VclPtr<vcl::Window> xWindow = this;
Select();
- if ( aDelData.IsDead() )
+ if ( xWindow->IsDisposed() )
return bRet;
- ImplRemoveDel( &aDelData );
Deactivate();
mbIsKeyEvent = false;
@@ -5140,8 +5134,7 @@ void ToolBox::KeyInput( const KeyEvent& rKEvt )
bool bGrabFocusToDocument = false;
// #107776# we might be destroyed in the keyhandler
- ImplDelData aDelData;
- ImplAddDel( &aDelData );
+ VclPtr<vcl::Window> xWindow = this;
switch ( nCode )
{
@@ -5288,9 +5281,8 @@ void ToolBox::KeyInput( const KeyEvent& rKEvt )
}
}
- if ( aDelData.IsDead() )
+ if ( xWindow->IsDisposed() )
return;
- ImplRemoveDel( &aDelData );
// #107251# move focus away if this toolbox was disabled during keyinput
if (HasFocus() && mpData->mbKeyInputDisabled && bParentIsContainer)
More information about the Libreoffice-commits
mailing list