summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2013-08-10 12:30:11 +0100
committerCaolán McNamara <caolanm@redhat.com>2013-08-10 21:51:42 +0100
commit9891cb881b68d643bcae6160e2284be4728a3612 (patch)
tree15653864201a40b3192188fb7eaf339ed632226a
parentce6b095ce310c1bd6c9b3120497a3af511186d2b (diff)
Related: fdo#38838 remove String::Equals(const sal_Unicode* ...)
Change-Id: I6eeede3261e7b6f5ad81a4d2fa9ecc6c07002dbb
-rw-r--r--include/tools/string.hxx4
-rw-r--r--tools/source/string/strimp.cxx16
-rw-r--r--tools/source/string/tustring.cxx11
-rw-r--r--unusedcode.easy1
4 files changed, 2 insertions, 30 deletions
diff --git a/include/tools/string.hxx b/include/tools/string.hxx
index e1854803bc5c..9de7baa15ef6 100644
--- a/include/tools/string.hxx
+++ b/include/tools/string.hxx
@@ -134,6 +134,8 @@ private:
TOOLS_DLLPRIVATE UniString( sal_Unicode c );
TOOLS_DLLPRIVATE UniString& Assign( const sal_Unicode* pCharStr, xub_StrLen nLen );
TOOLS_DLLPRIVATE UniString& Expand( xub_StrLen nCount, sal_Unicode cExpandChar );
+ TOOLS_DLLPRIVATE sal_Bool Equals( const sal_Unicode* pCharStr,
+ xub_StrLen nIndex, xub_StrLen nLen ) const;
public:
UniString();
UniString( const ResId& rResId );
@@ -242,8 +244,6 @@ public:
sal_Bool EqualsIgnoreCaseAscii( const sal_Char* pAsciiStr ) const;
sal_Bool Equals( const UniString& rStr,
xub_StrLen nIndex, xub_StrLen nLen ) const;
- sal_Bool Equals( const sal_Unicode* pCharStr,
- xub_StrLen nIndex, xub_StrLen nLen ) const;
sal_Bool EqualsAscii( const sal_Char* pAsciiStr,
xub_StrLen nIndex, xub_StrLen nLen ) const;
sal_Bool EqualsIgnoreCaseAscii( const UniString& rStr,
diff --git a/tools/source/string/strimp.cxx b/tools/source/string/strimp.cxx
index 3c47dabfbeb6..6fbb280cab74 100644
--- a/tools/source/string/strimp.cxx
+++ b/tools/source/string/strimp.cxx
@@ -17,22 +17,6 @@
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/
-static sal_Int32 ImplStringCompare( const STRCODE* pStr1, const STRCODE* pStr2,
- xub_StrLen nCount )
-{
- sal_Int32 nRet = 0;
- while ( nCount &&
- ((nRet = ((sal_Int32)((STRCODEU)*pStr1))-((sal_Int32)((STRCODEU)*pStr2))) == 0) &&
- *pStr2 )
- {
- ++pStr1,
- ++pStr2,
- --nCount;
- }
-
- return nRet;
-}
-
static sal_Int32 ImplStringCompareWithoutZero( const STRCODE* pStr1, const STRCODE* pStr2,
sal_Int32 nCount )
{
diff --git a/tools/source/string/tustring.cxx b/tools/source/string/tustring.cxx
index ac4bb4ac5181..4d3d8c79f41a 100644
--- a/tools/source/string/tustring.cxx
+++ b/tools/source/string/tustring.cxx
@@ -412,17 +412,6 @@ sal_Bool STRING::Equals( const STRING& rStr, xub_StrLen nIndex, xub_StrLen nLen
return (ImplStringCompareWithoutZero( mpData->maStr+nIndex, rStr.mpData->maStr, nLen ) == 0);
}
-sal_Bool STRING::Equals( const STRCODE* pCharStr, xub_StrLen nIndex, xub_StrLen nLen ) const
-{
- DBG_CHKTHIS( STRING, DBGCHECKSTRING );
-
- // Are there enough codes for comparing?
- if ( nIndex > mpData->mnLen )
- return (*pCharStr == 0);
-
- return (ImplStringCompare( mpData->maStr+nIndex, pCharStr, nLen ) == 0);
-}
-
xub_StrLen STRING::Match( const STRING& rStr ) const
{
DBG_CHKTHIS( STRING, DBGCHECKSTRING );
diff --git a/unusedcode.easy b/unusedcode.easy
index 07246c1cb978..30b8cd98e437 100644
--- a/unusedcode.easy
+++ b/unusedcode.easy
@@ -75,7 +75,6 @@ SmFontPickList::Contains(Font const&) const
StatusBar::CopyItems(StatusBar const&)
StatusBar::HideItems()
StatusBar::ShowItems()
-String::Equals(unsigned short const*, unsigned short, unsigned short) const
SvFileStream::GetFileHandle() const
SvdProgressInfo::ReportError()
SvpSalInstance::PostEvent(SalFrame const*, void*, unsigned short)