kopia lustrzana https://github.com/jameshball/osci-render
Enable all buttons on native title bar
rodzic
3c1c73054e
commit
eddfa9bcd9
|
@ -56,7 +56,12 @@ OscirenderAudioProcessorEditor::OscirenderAudioProcessorEditor(OscirenderAudioPr
|
||||||
if (audioProcessor.wrapperType == juce::AudioProcessor::WrapperType::wrapperType_Standalone) {
|
if (audioProcessor.wrapperType == juce::AudioProcessor::WrapperType::wrapperType_Standalone) {
|
||||||
if (juce::TopLevelWindow::getNumTopLevelWindows() == 1) {
|
if (juce::TopLevelWindow::getNumTopLevelWindows() == 1) {
|
||||||
juce::TopLevelWindow* w = juce::TopLevelWindow::getTopLevelWindow(0);
|
juce::TopLevelWindow* w = juce::TopLevelWindow::getTopLevelWindow(0);
|
||||||
w->setColour(juce::ResizableWindow::backgroundColourId, Colours::veryDark);
|
juce::DocumentWindow* dw = dynamic_cast<juce::DocumentWindow*>(w);
|
||||||
|
if (dw != nullptr) {
|
||||||
|
dw->setColour(juce::ResizableWindow::backgroundColourId, Colours::veryDark);
|
||||||
|
dw->setTitleBarButtonsRequired(juce::DocumentWindow::allButtons, false);
|
||||||
|
dw->setUsingNativeTitleBar(true);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -645,12 +645,6 @@ bool OscirenderAudioProcessor::hasEditor() const {
|
||||||
|
|
||||||
juce::AudioProcessorEditor* OscirenderAudioProcessor::createEditor() {
|
juce::AudioProcessorEditor* OscirenderAudioProcessor::createEditor() {
|
||||||
auto editor = new OscirenderAudioProcessorEditor(*this);
|
auto editor = new OscirenderAudioProcessorEditor(*this);
|
||||||
if (wrapperType == wrapperType_Standalone) {
|
|
||||||
if (juce::TopLevelWindow::getNumTopLevelWindows() == 1) {
|
|
||||||
juce::TopLevelWindow* w = juce::TopLevelWindow::getTopLevelWindow(0);
|
|
||||||
w->setUsingNativeTitleBar(true);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return editor;
|
return editor;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Ładowanie…
Reference in New Issue