From e6d94a23f0d5153d5d2f1c6a7bc303466cd7ea65 Mon Sep 17 00:00:00 2001 From: falkTX Date: Tue, 8 Mar 2016 15:42:11 +0100 Subject: [PATCH] Update DPF --- source/modules/dgl/Application.hpp | 2 +- source/modules/dgl/ImageWidgets.hpp | 4 ++-- source/modules/dgl/src/Geometry.cpp | 4 ++-- source/modules/dgl/src/WidgetPrivateData.hpp | 11 ++++++----- source/modules/distrho/DistrhoUtils.hpp | 2 +- 5 files changed, 12 insertions(+), 11 deletions(-) diff --git a/source/modules/dgl/Application.hpp b/source/modules/dgl/Application.hpp index 85c3770f4..6787c493d 100644 --- a/source/modules/dgl/Application.hpp +++ b/source/modules/dgl/Application.hpp @@ -49,7 +49,7 @@ public: /** Destructor. */ - ~Application(); + virtual ~Application(); /** Idle function. diff --git a/source/modules/dgl/ImageWidgets.hpp b/source/modules/dgl/ImageWidgets.hpp index 5c23319b5..aafe19622 100644 --- a/source/modules/dgl/ImageWidgets.hpp +++ b/source/modules/dgl/ImageWidgets.hpp @@ -79,7 +79,7 @@ private: struct PrivateData; PrivateData* const pData; - DISTRHO_LEAK_DETECTOR(ImageButton) + DISTRHO_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR(ImageButton) }; // ----------------------------------------------------------------------- @@ -225,7 +225,7 @@ private: void setAbsolutePos(int, int) const noexcept {} void setAbsolutePos(const Point&) const noexcept {} - DISTRHO_LEAK_DETECTOR(ImageSlider) + DISTRHO_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR(ImageSlider) }; // ----------------------------------------------------------------------- diff --git a/source/modules/dgl/src/Geometry.cpp b/source/modules/dgl/src/Geometry.cpp index 11916c56a..2aafce70c 100644 --- a/source/modules/dgl/src/Geometry.cpp +++ b/source/modules/dgl/src/Geometry.cpp @@ -655,13 +655,13 @@ void Circle::_draw(const bool outline) { DISTRHO_SAFE_ASSERT_RETURN(fNumSegments >= 3 && fSize > 0.0f,); - float t, x = fSize, y = 0.0f; + double t, x = fSize, y = 0.0; glBegin(outline ? GL_LINE_LOOP : GL_POLYGON); for (uint i=0; i(self->getHeight()) - absolutePos.getY(), + static_cast(height - self->getHeight()) - absolutePos.getY(), static_cast(self->getWidth()), static_cast(self->getHeight())); } @@ -89,13 +90,13 @@ struct Widget::PrivateData { { // only set viewport pos glViewport(absolutePos.getX(), - /*height - static_cast(self->getHeight())*/ - absolutePos.getY(), - static_cast(width), - static_cast(height)); + /*static_cast(height - self->getHeight())*/ - absolutePos.getY(), + static_cast(width), + static_cast(height)); // then cut the outer bounds glScissor(absolutePos.getX(), - height - static_cast(self->getHeight()) - absolutePos.getY(), + static_cast(height - self->getHeight()) - absolutePos.getY(), static_cast(self->getWidth()), static_cast(self->getHeight())); diff --git a/source/modules/distrho/DistrhoUtils.hpp b/source/modules/distrho/DistrhoUtils.hpp index 967821d1f..9b768cb84 100644 --- a/source/modules/distrho/DistrhoUtils.hpp +++ b/source/modules/distrho/DistrhoUtils.hpp @@ -68,7 +68,7 @@ int64_t d_cconst(const uint8_t a, const uint8_t b, const uint8_t c, const uint8_ static inline uint32_t d_version(const uint8_t major, const uint8_t minor, const uint8_t micro) noexcept { - return (major << 16) | (minor << 8) | (micro << 0); + return uint32_t(major << 16) | uint32_t(minor << 8) | (micro << 0); } /*