diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2022-04-29 11:06:33 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2022-05-01 08:30:18 +0200 |
commit | 5200a73627d13e2997f81b53f61e143e77e328ee (patch) | |
tree | f95c8346d061ecd0ad33d574895d18e169662785 /sw | |
parent | b90d3d316dd9c720c83180b31f6bbd7003fead78 (diff) |
use more string_view in various
found by examining uses of OUString::copy() for likely places
Change-Id: I6ff20e7b273ad6005410b82719183c1122f8c018
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/133617
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sw')
-rw-r--r-- | sw/source/core/access/accpara.cxx | 8 | ||||
-rw-r--r-- | sw/source/core/bastyp/calc.cxx | 12 | ||||
-rw-r--r-- | sw/source/core/doc/DocumentLinksAdministrationManager.cxx | 10 | ||||
-rw-r--r-- | sw/source/core/table/swtable.cxx | 11 | ||||
-rw-r--r-- | sw/source/core/tox/txmsrt.cxx | 6 | ||||
-rw-r--r-- | sw/source/core/txtnode/ndtxt.cxx | 4 | ||||
-rw-r--r-- | sw/source/core/unocore/unochart.cxx | 6 | ||||
-rw-r--r-- | sw/source/filter/html/css1atr.cxx | 48 | ||||
-rw-r--r-- | sw/source/uibase/docvw/edtwin2.cxx | 18 | ||||
-rw-r--r-- | sw/source/uibase/uiview/view2.cxx | 2 | ||||
-rw-r--r-- | sw/source/uibase/uiview/viewport.cxx | 2 | ||||
-rw-r--r-- | sw/source/uibase/uno/unotxdoc.cxx | 27 |
12 files changed, 77 insertions, 77 deletions
diff --git a/sw/source/core/access/accpara.cxx b/sw/source/core/access/accpara.cxx index f8e3b5966f91..69c28dbbd09f 100644 --- a/sw/source/core/access/accpara.cxx +++ b/sw/source/core/access/accpara.cxx @@ -88,6 +88,7 @@ #include <cppuhelper/supportsservice.hxx> #include <cppuhelper/typeprovider.hxx> #include <svx/colorwindow.hxx> +#include <o3tl/string_view.hxx> #include <editeng/editids.hrc> #include <reffld.hxx> @@ -3512,11 +3513,10 @@ sal_Int32 SwAccessibleParagraph::GetRealHeadingLevel() sal_Int32 length = sValue.getLength(); if (length == 9 || length == 10) { - OUString headStr = sValue.copy(0, 7); - if (headStr == "Heading") + if (sValue.startsWith("Heading")) { - OUString intStr = sValue.copy(8); - sal_Int32 headingLevel = intStr.toInt32(); + std::u16string_view intStr = sValue.subView(8); + sal_Int32 headingLevel = o3tl::toInt32(intStr); return headingLevel; } } diff --git a/sw/source/core/bastyp/calc.cxx b/sw/source/core/bastyp/calc.cxx index 4132cbb1869b..4c6f2258dc57 100644 --- a/sw/source/core/bastyp/calc.cxx +++ b/sw/source/core/bastyp/calc.cxx @@ -713,9 +713,9 @@ SwCalcOper SwCalc::GetToken() } else if( aRes.TokenType & KParseType::ONE_SINGLE_CHAR ) { - OUString aName( m_sCommand.copy( nRealStt, + std::u16string_view aName( m_sCommand.subView( nRealStt, aRes.EndPos - nRealStt )); - if( 1 == aName.getLength() ) + if( 1 == aName.size() ) { bSetError = false; sal_Unicode ch = aName[0]; @@ -819,9 +819,9 @@ SwCalcOper SwCalc::GetToken() } else if( aRes.TokenType & KParseType::BOOLEAN ) { - OUString aName( m_sCommand.copy( nRealStt, + std::u16string_view aName( m_sCommand.subView( nRealStt, aRes.EndPos - nRealStt )); - if( !aName.isEmpty() ) + if( !aName.empty() ) { sal_Unicode ch = aName[0]; @@ -833,9 +833,9 @@ SwCalcOper SwCalc::GetToken() SwCalcOper eTmp2 = ('<' == ch) ? CALC_LEQ : CALC_GEQ; m_eCurrOper = ('<' == ch) ? CALC_LES : CALC_GRE; - if( 2 == aName.getLength() && '=' == aName[1] ) + if( 2 == aName.size() && '=' == aName[1] ) m_eCurrOper = eTmp2; - else if( 1 != aName.getLength() ) + else if( 1 != aName.size() ) bSetError = true; } } diff --git a/sw/source/core/doc/DocumentLinksAdministrationManager.cxx b/sw/source/core/doc/DocumentLinksAdministrationManager.cxx index c010a7c9aa49..175b50caba8e 100644 --- a/sw/source/core/doc/DocumentLinksAdministrationManager.cxx +++ b/sw/source/core/doc/DocumentLinksAdministrationManager.cxx @@ -461,12 +461,12 @@ bool DocumentLinksAdministrationManager::SelectServerObj( std::u16string_view rS { bool bContinue = false; OUString sName( sItem.copy( 0, nPos ) ); - OUString sCmp( sItem.copy( nPos + 1 )); + std::u16string_view sCmp( sItem.subView( nPos + 1 )); sItem = rCC.lowercase( sItem ); FindItem aPara( sName ); - if( sCmp == "table" ) + if( sCmp == u"table" ) { sName = rCC.lowercase( sName ); for( const SwFrameFormat* pFormat : *m_rDoc.GetTableFrameFormats() ) @@ -481,7 +481,7 @@ bool DocumentLinksAdministrationManager::SelectServerObj( std::u16string_view rS return true; } } - else if( sCmp == "frame" ) + else if( sCmp == u"frame" ) { const SwFlyFrameFormat* pFlyFormat = m_rDoc.FindFlyByName( sName ); if( pFlyFormat ) @@ -498,12 +498,12 @@ bool DocumentLinksAdministrationManager::SelectServerObj( std::u16string_view rS } } } - else if( sCmp == "region" ) + else if( sCmp == u"region" ) { sItem = sName; // Is being dealt with further down! bContinue = true; } - else if( sCmp == "outline" ) + else if( sCmp == u"outline" ) { SwPosition aPos( SwNodeIndex( m_rDoc.GetNodes() )); if (m_rDoc.GotoOutline(aPos, sName, nullptr)) diff --git a/sw/source/core/table/swtable.cxx b/sw/source/core/table/swtable.cxx index 8d033cf28ab0..7b9f6b030970 100644 --- a/sw/source/core/table/swtable.cxx +++ b/sw/source/core/table/swtable.cxx @@ -57,6 +57,7 @@ #include <redline.hxx> #include <vector> #include <calbck.hxx> +#include <o3tl/string_view.hxx> #include <svl/numformat.hxx> #ifdef DBG_UTIL @@ -1266,11 +1267,11 @@ void SwTable::NewSetTabCols( Parm &rParm, const SwTabCols &rNew, } // return the pointer of the box specified. -static bool lcl_IsValidRowName( const OUString& rStr ) +static bool lcl_IsValidRowName( std::u16string_view rStr ) { bool bIsValid = true; - sal_Int32 nLen = rStr.getLength(); - for( sal_Int32 i = 0; i < nLen && bIsValid; ++i ) + size_t nLen = rStr.size(); + for( size_t i = 0; i < nLen && bIsValid; ++i ) { const sal_Unicode cChar = rStr[i]; if (cChar < '0' || cChar > '9') @@ -1328,10 +1329,10 @@ sal_uInt16 SwTable::GetBoxNum( OUString& rStr, bool bFirstPart, else { nRet = 0; - const OUString aText( rStr.copy( 0, nPos ) ); + const std::u16string_view aText( rStr.subView( 0, nPos ) ); if ( !bPerformValidCheck || lcl_IsValidRowName( aText ) ) { - nRet = o3tl::narrowing<sal_uInt16>(aText.toInt32()); + nRet = o3tl::narrowing<sal_uInt16>(o3tl::toInt32(aText)); } rStr = rStr.copy( nPos+1 ); } diff --git a/sw/source/core/tox/txmsrt.cxx b/sw/source/core/tox/txmsrt.cxx index cabbad160e9d..b0195ff8d718 100644 --- a/sw/source/core/tox/txmsrt.cxx +++ b/sw/source/core/tox/txmsrt.cxx @@ -883,12 +883,12 @@ void SwTOXAuthority::FillText(SwTextNode& rNd, const SwIndex& rInsPos, sal_uInt1 // Convert URL to a relative one if requested. SwDoc* pDoc = static_cast<SwAuthorityFieldType*>(m_rField.GetField()->GetTyp())->GetDoc(); SwDocShell* pDocShell = pDoc->GetDocShell(); - OUString aBaseURL = pDocShell->getDocumentBaseURL(); - OUString aBaseURIScheme; + const OUString aBaseURL = pDocShell->getDocumentBaseURL(); + std::u16string_view aBaseURIScheme; sal_Int32 nSep = aBaseURL.indexOf(':'); if (nSep != -1) { - aBaseURIScheme = aBaseURL.copy(0, nSep); + aBaseURIScheme = aBaseURL.subView(0, nSep); } uno::Reference<uri::XUriReferenceFactory> xUriReferenceFactory diff --git a/sw/source/core/txtnode/ndtxt.cxx b/sw/source/core/txtnode/ndtxt.cxx index 68223f742796..591a75431cc9 100644 --- a/sw/source/core/txtnode/ndtxt.cxx +++ b/sw/source/core/txtnode/ndtxt.cxx @@ -3708,9 +3708,9 @@ void SwTextNode::ReplaceText( const SwIndex& rStart, const sal_Int32 nDelLen, m_Text = m_Text.replaceAt(rStart.GetIndex(), nLen - 1, u""); Update( rStart, nLen - 1, true ); - OUString aTmpText( sInserted.copy(1) ); + std::u16string_view aTmpText( sInserted.subView(1) ); m_Text = m_Text.replaceAt(rStart.GetIndex(), 0, aTmpText); - Update( rStart, aTmpText.getLength() ); + Update( rStart, aTmpText.size() ); } else { diff --git a/sw/source/core/unocore/unochart.cxx b/sw/source/core/unocore/unochart.cxx index 84da9ee071b4..edaa628c68f4 100644 --- a/sw/source/core/unocore/unochart.cxx +++ b/sw/source/core/unocore/unochart.cxx @@ -1984,16 +1984,16 @@ uno::Sequence< OUString > SAL_CALL SwChartDataSequence::generateLabel( if (pBuf < pEnd && ('0' <= *pBuf && *pBuf <= '9')) { OUString aRplc; - OUString aNew; + std::u16string_view aNew; if (bUseCol) { aRplc = "%COLUMNLETTER"; - aNew = aCellName.copy(0, pBuf - aCellName.getStr()); + aNew = aCellName.subView(0, pBuf - aCellName.getStr()); } else { aRplc = "%ROWNUMBER"; - aNew = OUString(pBuf, (aCellName.getStr() + nLen) - pBuf); + aNew = std::u16string_view(pBuf, (aCellName.getStr() + nLen) - pBuf); } aText = aText.replaceFirst( aRplc, aNew ); } diff --git a/sw/source/filter/html/css1atr.cxx b/sw/source/filter/html/css1atr.cxx index 040914222d77..41912dac4881 100644 --- a/sw/source/filter/html/css1atr.cxx +++ b/sw/source/filter/html/css1atr.cxx @@ -1224,16 +1224,16 @@ static bool OutCSS1Rule( SwHTMLWriter& rHTMLWrt, const OUString& rSelector, if( SwHTMLWriter::HasScriptDependentItems( rItemSet, bHasClass ) ) { bScriptDependent = true; - OUString aSelector( rSelector ); + std::u16string_view aSelector( rSelector ); - OUString aPseudo; + std::u16string_view aPseudo; if( bCheckForPseudo ) { - sal_Int32 nPos = aSelector.lastIndexOf( ':' ); - if( nPos >= 0 ) + size_t nPos = aSelector.rfind( ':' ); + if( nPos != std::u16string_view::npos ) { - aPseudo = aSelector.copy( nPos ); - aSelector =aSelector.copy( 0, nPos ); + aPseudo = aSelector.substr( nPos ); + aSelector =aSelector.substr( 0, nPos ); } } @@ -1257,21 +1257,21 @@ static bool OutCSS1Rule( SwHTMLWriter& rHTMLWrt, const OUString& rSelector, aScriptItemSet( *rItemSet.GetPool() ); aScriptItemSet.Put( rItemSet ); - OUString aNewSelector = aSelector + ".western" + aPseudo; + OUString aNewSelector = OUString::Concat(aSelector) + ".western" + aPseudo; { SwCSS1OutMode aMode( rHTMLWrt, CSS1_OUTMODE_WESTERN|CSS1_OUTMODE_RULE|CSS1_OUTMODE_TEMPLATE, &aNewSelector ); rHTMLWrt.OutCSS1_SfxItemSet( aScriptItemSet, false ); } - aNewSelector = aSelector + ".cjk" + aPseudo; + aNewSelector = OUString::Concat(aSelector) + ".cjk" + aPseudo; { SwCSS1OutMode aMode( rHTMLWrt, CSS1_OUTMODE_CJK|CSS1_OUTMODE_RULE|CSS1_OUTMODE_TEMPLATE, &aNewSelector ); rHTMLWrt.OutCSS1_SfxItemSet( aScriptItemSet, false ); } - aNewSelector = aSelector + ".ctl" + aPseudo; + aNewSelector = OUString::Concat(aSelector) + ".ctl" + aPseudo; { SwCSS1OutMode aMode( rHTMLWrt, CSS1_OUTMODE_CTL|CSS1_OUTMODE_RULE|CSS1_OUTMODE_TEMPLATE, &aNewSelector ); @@ -1283,21 +1283,21 @@ static bool OutCSS1Rule( SwHTMLWriter& rHTMLWrt, const OUString& rSelector, // If there are script dependencies and we are derived from a tag, // when we have to export a style dependent class for all // scripts - OUString aNewSelector = aSelector + "-western" + aPseudo; + OUString aNewSelector = OUString::Concat(aSelector) + "-western" + aPseudo; { SwCSS1OutMode aMode( rHTMLWrt, CSS1_OUTMODE_WESTERN|CSS1_OUTMODE_RULE|CSS1_OUTMODE_TEMPLATE, &aNewSelector ); rHTMLWrt.OutCSS1_SfxItemSet( rItemSet, false ); } - aNewSelector = aSelector + "-cjk" + aPseudo; + aNewSelector = OUString::Concat(aSelector) + "-cjk" + aPseudo; { SwCSS1OutMode aMode( rHTMLWrt, CSS1_OUTMODE_CJK|CSS1_OUTMODE_RULE|CSS1_OUTMODE_TEMPLATE, &aNewSelector ); rHTMLWrt.OutCSS1_SfxItemSet( rItemSet, false ); } - aNewSelector = aSelector + "-ctl" + aPseudo; + aNewSelector = OUString::Concat(aSelector) + "-ctl" + aPseudo; { SwCSS1OutMode aMode( rHTMLWrt, CSS1_OUTMODE_CTL|CSS1_OUTMODE_RULE|CSS1_OUTMODE_TEMPLATE, &aNewSelector ); @@ -1329,14 +1329,14 @@ static void OutCSS1DropCapRule( if( (bHasScriptDependencies && bHasClass) || (pDCCharFormat && SwHTMLWriter::HasScriptDependentItems( pDCCharFormat->GetAttrSet(), false ) ) ) { - OUString aSelector( rSelector ); + std::u16string_view aSelector( rSelector ); - OUString aPseudo; - sal_Int32 nPos = aSelector.lastIndexOf( ':' ); - if( nPos >= 0 ) + std::u16string_view aPseudo; + size_t nPos = aSelector.rfind( ':' ); + if( nPos != std::u16string_view::npos ) { - aPseudo = aSelector.copy( nPos ); - aSelector = aSelector.copy( 0, nPos ); + aPseudo = aSelector.substr( nPos ); + aSelector = aSelector.substr( 0, nPos ); } if( !bHasClass ) @@ -1358,21 +1358,21 @@ static void OutCSS1DropCapRule( if( pDCCharFormat ) aScriptItemSet.Set( pDCCharFormat->GetAttrSet() ); - OUString aNewSelector = aSelector + ".western" + aPseudo; + OUString aNewSelector = OUString::Concat(aSelector) + ".western" + aPseudo; { SwCSS1OutMode aMode( rHTMLWrt, CSS1_OUTMODE_WESTERN|CSS1_OUTMODE_RULE|CSS1_OUTMODE_DROPCAP, &aNewSelector ); OutCSS1_SwFormatDropAttrs( rHTMLWrt, rDrop, &aScriptItemSet ); } - aNewSelector = aSelector + ".cjk" + aPseudo; + aNewSelector = OUString::Concat(aSelector) + ".cjk" + aPseudo; { SwCSS1OutMode aMode( rHTMLWrt, CSS1_OUTMODE_CJK|CSS1_OUTMODE_RULE|CSS1_OUTMODE_DROPCAP, &aNewSelector ); OutCSS1_SwFormatDropAttrs( rHTMLWrt, rDrop, &aScriptItemSet ); } - aNewSelector = aSelector + ".ctl" + aPseudo; + aNewSelector = OUString::Concat(aSelector) + ".ctl" + aPseudo; { SwCSS1OutMode aMode( rHTMLWrt, CSS1_OUTMODE_CTL|CSS1_OUTMODE_RULE|CSS1_OUTMODE_DROPCAP, &aNewSelector ); @@ -1384,21 +1384,21 @@ static void OutCSS1DropCapRule( // If there are script dependencies and we are derived from a tag, // when we have to export a style dependent class for all // scripts - OUString aNewSelector = aSelector + "-western" + aPseudo; + OUString aNewSelector = OUString::Concat(aSelector) + "-western" + aPseudo; { SwCSS1OutMode aMode( rHTMLWrt, CSS1_OUTMODE_WESTERN|CSS1_OUTMODE_RULE|CSS1_OUTMODE_DROPCAP, &aNewSelector ); OutCSS1_SwFormatDropAttrs( rHTMLWrt, rDrop ); } - aNewSelector = aSelector + "-cjk" + aPseudo; + aNewSelector = OUString::Concat(aSelector) + "-cjk" + aPseudo; { SwCSS1OutMode aMode( rHTMLWrt, CSS1_OUTMODE_CJK|CSS1_OUTMODE_RULE|CSS1_OUTMODE_DROPCAP, &aNewSelector ); OutCSS1_SwFormatDropAttrs( rHTMLWrt, rDrop ); } - aNewSelector = aSelector + "-ctl" + aPseudo; + aNewSelector = OUString::Concat(aSelector) + "-ctl" + aPseudo; { SwCSS1OutMode aMode( rHTMLWrt, CSS1_OUTMODE_CTL|CSS1_OUTMODE_RULE|CSS1_OUTMODE_DROPCAP, &aNewSelector ); diff --git a/sw/source/uibase/docvw/edtwin2.cxx b/sw/source/uibase/docvw/edtwin2.cxx index b16455db07b0..a7aeb028c45e 100644 --- a/sw/source/uibase/docvw/edtwin2.cxx +++ b/sw/source/uibase/docvw/edtwin2.cxx @@ -179,15 +179,15 @@ void SwEditWin::RequestHelp(const HelpEvent &rEvt) sal_Int32 nFound = sText.indexOf(cMarkSeparator); if( nFound != -1 && (++nFound) < sText.getLength() ) { - OUString sSuffix( sText.copy(nFound) ); - if( sSuffix == "table" || - sSuffix == "frame" || - sSuffix == "region" || - sSuffix == "outline" || - sSuffix == "text" || - sSuffix == "graphic" || - sSuffix == "ole" || - sSuffix == "drawingobject" ) + std::u16string_view sSuffix( sText.subView(nFound) ); + if( sSuffix == u"table" || + sSuffix == u"frame" || + sSuffix == u"region" || + sSuffix == u"outline" || + sSuffix == u"text" || + sSuffix == u"graphic" || + sSuffix == u"ole" || + sSuffix == u"drawingobject" ) sText = sText.copy( 0, nFound - 1); } // #i104300# diff --git a/sw/source/uibase/uiview/view2.cxx b/sw/source/uibase/uiview/view2.cxx index a9f13a02b2df..910fea4e1bf2 100644 --- a/sw/source/uibase/uiview/view2.cxx +++ b/sw/source/uibase/uiview/view2.cxx @@ -2180,7 +2180,7 @@ auto PrepareJumpToTOXMark(SwDoc const& rDoc, OUString const& rName) return std::optional<std::pair<SwTOXMark, sal_Int32>>(); } sal_uInt16 const indexType(rName[second + 1]); - OUString const indexName(rName.copy(second + 2)); + std::u16string_view const indexName(rName.subView(second + 2)); SwTOXType const* pType(nullptr); switch (indexType) { diff --git a/sw/source/uibase/uiview/viewport.cxx b/sw/source/uibase/uiview/viewport.cxx index 1edfa5d52c26..af80d856daed 100644 --- a/sw/source/uibase/uiview/viewport.cxx +++ b/sw/source/uibase/uiview/viewport.cxx @@ -723,7 +723,7 @@ IMPL_LINK( SwView, ScrollHdl, ScrollBar *, p, void ) { sPageStr += " - "; sal_Int32 nChunkLen = std::min<sal_Int32>(aCnt.sStr.getLength(), 80); - OUString sChunk = aCnt.sStr.copy(0, nChunkLen); + std::u16string_view sChunk = aCnt.sStr.subView(0, nChunkLen); sPageStr = sChunk + sPageStr; sPageStr = sPageStr.replace('\t', ' '); sPageStr = sPageStr.replace(0x0a, ' '); diff --git a/sw/source/uibase/uno/unotxdoc.cxx b/sw/source/uibase/uno/unotxdoc.cxx index b9cb5cab3db7..a5ce16dc8642 100644 --- a/sw/source/uibase/uno/unotxdoc.cxx +++ b/sw/source/uibase/uno/unotxdoc.cxx @@ -4007,7 +4007,7 @@ Any SwXLinkNameAccessWrapper::getByName(const OUString& rName) OUString sSuffix(m_sLinkSuffix); if(sParam.getLength() > sSuffix.getLength() ) { - OUString sCmp = sParam.copy(sParam.getLength() - sSuffix.getLength(), + std::u16string_view sCmp = sParam.subView(sParam.getLength() - sSuffix.getLength(), sSuffix.getLength()); if(sCmp == sSuffix) { @@ -4128,7 +4128,7 @@ sal_Bool SwXLinkNameAccessWrapper::hasByName(const OUString& rName) OUString sParam(rName); if(sParam.getLength() > m_sLinkSuffix.getLength() ) { - OUString sCmp = sParam.copy(sParam.getLength() - m_sLinkSuffix.getLength(), + std::u16string_view sCmp = sParam.subView(sParam.getLength() - m_sLinkSuffix.getLength(), m_sLinkSuffix.getLength()); if(sCmp == m_sLinkSuffix) { @@ -4205,29 +4205,28 @@ void SwXLinkNameAccessWrapper::setPropertyValue( throw UnknownPropertyException(rPropName); } -static Any lcl_GetDisplayBitmap(const OUString& _sLinkSuffix) +static Any lcl_GetDisplayBitmap(std::u16string_view sLinkSuffix) { Any aRet; - OUString sLinkSuffix = _sLinkSuffix; - if(!sLinkSuffix.isEmpty()) - sLinkSuffix = sLinkSuffix.copy(1); + if(!sLinkSuffix.empty()) + sLinkSuffix = sLinkSuffix.substr(1); OUString sImgId; - if(sLinkSuffix == "outline") + if(sLinkSuffix == u"outline") sImgId = RID_BMP_NAVI_OUTLINE; - else if(sLinkSuffix == "table") + else if(sLinkSuffix == u"table") sImgId = RID_BMP_NAVI_TABLE; - else if(sLinkSuffix == "frame") + else if(sLinkSuffix == u"frame") sImgId = RID_BMP_NAVI_FRAME; - else if(sLinkSuffix == "graphic") + else if(sLinkSuffix == u"graphic") sImgId = RID_BMP_NAVI_GRAPHIC; - else if(sLinkSuffix == "ole") + else if(sLinkSuffix == u"ole") sImgId = RID_BMP_NAVI_OLE; - else if(sLinkSuffix.isEmpty()) + else if(sLinkSuffix.empty()) sImgId = RID_BMP_NAVI_BOOKMARK; - else if(sLinkSuffix == "region") + else if(sLinkSuffix == u"region") sImgId = RID_BMP_NAVI_REGION; - else if(sLinkSuffix == "drawingobject") + else if(sLinkSuffix == u"drawingobject") sImgId = RID_BMP_NAVI_DRAWOBJECT; if (!sImgId.isEmpty()) |