summaryrefslogtreecommitdiff
path: root/framework/source/uielement/edittoolbarcontroller.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'framework/source/uielement/edittoolbarcontroller.cxx')
-rw-r--r--framework/source/uielement/edittoolbarcontroller.cxx24
1 files changed, 12 insertions, 12 deletions
diff --git a/framework/source/uielement/edittoolbarcontroller.cxx b/framework/source/uielement/edittoolbarcontroller.cxx
index 2e6164181072..5b6cd39cd45d 100644
--- a/framework/source/uielement/edittoolbarcontroller.cxx
+++ b/framework/source/uielement/edittoolbarcontroller.cxx
@@ -189,20 +189,20 @@ bool EditToolbarController::PreNotify( NotifyEvent const & rNEvt )
void EditToolbarController::executeControlCommand( const css::frame::ControlCommand& rControlCommand )
{
- if ( rControlCommand.Command.startsWith( "SetText" ))
+ if ( !rControlCommand.Command.startsWith( "SetText" ))
+ return;
+
+ for ( sal_Int32 i = 0; i < rControlCommand.Arguments.getLength(); i++ )
{
- for ( sal_Int32 i = 0; i < rControlCommand.Arguments.getLength(); i++ )
+ if ( rControlCommand.Arguments[i].Name.startsWith( "Text" ))
{
- if ( rControlCommand.Arguments[i].Name.startsWith( "Text" ))
- {
- OUString aText;
- rControlCommand.Arguments[i].Value >>= aText;
- m_pEditControl->SetText( aText );
-
- // send notification
- notifyTextChanged( aText );
- break;
- }
+ OUString aText;
+ rControlCommand.Arguments[i].Value >>= aText;
+ m_pEditControl->SetText( aText );
+
+ // send notification
+ notifyTextChanged( aText );
+ break;
}
}
}