From 8a3aef5c080eaadfcb88f1b86699466f9c5fdb50 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Caol=C3=A1n=20McNamara?= Date: Mon, 14 Feb 2011 11:23:22 +0000 Subject: [PATCH] adapt for move of natural sort --- sfx2/source/dialog/templdlg.cxx | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/sfx2/source/dialog/templdlg.cxx b/sfx2/source/dialog/templdlg.cxx index 538ca9364bb7..0c90572fa94e 100644 --- a/sfx2/source/dialog/templdlg.cxx +++ b/sfx2/source/dialog/templdlg.cxx @@ -76,6 +76,7 @@ #include #include +#include using namespace ::com::sun::star; using namespace ::com::sun::star::beans; @@ -684,7 +685,7 @@ StyleTreeArr_Impl &MakeTree_Impl(StyleTreeArr_Impl &rArr) // initial sortiert einfuegen USHORT nPos; for( nPos = 0 ; nPos < pCmp->Count() && - (*pCmp->pChilds)[nPos]->aName.CompareToNumeric(pEntry->aName) < 0 ; nPos++); + comphelper::string::compareNatural((*pCmp->pChilds)[nPos]->aName, pEntry->aName) < 0 ; nPos++); pCmp->Put(pEntry,nPos); break; } @@ -1317,7 +1318,7 @@ void SfxCommonTemplateDialog_Impl::UpdateStyles_Impl(USHORT nFlags) //Bubblesort USHORT nPos; for( nPos = aStrings.Count() ; nPos && - aStrings[nPos-1]->CompareToNumeric(pStyle->GetName()) > 0 ; nPos--); + comphelper::string::compareNatural(*(aStrings[nPos-1]), pStyle->GetName()) > 0 ; nPos--); aStrings.Insert( new String( pStyle->GetName() ), nPos ); pStyle = pStyleSheetPool->Next(); }