Browse Source

Cleanup

Signed-off-by: falkTX <falktx@falktx.com>
main
falkTX 1 year ago
parent
commit
7943e71139
Signed by: falkTX <falktx@falktx.com> GPG Key ID: CDBAA37ABC74FBA0
4 changed files with 19 additions and 10 deletions
  1. +1
    -1
      Makefile
  2. +1
    -1
      dpf
  3. +12
    -7
      plugins/Common/IldaeilUI.cpp
  4. +5
    -1
      plugins/Standalone/DistrhoPluginInfo.h

+ 1
- 1
Makefile View File

@@ -160,7 +160,7 @@ gen:
endif

jack: carla dgl
$(MAKE) $(CARLA_EXTRA_ARGS) $(ILDAEIL_FX_ARGS) -C plugins/Standalone
$(MAKE) $(CARLA_EXTRA_ARGS) $(DGL_EXTRA_ARGS) $(ILDAEIL_FX_ARGS) -C plugins/Standalone

# ---------------------------------------------------------------------------------------------------------------------



+ 1
- 1
dpf

@@ -1 +1 @@
Subproject commit 11ea617b17d9daef7c4194baf997c83bf921c905
Subproject commit 83b574eaf2ecb8f715d6cab5162d14388feb670e

+ 12
- 7
plugins/Common/IldaeilUI.cpp View File

@@ -692,7 +692,7 @@ protected:
fUpdateGeometryConstraints = true;
}

#if ILDAEIL_STANDALONE
#if DISTRHO_UI_USER_RESIZABLE
void onResize(const ResizeEvent& ev) override
{
UI::onResize(ev);
@@ -701,13 +701,18 @@ protected:
return;
if (fShowingHostWindow)
return;
if (fDrawingState != kDrawingPluginEmbedUI)
return;

if (fDrawingState == kDrawingPluginEmbedUI)
{
const uint extraHeight = kButtonHeight * getScaleFactor() + ImGui::GetStyle().WindowPadding.y * 2;

fPluginHostWindow.setSize(ev.size.getWidth(), ev.size.getHeight() - extraHeight);
}
const double scaleFactor = getScaleFactor();
const uint extraHeight = kButtonHeight * scaleFactor + ImGui::GetStyle().WindowPadding.y * 2;
uint width = ev.size.getWidth();
uint height = ev.size.getHeight() - extraHeight;
#ifdef DISTRHO_OS_MAC
width /= scaleFactor;
height /= scaleFactor;
#endif
fPluginHostWindow.setSize(width, height);
}
#endif



+ 5
- 1
plugins/Standalone/DistrhoPluginInfo.h View File

@@ -34,7 +34,6 @@
#define DISTRHO_PLUGIN_WANT_TIMEPOS 1
#define DISTRHO_PLUGIN_WANT_DIRECT_ACCESS 1
#define DISTRHO_UI_USE_CUSTOM 1
#define DISTRHO_UI_USER_RESIZABLE 1
#define DISTRHO_UI_CUSTOM_INCLUDE_PATH "DearImGui.hpp"
#define DISTRHO_UI_CUSTOM_WIDGET_TYPE DGL_NAMESPACE::ImGuiTopLevelWidget
#define DISTRHO_UI_DEFAULT_WIDTH kInitialWidth
@@ -42,6 +41,11 @@

#define ILDAEIL_STANDALONE 1

#ifndef __APPLE__
// FIXME
#define DISTRHO_UI_USER_RESIZABLE 1
#endif

static constexpr const uint kInitialWidth = 640;
static constexpr const uint kInitialHeight = 480;



Loading…
Cancel
Save