From 4800216b82149677982154178bff3c6cfb0031a5 Mon Sep 17 00:00:00 2001 From: ed Date: Thu, 7 Dec 2017 10:27:46 +0000 Subject: [PATCH] Only resize SidePanel on mouse drag if it is currently showing --- modules/juce_gui_basics/layout/juce_SidePanel.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/juce_gui_basics/layout/juce_SidePanel.cpp b/modules/juce_gui_basics/layout/juce_SidePanel.cpp index c2b3d07207..6e4255b4dc 100644 --- a/modules/juce_gui_basics/layout/juce_SidePanel.cpp +++ b/modules/juce_gui_basics/layout/juce_SidePanel.cpp @@ -153,7 +153,7 @@ void SidePanel::mouseDrag (const MouseEvent& e) setBounds (getBounds().withX (startingBounds.getX() + jmax (amountMoved, 0))); } } - else + else if (isShowing) { auto relativeMouseDownPosition = getLocalPoint (e.eventComponent, e.getMouseDownPosition()); auto relativeMouseDragPosition = getLocalPoint (e.eventComponent, e.getPosition());