From 257d494a3a1d2a093ede8788ab3b8c68db2d9898 Mon Sep 17 00:00:00 2001 From: falkTX Date: Tue, 24 Feb 2015 15:56:46 +0000 Subject: [PATCH] Don't use about-dialogs in dpf plugins on osx, fixme later --- .../distrho-3bandeq/DistrhoUI3BandEQ.cpp | 10 ++++++++-- .../distrho-3bandeq/DistrhoUI3BandEQ.hpp | 2 ++ .../distrho-3bandsplitter/DistrhoUI3BandSplitter.cpp | 10 ++++++++-- .../distrho-3bandsplitter/DistrhoUI3BandSplitter.hpp | 2 ++ .../native-plugins/distrho-nekobi/DistrhoUINekobi.cpp | 10 ++++++++-- .../native-plugins/distrho-nekobi/DistrhoUINekobi.hpp | 2 ++ .../distrho-pingpongpan/DistrhoUIPingPongPan.cpp | 10 ++++++++-- .../distrho-pingpongpan/DistrhoUIPingPongPan.hpp | 2 ++ .../distrho-vectorjuice/VectorJuiceUI.cpp | 10 ++++++++-- .../distrho-vectorjuice/VectorJuiceUI.hpp | 2 ++ .../distrho-wobblejuice/WobbleJuiceUI.cpp | 10 ++++++++-- .../distrho-wobblejuice/WobbleJuiceUI.hpp | 2 ++ 12 files changed, 60 insertions(+), 12 deletions(-) diff --git a/source/native-plugins/distrho-3bandeq/DistrhoUI3BandEQ.cpp b/source/native-plugins/distrho-3bandeq/DistrhoUI3BandEQ.cpp index af7997c2a..d72df4eaf 100644 --- a/source/native-plugins/distrho-3bandeq/DistrhoUI3BandEQ.cpp +++ b/source/native-plugins/distrho-3bandeq/DistrhoUI3BandEQ.cpp @@ -24,8 +24,10 @@ START_NAMESPACE_DISTRHO // ----------------------------------------------------------------------- DistrhoUI3BandEQ::DistrhoUI3BandEQ() - : UI(), - fAboutWindow(this) + : UI() +#ifndef DISTRHO_OS_MAC + , fAboutWindow(this) +#endif { // set UI size setSize(DistrhoArtwork3BandEQ::backgroundWidth, DistrhoArtwork3BandEQ::backgroundHeight); @@ -33,9 +35,11 @@ DistrhoUI3BandEQ::DistrhoUI3BandEQ() // background fImgBackground = Image(DistrhoArtwork3BandEQ::backgroundData, DistrhoArtwork3BandEQ::backgroundWidth, DistrhoArtwork3BandEQ::backgroundHeight, GL_BGR); +#ifndef DISTRHO_OS_MAC // about Image aboutImage(DistrhoArtwork3BandEQ::aboutData, DistrhoArtwork3BandEQ::aboutWidth, DistrhoArtwork3BandEQ::aboutHeight, GL_BGR); fAboutWindow.setImage(aboutImage); +#endif // sliders Image sliderImage(DistrhoArtwork3BandEQ::sliderData, DistrhoArtwork3BandEQ::sliderWidth, DistrhoArtwork3BandEQ::sliderHeight); @@ -157,7 +161,9 @@ void DistrhoUI3BandEQ::imageButtonClicked(ImageButton* button, int) if (button != fButtonAbout) return; +#ifndef DISTRHO_OS_MAC fAboutWindow.exec(); +#endif } void DistrhoUI3BandEQ::imageKnobDragStarted(ImageKnob* knob) diff --git a/source/native-plugins/distrho-3bandeq/DistrhoUI3BandEQ.hpp b/source/native-plugins/distrho-3bandeq/DistrhoUI3BandEQ.hpp index 05e06b93a..a16bfdab2 100644 --- a/source/native-plugins/distrho-3bandeq/DistrhoUI3BandEQ.hpp +++ b/source/native-plugins/distrho-3bandeq/DistrhoUI3BandEQ.hpp @@ -66,7 +66,9 @@ protected: private: Image fImgBackground; +#ifndef DISTRHO_OS_MAC ImageAboutWindow fAboutWindow; +#endif ScopedPointer fButtonAbout; ScopedPointer fKnobLowMid, fKnobMidHigh; diff --git a/source/native-plugins/distrho-3bandsplitter/DistrhoUI3BandSplitter.cpp b/source/native-plugins/distrho-3bandsplitter/DistrhoUI3BandSplitter.cpp index 9ba367e50..ccd2d9711 100644 --- a/source/native-plugins/distrho-3bandsplitter/DistrhoUI3BandSplitter.cpp +++ b/source/native-plugins/distrho-3bandsplitter/DistrhoUI3BandSplitter.cpp @@ -24,8 +24,10 @@ START_NAMESPACE_DISTRHO // ----------------------------------------------------------------------- DistrhoUI3BandSplitter::DistrhoUI3BandSplitter() - : UI(), - fAboutWindow(this) + : UI() +#ifndef DISTRHO_OS_MAC + , fAboutWindow(this) +#endif { // set UI size setSize(DistrhoArtwork3BandSplitter::backgroundWidth, DistrhoArtwork3BandSplitter::backgroundHeight); @@ -33,9 +35,11 @@ DistrhoUI3BandSplitter::DistrhoUI3BandSplitter() // background fImgBackground = Image(DistrhoArtwork3BandSplitter::backgroundData, DistrhoArtwork3BandSplitter::backgroundWidth, DistrhoArtwork3BandSplitter::backgroundHeight, GL_BGR); +#ifndef DISTRHO_OS_MAC // about Image aboutImage(DistrhoArtwork3BandSplitter::aboutData, DistrhoArtwork3BandSplitter::aboutWidth, DistrhoArtwork3BandSplitter::aboutHeight, GL_BGR); fAboutWindow.setImage(aboutImage); +#endif // sliders Image sliderImage(DistrhoArtwork3BandSplitter::sliderData, DistrhoArtwork3BandSplitter::sliderWidth, DistrhoArtwork3BandSplitter::sliderHeight); @@ -157,7 +161,9 @@ void DistrhoUI3BandSplitter::imageButtonClicked(ImageButton* button, int) if (button != fButtonAbout) return; +#ifndef DISTRHO_OS_MAC fAboutWindow.exec(); +#endif } void DistrhoUI3BandSplitter::imageKnobDragStarted(ImageKnob* knob) diff --git a/source/native-plugins/distrho-3bandsplitter/DistrhoUI3BandSplitter.hpp b/source/native-plugins/distrho-3bandsplitter/DistrhoUI3BandSplitter.hpp index 5d4482248..27f4c1bf0 100644 --- a/source/native-plugins/distrho-3bandsplitter/DistrhoUI3BandSplitter.hpp +++ b/source/native-plugins/distrho-3bandsplitter/DistrhoUI3BandSplitter.hpp @@ -66,7 +66,9 @@ protected: private: Image fImgBackground; +#ifndef DISTRHO_OS_MAC ImageAboutWindow fAboutWindow; +#endif ScopedPointer fButtonAbout; ScopedPointer fKnobLowMid, fKnobMidHigh; diff --git a/source/native-plugins/distrho-nekobi/DistrhoUINekobi.cpp b/source/native-plugins/distrho-nekobi/DistrhoUINekobi.cpp index aeda697a4..874ee8210 100644 --- a/source/native-plugins/distrho-nekobi/DistrhoUINekobi.cpp +++ b/source/native-plugins/distrho-nekobi/DistrhoUINekobi.cpp @@ -23,8 +23,10 @@ START_NAMESPACE_DISTRHO // ----------------------------------------------------------------------- DistrhoUINekobi::DistrhoUINekobi() - : UI(), - fAboutWindow(this) + : UI() +#ifndef DISTRHO_OS_MAC + , fAboutWindow(this) +#endif { // FIXME fNeko.setTimerSpeed(5); @@ -35,8 +37,10 @@ DistrhoUINekobi::DistrhoUINekobi() // background fImgBackground = Image(DistrhoArtworkNekobi::backgroundData, DistrhoArtworkNekobi::backgroundWidth, DistrhoArtworkNekobi::backgroundHeight, GL_BGR); +#ifndef DISTRHO_OS_MAC Image aboutImage(DistrhoArtworkNekobi::aboutData, DistrhoArtworkNekobi::aboutWidth, DistrhoArtworkNekobi::aboutHeight, GL_BGR); fAboutWindow.setImage(aboutImage); +#endif // slider Image sliderImage(DistrhoArtworkNekobi::sliderData, DistrhoArtworkNekobi::sliderWidth, DistrhoArtworkNekobi::sliderHeight); @@ -182,7 +186,9 @@ void DistrhoUINekobi::imageButtonClicked(ImageButton* button, int) if (button != fButtonAbout) return; +#ifndef DISTRHO_OS_MAC fAboutWindow.exec(); +#endif } void DistrhoUINekobi::imageKnobDragStarted(ImageKnob* knob) diff --git a/source/native-plugins/distrho-nekobi/DistrhoUINekobi.hpp b/source/native-plugins/distrho-nekobi/DistrhoUINekobi.hpp index ab29a2935..5d387f031 100644 --- a/source/native-plugins/distrho-nekobi/DistrhoUINekobi.hpp +++ b/source/native-plugins/distrho-nekobi/DistrhoUINekobi.hpp @@ -71,7 +71,9 @@ protected: private: Image fImgBackground; +#ifndef DISTRHO_OS_MAC ImageAboutWindow fAboutWindow; +#endif NekoWidget fNeko; ScopedPointer fButtonAbout; diff --git a/source/native-plugins/distrho-pingpongpan/DistrhoUIPingPongPan.cpp b/source/native-plugins/distrho-pingpongpan/DistrhoUIPingPongPan.cpp index 038384e6d..4303ffe5d 100644 --- a/source/native-plugins/distrho-pingpongpan/DistrhoUIPingPongPan.cpp +++ b/source/native-plugins/distrho-pingpongpan/DistrhoUIPingPongPan.cpp @@ -22,8 +22,10 @@ START_NAMESPACE_DISTRHO // ----------------------------------------------------------------------- DistrhoUIPingPongPan::DistrhoUIPingPongPan() - : UI(), - fAboutWindow(this) + : UI() +#ifndef DISTRHO_OS_MAC + , fAboutWindow(this) +#endif { // set UI size setSize(DistrhoArtworkPingPongPan::backgroundWidth, DistrhoArtworkPingPongPan::backgroundHeight); @@ -31,8 +33,10 @@ DistrhoUIPingPongPan::DistrhoUIPingPongPan() // background fImgBackground = Image(DistrhoArtworkPingPongPan::backgroundData, DistrhoArtworkPingPongPan::backgroundWidth, DistrhoArtworkPingPongPan::backgroundHeight, GL_BGR); +#ifndef DISTRHO_OS_MAC Image imageAbout(DistrhoArtworkPingPongPan::aboutData, DistrhoArtworkPingPongPan::aboutWidth, DistrhoArtworkPingPongPan::aboutHeight, GL_BGR); fAboutWindow.setImage(imageAbout); +#endif // knobs Image knobImage(DistrhoArtworkPingPongPan::knobData, DistrhoArtworkPingPongPan::knobWidth, DistrhoArtworkPingPongPan::knobHeight); @@ -100,7 +104,9 @@ void DistrhoUIPingPongPan::imageButtonClicked(ImageButton* button, int) if (button != fButtonAbout) return; +#ifndef DISTRHO_OS_MAC fAboutWindow.exec(); +#endif } void DistrhoUIPingPongPan::imageKnobDragStarted(ImageKnob* knob) diff --git a/source/native-plugins/distrho-pingpongpan/DistrhoUIPingPongPan.hpp b/source/native-plugins/distrho-pingpongpan/DistrhoUIPingPongPan.hpp index 973ad45b8..a39bbd220 100644 --- a/source/native-plugins/distrho-pingpongpan/DistrhoUIPingPongPan.hpp +++ b/source/native-plugins/distrho-pingpongpan/DistrhoUIPingPongPan.hpp @@ -60,7 +60,9 @@ protected: private: Image fImgBackground; +#ifndef DISTRHO_OS_MAC ImageAboutWindow fAboutWindow; +#endif ScopedPointer fButtonAbout; ScopedPointer fKnobFreq, fKnobWidth; diff --git a/source/native-plugins/distrho-vectorjuice/VectorJuiceUI.cpp b/source/native-plugins/distrho-vectorjuice/VectorJuiceUI.cpp index 8a4299032..316a24889 100644 --- a/source/native-plugins/distrho-vectorjuice/VectorJuiceUI.cpp +++ b/source/native-plugins/distrho-vectorjuice/VectorJuiceUI.cpp @@ -25,8 +25,10 @@ START_NAMESPACE_DISTRHO // ----------------------------------------------------------------------- VectorJuiceUI::VectorJuiceUI() - : UI(), - fAboutWindow(this) + : UI() +#ifndef DISTRHO_OS_MAC + , fAboutWindow(this) +#endif { setSize(VectorJuiceArtwork::backgroundWidth, VectorJuiceArtwork::backgroundHeight); @@ -55,9 +57,11 @@ VectorJuiceUI::VectorJuiceUI() //subOrbit fImgSubOrbit = Image(VectorJuiceArtwork::subOrbitData, VectorJuiceArtwork::subOrbitWidth, VectorJuiceArtwork::subOrbitHeight); +#ifndef DISTRHO_OS_MAC // about Image aboutImage(VectorJuiceArtwork::aboutData, VectorJuiceArtwork::aboutWidth, VectorJuiceArtwork::aboutHeight, GL_BGR); fAboutWindow.setImage(aboutImage); +#endif // about button Image aboutImageNormal(VectorJuiceArtwork::aboutButtonNormalData, VectorJuiceArtwork::aboutButtonNormalWidth, VectorJuiceArtwork::aboutButtonNormalHeight); @@ -303,7 +307,9 @@ void VectorJuiceUI::imageButtonClicked(ImageButton* button, int) if (button != fButtonAbout) return; +#ifndef DISTRHO_OS_MAC fAboutWindow.exec(); +#endif } void VectorJuiceUI::imageKnobDragStarted(ImageKnob* knob) diff --git a/source/native-plugins/distrho-vectorjuice/VectorJuiceUI.hpp b/source/native-plugins/distrho-vectorjuice/VectorJuiceUI.hpp index 991f7e476..e25f59122 100644 --- a/source/native-plugins/distrho-vectorjuice/VectorJuiceUI.hpp +++ b/source/native-plugins/distrho-vectorjuice/VectorJuiceUI.hpp @@ -74,7 +74,9 @@ private: Image fImgRoundlet; Image fImgOrbit; Image fImgSubOrbit; +#ifndef DISTRHO_OS_MAC ImageAboutWindow fAboutWindow; +#endif ScopedPointer fButtonAbout; diff --git a/source/native-plugins/distrho-wobblejuice/WobbleJuiceUI.cpp b/source/native-plugins/distrho-wobblejuice/WobbleJuiceUI.cpp index bd8fbdb1d..c5e8ae971 100644 --- a/source/native-plugins/distrho-wobblejuice/WobbleJuiceUI.cpp +++ b/source/native-plugins/distrho-wobblejuice/WobbleJuiceUI.cpp @@ -23,17 +23,21 @@ START_NAMESPACE_DISTRHO // ----------------------------------------------------------------------- WobbleJuiceUI::WobbleJuiceUI() - : UI(), - fAboutWindow(this) + : UI() +#ifndef DISTRHO_OS_MAC + , fAboutWindow(this) +#endif { setSize(WobbleJuiceArtwork::backgroundWidth, WobbleJuiceArtwork::backgroundHeight); // background fImgBackground = Image(WobbleJuiceArtwork::backgroundData, WobbleJuiceArtwork::backgroundWidth, WobbleJuiceArtwork::backgroundHeight, GL_BGR); +#ifndef DISTRHO_OS_MAC // about Image aboutImage(WobbleJuiceArtwork::aboutData, WobbleJuiceArtwork::aboutWidth, WobbleJuiceArtwork::aboutHeight, GL_BGR); fAboutWindow.setImage(aboutImage); +#endif // knobs Image knobImage(WobbleJuiceArtwork::knobData, WobbleJuiceArtwork::knobWidth, WobbleJuiceArtwork::knobHeight); @@ -154,7 +158,9 @@ void WobbleJuiceUI::imageButtonClicked(ImageButton* button, int) if (button != fButtonAbout) return; +#ifndef DISTRHO_OS_MAC fAboutWindow.exec(); +#endif } void WobbleJuiceUI::imageKnobDragStarted(ImageKnob* knob) diff --git a/source/native-plugins/distrho-wobblejuice/WobbleJuiceUI.hpp b/source/native-plugins/distrho-wobblejuice/WobbleJuiceUI.hpp index 1a0afd863..bcbf4e185 100644 --- a/source/native-plugins/distrho-wobblejuice/WobbleJuiceUI.hpp +++ b/source/native-plugins/distrho-wobblejuice/WobbleJuiceUI.hpp @@ -61,7 +61,9 @@ protected: private: Image fImgBackground; +#ifndef DISTRHO_OS_MAC ImageAboutWindow fAboutWindow; +#endif ScopedPointer fButtonAbout; ScopedPointer fKnobDivision, fKnobResonance, fKnobRange;