From a5e6a1faa36c72be6fcc16404f5daa4993d73bce Mon Sep 17 00:00:00 2001 From: José Guilherme Vanz Date: Thu, 6 Dec 2012 21:55:58 -0200 Subject: ::rtl:: removal in oox MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This commit removes some ::rtl:: prefixes on oox Change-Id: Ibb3be70695c48eb0a02fdf285a0c049e244d613e Signed-off-by: José Guilherme Vanz Reviewed-on: https://gerrit.libreoffice.org/1259 Reviewed-by: Caolán McNamara Tested-by: Caolán McNamara --- .../drawingml/diagram/constraintlistcontext.cxx | 1 - oox/source/drawingml/diagram/datamodelcontext.cxx | 1 - oox/source/drawingml/diagram/diagram.cxx | 29 ++++---- oox/source/drawingml/diagram/diagram.hxx | 78 +++++++++++----------- .../drawingml/diagram/diagramdefinitioncontext.cxx | 1 - .../drawingml/diagram/diagramfragmenthandler.cxx | 3 +- .../drawingml/diagram/diagramfragmenthandler.hxx | 4 +- .../drawingml/diagram/diagramlayoutatoms.cxx | 6 +- .../drawingml/diagram/diagramlayoutatoms.hxx | 26 ++++---- oox/source/drawingml/diagram/layoutnodecontext.cxx | 1 - 10 files changed, 72 insertions(+), 78 deletions(-) (limited to 'oox') diff --git a/oox/source/drawingml/diagram/constraintlistcontext.cxx b/oox/source/drawingml/diagram/constraintlistcontext.cxx index f1e5076b7b23..8bc0e945920b 100644 --- a/oox/source/drawingml/diagram/constraintlistcontext.cxx +++ b/oox/source/drawingml/diagram/constraintlistcontext.cxx @@ -23,7 +23,6 @@ using namespace ::oox::core; using namespace ::com::sun::star::uno; using namespace ::com::sun::star::xml::sax; -using ::rtl::OUString; namespace oox { namespace drawingml { diff --git a/oox/source/drawingml/diagram/datamodelcontext.cxx b/oox/source/drawingml/diagram/datamodelcontext.cxx index 1dcee0d14ded..2526be2f7e7d 100644 --- a/oox/source/drawingml/diagram/datamodelcontext.cxx +++ b/oox/source/drawingml/diagram/datamodelcontext.cxx @@ -26,7 +26,6 @@ using namespace ::oox::core; using namespace ::com::sun::star::xml::sax; using namespace ::com::sun::star::uno; -using ::rtl::OUString; namespace oox { namespace drawingml { diff --git a/oox/source/drawingml/diagram/diagram.cxx b/oox/source/drawingml/diagram/diagram.cxx index 29f28dcadd1b..0b7ab560696e 100644 --- a/oox/source/drawingml/diagram/diagram.cxx +++ b/oox/source/drawingml/diagram/diagram.cxx @@ -40,7 +40,6 @@ #include #include -using rtl::OUString; using namespace ::com::sun::star; namespace oox { namespace drawingml { @@ -99,9 +98,9 @@ void Diagram::setLayout( const DiagramLayoutPtr & pLayout) } #if OSL_DEBUG_LEVEL > 1 -rtl::OString normalizeDotName( const rtl::OUString& rStr ) +OString normalizeDotName( const OUString& rStr ) { - rtl::OUStringBuffer aBuf; + OUStringBuffer aBuf; aBuf.append((sal_Unicode)'N'); const sal_Int32 nLen(rStr.getLength()); @@ -113,12 +112,12 @@ rtl::OString normalizeDotName( const rtl::OUString& rStr ) aBuf.append((sal_Unicode)aChar); } - return rtl::OUStringToOString(aBuf.makeStringAndClear(), + return OUStringToOString(aBuf.makeStringAndClear(), RTL_TEXTENCODING_UTF8); } #endif -static sal_Int32 calcDepth( const rtl::OUString& rNodeName, +static sal_Int32 calcDepth( const OUString& rNodeName, const dgm::Connections& rCnx ) { // find length of longest path in 'isChild' graph, ending with rNodeName @@ -166,12 +165,12 @@ void Diagram::build( ) if( !aCurrPoint->msPresentationLayoutName.isEmpty() ) output << "label=\"" - << rtl::OUStringToOString( + << OUStringToOString( aCurrPoint->msPresentationLayoutName, RTL_TEXTENCODING_UTF8).getStr() << "\", "; else output << "label=\"" - << rtl::OUStringToOString( + << OUStringToOString( aCurrPoint->msModelId, RTL_TEXTENCODING_UTF8).getStr() << "\", "; @@ -200,7 +199,7 @@ void Diagram::build( ) << "textNode" << nCount << " [" << "label=\"" - << rtl::OUStringToOString( + << OUStringToOString( aCurrPoint->mpShape->getTextBody()->getParagraphs().front()->getRuns().front()->getText(), RTL_TEXTENCODING_UTF8).getStr() << "\"" << "];" << std::endl; @@ -249,7 +248,7 @@ void Diagram::build( ) << " [style=dotted," << ((aCurrCxn->mnType == XML_presOf) ? " color=red, " : ((aCurrCxn->mnType == XML_presParOf) ? " color=green, " : " ")) << "label=\"" - << rtl::OUStringToOString(aCurrCxn->msModelId, + << OUStringToOString(aCurrCxn->msModelId, RTL_TEXTENCODING_UTF8 ).getStr() << "\"];" << std::endl; } @@ -262,7 +261,7 @@ void Diagram::build( ) << " [" << ((aCurrCxn->mnType == XML_presOf) ? " color=red, " : ((aCurrCxn->mnType == XML_presParOf) ? " color=green, " : " ")) << "label=\"" - << rtl::OUStringToOString(aCurrCxn->msModelId, + << OUStringToOString(aCurrCxn->msModelId, RTL_TEXTENCODING_UTF8 ).getStr() << "\"];" << std::endl; } @@ -274,7 +273,7 @@ void Diagram::build( ) << " -> " << normalizeDotName(aCurrCxn->msDestId).getStr() << " [label=\"" - << rtl::OUStringToOString(aCurrCxn->msModelId, + << OUStringToOString(aCurrCxn->msModelId, RTL_TEXTENCODING_UTF8 ).getStr() << ((aCurrCxn->mnType == XML_presOf) ? "\", color=red]" : ((aCurrCxn->mnType == XML_presParOf) ? "\", color=green]" : "\"]")) << ";" << std::endl; @@ -356,10 +355,10 @@ void importFragment( core::XmlFilterBase& rFilter, void loadDiagram( ShapePtr& pShape, core::XmlFilterBase& rFilter, - const ::rtl::OUString& rDataModelPath, - const ::rtl::OUString& rLayoutPath, - const ::rtl::OUString& rQStylePath, - const ::rtl::OUString& rColorStylePath ) + const OUString& rDataModelPath, + const OUString& rLayoutPath, + const OUString& rQStylePath, + const OUString& rColorStylePath ) { DiagramPtr pDiagram( new Diagram() ); diff --git a/oox/source/drawingml/diagram/diagram.hxx b/oox/source/drawingml/diagram/diagram.hxx index fed91c619f15..23ec27ff6bdf 100644 --- a/oox/source/drawingml/diagram/diagram.hxx +++ b/oox/source/drawingml/diagram/diagram.hxx @@ -52,12 +52,12 @@ struct Connection void dump(); sal_Int32 mnType; - ::rtl::OUString msModelId; - ::rtl::OUString msSourceId; - ::rtl::OUString msDestId; - ::rtl::OUString msParTransId; - ::rtl::OUString msPresId; - ::rtl::OUString msSibTransId; + OUString msModelId; + OUString msSourceId; + OUString msDestId; + OUString msParTransId; + OUString msPresId; + OUString msSibTransId; sal_Int32 mnSourceOrder; sal_Int32 mnDestOrder; @@ -103,18 +103,18 @@ struct Point ShapePtr mpShape; - rtl::OUString msCnxId; - rtl::OUString msModelId; - rtl::OUString msColorTransformCategoryId; - rtl::OUString msColorTransformTypeId; - rtl::OUString msLayoutCategoryId; - rtl::OUString msLayoutTypeId; - rtl::OUString msPlaceholderText; - rtl::OUString msPresentationAssociationId; - rtl::OUString msPresentationLayoutName; - rtl::OUString msPresentationLayoutStyleLabel; - rtl::OUString msQuickStyleCategoryId; - rtl::OUString msQuickStyleTypeId; + OUString msCnxId; + OUString msModelId; + OUString msColorTransformCategoryId; + OUString msColorTransformTypeId; + OUString msLayoutCategoryId; + OUString msLayoutTypeId; + OUString msPlaceholderText; + OUString msPresentationAssociationId; + OUString msPresentationLayoutName; + OUString msPresentationLayoutStyleLabel; + OUString msQuickStyleCategoryId; + OUString msQuickStyleTypeId; sal_Int32 mnType; sal_Int32 mnMaxChildren; @@ -157,13 +157,13 @@ typedef boost::shared_ptr< LayoutNode > LayoutNodePtr; class DiagramData { public: - ::std::vector maExtDrawings; - typedef std::map< rtl::OUString, dgm::Point* > PointNameMap; - typedef std::map< rtl::OUString, + ::std::vector maExtDrawings; + typedef std::map< OUString, dgm::Point* > PointNameMap; + typedef std::map< OUString, std::vector > PointsNameMap; - typedef std::map< rtl::OUString, const dgm::Connection* > ConnectionNameMap; - typedef std::map< rtl::OUString, - std::vector > > StringMap; + typedef std::map< OUString, const dgm::Connection* > ConnectionNameMap; + typedef std::map< OUString, + std::vector > > StringMap; DiagramData(); FillPropertiesPtr & getFillProperties() @@ -180,7 +180,7 @@ public: { return maPointNameMap; } PointsNameMap & getPointsPresNameMap() { return maPointsPresNameMap; } - ::std::vector &getExtDrawings() + ::std::vector &getExtDrawings() { return maExtDrawings; } void dump(); private: @@ -202,17 +202,17 @@ typedef boost::shared_ptr< DiagramData > DiagramDataPtr; class DiagramLayout { public: - void setDefStyle( const ::rtl::OUString & sDefStyle ) + void setDefStyle( const OUString & sDefStyle ) { msDefStyle = sDefStyle; } - void setMinVer( const ::rtl::OUString & sMinVer ) + void setMinVer( const OUString & sMinVer ) { msMinVer = sMinVer; } - void setUniqueId( const ::rtl::OUString & sUniqueId ) + void setUniqueId( const OUString & sUniqueId ) { msUniqueId = sUniqueId; } - const ::rtl::OUString & getUniqueId() + const OUString & getUniqueId() { return msUniqueId; } - void setTitle( const ::rtl::OUString & sTitle ) + void setTitle( const OUString & sTitle ) { msTitle = sTitle; } - void setDesc( const ::rtl::OUString & sDesc ) + void setDesc( const OUString & sDesc ) { msDesc = sDesc; } LayoutNodePtr & getNode() @@ -229,12 +229,12 @@ public: { return mpStyleData; } private: - ::rtl::OUString msDefStyle; - ::rtl::OUString msMinVer; - ::rtl::OUString msUniqueId; + OUString msDefStyle; + OUString msMinVer; + OUString msUniqueId; - ::rtl::OUString msTitle; - ::rtl::OUString msDesc; + OUString msTitle; + OUString msDesc; LayoutNodePtr mpNode; DiagramDataPtr mpSampData; DiagramDataPtr mpStyleData; @@ -255,7 +255,7 @@ struct DiagramStyle ShapeStyleRef maTextStyle; }; -typedef std::map DiagramQStyleMap; +typedef std::map DiagramQStyleMap; struct DiagramColor { @@ -267,7 +267,7 @@ struct DiagramColor oox::drawingml::Color maTextEffectColor; }; -typedef std::map DiagramColorMap; +typedef std::map DiagramColorMap; /////////////////////// @@ -297,7 +297,7 @@ private: DiagramLayoutPtr mpLayout; DiagramQStyleMap maStyles; DiagramColorMap maColors; - std::map< ::rtl::OUString, ShapePtr > maShapeMap; + std::map< OUString, ShapePtr > maShapeMap; }; diff --git a/oox/source/drawingml/diagram/diagramdefinitioncontext.cxx b/oox/source/drawingml/diagram/diagramdefinitioncontext.cxx index 5bd9c5e0a2e7..6e153577aa79 100644 --- a/oox/source/drawingml/diagram/diagramdefinitioncontext.cxx +++ b/oox/source/drawingml/diagram/diagramdefinitioncontext.cxx @@ -24,7 +24,6 @@ using namespace ::oox::core; using namespace ::com::sun::star::uno; using namespace ::com::sun::star::xml::sax; -using ::rtl::OUString; namespace oox { namespace drawingml { diff --git a/oox/source/drawingml/diagram/diagramfragmenthandler.cxx b/oox/source/drawingml/diagram/diagramfragmenthandler.cxx index bdbfb269096b..658b46eff197 100644 --- a/oox/source/drawingml/diagram/diagramfragmenthandler.cxx +++ b/oox/source/drawingml/diagram/diagramfragmenthandler.cxx @@ -27,7 +27,6 @@ using namespace ::oox::core; using namespace ::com::sun::star::xml::sax; using namespace ::com::sun::star::uno; -using ::rtl::OUString; namespace oox { namespace drawingml { @@ -197,7 +196,7 @@ void DiagramQStylesFragmentHandler::onEndElement( ) } ColorFragmentHandler::ColorFragmentHandler( ::oox::core::XmlFilterBase& rFilter, - const ::rtl::OUString& rFragmentPath, + const OUString& rFragmentPath, DiagramColorMap& rColorsMap ) : FragmentHandler2(rFilter,rFragmentPath), maColorName(), diff --git a/oox/source/drawingml/diagram/diagramfragmenthandler.hxx b/oox/source/drawingml/diagram/diagramfragmenthandler.hxx index a858719b8df0..e42ddcf82967 100644 --- a/oox/source/drawingml/diagram/diagramfragmenthandler.hxx +++ b/oox/source/drawingml/diagram/diagramfragmenthandler.hxx @@ -30,7 +30,7 @@ namespace oox { namespace drawingml { class DiagramDataFragmentHandler : public ::oox::core::FragmentHandler { public: - DiagramDataFragmentHandler( oox::core::XmlFilterBase& rFilter, const ::rtl::OUString& rFragmentPath, const DiagramDataPtr pDataPtr ) throw(); + DiagramDataFragmentHandler( oox::core::XmlFilterBase& rFilter, const OUString& rFragmentPath, const DiagramDataPtr pDataPtr ) throw(); virtual ~DiagramDataFragmentHandler() throw(); virtual void SAL_CALL endDocument() throw (::com::sun::star::xml::sax::SAXException, ::com::sun::star::uno::RuntimeException); @@ -46,7 +46,7 @@ private: class DiagramLayoutFragmentHandler : public ::oox::core::FragmentHandler { public: - DiagramLayoutFragmentHandler( oox::core::XmlFilterBase& rFilter, const ::rtl::OUString& rFragmentPath, const DiagramLayoutPtr pDataPtr ) throw(); + DiagramLayoutFragmentHandler( oox::core::XmlFilterBase& rFilter, const OUString& rFragmentPath, const DiagramLayoutPtr pDataPtr ) throw(); virtual ~DiagramLayoutFragmentHandler() throw(); virtual void SAL_CALL endDocument() throw (::com::sun::star::xml::sax::SAXException, ::com::sun::star::uno::RuntimeException); diff --git a/oox/source/drawingml/diagram/diagramlayoutatoms.cxx b/oox/source/drawingml/diagram/diagramlayoutatoms.cxx index ee6860cfc97f..63cdcecc8f6f 100644 --- a/oox/source/drawingml/diagram/diagramlayoutatoms.cxx +++ b/oox/source/drawingml/diagram/diagramlayoutatoms.cxx @@ -155,7 +155,7 @@ void AlgAtom::accept( LayoutAtomVisitor& rVisitor ) void AlgAtom::layoutShape( const ShapePtr& rShape, const Diagram& /*rDgm*/, - const rtl::OUString& rName ) const + const OUString& rName ) const { switch(mnType) { @@ -516,7 +516,7 @@ class ShapeLayoutingVisitor : public LayoutAtomVisitor { ShapePtr mpParentShape; const Diagram& mrDgm; - rtl::OUString maName; + OUString maName; virtual void visit(ConstraintAtom& rAtom); virtual void visit(AlgAtom& rAtom); @@ -528,7 +528,7 @@ class ShapeLayoutingVisitor : public LayoutAtomVisitor public: ShapeLayoutingVisitor(const ShapePtr& rParentShape, const Diagram& rDgm, - const rtl::OUString& rName) : + const OUString& rName) : mpParentShape(rParentShape), mrDgm(rDgm), maName(rName) diff --git a/oox/source/drawingml/diagram/diagramlayoutatoms.hxx b/oox/source/drawingml/diagram/diagramlayoutatoms.hxx index 6c8c63258211..a377c84c77a0 100644 --- a/oox/source/drawingml/diagram/diagramlayoutatoms.hxx +++ b/oox/source/drawingml/diagram/diagramlayoutatoms.hxx @@ -64,7 +64,7 @@ struct ConditionAttr sal_Int32 mnFunc; sal_Int32 mnArg; sal_Int32 mnOp; - ::rtl::OUString msVal; + OUString msVal; }; struct LayoutAtomVisitor; @@ -82,9 +82,9 @@ public: */ virtual void accept( LayoutAtomVisitor& ) = 0; - void setName( const ::rtl::OUString& sName ) + void setName( const OUString& sName ) { msName = sName; } - const ::rtl::OUString& getName() const + const OUString& getName() const { return msName; } virtual void addChild( const LayoutAtomPtr & pNode ) @@ -96,7 +96,7 @@ public: void dump(int level = 0); protected: std::vector< LayoutAtomPtr > mpChildNodes; - ::rtl::OUString msName; + OUString msName; }; class ConstraintAtom @@ -114,7 +114,7 @@ public: void setFor( sal_Int32 nToken ) { mnFor = nToken; } - void setForName( const ::rtl::OUString & sName ) + void setForName( const OUString & sName ) { msForName = sName; } void setPointType( sal_Int32 nToken ) { mnPointType = nToken; } @@ -122,7 +122,7 @@ public: { mnType = nToken; } void setRefFor( sal_Int32 nToken ) { mnRefFor = nToken; } - void setRefForName( const ::rtl::OUString & sName ) + void setRefForName( const OUString & sName ) { msRefForName = sName; } void setRefType( sal_Int32 nToken ) { mnRefType = nToken; } @@ -136,11 +136,11 @@ public: { mnOperator = nToken; } private: sal_Int32 mnFor; - ::rtl::OUString msForName; + OUString msForName; sal_Int32 mnPointType; sal_Int32 mnType; sal_Int32 mnRefFor; - ::rtl::OUString msRefForName; + OUString msRefForName; sal_Int32 mnRefType; sal_Int32 mnRefPointType; double mfFactor; @@ -168,7 +168,7 @@ public: { maMap[nType]=nVal; } void layoutShape( const ShapePtr& rShape, const Diagram& rDgm, - const rtl::OUString& rName ) const; + const OUString& rName ) const; private: sal_Int32 mnType; ParamMap maMap; @@ -256,9 +256,9 @@ public: virtual void accept( LayoutAtomVisitor& ); VarMap & variables() { return mVariables; } - void setMoveWith( const ::rtl::OUString & sName ) + void setMoveWith( const OUString & sName ) { msMoveWith = sName; } - void setStyleLabel( const ::rtl::OUString & sLabel ) + void setStyleLabel( const OUString & sLabel ) { msStyleLabel = sLabel; } void setChildOrder( sal_Int32 nOrder ) { mnChildOrder = nOrder; } @@ -273,8 +273,8 @@ public: private: VarMap mVariables; - ::rtl::OUString msMoveWith; - ::rtl::OUString msStyleLabel; + OUString msMoveWith; + OUString msStyleLabel; ShapePtr mpShape; sal_Int32 mnChildOrder; }; diff --git a/oox/source/drawingml/diagram/layoutnodecontext.cxx b/oox/source/drawingml/diagram/layoutnodecontext.cxx index ac8465d4a517..5c0103836f0b 100644 --- a/oox/source/drawingml/diagram/layoutnodecontext.cxx +++ b/oox/source/drawingml/diagram/layoutnodecontext.cxx @@ -29,7 +29,6 @@ using namespace ::oox::core; using namespace ::com::sun::star::uno; using namespace ::com::sun::star::xml::sax; -using ::rtl::OUString; namespace oox { namespace drawingml { -- cgit