diff --git a/dpf b/dpf index 5709c0e..2e508c7 160000 --- a/dpf +++ b/dpf @@ -1 +1 @@ -Subproject commit 5709c0e4e573921e3fe90a54113f57885f4e4340 +Subproject commit 2e508c73e95ef50947e3ed6e941b67b1f6b5bed4 diff --git a/plugins/PowerJuice/PowerJuiceUI.cpp b/plugins/PowerJuice/PowerJuiceUI.cpp index 7c698b1..b7a7e2c 100644 --- a/plugins/PowerJuice/PowerJuiceUI.cpp +++ b/plugins/PowerJuice/PowerJuiceUI.cpp @@ -101,6 +101,9 @@ PowerJuiceUI::PowerJuiceUI() // set default values programLoaded(0); + + // automatically-scale + setGeometryConstraints(PowerJuiceArtwork::backgroundWidth, PowerJuiceArtwork::backgroundHeight, true, true); } // ----------------------------------------------------------------------- @@ -153,7 +156,7 @@ void PowerJuiceUI::imageButtonClicked(ImageButton* button, int) if (button != fButtonAbout) return; - fAboutWindow.exec(); + fAboutWindow.runAsModal(); } void PowerJuiceUI::imageKnobDragStarted(ImageKnob* knob) @@ -213,7 +216,9 @@ void PowerJuiceUI::uiIdle() void PowerJuiceUI::onDisplay() { - fImgBackground.draw(); + const GraphicsContext& context(getGraphicsContext()); + + fImgBackground.draw(context); if (dsp == nullptr) return; diff --git a/plugins/PowerJuiceX2/PowerJuiceX2UI.cpp b/plugins/PowerJuiceX2/PowerJuiceX2UI.cpp index ec24322..df90782 100644 --- a/plugins/PowerJuiceX2/PowerJuiceX2UI.cpp +++ b/plugins/PowerJuiceX2/PowerJuiceX2UI.cpp @@ -101,6 +101,9 @@ PowerJuiceX2UI::PowerJuiceX2UI() // set default values programLoaded(0); + + // automatically-scale + setGeometryConstraints(PowerJuiceX2Artwork::backgroundWidth, PowerJuiceX2Artwork::backgroundHeight, true, true); } // ----------------------------------------------------------------------- @@ -153,7 +156,7 @@ void PowerJuiceX2UI::imageButtonClicked(ImageButton* button, int) if (button != fButtonAbout) return; - fAboutWindow.exec(); + fAboutWindow.runAsModal(); } void PowerJuiceX2UI::imageKnobDragStarted(ImageKnob* knob) @@ -213,7 +216,9 @@ void PowerJuiceX2UI::uiIdle() void PowerJuiceX2UI::onDisplay() { - fImgBackground.draw(); + const GraphicsContext& context(getGraphicsContext()); + + fImgBackground.draw(context); if (dsp == nullptr) return; diff --git a/plugins/StutterJuice/StutterJuiceUI.cpp b/plugins/StutterJuice/StutterJuiceUI.cpp index 67c945c..c53244f 100644 --- a/plugins/StutterJuice/StutterJuiceUI.cpp +++ b/plugins/StutterJuice/StutterJuiceUI.cpp @@ -81,6 +81,9 @@ StutterJuiceUI::StutterJuiceUI() // set default values programLoaded(0); + + // automatically-scale + setGeometryConstraints(StutterJuiceArtwork::backgroundWidth, StutterJuiceArtwork::backgroundHeight, true, true); } // ----------------------------------------------------------------------- @@ -112,7 +115,7 @@ void StutterJuiceUI::imageButtonClicked(ImageButton* button, int) if (button != fButtonAbout) return; - fAboutWindow.exec(); + fAboutWindow.runAsModal(); } void StutterJuiceUI::imageSliderDragStarted(ImageSlider* slider) @@ -132,10 +135,12 @@ void StutterJuiceUI::imageSliderValueChanged(ImageSlider* slider, float value) void StutterJuiceUI::onDisplay() { - fImgBackground.draw(); + const GraphicsContext& context(getGraphicsContext()); + + fImgBackground.draw(context); drawLFOs(); - fImgOverlay.draw(); + fImgOverlay.draw(context); } // ----------------------------------------------------------------------- diff --git a/plugins/TriggerJuice/TriggerJuiceUI.cpp b/plugins/TriggerJuice/TriggerJuiceUI.cpp index 413599e..a3d44a5 100644 --- a/plugins/TriggerJuice/TriggerJuiceUI.cpp +++ b/plugins/TriggerJuice/TriggerJuiceUI.cpp @@ -98,6 +98,9 @@ TriggerJuiceUI::TriggerJuiceUI() // set default values programLoaded(0); + + // automatically-scale + setGeometryConstraints(TriggerJuiceArtwork::backgroundWidth, TriggerJuiceArtwork::backgroundHeight, true, true); } // ----------------------------------------------------------------------- diff --git a/plugins/VectorJuice/VectorJuiceUI.cpp b/plugins/VectorJuice/VectorJuiceUI.cpp index 69185e4..a4d606c 100644 --- a/plugins/VectorJuice/VectorJuiceUI.cpp +++ b/plugins/VectorJuice/VectorJuiceUI.cpp @@ -25,11 +25,9 @@ START_NAMESPACE_DISTRHO // ----------------------------------------------------------------------- VectorJuiceUI::VectorJuiceUI() - : UI(), + : UI(VectorJuiceArtwork::backgroundWidth, VectorJuiceArtwork::backgroundHeight), fAboutWindow(this) { - setSize(VectorJuiceArtwork::backgroundWidth, VectorJuiceArtwork::backgroundHeight); - // xy params paramX = paramY = 0.5f; @@ -186,6 +184,9 @@ VectorJuiceUI::VectorJuiceUI() // set default values programLoaded(0); + + // automatically-scale + setGeometryConstraints(VectorJuiceArtwork::backgroundWidth, VectorJuiceArtwork::backgroundHeight, true, true); } // ----------------------------------------------------------------------- @@ -303,7 +304,7 @@ void VectorJuiceUI::imageButtonClicked(ImageButton* button, int) if (button != fButtonAbout) return; - fAboutWindow.exec(); + fAboutWindow.runAsModal(); } void VectorJuiceUI::imageKnobDragStarted(ImageKnob* knob) @@ -338,7 +339,9 @@ void VectorJuiceUI::imageSliderValueChanged(ImageSlider* slider, float value) void VectorJuiceUI::onDisplay() { - fImgBackground.draw(); + const GraphicsContext& context(getGraphicsContext()); + + fImgBackground.draw(context); // get x, y mapped to XY area int x = fCanvasArea.getX() + paramX*fCanvasArea.getWidth() - fImgRoundlet.getWidth()/2; diff --git a/plugins/WobbleJuice/WobbleJuiceUI.cpp b/plugins/WobbleJuice/WobbleJuiceUI.cpp index d0885a8..31fd121 100644 --- a/plugins/WobbleJuice/WobbleJuiceUI.cpp +++ b/plugins/WobbleJuice/WobbleJuiceUI.cpp @@ -23,11 +23,9 @@ START_NAMESPACE_DISTRHO // ----------------------------------------------------------------------- WobbleJuiceUI::WobbleJuiceUI() - : UI(), + : UI(WobbleJuiceArtwork::backgroundWidth, WobbleJuiceArtwork::backgroundHeight), fAboutWindow(this) { - setSize(WobbleJuiceArtwork::backgroundWidth, WobbleJuiceArtwork::backgroundHeight); - // background fImgBackground = Image(WobbleJuiceArtwork::backgroundData, WobbleJuiceArtwork::backgroundWidth, WobbleJuiceArtwork::backgroundHeight, kImageFormatBGR); @@ -102,6 +100,9 @@ WobbleJuiceUI::WobbleJuiceUI() // set default values programLoaded(0); + + // automatically-scale + setGeometryConstraints(WobbleJuiceArtwork::backgroundWidth, WobbleJuiceArtwork::backgroundHeight, true, true); } // ----------------------------------------------------------------------- @@ -154,7 +155,7 @@ void WobbleJuiceUI::imageButtonClicked(ImageButton* button, int) if (button != fButtonAbout) return; - fAboutWindow.exec(); + fAboutWindow.runAsModal(); } void WobbleJuiceUI::imageKnobDragStarted(ImageKnob* knob)