DPF

DISTRHO Plugin Framework
Log | Files | Refs | Submodules | README | LICENSE

commit db1ec7ea5282bfaa0c12634d512acd9c417725c9
parent 3ec241f04c4850be3c39049fa6ad53653ab24c4c
Author: falkTX <falktx@gmail.com>
Date:   Tue,  6 May 2014 19:25:57 +0200

Cleanup

Diffstat:
Mdgl/Geometry.hpp | 10++++------
Mdgl/Widget.hpp | 3---
Mdgl/src/Widget.cpp | 17-----------------
Mdistrho/extra/d_leakdetector.hpp | 2+-
4 files changed, 5 insertions(+), 27 deletions(-)

diff --git a/dgl/Geometry.hpp b/dgl/Geometry.hpp @@ -23,6 +23,10 @@ START_NAMESPACE_DGL // ----------------------------------------------------------------------- +template<typename> class Rectangle; + +// ----------------------------------------------------------------------- + template<typename T> class Point { @@ -51,8 +55,6 @@ public: private: T fX, fY; template<typename> friend class Rectangle; - - DISTRHO_PREVENT_HEAP_ALLOCATION }; // ----------------------------------------------------------------------- @@ -87,8 +89,6 @@ public: private: T fWidth, fHeight; template<typename> friend class Rectangle; - - DISTRHO_PREVENT_HEAP_ALLOCATION }; // ----------------------------------------------------------------------- @@ -144,8 +144,6 @@ public: private: Point<T> fPos; Size<T> fSize; - - DISTRHO_PREVENT_HEAP_ALLOCATION }; // ----------------------------------------------------------------------- diff --git a/dgl/Widget.hpp b/dgl/Widget.hpp @@ -53,9 +53,6 @@ public: void setPos(int x, int y); void setPos(const Point<int>& pos); - void moveBy(int x, int y); - void moveBy(const Point<int>& pos); - int getWidth() const noexcept; int getHeight() const noexcept; const Size<int>& getSize() const noexcept; diff --git a/dgl/src/Widget.cpp b/dgl/src/Widget.cpp @@ -108,23 +108,6 @@ void Widget::setPos(const Point<int>& pos) fParent.repaint(); } -void Widget::moveBy(int x, int y) -{ - fArea.moveBy(x, y); - fParent.repaint(); -} - -void Widget::moveBy(const Point<int>& pos) -{ - Point<int> movedPos = fArea.getPos() + pos; - - if (fArea.getPos() == movedPos) - return; - - fArea.moveBy(pos); - fParent.repaint(); -} - int Widget::getWidth() const noexcept { return fArea.getWidth(); diff --git a/distrho/extra/d_leakdetector.hpp b/distrho/extra/d_leakdetector.hpp @@ -71,7 +71,7 @@ class DistrhoLeakedObjectDetector { public: //============================================================================== - DistrhoLeakedObjectDetector() noexcept { ++(getCounter().numObjects); } + DistrhoLeakedObjectDetector() noexcept { ++(getCounter().numObjects); } DistrhoLeakedObjectDetector(const DistrhoLeakedObjectDetector&) noexcept { ++(getCounter().numObjects); } ~DistrhoLeakedObjectDetector() noexcept