diff options
author | Caolán McNamara <caolanm@redhat.com> | 2015-03-04 16:29:43 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2015-03-04 17:01:52 +0000 |
commit | 429ff8877a0a8c864b6b1fc227f6efccb61b5be6 (patch) | |
tree | 4e04d30ec3cf0044a7cbefc7ca7c20c38ad67e37 /sd/source/ui/dlg/RemoteDialogClientBox.cxx | |
parent | 2567d8040d060525a1125a36e4e3704421833787 (diff) |
V813: Decreased performance
Change-Id: Ib40140b97b53ed7affaf3a209a0a12a60ee7434c
Diffstat (limited to 'sd/source/ui/dlg/RemoteDialogClientBox.cxx')
-rw-r--r-- | sd/source/ui/dlg/RemoteDialogClientBox.cxx | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/sd/source/ui/dlg/RemoteDialogClientBox.cxx b/sd/source/ui/dlg/RemoteDialogClientBox.cxx index ac27e7717dd8..614a2b18e730 100644 --- a/sd/source/ui/dlg/RemoteDialogClientBox.cxx +++ b/sd/source/ui/dlg/RemoteDialogClientBox.cxx @@ -271,16 +271,16 @@ void ClientBox::selectEntry( const long nPos ) guard.clear(); } -void ClientBox::DrawRow( const Rectangle& rRect, const TClientBoxEntry pEntry ) +void ClientBox::DrawRow( const Rectangle& rRect, const TClientBoxEntry& rEntry ) { const StyleSettings& rStyleSettings = GetSettings().GetStyleSettings(); - if ( pEntry->m_bActive ) + if ( rEntry->m_bActive ) SetTextColor( rStyleSettings.GetHighlightTextColor() ); else SetTextColor( rStyleSettings.GetFieldTextColor() ); - if ( pEntry->m_bActive ) + if ( rEntry->m_bActive ) { SetLineColor(); SetFillColor( rStyleSettings.GetHighlightColor() ); @@ -311,25 +311,25 @@ void ClientBox::DrawRow( const Rectangle& rRect, const TClientBoxEntry pEntry ) long nMaxTitleWidth = rRect.GetWidth() - ICON_OFFSET; nMaxTitleWidth -= ( 2 * SMALL_ICON_SIZE ) + ( 4 * SPACE_BETWEEN ); - long aTitleWidth = GetTextWidth( pEntry->m_pClientInfo->mName ) + (aTextHeight / 3); + long aTitleWidth = GetTextWidth( rEntry->m_pClientInfo->mName ) + (aTextHeight / 3); aPos = rRect.TopLeft() + Point( ICON_OFFSET, TOP_OFFSET ); if ( aTitleWidth > nMaxTitleWidth ) { aTitleWidth = nMaxTitleWidth - (aTextHeight / 3); - OUString aShortTitle = GetEllipsisString( pEntry->m_pClientInfo->mName, + OUString aShortTitle = GetEllipsisString( rEntry->m_pClientInfo->mName, aTitleWidth ); DrawText( aPos, aShortTitle ); aTitleWidth += (aTextHeight / 3); } else - DrawText( aPos, pEntry->m_pClientInfo->mName ); + DrawText( aPos, rEntry->m_pClientInfo->mName ); SetFont( aStdFont ); aPos.Y() += aTextHeight; - if ( pEntry->m_bActive ) + if ( rEntry->m_bActive ) { OUString sPinText(SD_RESSTR(STR_ENTER_PIN)); DrawText( m_sPinTextRect, @@ -635,18 +635,18 @@ long ClientBox::addEntry( ::boost::shared_ptr<ClientInfo> pClientInfo ) { long nPos = 0; - TClientBoxEntry pEntry( new ClientBoxEntry( pClientInfo ) ); + TClientBoxEntry xEntry( new ClientBoxEntry( pClientInfo ) ); ::osl::ClearableMutexGuard guard(m_entriesMutex); if ( m_vEntries.empty() ) { - m_vEntries.push_back( pEntry ); + m_vEntries.push_back( xEntry ); } else { -// if ( !FindEntryPos( pEntry, 0, m_vEntries.size()-1, nPos ) ) +// if ( !FindEntryPos( xEntry, 0, m_vEntries.size()-1, nPos ) ) // { - m_vEntries.insert( m_vEntries.begin()+nPos, pEntry ); + m_vEntries.insert( m_vEntries.begin()+nPos, xEntry ); // } // else if ( !m_bInCheckMode ) // { |