summaryrefslogtreecommitdiff
path: root/vcl/osx/printaccessoryview.mm
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2014-05-14 20:52:42 +0200
committerStephan Bergmann <sbergman@redhat.com>2014-05-14 20:52:42 +0200
commit9f2217fd8a62a3c1f560fc26e6d56e4cade30ca2 (patch)
tree30a6f7bd175e00d324c47b355b6b94bd44f7a2e7 /vcl/osx/printaccessoryview.mm
parentd459c3648c28981250809ae3e3cf02dde7157f51 (diff)
loplugin:passsequencebyref
Change-Id: I3a6656117b2d2aa9d9cdcadc53a804e963f805a7
Diffstat (limited to 'vcl/osx/printaccessoryview.mm')
-rw-r--r--vcl/osx/printaccessoryview.mm17
1 files changed, 8 insertions, 9 deletions
diff --git a/vcl/osx/printaccessoryview.mm b/vcl/osx/printaccessoryview.mm
index 852263a4b227..1ee21901c530 100644
--- a/vcl/osx/printaccessoryview.mm
+++ b/vcl/osx/printaccessoryview.mm
@@ -446,12 +446,12 @@ class ControllerProperties
}
};
-static void filterAccelerator( rtl::OUString& io_rText )
+static OUString filterAccelerator( rtl::OUString const & rText )
{
- rtl::OUStringBuffer aBuf( io_rText.getLength() );
+ rtl::OUStringBuffer aBuf( rText.getLength() );
for( sal_Int32 nIndex = 0; nIndex != -1; )
- aBuf.append( io_rText.getToken( 0, '~', nIndex ) );
- io_rText = aBuf.makeStringAndClear();
+ aBuf.append( rText.getToken( 0, '~', nIndex ) );
+ return aBuf.makeStringAndClear();
}
@implementation ControlTarget
@@ -823,7 +823,7 @@ static void addBool( NSView* pCurParent, long& rCurX, long& rCurY, long nAttachO
static void addRadio( NSView* pCurParent, long& rCurX, long& rCurY, long nAttachOffset,
const rtl::OUString& rText,
- const rtl::OUString& rProperty, Sequence< rtl::OUString > rChoices, sal_Int32 nSelectValue,
+ const rtl::OUString& rProperty, Sequence<rtl::OUString> const & rChoices, sal_Int32 nSelectValue,
std::vector<ColumnItem >& rLeftColumn,
std::vector<ColumnItem >& rRightColumn,
ControllerProperties* pControllerProperties,
@@ -868,8 +868,7 @@ static void addRadio( NSView* pCurParent, long& rCurX, long& rCurY, long nAttach
for( sal_Int32 m = 0; m < rChoices.getLength(); m++ )
{
NSCell* pCell = [pCells objectAtIndex: m];
- filterAccelerator( rChoices[m] );
- linebreakCell( pCell, rChoices[m] );
+ linebreakCell( pCell, filterAccelerator( rChoices[m] ) );
// connect target and action
[pCell setTarget: pCtrlTarget];
[pCell setAction: @selector(triggered:)];
@@ -898,7 +897,7 @@ static void addRadio( NSView* pCurParent, long& rCurX, long& rCurY, long nAttach
static void addList( NSView* pCurParent, long& rCurX, long& rCurY, long /*nAttachOffset*/,
const rtl::OUString& rText,
- const rtl::OUString& rProperty, const Sequence< rtl::OUString > rChoices, sal_Int32 nSelectValue,
+ const rtl::OUString& rProperty, Sequence<rtl::OUString> const & rChoices, sal_Int32 nSelectValue,
std::vector<ColumnItem >& rLeftColumn,
std::vector<ColumnItem >& rRightColumn,
ControllerProperties* pControllerProperties,
@@ -1184,7 +1183,7 @@ static void addEdit( NSView* pCurParent, long& rCurX, long& rCurY, long nAttachO
if( rEntry.Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("Text")) )
{
rEntry.Value >>= aText;
- filterAccelerator( aText );
+ aText = filterAccelerator( aText );
}
else if( rEntry.Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("ControlType")) )
{