From a5be07d6b627a18f104e2feed063ff9020e8c610 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Mon, 18 Dec 2017 14:24:50 +0200 Subject: inline use-once typedefs Change-Id: I5c3ffc03c26b3428f1f336e6ecba7838a1cf1157 Reviewed-on: https://gerrit.libreoffice.org/46764 Tested-by: Jenkins Reviewed-by: Noel Grandin --- svgio/inc/svgdocument.hxx | 2 -- svgio/inc/svgnode.hxx | 3 +-- svgio/source/svgreader/svgdocument.cxx | 4 ++-- 3 files changed, 3 insertions(+), 6 deletions(-) (limited to 'svgio') diff --git a/svgio/inc/svgdocument.hxx b/svgio/inc/svgdocument.hxx index 97acd39d8e31..de7fbc304c88 100644 --- a/svgio/inc/svgdocument.hxx +++ b/svgio/inc/svgdocument.hxx @@ -38,12 +38,10 @@ namespace svgio /// hash mapper to find nodes by their id typedef std::unordered_map< OUString, const SvgNode* > IdTokenMapper; - typedef std::pair< const OUString, const SvgNode* > IdTokenValueType; IdTokenMapper maIdTokenMapperList; /// hash mapper to find css styles by their id typedef std::unordered_map< OUString, const SvgStyleAttributes* > IdStyleTokenMapper; - typedef std::pair< const OUString, const SvgStyleAttributes* > IdStyleTokenValueType; IdStyleTokenMapper maIdStyleTokenMapperList; public: diff --git a/svgio/inc/svgnode.hxx b/svgio/inc/svgnode.hxx index a5da1faee343..fd4e45c5ccc4 100644 --- a/svgio/inc/svgnode.hxx +++ b/svgio/inc/svgnode.hxx @@ -45,7 +45,6 @@ namespace svgio namespace svgreader { typedef ::std::vector< SvgNode* > SvgNodeVector; - typedef ::std::vector< const SvgStyleAttributes* > SvgStyleAttributeVector; enum XmlSpace { @@ -109,7 +108,7 @@ namespace svgio // CSS style vector chain, used in decompose phase and built up once per node. // It contains the StyleHierarchy for the local node. INdependent from the // node hierarchy itself which also needs to be used in style entry solving - SvgStyleAttributeVector maCssStyleVector; + ::std::vector< const SvgStyleAttributes* > maCssStyleVector; /// possible local CssStyle, e.g. style="fill:red; stroke:red;" SvgStyleAttributes* mpLocalCssStyle; diff --git a/svgio/source/svgreader/svgdocument.cxx b/svgio/source/svgreader/svgdocument.cxx index 227ad4ae40d6..44fb0d507eec 100644 --- a/svgio/source/svgreader/svgdocument.cxx +++ b/svgio/source/svgreader/svgdocument.cxx @@ -51,7 +51,7 @@ namespace svgio { if(!rStr.isEmpty()) { - maIdTokenMapperList.insert(IdTokenValueType(rStr, &rNode)); + maIdTokenMapperList.emplace(rStr, &rNode); } } @@ -81,7 +81,7 @@ namespace svgio { if(!rStr.isEmpty()) { - maIdStyleTokenMapperList.insert(IdStyleTokenValueType(rStr, &rSvgStyleAttributes)); + maIdStyleTokenMapperList.emplace(rStr, &rSvgStyleAttributes); } } -- cgit