mirror of
https://github.com/cookiengineer/audacity
synced 2025-11-08 14:13:57 +01:00
Round 2 of wx3 changes on OSX
Main change is that VST GUI support is now integrate with new Cocoa views. Direct support for VST Cocoa views (via Cockos extensions: http://www.reaper.fm/sdk/vst/vst_ext.php) has been added.
This commit is contained in:
@@ -18,9 +18,7 @@
|
||||
#include <wx/osx/private.h>
|
||||
#include <wx/control.h>
|
||||
|
||||
//#include <AudioUnit/AudioUnit.h>
|
||||
#include <AudioUnit/AudioComponent.h>
|
||||
//#include <AudioUnit/AudioUnitProperties.h>
|
||||
|
||||
class AUControlImpl : public wxWidgetCocoaImpl
|
||||
{
|
||||
|
||||
@@ -107,9 +107,6 @@ AUControl::AUControl()
|
||||
AUControl::~AUControl()
|
||||
{
|
||||
#if !defined(_LP64)
|
||||
if (mHIView)
|
||||
{
|
||||
}
|
||||
|
||||
if (mInstance)
|
||||
{
|
||||
@@ -117,6 +114,7 @@ AUControl::~AUControl()
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
if (mView)
|
||||
{
|
||||
NSNotificationCenter *center = [NSNotificationCenter defaultCenter];
|
||||
@@ -242,8 +240,8 @@ void AUControl::OnSize(wxSizeEvent & evt)
|
||||
wxSize min = w->GetMinSize();
|
||||
min.x += (rect.size.width - mLastMin.GetWidth());
|
||||
min.y += (rect.size.height - mLastMin.GetHeight());
|
||||
w->SetMinSize(min);
|
||||
w->SetMaxSize(min);
|
||||
|
||||
w->SetSizeHints(min, min);
|
||||
|
||||
mLastMin = wxSize(rect.size.width, rect.size.height);
|
||||
}
|
||||
@@ -537,7 +535,7 @@ void AUControl::CreateCarbon()
|
||||
AudioComponentInstanceDispose(mInstance);
|
||||
mInstance = NULL;
|
||||
|
||||
return nil;
|
||||
return;
|
||||
}
|
||||
|
||||
SetWindowActivationScope(mWindowRef, kWindowActivationScopeIndependent);
|
||||
@@ -647,12 +645,16 @@ void AUControl::CarbonViewResized()
|
||||
size.x += (rect.size.width - frameSize.width);
|
||||
size.y += (rect.size.height - frameSize.height);
|
||||
|
||||
w->SetMinSize(wxDefaultSize);
|
||||
w->SetMaxSize(wxDefaultSize);
|
||||
// Reset the current max/min
|
||||
w->SetSizeHints(wxDefaultSize, wxDefaultSize);
|
||||
|
||||
// Set the dialog size
|
||||
w->SetSize(size);
|
||||
w->SetMinSize(size);
|
||||
w->SetMaxSize(size);
|
||||
mLastMin = size;
|
||||
|
||||
// And finally set the new max/min
|
||||
w->SetSizeHints(size, size);
|
||||
|
||||
mLastMin = wxSize(rect.size.width, rect.size.height);
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user