Browse Source

VST2: Fix a conversion warning in the wrapper and prevent resizing the plug-in window in resizeHostWindow() to fix some flickering when resizing

tags/2021-05-28
ed 6 years ago
parent
commit
98219bf98e
1 changed files with 4 additions and 3 deletions
  1. +4
    -3
      modules/juce_audio_plugin_client/VST/juce_VST_Wrapper.cpp

+ 4
- 3
modules/juce_audio_plugin_client/VST/juce_VST_Wrapper.cpp View File

@@ -1258,7 +1258,7 @@ public:
if (! getHostType().isReceptor())
addMouseListener (this, true);
#if JUCE_WIN_PER_MONITOR_DPI_AWARE
wrapper.editorScaleFactor = Desktop::getInstance().getDisplays().getMainDisplay().scale;
wrapper.editorScaleFactor = static_cast<float> (Desktop::getInstance().getDisplays().getMainDisplay().scale);
#endif
#endif
@@ -1489,8 +1489,9 @@ public:
GetWindowRect (w, &windowPos);
GetWindowRect (parent, &parentPos);
SetWindowPos (w, 0, 0, 0, newWidth + dw, newHeight + dh,
SWP_NOACTIVATE | SWP_NOMOVE | SWP_NOZORDER | SWP_NOOWNERZORDER);
if (w != (HWND) getWindowHandle())
SetWindowPos (w, 0, 0, 0, newWidth + dw, newHeight + dh,
SWP_NOACTIVATE | SWP_NOMOVE | SWP_NOZORDER | SWP_NOOWNERZORDER);
dw = (parentPos.right - parentPos.left) - (windowPos.right - windowPos.left);
dh = (parentPos.bottom - parentPos.top) - (windowPos.bottom - windowPos.top);


Loading…
Cancel
Save