diff options
author | Rafael Dominguez <venccsralph@gmail.com> | 2011-05-07 18:54:59 -0430 |
---|---|---|
committer | Joseph Powers <jpowers27@cox.net> | 2011-05-07 22:43:22 -0700 |
commit | e7df508e1e0c5c0e77bfef220dd4e8f04d2fcecd (patch) | |
tree | c756fd1b2b054d7bff177d00bf993895b0c90fb8 | |
parent | 7efc8161f87f38709b96ac3ab7d5affcad54c722 (diff) |
Remove deprecated List in SwInsertGrfRulerDlg.
-rw-r--r-- | sw/source/ui/inc/insrule.hxx | 7 | ||||
-rw-r--r-- | sw/source/ui/misc/insrule.cxx | 8 |
2 files changed, 9 insertions, 6 deletions
diff --git a/sw/source/ui/inc/insrule.hxx b/sw/source/ui/inc/insrule.hxx index 385fdaa1cade..ea4d0cc08268 100644 --- a/sw/source/ui/inc/insrule.hxx +++ b/sw/source/ui/inc/insrule.hxx @@ -27,6 +27,9 @@ ************************************************************************/ #ifndef _INSRULE_HXX #define _INSRULE_HXX + +#include <vector> + #include "num.hxx" class SwRulerValueSet; @@ -39,7 +42,7 @@ class SwInsertGrfRulerDlg : public SfxModalDialog CancelButton aCancelPB; HelpButton aHelpPB; - List aGrfNames; + std::vector<String> aGrfNames; String sSimple; String sRulers; sal_uInt16 nSelPos; @@ -56,7 +59,7 @@ public: String GetGraphicName(); sal_Bool IsSimpleLine() {return nSelPos == 1;} - sal_Bool HasImages() const {return 0 != aGrfNames.Count();} + sal_Bool HasImages() const {return !aGrfNames.empty();} }; #endif diff --git a/sw/source/ui/misc/insrule.cxx b/sw/source/ui/misc/insrule.cxx index d861f085c86f..944a45f55808 100644 --- a/sw/source/ui/misc/insrule.cxx +++ b/sw/source/ui/misc/insrule.cxx @@ -76,10 +76,10 @@ SwInsertGrfRulerDlg::SwInsertGrfRulerDlg( Window* pParent ) : pExampleVS->InsertItem( 1, 1); pExampleVS->SetItemText( 1, sSimple); - for(sal_uInt16 i = 1; i <= aGrfNames.Count(); i++) + for(sal_uInt16 i = 1; i <= aGrfNames.size(); i++) { pExampleVS->InsertItem( i + 1, i); - pExampleVS->SetItemText( i + 1, *((String*)aGrfNames.GetObject(i-1))); + pExampleVS->SetItemText( i + 1, aGrfNames[i-1]); } pExampleVS->Show(); @@ -95,9 +95,9 @@ String SwInsertGrfRulerDlg::GetGraphicName() { String sRet; sal_uInt16 nSel = nSelPos - 2; //align selection position with ValueSet index - if(nSel < aGrfNames.Count()) + if(nSel < aGrfNames.size()) sRet = URIHelper::SmartRel2Abs( - INetURLObject(), *(String*) aGrfNames.GetObject(nSel), + INetURLObject(), aGrfNames[nSel], URIHelper::GetMaybeFileHdl()); return sRet; } |