summaryrefslogtreecommitdiff
path: root/vcl/source
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2015-10-15 12:28:31 +0200
committerNoel Grandin <noel@peralex.com>2015-10-15 12:29:01 +0200
commit0e8a40e8b8c883611b6d34e47dc6e33ba60e0f91 (patch)
tree92e49014bb9b368309c98d85dcfbd2f673e23d54 /vcl/source
parentcfc7307a23eed561152c1b016cd0ec22bc7af145 (diff)
calling IsSet() before Call() on Link<> is unnecessary
the Call() already does a check Found with: git grep -A 1 -w 'IsSet()' | grep -B 1 '.Call(' | grep ':' | cut -d ':' -f 1 Change-Id: Ia7248f5d62640b75f705e539c3d1183e39c0d847
Diffstat (limited to 'vcl/source')
-rw-r--r--vcl/source/gdi/impvect.cxx2
-rw-r--r--vcl/source/window/split.cxx3
-rw-r--r--vcl/source/window/toolbox.cxx9
3 files changed, 5 insertions, 9 deletions
diff --git a/vcl/source/gdi/impvect.cxx b/vcl/source/gdi/impvect.cxx
index 7e3c7dd2a791..33dfccc3436d 100644
--- a/vcl/source/gdi/impvect.cxx
+++ b/vcl/source/gdi/impvect.cxx
@@ -42,7 +42,7 @@
#define VECT_MAP( _def_pIn, _def_pOut, _def_nVal ) _def_pOut[_def_nVal]=(_def_pIn[_def_nVal]=((_def_nVal)*4L)+1L)+5L;
#define BACK_MAP( _def_nVal ) ((((_def_nVal)+2)>>2)-1)
#define VECT_PROGRESS( _def_pProgress, _def_nVal ) \
- if(_def_pProgress && _def_pProgress->IsSet()) \
+ if(_def_pProgress) \
(_def_pProgress->Call(_def_nVal));
class ImplVectMap;
diff --git a/vcl/source/window/split.cxx b/vcl/source/window/split.cxx
index af33e4f5d98c..115ec625e159 100644
--- a/vcl/source/window/split.cxx
+++ b/vcl/source/window/split.cxx
@@ -450,8 +450,7 @@ void Splitter::Split()
void Splitter::EndSplit()
{
- if ( maEndSplitHdl.IsSet() )
- maEndSplitHdl.Call( this );
+ maEndSplitHdl.Call( this );
}
void Splitter::Splitting( Point& /* rSplitPos */ )
diff --git a/vcl/source/window/toolbox.cxx b/vcl/source/window/toolbox.cxx
index 84a28c84c4e4..8b4308a9503a 100644
--- a/vcl/source/window/toolbox.cxx
+++ b/vcl/source/window/toolbox.cxx
@@ -4421,8 +4421,7 @@ bool ToolBox::Notify( NotifyEvent& rNEvt )
void ToolBox::Command( const CommandEvent& rCEvt )
{
- if ( maCommandHandler.IsSet() )
- maCommandHandler.Call( &rCEvt );
+ maCommandHandler.Call( &rCEvt );
// depict StartDrag on MouseButton/Left/Alt
if ( (rCEvt.GetCommand() == CommandEventId::StartDrag) && rCEvt.IsMouseEvent() &&
@@ -4515,8 +4514,7 @@ void ToolBox::StateChanged( StateChangedType nType )
Invalidate();
}
- if ( maStateChangedHandler.IsSet() )
- maStateChangedHandler.Call( &nType );
+ maStateChangedHandler.Call( &nType );
}
void ToolBox::DataChanged( const DataChangedEvent& rDCEvt )
@@ -4535,8 +4533,7 @@ void ToolBox::DataChanged( const DataChangedEvent& rDCEvt )
Invalidate();
}
- if ( maDataChangedHandler.IsSet() )
- maDataChangedHandler.Call( &rDCEvt );
+ maDataChangedHandler.Call( &rDCEvt );
}
bool ToolBox::PrepareToggleFloatingMode()