Dispatches window resize events from VST PlugView to the wxWindow.
More...
#include <PlugFrame.h>
|
| PlugFrame (wxWindow *window) |
|
virtual | ~PlugFrame () |
|
void | init (Steinberg::IPlugView *view, Steinberg::ViewRect *size) |
|
Steinberg::tresult PLUGIN_API | resizeView (Steinberg::IPlugView *view, Steinberg::ViewRect *newSize) override |
|
Dispatches window resize events from VST PlugView to the wxWindow.
Definition at line 22 of file PlugFrame.h.
◆ PlugFrame()
internal::PlugFrame::PlugFrame |
( |
wxWindow * |
window | ) |
|
Definition at line 16 of file PlugFrame.cpp.
18{
19 FUNKNOWN_CTOR
20}
wxWeakRef< wxWindow > mWindow
◆ ~PlugFrame()
internal::PlugFrame::~PlugFrame |
( |
| ) |
|
|
virtual |
◆ init()
void internal::PlugFrame::init |
( |
Steinberg::IPlugView * |
view, |
|
|
Steinberg::ViewRect * |
size |
|
) |
| |
Definition at line 27 of file PlugFrame.cpp.
28{
31}
Steinberg::tresult PLUGIN_API resizeView(Steinberg::IPlugView *view, Steinberg::ViewRect *newSize) override
References size.
◆ resizeView()
Steinberg::tresult internal::PlugFrame::resizeView |
( |
Steinberg::IPlugView * |
view, |
|
|
Steinberg::ViewRect * |
newSize |
|
) |
| |
|
override |
Definition at line 33 of file PlugFrame.cpp.
34{
36 {
37 auto topWindow = wxGetTopLevelParent(window);
38
39 wxWindowUpdateLocker windowUpdateLocker(topWindow);
40
41 window->SetInitialSize({newSize->getWidth(), newSize->getHeight() });
42
43 topWindow->SetMinSize(wxDefaultSize);
44 topWindow->Fit();
45 topWindow->SetMinSize(topWindow->GetSize());
46
48 {
50 topWindow->Center();
51 }
52 return view->onSize(newSize);
53 }
54 return Steinberg::kResultFalse;
55}
◆ mInitialized
bool internal::PlugFrame::mInitialized {false} |
|
private |
◆ mWindow
wxWeakRef<wxWindow> internal::PlugFrame::mWindow |
|
private |
The documentation for this class was generated from the following files: