Browse Source

VST: Made the check for Windows high-DPI screen change resizing more strict to prevent UI glitches when resizing manually

tags/2021-05-28
ed 4 years ago
parent
commit
5fc20f7106
2 changed files with 2 additions and 2 deletions
  1. +1
    -1
      modules/juce_audio_plugin_client/VST/juce_VST_Wrapper.cpp
  2. +1
    -1
      modules/juce_audio_plugin_client/VST3/juce_VST3_Wrapper.cpp

+ 1
- 1
modules/juce_audio_plugin_client/VST/juce_VST_Wrapper.cpp View File

@@ -1141,7 +1141,7 @@ public:
auto newBounds = getLocalBounds();
#if JUCE_WINDOWS && JUCE_WIN_PER_MONITOR_DPI_AWARE
if (! lastBounds.isEmpty() && isWithin (newBounds.toDouble().getAspectRatio(), lastBounds.toDouble().getAspectRatio(), 0.1))
if (! lastBounds.isEmpty() && isWithin (newBounds.toDouble().getAspectRatio(), lastBounds.toDouble().getAspectRatio(), 0.001))
return;
lastBounds = newBounds;


+ 1
- 1
modules/juce_audio_plugin_client/VST3/juce_VST3_Wrapper.cpp View File

@@ -1576,7 +1576,7 @@ private:
auto newBounds = getLocalBounds();
#if JUCE_WINDOWS && JUCE_WIN_PER_MONITOR_DPI_AWARE
if (! lastBounds.isEmpty() && isWithin (newBounds.toDouble().getAspectRatio(), lastBounds.toDouble().getAspectRatio(), 0.1))
if (! lastBounds.isEmpty() && isWithin (newBounds.toDouble().getAspectRatio(), lastBounds.toDouble().getAspectRatio(), 0.001))
return;
#endif


Loading…
Cancel
Save