Reverse ClientUI sidebar condition

- Reverse ClientUI sidebar condition as when opening sidebar is always
open so current master will effectively shrink window instead of
restoring to correct size
- Apply this condition also to KEEP_WINDOW_SIZE

Signed-off-by: Tomas Slusny <slusnucky@gmail.com>
This commit is contained in:
Tomas Slusny
2018-08-02 07:57:44 +02:00
parent 19f3d05dae
commit b3d9de7a41

View File

@@ -735,13 +735,14 @@ public class ClientUI
{
final Rectangle bounds = frame.getBounds();
// Try to expand sidebar
if (!sidebarOpen)
{
bounds.width += pluginToolbar.getWidth();
}
if (config.automaticResizeType() == ExpandResizeType.KEEP_GAME_SIZE)
{
// Try to contract sidebar
if (sidebarOpen)
{
bounds.width -= pluginToolbar.getWidth();
}
// Try to contract plugin panel
if (pluginPanel != null)