[Libreoffice-commits] core.git: 2 commits - drawinglayer/source include/drawinglayer include/svx starmath/inc svx/source
Jan Holesovsky
kendy at collabora.com
Wed Mar 19 04:29:31 PDT 2014
drawinglayer/source/primitive2d/openglprimitive2d.cxx | 32 ++++++----------
include/drawinglayer/primitive2d/openglprimitive2d.hxx | 33 ++++++++--------
include/svx/sdr/contact/viewcontactofopengl.hxx | 28 +++++++-------
starmath/inc/node.hxx | 3 -
svx/source/sdr/contact/viewcontactofopengl.cxx | 34 +++++++----------
5 files changed, 57 insertions(+), 73 deletions(-)
New commits:
commit 24da9e2538dc8f80fb6ac6d498992f9093495b22
Author: Jan Holesovsky <kendy at collabora.com>
Date: Wed Mar 19 11:11:15 2014 +0100
Use sane indentation in new files.
Change-Id: Ida89284c00946d3972c4e45a5453ccfdff99713f
diff --git a/drawinglayer/source/primitive2d/openglprimitive2d.cxx b/drawinglayer/source/primitive2d/openglprimitive2d.cxx
index 48724df..3ed333b 100644
--- a/drawinglayer/source/primitive2d/openglprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/openglprimitive2d.cxx
@@ -10,29 +10,23 @@
#include <drawinglayer/primitive2d/openglprimitive2d.hxx>
#include <svx/sdr/primitive2d/svx_primitivetypes2d.hxx>
+using namespace drawinglayer::primitive2d;
-namespace drawinglayer
+OpenGLPrimitive2D::OpenGLPrimitive2D(const Point& rPos)
+ : m_aPos(rPos)
{
- namespace primitive2d
- {
-
- OpenGLPrimitive2D::OpenGLPrimitive2D(const Point& rPos)
- : m_aPos(rPos)
- {
- }
-
- bool OpenGLPrimitive2D::operator==( const BasePrimitive2D& rPrimitive ) const
- {
- if(BasePrimitive2D::operator==(rPrimitive))
- {
- const OpenGLPrimitive2D& rCompare = static_cast< const OpenGLPrimitive2D& >(rPrimitive);
- return m_aPos == rCompare.getPos();
- }
- return false;
- }
+}
- ImplPrimitive2DIDBlock(OpenGLPrimitive2D, PRIMITIVE2D_ID_OPENGLPRIMITIVE2D)
+bool OpenGLPrimitive2D::operator==( const BasePrimitive2D& rPrimitive ) const
+{
+ if(BasePrimitive2D::operator==(rPrimitive))
+ {
+ const OpenGLPrimitive2D& rCompare = static_cast< const OpenGLPrimitive2D& >(rPrimitive);
+ return m_aPos == rCompare.getPos();
}
+ return false;
}
+ImplPrimitive2DIDBlock(OpenGLPrimitive2D, PRIMITIVE2D_ID_OPENGLPRIMITIVE2D)
+
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/include/drawinglayer/primitive2d/openglprimitive2d.hxx b/include/drawinglayer/primitive2d/openglprimitive2d.hxx
index c251dcb..832a657 100644
--- a/include/drawinglayer/primitive2d/openglprimitive2d.hxx
+++ b/include/drawinglayer/primitive2d/openglprimitive2d.hxx
@@ -13,29 +13,28 @@
#include <tools/gen.hxx>
#include <drawinglayer/primitive2d/baseprimitive2d.hxx>
-namespace drawinglayer
-{
- namespace primitive2d
- {
+namespace drawinglayer {
+namespace primitive2d {
- class DRAWINGLAYER_DLLPUBLIC OpenGLPrimitive2D : public BasePrimitive2D
- {
- public:
- explicit OpenGLPrimitive2D(const Point& rPos);
+/// Primitive to hold data necessary for openGL objects
+class DRAWINGLAYER_DLLPUBLIC OpenGLPrimitive2D : public BasePrimitive2D
+{
+public:
+ explicit OpenGLPrimitive2D(const Point& rPos);
- const Point& getPos() const { return m_aPos; }
+ const Point& getPos() const { return m_aPos; }
- virtual bool operator==( const BasePrimitive2D& rPrimitive ) const;
+ virtual bool operator==( const BasePrimitive2D& rPrimitive ) const;
- /// provide unique ID
- DeclPrimitive2DIDBlock()
+ /// provide unique ID
+ DeclPrimitive2DIDBlock()
- private:
- Point m_aPos;
- };
+private:
+ Point m_aPos;
+};
- }
-}
+} // namespace primitive2d
+} // namespace drawinglayer
#endif
diff --git a/include/svx/sdr/contact/viewcontactofopengl.hxx b/include/svx/sdr/contact/viewcontactofopengl.hxx
index ad96b0c..e5fae8b 100644
--- a/include/svx/sdr/contact/viewcontactofopengl.hxx
+++ b/include/svx/sdr/contact/viewcontactofopengl.hxx
@@ -14,21 +14,21 @@
class SdrOpenGLObj;
-namespace sdr
+namespace sdr {
+namespace contact {
+
+class ViewContactOfOpenGL : public ViewContactOfSdrObj
{
- namespace contact
- {
- class ViewContactOfOpenGL : public ViewContactOfSdrObj
- {
- public:
- explicit ViewContactOfOpenGL(SdrOpenGLObj& rOpenGLObj);
- virtual ~ViewContactOfOpenGL();
-
- protected:
- virtual drawinglayer::primitive2d::Primitive2DSequence createViewIndependentPrimitive2DSequence() const;
- };
- }
-}
+public:
+ explicit ViewContactOfOpenGL(SdrOpenGLObj& rOpenGLObj);
+ virtual ~ViewContactOfOpenGL();
+
+protected:
+ virtual drawinglayer::primitive2d::Primitive2DSequence createViewIndependentPrimitive2DSequence() const;
+};
+
+} // namespace contact
+} // namespace sdr
#endif
diff --git a/svx/source/sdr/contact/viewcontactofopengl.cxx b/svx/source/sdr/contact/viewcontactofopengl.cxx
index 34630ec..054fb99 100644
--- a/svx/source/sdr/contact/viewcontactofopengl.cxx
+++ b/svx/source/sdr/contact/viewcontactofopengl.cxx
@@ -13,32 +13,26 @@
#include <svx/svdoopengl.hxx>
#include <tools/gen.hxx>
+using namespace sdr::contact;
-namespace sdr
+ViewContactOfOpenGL::ViewContactOfOpenGL(SdrOpenGLObj& rOpenGLObj)
+ : ViewContactOfSdrObj(rOpenGLObj)
{
- namespace contact
- {
-
- ViewContactOfOpenGL::ViewContactOfOpenGL(SdrOpenGLObj& rOpenGLObj)
- : ViewContactOfSdrObj(rOpenGLObj)
- {
- }
+}
- ViewContactOfOpenGL::~ViewContactOfOpenGL()
- {
- }
+ViewContactOfOpenGL::~ViewContactOfOpenGL()
+{
+}
- drawinglayer::primitive2d::Primitive2DSequence ViewContactOfOpenGL::createViewIndependentPrimitive2DSequence() const
- {
- com::sun::star::uno::Reference< com::sun::star::drawing::XShape > xShape(GetSdrObject().getUnoShape(), com::sun::star::uno::UNO_QUERY);
- const Point aPos(xShape->getPosition().X,xShape->getPosition().Y);
+drawinglayer::primitive2d::Primitive2DSequence ViewContactOfOpenGL::createViewIndependentPrimitive2DSequence() const
+{
+ com::sun::star::uno::Reference< com::sun::star::drawing::XShape > xShape(GetSdrObject().getUnoShape(), com::sun::star::uno::UNO_QUERY);
+ const Point aPos(xShape->getPosition().X,xShape->getPosition().Y);
- const drawinglayer::primitive2d::Primitive2DReference xReference(
- new drawinglayer::primitive2d::OpenGLPrimitive2D(aPos));
+ const drawinglayer::primitive2d::Primitive2DReference xReference(
+ new drawinglayer::primitive2d::OpenGLPrimitive2D(aPos));
- return drawinglayer::primitive2d::Primitive2DSequence(&xReference, 1);
- }
- }
+ return drawinglayer::primitive2d::Primitive2DSequence(&xReference, 1);
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
commit 3e57225929a12fb3d7cecbf662bb2d4605621da2
Author: Jan Holesovsky <kendy at collabora.com>
Date: Wed Mar 19 11:07:06 2014 +0100
Don't add visual noise in new code.
Change-Id: I3e8370fdfed58afe0c253410465219cce3065808
diff --git a/starmath/inc/node.hxx b/starmath/inc/node.hxx
index ab27af0..1f2b2a9 100644
--- a/starmath/inc/node.hxx
+++ b/starmath/inc/node.hxx
@@ -618,7 +618,6 @@ public:
void Accept(SmVisitor* pVisitor);
};
-////////////////////////////////////////////////////////////////////////////////
/** Dynamic Integral symbol node
*
@@ -830,8 +829,6 @@ public:
};
-////////////////////////////////////////////////////////////////////////////////
-
/** Dynamic Integral node
*
* Used to create Dynamically sized integrals
More information about the Libreoffice-commits
mailing list