diff options
author | Caolán McNamara <caolanm@redhat.com> | 2013-07-27 17:01:36 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2013-07-28 16:45:48 +0100 |
commit | 5efc15f0006866ac4c422c1b2bde173ded47893f (patch) | |
tree | 119b46339aae67b9a5b1a76ea2a955a548e5016e /extensions/source/bibliography | |
parent | e39a959429234aef5348a8b5800b27c29de02a6f (diff) |
reduce use of UniString from ResID ctor
Change-Id: I8d7619e7807ff2d400ec5c7fd181375130245728
Diffstat (limited to 'extensions/source/bibliography')
-rw-r--r-- | extensions/source/bibliography/bibload.cxx | 2 | ||||
-rw-r--r-- | extensions/source/bibliography/bibresid.hxx | 2 | ||||
-rw-r--r-- | extensions/source/bibliography/bibview.cxx | 2 | ||||
-rw-r--r-- | extensions/source/bibliography/datman.cxx | 68 | ||||
-rw-r--r-- | extensions/source/bibliography/general.cxx | 108 |
5 files changed, 91 insertions, 91 deletions
diff --git a/extensions/source/bibliography/bibload.cxx b/extensions/source/bibliography/bibload.cxx index 9d6c6e7c08a4..9dbb7be0469b 100644 --- a/extensions/source/bibliography/bibload.cxx +++ b/extensions/source/bibliography/bibload.cxx @@ -239,7 +239,7 @@ void BibliographyLoader::load(const Reference< XFrame > & rFrame, const OUString if(xPrSet.is()) { Any aTitle; - aTitle <<= OUString(String(BibResId(RID_BIB_STR_FRAME_TITLE))); + aTitle <<= BibResId(RID_BIB_STR_FRAME_TITLE).toString(); xPrSet->setPropertyValue("Title", aTitle); } if(aPartName.EqualsAscii("View") || aPartName.EqualsAscii("View1")) diff --git a/extensions/source/bibliography/bibresid.hxx b/extensions/source/bibliography/bibresid.hxx index 8188c4e17df4..daa100db103b 100644 --- a/extensions/source/bibliography/bibresid.hxx +++ b/extensions/source/bibliography/bibresid.hxx @@ -30,7 +30,7 @@ class BibResId : public ResId BibResId( sal_uInt16 nId ); }; - +#define BIB_RESSTR(i) BibResId(i).toString() #endif // ADRRESID_HXX diff --git a/extensions/source/bibliography/bibview.cxx b/extensions/source/bibliography/bibview.cxx index dac90718d065..9063b8031bd8 100644 --- a/extensions/source/bibliography/bibview.cxx +++ b/extensions/source/bibliography/bibview.cxx @@ -134,7 +134,7 @@ namespace bib else if(bExecute) { sErrorString += '\n'; - sErrorString += String( BibResId( RID_MAP_QUESTION ) ); + sErrorString += BIB_RESSTR(RID_MAP_QUESTION); QueryBox aQuery( this, WB_YES_NO, sErrorString ); aQuery.SetDefaultCheckBoxText(); short nResult = aQuery.Execute(); diff --git a/extensions/source/bibliography/datman.cxx b/extensions/source/bibliography/datman.cxx index 60a1fc95e94f..668dcc31a9b5 100644 --- a/extensions/source/bibliography/datman.cxx +++ b/extensions/source/bibliography/datman.cxx @@ -360,42 +360,42 @@ MappingDialog_Impl::MappingDialog_Impl(Window* pParent, BibDataManager* pMan) : aCustom4LB(this, BibResId( LB_CUSTOM4 )), aCustom5FT(this, BibResId( FT_CUSTOM5 )), aCustom5LB(this, BibResId( LB_CUSTOM5 )), - sNone(BibResId(ST_NONE)), + sNone(BIB_RESSTR(ST_NONE)), bModified(sal_False) { FreeResource(); - aIdentifierFT.SetText(String( BibResId( ST_IDENTIFIER ))); - aAuthorityTypeFT.SetText(String( BibResId( ST_AUTHTYPE ))); - aAuthorFT.SetText(String( BibResId( ST_AUTHOR ))); - aTitleFT.SetText(String( BibResId( ST_TITLE ))); - aMonthFT.SetText(String( BibResId( ST_MONTH ))); - aYearFT.SetText(String( BibResId( ST_YEAR ))); - aISBNFT.SetText(String( BibResId( ST_ISBN ))); - aBooktitleFT.SetText(String( BibResId( ST_BOOKTITLE ))); - aChapterFT.SetText(String( BibResId( ST_CHAPTER ))); - aEditionFT.SetText(String( BibResId( ST_EDITION ))); - aEditorFT.SetText(String( BibResId( ST_EDITOR ))); - aHowpublishedFT.SetText(String( BibResId( ST_HOWPUBLISHED ))); - aInstitutionFT.SetText(String( BibResId( ST_INSTITUTION ))); - aJournalFT.SetText(String( BibResId( ST_JOURNAL ))); - aNoteFT.SetText(String( BibResId( ST_NOTE ))); - aAnnoteFT.SetText(String( BibResId( ST_ANNOTE ))); - aNumberFT.SetText(String( BibResId( ST_NUMBER ))); - aOrganizationsFT.SetText(String( BibResId( ST_ORGANIZATION ))); - aPagesFT.SetText(String( BibResId( ST_PAGE ))); - aPublisherFT.SetText(String( BibResId( ST_PUBLISHER ))); - aAddressFT.SetText(String( BibResId( ST_ADDRESS ))); - aSchoolFT.SetText(String( BibResId( ST_SCHOOL ))); - aSeriesFT.SetText(String( BibResId( ST_SERIES ))); - aReportTypeFT.SetText(String( BibResId( ST_REPORT ))); - aVolumeFT.SetText(String( BibResId( ST_VOLUME ))); - aURLFT.SetText(String( BibResId( ST_URL ))); - aCustom1FT.SetText(String( BibResId( ST_CUSTOM1 ))); - aCustom2FT.SetText(String( BibResId( ST_CUSTOM2 ))); - aCustom3FT.SetText(String( BibResId( ST_CUSTOM3 ))); - aCustom4FT.SetText(String( BibResId( ST_CUSTOM4 ))); - aCustom5FT.SetText(String( BibResId( ST_CUSTOM5 ))); + aIdentifierFT.SetText(BIB_RESSTR(ST_IDENTIFIER)); + aAuthorityTypeFT.SetText(BIB_RESSTR(ST_AUTHTYPE)); + aAuthorFT.SetText(BIB_RESSTR(ST_AUTHOR)); + aTitleFT.SetText(BIB_RESSTR(ST_TITLE)); + aMonthFT.SetText(BIB_RESSTR(ST_MONTH)); + aYearFT.SetText(BIB_RESSTR(ST_YEAR)); + aISBNFT.SetText(BIB_RESSTR(ST_ISBN)); + aBooktitleFT.SetText(BIB_RESSTR(ST_BOOKTITLE)); + aChapterFT.SetText(BIB_RESSTR(ST_CHAPTER)); + aEditionFT.SetText(BIB_RESSTR(ST_EDITION)); + aEditorFT.SetText(BIB_RESSTR(ST_EDITOR)); + aHowpublishedFT.SetText(BIB_RESSTR(ST_HOWPUBLISHED)); + aInstitutionFT.SetText(BIB_RESSTR(ST_INSTITUTION)); + aJournalFT.SetText(BIB_RESSTR(ST_JOURNAL)); + aNoteFT.SetText(BIB_RESSTR(ST_NOTE)); + aAnnoteFT.SetText(BIB_RESSTR(ST_ANNOTE)); + aNumberFT.SetText(BIB_RESSTR(ST_NUMBER)); + aOrganizationsFT.SetText(BIB_RESSTR(ST_ORGANIZATION)); + aPagesFT.SetText(BIB_RESSTR(ST_PAGE)); + aPublisherFT.SetText(BIB_RESSTR(ST_PUBLISHER)); + aAddressFT.SetText(BIB_RESSTR(ST_ADDRESS)); + aSchoolFT.SetText(BIB_RESSTR(ST_SCHOOL)); + aSeriesFT.SetText(BIB_RESSTR(ST_SERIES)); + aReportTypeFT.SetText(BIB_RESSTR(ST_REPORT)); + aVolumeFT.SetText(BIB_RESSTR(ST_VOLUME)); + aURLFT.SetText(BIB_RESSTR(ST_URL)); + aCustom1FT.SetText(BIB_RESSTR(ST_CUSTOM1)); + aCustom2FT.SetText(BIB_RESSTR(ST_CUSTOM2)); + aCustom3FT.SetText(BIB_RESSTR(ST_CUSTOM3)); + aCustom4FT.SetText(BIB_RESSTR(ST_CUSTOM4)); + aCustom5FT.SetText(BIB_RESSTR(ST_CUSTOM5)); aOKBT.SetClickHdl(LINK(this, MappingDialog_Impl, OkHdl)); String sTitle = GetText(); @@ -556,8 +556,8 @@ DBChangeDialog_Impl::DBChangeDialog_Impl(Window* pParent, BibDataManager* pMan ) aSelectionGB(this, BibResId( GB_SELECTION )), aSelectionLB(this, BibResId( LB_SELECTION )), aSelectionHB(this, BibResId( HB_SELECTION )), - aEntryST(BibResId(ST_ENTRY)), - aURLST( BibResId(ST_URL)), + aEntryST(BIB_RESSTR(ST_ENTRY)), + aURLST(BIB_RESSTR(ST_URL)), pDatMan(pMan) { FreeResource(); diff --git a/extensions/source/bibliography/general.cxx b/extensions/source/bibliography/general.cxx index 25bc0f92d6b8..4b226f5604df 100644 --- a/extensions/source/bibliography/general.cxx +++ b/extensions/source/bibliography/general.cxx @@ -215,35 +215,35 @@ BibGeneralPage::BibGeneralPage(Window* pParent, BibDataManager* pMan): aCustom5FT(&aControlParentWin, BibResId(FT_CUSTOM5 )), aHoriScroll(this, WB_HORZ), aVertScroll(this, WB_VERT), - sErrorPrefix(BibResId(ST_ERROR_PREFIX)), + sErrorPrefix(BIB_RESSTR(ST_ERROR_PREFIX)), pDatMan(pMan) { aControlParentWin.Show(); aControlParentWin.SetHelpId(HID_BIB_CONTROL_PARENT); aStdSize = GetOutputSizePixel(); - aBibTypeArr[0] = String(BibResId(ST_TYPE_ARTICLE)); - aBibTypeArr[1] = String(BibResId(ST_TYPE_BOOK)); - aBibTypeArr[2] = String(BibResId(ST_TYPE_BOOKLET)); - aBibTypeArr[3] = String(BibResId(ST_TYPE_CONFERENCE)); - aBibTypeArr[4] = String(BibResId(ST_TYPE_INBOOK )); - aBibTypeArr[5] = String(BibResId(ST_TYPE_INCOLLECTION)); - aBibTypeArr[6] = String(BibResId(ST_TYPE_INPROCEEDINGS)); - aBibTypeArr[7] = String(BibResId(ST_TYPE_JOURNAL )); - aBibTypeArr[8] = String(BibResId(ST_TYPE_MANUAL )); - aBibTypeArr[9] = String(BibResId(ST_TYPE_MASTERSTHESIS)); - aBibTypeArr[10] = String(BibResId(ST_TYPE_MISC )); - aBibTypeArr[11] = String(BibResId(ST_TYPE_PHDTHESIS )); - aBibTypeArr[12] = String(BibResId(ST_TYPE_PROCEEDINGS )); - aBibTypeArr[13] = String(BibResId(ST_TYPE_TECHREPORT )); - aBibTypeArr[14] = String(BibResId(ST_TYPE_UNPUBLISHED )); - aBibTypeArr[15] = String(BibResId(ST_TYPE_EMAIL )); - aBibTypeArr[16] = String(BibResId(ST_TYPE_WWW )); - aBibTypeArr[17] = String(BibResId(ST_TYPE_CUSTOM1 )); - aBibTypeArr[18] = String(BibResId(ST_TYPE_CUSTOM2 )); - aBibTypeArr[19] = String(BibResId(ST_TYPE_CUSTOM3 )); - aBibTypeArr[20] = String(BibResId(ST_TYPE_CUSTOM4 )); - aBibTypeArr[21] = String(BibResId(ST_TYPE_CUSTOM5 )); + aBibTypeArr[0] = BIB_RESSTR(ST_TYPE_ARTICLE); + aBibTypeArr[1] = BIB_RESSTR(ST_TYPE_BOOK); + aBibTypeArr[2] = BIB_RESSTR(ST_TYPE_BOOKLET); + aBibTypeArr[3] = BIB_RESSTR(ST_TYPE_CONFERENCE); + aBibTypeArr[4] = BIB_RESSTR(ST_TYPE_INBOOK ); + aBibTypeArr[5] = BIB_RESSTR(ST_TYPE_INCOLLECTION); + aBibTypeArr[6] = BIB_RESSTR(ST_TYPE_INPROCEEDINGS); + aBibTypeArr[7] = BIB_RESSTR(ST_TYPE_JOURNAL ); + aBibTypeArr[8] = BIB_RESSTR(ST_TYPE_MANUAL ); + aBibTypeArr[9] = BIB_RESSTR(ST_TYPE_MASTERSTHESIS); + aBibTypeArr[10] = BIB_RESSTR(ST_TYPE_MISC ); + aBibTypeArr[11] = BIB_RESSTR(ST_TYPE_PHDTHESIS ); + aBibTypeArr[12] = BIB_RESSTR(ST_TYPE_PROCEEDINGS ); + aBibTypeArr[13] = BIB_RESSTR(ST_TYPE_TECHREPORT ); + aBibTypeArr[14] = BIB_RESSTR(ST_TYPE_UNPUBLISHED ); + aBibTypeArr[15] = BIB_RESSTR(ST_TYPE_EMAIL ); + aBibTypeArr[16] = BIB_RESSTR(ST_TYPE_WWW ); + aBibTypeArr[17] = BIB_RESSTR(ST_TYPE_CUSTOM1 ); + aBibTypeArr[18] = BIB_RESSTR(ST_TYPE_CUSTOM2 ); + aBibTypeArr[19] = BIB_RESSTR(ST_TYPE_CUSTOM3 ); + aBibTypeArr[20] = BIB_RESSTR(ST_TYPE_CUSTOM4 ); + aBibTypeArr[21] = BIB_RESSTR(ST_TYPE_CUSTOM5 ); FreeResource(); @@ -617,37 +617,37 @@ void BibGeneralPage::InitFixedTexts( void ) { String aFixedStrings[ FIELD_COUNT ] = { - String( BibResId( ST_IDENTIFIER ) ), - String( BibResId( ST_AUTHTYPE ) ), - String( BibResId( ST_AUTHOR ) ), - String( BibResId( ST_TITLE ) ), - String( BibResId( ST_MONTH ) ), - String( BibResId( ST_YEAR ) ), - String( BibResId( ST_ISBN ) ), - String( BibResId( ST_BOOKTITLE ) ), - String( BibResId( ST_CHAPTER ) ), - String( BibResId( ST_EDITION ) ), - String( BibResId( ST_EDITOR ) ), - String( BibResId( ST_HOWPUBLISHED ) ), - String( BibResId( ST_INSTITUTION ) ), - String( BibResId( ST_JOURNAL ) ), - String( BibResId( ST_NOTE ) ), - String( BibResId( ST_ANNOTE ) ), - String( BibResId( ST_NUMBER ) ), - String( BibResId( ST_ORGANIZATION ) ), - String( BibResId( ST_PAGE ) ), - String( BibResId( ST_PUBLISHER ) ), - String( BibResId( ST_ADDRESS ) ), - String( BibResId( ST_SCHOOL ) ), - String( BibResId( ST_SERIES ) ), - String( BibResId( ST_REPORT ) ), - String( BibResId( ST_VOLUME ) ), - String( BibResId( ST_URL ) ), - String( BibResId( ST_CUSTOM1 ) ), - String( BibResId( ST_CUSTOM2 ) ), - String( BibResId( ST_CUSTOM3 ) ), - String( BibResId( ST_CUSTOM4 ) ), - String( BibResId( ST_CUSTOM5 ) ) + BIB_RESSTR( ST_IDENTIFIER ), + BIB_RESSTR( ST_AUTHTYPE ), + BIB_RESSTR( ST_AUTHOR ), + BIB_RESSTR( ST_TITLE ), + BIB_RESSTR( ST_MONTH ), + BIB_RESSTR( ST_YEAR ), + BIB_RESSTR( ST_ISBN ), + BIB_RESSTR( ST_BOOKTITLE ), + BIB_RESSTR( ST_CHAPTER ), + BIB_RESSTR( ST_EDITION ), + BIB_RESSTR( ST_EDITOR ), + BIB_RESSTR( ST_HOWPUBLISHED ), + BIB_RESSTR( ST_INSTITUTION ), + BIB_RESSTR( ST_JOURNAL ), + BIB_RESSTR( ST_NOTE ), + BIB_RESSTR( ST_ANNOTE ), + BIB_RESSTR( ST_NUMBER ), + BIB_RESSTR( ST_ORGANIZATION ), + BIB_RESSTR( ST_PAGE ), + BIB_RESSTR( ST_PUBLISHER ), + BIB_RESSTR( ST_ADDRESS ), + BIB_RESSTR( ST_SCHOOL ), + BIB_RESSTR( ST_SERIES ), + BIB_RESSTR( ST_REPORT ), + BIB_RESSTR( ST_VOLUME ), + BIB_RESSTR( ST_URL ), + BIB_RESSTR( ST_CUSTOM1 ), + BIB_RESSTR( ST_CUSTOM2 ), + BIB_RESSTR( ST_CUSTOM3 ), + BIB_RESSTR( ST_CUSTOM4 ), + BIB_RESSTR( ST_CUSTOM5 ) }; aFixedTexts[0] = &aIdentifierFT; |