summaryrefslogtreecommitdiff
path: root/padmin
diff options
context:
space:
mode:
authorChr. Rossmanith <ChrRossmanith@gmx.de>2013-03-28 21:35:39 +0100
committerChr. Rossmanith <ChrRossmanith@gmx.de>2013-03-28 22:54:53 +0100
commit6833a02def7ff76ce8d5e0588da65023f03ac377 (patch)
treee8d4b07bdcf57a75bed0d02b60d528dd81e0c8cd /padmin
parent8333cbf2a3940abd0ed6b6bbb2ac25513f86a2fd (diff)
Remove RTL_CONSTASCII_(U)STRINGPARAM in padmin
Change-Id: Icdf78be74a1ce82de50772e9424dbc172f355484
Diffstat (limited to 'padmin')
-rw-r--r--padmin/source/adddlg.cxx21
-rw-r--r--padmin/source/padialog.cxx9
-rw-r--r--padmin/source/prtsetup.cxx14
3 files changed, 20 insertions, 24 deletions
diff --git a/padmin/source/adddlg.cxx b/padmin/source/adddlg.cxx
index 12c4efaee1fe..d9303845fe07 100644
--- a/padmin/source/adddlg.cxx
+++ b/padmin/source/adddlg.cxx
@@ -506,8 +506,8 @@ APOldPrinterPage::APOldPrinterPage( AddPrinterDialog* pParent )
rtl::OString aDriver(aValue.getToken(0, ' '));
rtl::OString aPS( aValue.getToken(0, ',').getToken(1, ' ') );
rtl::OString aNewDriver(aDriver);
- if( aDriver.equalsL(RTL_CONSTASCII_STRINGPARAM("GENERIC")))
- aNewDriver = rtl::OString(RTL_CONSTASCII_STRINGPARAM("SGENPRT"));
+ if( aDriver == "GENERIC")
+ aNewDriver = rtl::OString("SGENPRT");
if( aPS != "PostScript" )
continue;
@@ -547,7 +547,7 @@ APOldPrinterPage::APOldPrinterPage( AddPrinterDialog* pParent )
// read the printer settings
rtl::OStringBuffer aGroup(aDriver);
- aGroup.append(RTL_CONSTASCII_STRINGPARAM(",PostScript,"));
+ aGroup.append(",PostScript,");
aGroup.append(aPort);
aConfig.SetGroup(aGroup.makeStringAndClear());
@@ -598,13 +598,12 @@ APOldPrinterPage::APOldPrinterPage( AddPrinterDialog* pParent )
// should never have been writte because they are defaults
// PageRegion leads to problems in conjunction
// with a not matching PageSize
- if (aPPDKey.matchL(RTL_CONSTASCII_STRINGPARAM("PPD_")) &&
- !aPPDKey.equalsL(RTL_CONSTASCII_STRINGPARAM("PPD_PageRegion")))
+ if (aPPDKey.match("PPD_") && aPPDKey != "PPD_PageRegion")
{
aValue = aConfig.ReadKey( nPPDKey );
aPPDKey = aPPDKey.copy(4);
const PPDKey* pKey = aInfo.m_pParser->getKey( rtl::OStringToOUString(aPPDKey, RTL_TEXTENCODING_ISO_8859_1) );
- const PPDValue* pValue = pKey ? ( aValue.equalsL(RTL_CONSTASCII_STRINGPARAM("*nil")) ? NULL : pKey->getValue(rtl::OStringToOUString(aValue, RTL_TEXTENCODING_ISO_8859_1)) ) : NULL;
+ const PPDValue* pValue = pKey ? ( aValue == "*nil" ? NULL : pKey->getValue(rtl::OStringToOUString(aValue, RTL_TEXTENCODING_ISO_8859_1)) ) : NULL;
if( pKey )
aInfo.m_aContext.setValue( pKey, pValue, true );
}
@@ -1087,18 +1086,16 @@ String AddPrinterDialog::getOldPrinterLocation()
if( pHome )
{
aFileName = rtl::OStringBuffer().append(pHome).
- append(RTL_CONSTASCII_STRINGPARAM("/.Xpdefaults")).
- makeStringAndClear();
+ append("/.Xpdefaults").makeStringAndClear();
if (access(aFileName.getStr(), F_OK))
{
aFileName = rtl::OStringBuffer().append(pHome).
- append(RTL_CONSTASCII_STRINGPARAM("/.sversionrc")).
- makeStringAndClear();
+ append("/.sversionrc").makeStringAndClear();
Config aSVer(rtl::OStringToOUString(aFileName, aEncoding));
aSVer.SetGroup( "Versions" );
aFileName = aSVer.ReadKey( "StarOffice 5.2" );
if (!aFileName.isEmpty())
- aFileName = aFileName + rtl::OString(RTL_CONSTASCII_STRINGPARAM("/share/xp3/Xpdefaults"));
+ aFileName = aFileName + rtl::OString("/share/xp3/Xpdefaults");
else if(
(aFileName = aSVer.ReadKey( "StarOffice 5.1" ) ).getLength()
||
@@ -1107,7 +1104,7 @@ String AddPrinterDialog::getOldPrinterLocation()
(aFileName = aSVer.ReadKey( "StarOffice 4.0" ) ).getLength()
)
{
- aFileName = aFileName + rtl::OString(RTL_CONSTASCII_STRINGPARAM("/xp3/Xpdefaults"));
+ aFileName = aFileName + rtl::OString("/xp3/Xpdefaults");
}
if (!aFileName.isEmpty() && access(aFileName.getStr(), F_OK))
aFileName = rtl::OString();
diff --git a/padmin/source/padialog.cxx b/padmin/source/padialog.cxx
index bf89597b9b08..fc04a2c1e67b 100644
--- a/padmin/source/padialog.cxx
+++ b/padmin/source/padialog.cxx
@@ -408,7 +408,7 @@ void SpaPrinterController::printPage( int ) const
Size( aPaperSize.Width()-600,
aPaperSize.Height()-600 ) ) );
- Font aFont( String( RTL_CONSTASCII_USTRINGPARAM( "Courier" ) ), Size( 0, 400 ) );
+ Font aFont( String( "Courier" ), Size( 0, 400 ) );
aFont.SetWeight( WEIGHT_NORMAL );
aFont.SetItalic( ITALIC_NONE );
pPrinter->SetFont( aFont );
@@ -458,7 +458,7 @@ void SpaPrinterController::printPage( int ) const
if( pPrintParser )
aPrintText.append( pPrintParser->getPrinterName() );
aPrintText.appendAscii( "\n: " );
- INetURLObject aDriverPath( pPrintParser ? pPrintParser->getFilename() : String( RTL_CONSTASCII_USTRINGPARAM( "<undef>" ) ),
+ INetURLObject aDriverPath( pPrintParser ? pPrintParser->getFilename() : String( "<undef>" ),
INET_PROT_FILE, INetURLObject::ENCODE_ALL );
aPrintText.append( aDriverPath.GetName() );
aPrintText.appendAscii( "\n: " );
@@ -581,8 +581,7 @@ void PADialog::PrintTestPage()
boost::shared_ptr<vcl::PrinterController> pController( new SpaPrinterController( pPrinter ) );
JobSetup aJobSetup( pPrinter->GetJobSetup() );
- aJobSetup.SetValue( String( RTL_CONSTASCII_USTRINGPARAM( "IsQuickJob" ) ),
- String( RTL_CONSTASCII_USTRINGPARAM( "true" ) ) );
+ aJobSetup.SetValue( "IsQuickJob", "true" );
Printer::PrintJob( pController, aJobSetup );
}
@@ -605,7 +604,7 @@ void PADialog::RemDevice()
if( ! m_rPIManager.removePrinter( aPrinter ) )
{
String aText( PaResId( RID_ERR_PRINTERNOTREMOVEABLE ) );
- aText.SearchAndReplace( String( RTL_CONSTASCII_USTRINGPARAM( "%s" ) ), aPrinter );
+ aText.SearchAndReplace( String( "%s" ), aPrinter );
ErrorBox aBox( this, WB_OK | WB_DEF_OK, aText );
aBox.Execute();
return;
diff --git a/padmin/source/prtsetup.cxx b/padmin/source/prtsetup.cxx
index 2f136c9ab314..7d58ff9ef4a4 100644
--- a/padmin/source/prtsetup.cxx
+++ b/padmin/source/prtsetup.cxx
@@ -95,7 +95,7 @@ RTSDialog::RTSDialog( const PrinterInfo& rJobData, const String& rPrinter, bool
get(m_pTabControl, "notebook");
String aTitle( GetText() );
- aTitle.SearchAndReplace( String( RTL_CONSTASCII_USTRINGPARAM( "%s" ) ), m_aJobData.m_aPrinterName );
+ aTitle.SearchAndReplace( String( "%s" ), m_aJobData.m_aPrinterName );
SetText( aTitle );
if( ! bAllPages )
@@ -259,7 +259,7 @@ void RTSPaperPage::update()
// duplex
if( m_pParent->m_aJobData.m_pParser &&
- (pKey = m_pParent->m_aJobData.m_pParser->getKey( String( RTL_CONSTASCII_USTRINGPARAM( "Duplex" ) ) )) )
+ (pKey = m_pParent->m_aJobData.m_pParser->getKey( String( "Duplex" ) )) )
{
m_pParent->insertAllPPDValues( *m_pDuplexBox, m_pParent->m_aJobData.m_pParser, pKey );
}
@@ -271,7 +271,7 @@ void RTSPaperPage::update()
// paper
if( m_pParent->m_aJobData.m_pParser &&
- (pKey = m_pParent->m_aJobData.m_pParser->getKey( String( RTL_CONSTASCII_USTRINGPARAM( "PageSize" ) ) )) )
+ (pKey = m_pParent->m_aJobData.m_pParser->getKey( String( "PageSize" ) )) )
{
m_pParent->insertAllPPDValues( *m_pPaperBox, m_pParent->m_aJobData.m_pParser, pKey );
}
@@ -302,17 +302,17 @@ IMPL_LINK( RTSPaperPage, SelectHdl, ListBox*, pBox )
if( pBox == m_pPaperBox )
{
if( m_pParent->m_aJobData.m_pParser )
- pKey = m_pParent->m_aJobData.m_pParser->getKey( String( RTL_CONSTASCII_USTRINGPARAM( "PageSize" ) ) );
+ pKey = m_pParent->m_aJobData.m_pParser->getKey( String( "PageSize" ) );
}
else if( pBox == m_pDuplexBox )
{
if( m_pParent->m_aJobData.m_pParser )
- pKey = m_pParent->m_aJobData.m_pParser->getKey( String( RTL_CONSTASCII_USTRINGPARAM( "Duplex" ) ) );
+ pKey = m_pParent->m_aJobData.m_pParser->getKey( String( "Duplex" ) );
}
else if( pBox == m_pSlotBox )
{
if( m_pParent->m_aJobData.m_pParser )
- pKey = m_pParent->m_aJobData.m_pParser->getKey( String( RTL_CONSTASCII_USTRINGPARAM( "InputSlot" ) ) );
+ pKey = m_pParent->m_aJobData.m_pParser->getKey( String( "InputSlot" ) );
}
else if( pBox == m_pOrientBox )
{
@@ -800,7 +800,7 @@ RTSPWDialog::RTSPWDialog( const OString& rServer, const OString& rUserName, Wind
{
FreeResource();
String aText( m_aText.GetText() );
- aText.SearchAndReplace( String( RTL_CONSTASCII_USTRINGPARAM( "%s" ) ), OStringToOUString( rServer, osl_getThreadTextEncoding() ) );
+ aText.SearchAndReplace( String( "%s" ), OStringToOUString( rServer, osl_getThreadTextEncoding() ) );
m_aText.SetText( aText );
m_aUserEdit.SetText( OStringToOUString( rUserName, osl_getThreadTextEncoding() ) );
}