diff options
author | Noel Grandin <noel@peralex.com> | 2015-06-15 16:41:32 +0200 |
---|---|---|
committer | Noel Grandin <noel@peralex.com> | 2015-06-19 09:52:04 +0200 |
commit | 4c1926f34ec038b1566081f98b12f0a0d900d1cf (patch) | |
tree | 9c1bbb2f9c459bdf85942bc35ec5631af4cb8426 /sdext | |
parent | f9a555799774de06be34467e0c22d9a63f0b236c (diff) |
the ElementTreeVisitable interface is doing nothing useful
Change-Id: I89e8fb90de8aadce89a8f5e353a923c972e1569f
Diffstat (limited to 'sdext')
-rw-r--r-- | sdext/source/pdfimport/tree/genericelements.hxx | 19 | ||||
-rw-r--r-- | sdext/source/pdfimport/tree/style.hxx | 1 | ||||
-rw-r--r-- | sdext/source/pdfimport/tree/treevisiting.hxx | 13 |
3 files changed, 7 insertions, 26 deletions
diff --git a/sdext/source/pdfimport/tree/genericelements.hxx b/sdext/source/pdfimport/tree/genericelements.hxx index c91d11d82c36..f1b9d3442738 100644 --- a/sdext/source/pdfimport/tree/genericelements.hxx +++ b/sdext/source/pdfimport/tree/genericelements.hxx @@ -70,7 +70,7 @@ namespace pdfi css::uno::XComponentContext > m_xContext; }; - struct Element : public ElementTreeVisitable + struct Element { protected: Element( Element* pParent ) @@ -83,6 +83,11 @@ namespace pdfi public: virtual ~Element(); + /** + To be implemented by every tree node that needs to be + visitable. + */ + virtual void visitedBy( ElementTreeVisitor&, const std::list< Element* >::const_iterator& rParentIt ) = 0; /// Apply visitor to all children void applyToChildren( ElementTreeVisitor& ); /// Union element geometry with given element @@ -106,7 +111,6 @@ namespace pdfi struct ListElement : public Element { ListElement() : Element( NULL ) {} - // ElementTreeVisitable virtual void visitedBy( ElementTreeVisitor&, const std::list< Element* >::const_iterator& ) SAL_OVERRIDE; }; @@ -117,7 +121,6 @@ namespace pdfi HyperlinkElement( Element* pParent, const OUString& rURI ) : Element( pParent ), URI( rURI ) {} public: - // ElementTreeVisitable virtual void visitedBy( ElementTreeVisitor&, const std::list< Element* >::const_iterator& ) SAL_OVERRIDE; OUString URI; @@ -163,7 +166,6 @@ namespace pdfi : DrawElement( pParent, nGCId ) {} public: - // ElementTreeVisitable virtual void visitedBy( ElementTreeVisitor&, const std::list< Element* >::const_iterator& ) SAL_OVERRIDE; }; @@ -175,7 +177,6 @@ namespace pdfi : GraphicalElement( pParent, nGCId ), FontId( nFontId ) {} public: - // ElementTreeVisitable virtual void visitedBy( ElementTreeVisitor&, const std::list< Element* >::const_iterator& ) SAL_OVERRIDE; OUStringBuffer Text; @@ -189,7 +190,6 @@ namespace pdfi ParagraphElement( Element* pParent ) : Element( pParent ), Type( Normal ), bRtl( false ) {} public: - // ElementTreeVisitable virtual void visitedBy( ElementTreeVisitor&, const std::list< Element* >::const_iterator& rParentIt ) SAL_OVERRIDE; // returns true only if only a single line is contained @@ -213,7 +213,6 @@ namespace pdfi const basegfx::B2DPolyPolygon& rPolyPoly, sal_Int8 nAction ); public: - // ElementTreeVisitable virtual void visitedBy( ElementTreeVisitor&, const std::list< Element* >::const_iterator& rParentIt ) SAL_OVERRIDE; void updateGeometry(); @@ -234,7 +233,6 @@ namespace pdfi : DrawElement( pParent, nGCId ), Image( nImage ) {} public: - // ElementTreeVisitable virtual void visitedBy( ElementTreeVisitor&, const std::list< Element* >::const_iterator& ) SAL_OVERRIDE; ImageId Image; @@ -252,10 +250,9 @@ namespace pdfi private: // helper method for resolveHyperlinks bool resolveHyperlink( std::list<Element*>::iterator link_it, std::list<Element*>& rElements ); - public: + public: virtual ~PageElement(); - // ElementTreeVisitable virtual void visitedBy( ElementTreeVisitor&, const std::list< Element* >::const_iterator& rParentIt ) SAL_OVERRIDE; void emitPageAnchoredElements( EmitContext& rEmitContext ); @@ -282,9 +279,7 @@ namespace pdfi public: virtual ~DocumentElement(); - // ElementTreeVisitable virtual void visitedBy( ElementTreeVisitor&, const std::list< Element* >::const_iterator& ) SAL_OVERRIDE; - }; // this class is the differentiator of document types: it will create diff --git a/sdext/source/pdfimport/tree/style.hxx b/sdext/source/pdfimport/tree/style.hxx index 2b2e0a18d25e..d29cf8e5412a 100644 --- a/sdext/source/pdfimport/tree/style.hxx +++ b/sdext/source/pdfimport/tree/style.hxx @@ -31,7 +31,6 @@ namespace pdfi { struct Element; struct EmitContext; - struct ElementTreeVisitable; class StyleContainer { diff --git a/sdext/source/pdfimport/tree/treevisiting.hxx b/sdext/source/pdfimport/tree/treevisiting.hxx index 35217f845423..d19eafc210d5 100644 --- a/sdext/source/pdfimport/tree/treevisiting.hxx +++ b/sdext/source/pdfimport/tree/treevisiting.hxx @@ -55,19 +55,6 @@ namespace pdfi }; typedef boost::shared_ptr<ElementTreeVisitor> ElementTreeVisitorSharedPtr; - /** Visitee interface - - To be implemented by every tree node that needs to be - visitable. - */ - struct ElementTreeVisitable - { - virtual void visitedBy( ElementTreeVisitor&, const std::list< Element* >::const_iterator& rParentIt ) = 0; - - protected: - ~ElementTreeVisitable() {} - }; - typedef boost::shared_ptr<ElementTreeVisitable> ElementTreeVisitableSharedPtr; } #endif |