Update PluginEditor.cpp
This commit is contained in:
parent
e7230d41c2
commit
5915e1aa29
1 changed files with 10 additions and 6 deletions
|
@ -155,7 +155,7 @@ void ObxdAudioProcessorEditor::loadSkin (ObxdAudioProcessor& ownerFilter)
|
||||||
|
|
||||||
if (name == "voiceSwitch"){
|
if (name == "voiceSwitch"){
|
||||||
//if (voiceSwitch) voiceSwitch->setVisible(false);
|
//if (voiceSwitch) voiceSwitch->setVisible(false);
|
||||||
#if JUCE_WIN || JUCE_LINUX
|
#if JUCE_WINDOWS || JUCE_LINUX
|
||||||
voiceSwitch = addList (x, y, w, h, ownerFilter, VOICE_COUNT, "VoiceCount", ImageCache::getFromFile(skinFolder.getChildFile("voices.png"))); }
|
voiceSwitch = addList (x, y, w, h, ownerFilter, VOICE_COUNT, "VoiceCount", ImageCache::getFromFile(skinFolder.getChildFile("voices.png"))); }
|
||||||
#else
|
#else
|
||||||
voiceSwitch = addList (x, y, w, h, ownerFilter, VOICE_COUNT, "VoiceCount", ImageCache::getFromFile(skinFolder.getChildFile("voices@2x.png"))); }
|
voiceSwitch = addList (x, y, w, h, ownerFilter, VOICE_COUNT, "VoiceCount", ImageCache::getFromFile(skinFolder.getChildFile("voices@2x.png"))); }
|
||||||
|
@ -163,7 +163,7 @@ void ObxdAudioProcessorEditor::loadSkin (ObxdAudioProcessor& ownerFilter)
|
||||||
|
|
||||||
if (name == "legatoSwitch"){
|
if (name == "legatoSwitch"){
|
||||||
//if (legatoSwitch) legatoSwitch->setVisible(false);
|
//if (legatoSwitch) legatoSwitch->setVisible(false);
|
||||||
#if JUCE_WIN || JUCE_LINUX
|
#if JUCE_WINDOWS || JUCE_LINUX
|
||||||
legatoSwitch = addList (x, y, w, h, ownerFilter, LEGATOMODE, "Legato", ImageCache::getFromFile(skinFolder.getChildFile("legato.png"))); }
|
legatoSwitch = addList (x, y, w, h, ownerFilter, LEGATOMODE, "Legato", ImageCache::getFromFile(skinFolder.getChildFile("legato.png"))); }
|
||||||
#else
|
#else
|
||||||
legatoSwitch = addList (x, y, w, h, ownerFilter, LEGATOMODE, "Legato", ImageCache::getFromFile(skinFolder.getChildFile("legato@2x.png"))); }
|
legatoSwitch = addList (x, y, w, h, ownerFilter, LEGATOMODE, "Legato", ImageCache::getFromFile(skinFolder.getChildFile("legato@2x.png"))); }
|
||||||
|
@ -173,7 +173,11 @@ void ObxdAudioProcessorEditor::loadSkin (ObxdAudioProcessor& ownerFilter)
|
||||||
if (name == "menu")
|
if (name == "menu")
|
||||||
{
|
{
|
||||||
addMenuButton (x, y, d,
|
addMenuButton (x, y, d,
|
||||||
|
#if JUCE_WINDOWS || JUCE_LINUX
|
||||||
ImageCache::getFromFile (skinFolder.getChildFile ("menu.png")));
|
ImageCache::getFromFile (skinFolder.getChildFile ("menu.png")));
|
||||||
|
#else
|
||||||
|
ImageCache::getFromFile (skinFolder.getChildFile ("menu@2x.png")));
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
//DBG(" Name: " << name << " X: " <<x <<" Y: "<<y);
|
//DBG(" Name: " << name << " X: " <<x <<" Y: "<<y);
|
||||||
|
@ -240,7 +244,7 @@ ButtonList* ObxdAudioProcessorEditor::addList (int x, int y, int width, int heig
|
||||||
|
|
||||||
Knob* ObxdAudioProcessorEditor::addKnob (int x, int y, int d, ObxdAudioProcessor& filter, int parameter, String /*name*/, float defval)
|
Knob* ObxdAudioProcessorEditor::addKnob (int x, int y, int d, ObxdAudioProcessor& filter, int parameter, String /*name*/, float defval)
|
||||||
{
|
{
|
||||||
#if JUCE_WIN || JUCE_LINUX
|
#if JUCE_WINDOWS || JUCE_LINUX
|
||||||
Knob* knob = new Knob (ImageCache::getFromFile(skinFolder.getChildFile("knob.png")), 48);
|
Knob* knob = new Knob (ImageCache::getFromFile(skinFolder.getChildFile("knob.png")), 48);
|
||||||
#else
|
#else
|
||||||
Knob* knob = new Knob (ImageCache::getFromFile(skinFolder.getChildFile("knob@2x.png")), 96);
|
Knob* knob = new Knob (ImageCache::getFromFile(skinFolder.getChildFile("knob@2x.png")), 96);
|
||||||
|
@ -270,7 +274,7 @@ void ObxdAudioProcessorEditor::clean()
|
||||||
|
|
||||||
TooglableButton* ObxdAudioProcessorEditor::addButton (int x, int y, int w, int h, ObxdAudioProcessor& filter, int parameter, String name)
|
TooglableButton* ObxdAudioProcessorEditor::addButton (int x, int y, int w, int h, ObxdAudioProcessor& filter, int parameter, String name)
|
||||||
{
|
{
|
||||||
#if JUCE_WIN || JUCE_LINUX
|
#if JUCE_WINDOWS || JUCE_LINUX
|
||||||
TooglableButton* button = new TooglableButton (ImageCache::getFromFile(skinFolder.getChildFile("button.png")));
|
TooglableButton* button = new TooglableButton (ImageCache::getFromFile(skinFolder.getChildFile("button.png")));
|
||||||
#else
|
#else
|
||||||
TooglableButton* button = new TooglableButton (ImageCache::getFromFile(skinFolder.getChildFile("button@2x.png")));
|
TooglableButton* button = new TooglableButton (ImageCache::getFromFile(skinFolder.getChildFile("button@2x.png")));
|
||||||
|
@ -491,7 +495,7 @@ void ObxdAudioProcessorEditor::mouseUp (const MouseEvent& e)
|
||||||
void ObxdAudioProcessorEditor::paint(Graphics& g)
|
void ObxdAudioProcessorEditor::paint(Graphics& g)
|
||||||
{
|
{
|
||||||
g.fillAll (Colours::black);
|
g.fillAll (Colours::black);
|
||||||
#if JUCE_WIN || JUCE_LINUX
|
#if JUCE_WINDOWS || JUCE_LINUX
|
||||||
const File mainFile(skinFolder.getChildFile("main.png"));
|
const File mainFile(skinFolder.getChildFile("main.png"));
|
||||||
#else
|
#else
|
||||||
const File mainFile(skinFolder.getChildFile("main@2x.png"));
|
const File mainFile(skinFolder.getChildFile("main@2x.png"));
|
||||||
|
@ -502,7 +506,7 @@ void ObxdAudioProcessorEditor::paint(Graphics& g)
|
||||||
|
|
||||||
const Image image = ImageCache::getFromFile(mainFile);
|
const Image image = ImageCache::getFromFile(mainFile);
|
||||||
|
|
||||||
#if JUCE_WIN || JUCE_LINUX
|
#if JUCE_WINDOWS || JUCE_LINUX
|
||||||
g.drawImage (image,
|
g.drawImage (image,
|
||||||
0, 0, image.getWidth(), image.getHeight(),
|
0, 0, image.getWidth(), image.getHeight(),
|
||||||
0, 0, image.getWidth(), image.getHeight());
|
0, 0, image.getWidth(), image.getHeight());
|
||||||
|
|
Loading…
Reference in a new issue