mirror of
https://github.com/robbert-vdh/yabridge.git
synced 2026-05-10 04:30:12 +02:00
Rename maybe_resize_editor() to resize_editor()
This commit is contained in:
@@ -241,8 +241,7 @@ bool CLAP_ABI clap_host_proxy::ext_gui_request_resize(const clap_host_t* host,
|
|||||||
// If the resize request was accepted by the host, then we'll also resize
|
// If the resize request was accepted by the host, then we'll also resize
|
||||||
// our editor window
|
// our editor window
|
||||||
if (result) {
|
if (result) {
|
||||||
self->bridge_.maybe_resize_editor(self->owner_instance_id_, width,
|
self->bridge_.resize_editor(self->owner_instance_id_, width, height);
|
||||||
height);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return result;
|
return result;
|
||||||
|
|||||||
@@ -740,9 +740,9 @@ void ClapBridge::run() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// NOLINTNEXTLINE(bugprone-easily-swappable-parameters)
|
// NOLINTNEXTLINE(bugprone-easily-swappable-parameters)
|
||||||
bool ClapBridge::maybe_resize_editor(size_t instance_id,
|
bool ClapBridge::resize_editor(size_t instance_id,
|
||||||
uint16_t width,
|
uint16_t width,
|
||||||
uint16_t height) {
|
uint16_t height) {
|
||||||
const auto& [instance, _] = get_instance(instance_id);
|
const auto& [instance, _] = get_instance(instance_id);
|
||||||
|
|
||||||
if (instance.editor) {
|
if (instance.editor) {
|
||||||
|
|||||||
@@ -215,9 +215,7 @@ class ClapBridge : public HostBridge {
|
|||||||
* the new size. This is called from `clap_host_gui::request_resize()` after
|
* the new size. This is called from `clap_host_gui::request_resize()` after
|
||||||
* the host returns `true`.
|
* the host returns `true`.
|
||||||
*/
|
*/
|
||||||
bool maybe_resize_editor(size_t instance_id,
|
bool resize_editor(size_t instance_id, uint16_t width, uint16_t height);
|
||||||
uint16_t width,
|
|
||||||
uint16_t height);
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the plugin instance's current editor size, if it has an active
|
* Get the plugin instance's current editor size, if it has an active
|
||||||
|
|||||||
@@ -47,7 +47,7 @@ Vst3PlugFrameProxyImpl::resizeView(Steinberg::IPlugView* /*view*/,
|
|||||||
// Resize the editor wrapper window in advance. We will do another
|
// Resize the editor wrapper window in advance. We will do another
|
||||||
// resize automatically on `IPlugView::onSize()`, but this should make
|
// resize automatically on `IPlugView::onSize()`, but this should make
|
||||||
// resizes look a bit smoother.
|
// resizes look a bit smoother.
|
||||||
bridge_.maybe_resize_editor(owner_instance_id(), *newSize);
|
bridge_.resize_editor(owner_instance_id(), *newSize);
|
||||||
|
|
||||||
// We have to use this special sending function here so we can handle
|
// We have to use this special sending function here so we can handle
|
||||||
// calls to `IPlugView::onSize()` from this same thread (the UI thread).
|
// calls to `IPlugView::onSize()` from this same thread (the UI thread).
|
||||||
|
|||||||
@@ -1314,7 +1314,7 @@ void Vst3Bridge::run() {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
bool Vst3Bridge::maybe_resize_editor(size_t instance_id,
|
bool Vst3Bridge::resize_editor(size_t instance_id,
|
||||||
const Steinberg::ViewRect& new_size) {
|
const Steinberg::ViewRect& new_size) {
|
||||||
const auto& [instance, _] = get_instance(instance_id);
|
const auto& [instance, _] = get_instance(instance_id);
|
||||||
|
|
||||||
|
|||||||
@@ -308,7 +308,7 @@ class Vst3Bridge : public HostBridge {
|
|||||||
* the new size. This is called from `IPlugFrame::resizeView()` to make sure
|
* the new size. This is called from `IPlugFrame::resizeView()` to make sure
|
||||||
* we do the resize before the request gets sent to the host.
|
* we do the resize before the request gets sent to the host.
|
||||||
*/
|
*/
|
||||||
bool maybe_resize_editor(size_t instance_id,
|
bool resize_editor(size_t instance_id,
|
||||||
const Steinberg::ViewRect& new_size);
|
const Steinberg::ViewRect& new_size);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
Reference in New Issue
Block a user