Hide only inside of minimap but not logout

In normal resizable mode hide only insides of minimap but not logout
button when hiding minimap.

Signed-off-by: Tomas Slusny <slusnucky@gmail.com>
This commit is contained in:
Tomas Slusny
2018-07-20 22:33:44 +02:00
parent 0002a25d28
commit d1ba793849
3 changed files with 10 additions and 1 deletions

View File

@@ -246,6 +246,7 @@ public class WidgetID
static final int MINIMAP_RESIZABLE_DRAW_AREA = 25;
static final int MINIMAP_RESIZABLE_DECORATIONS = 27;
static final int MINIMAP_RESIZABLE_ORB_HOLDER = 28;
static final int MINIMAP_RESIZABLE_LOGOUT_BUTTON = 30;
static final int FIXED_VIEWPORT = 17;
static final int RESIZABLE_VIEWPORT_OLD_SCHOOL_BOX = 12;
static final int RESIZABLE_VIEWPORT_BOTTOM_LINE = 12;

View File

@@ -175,6 +175,7 @@ public enum WidgetInfo
RESIZABLE_MINIMAP_DRAW_AREA(WidgetID.RESIZABLE_VIEWPORT_BOTTOM_LINE_GROUP_ID, WidgetID.Viewport.MINIMAP_RESIZABLE_DRAW_AREA),
RESIZABLE_MINIMAP_DECORATIONS(WidgetID.RESIZABLE_VIEWPORT_BOTTOM_LINE_GROUP_ID, WidgetID.Viewport.MINIMAP_RESIZABLE_DECORATIONS),
RESIZABLE_MINIMAP_ORB_HOLDER(WidgetID.RESIZABLE_VIEWPORT_BOTTOM_LINE_GROUP_ID, WidgetID.Viewport.MINIMAP_RESIZABLE_ORB_HOLDER),
RESIZABLE_MINIMAP_LOGOUT_BUTTON(WidgetID.RESIZABLE_VIEWPORT_BOTTOM_LINE_GROUP_ID, WidgetID.Viewport.MINIMAP_RESIZABLE_LOGOUT_BUTTON),
RESIZABLE_MINIMAP_STONES_WIDGET(WidgetID.RESIZABLE_VIEWPORT_OLD_SCHOOL_BOX_GROUP_ID, WidgetID.Viewport.MINIMAP_RESIZABLE_WIDGET),
RESIZABLE_MINIMAP_STONES_CLICKBOX(WidgetID.RESIZABLE_VIEWPORT_OLD_SCHOOL_BOX_GROUP_ID, WidgetID.Viewport.MINIMAP_RESIZABLE_CLICKBOX),

View File

@@ -125,7 +125,14 @@ public class MinimapPlugin extends Plugin
if (resizableNormalWidget != null && !resizableNormalWidget.isSelfHidden())
{
resizableNormalWidget.setHidden(enable);
for (Widget widget : resizableNormalWidget.getStaticChildren())
{
if (widget.getId() != WidgetInfo.RESIZABLE_VIEWPORT_BOTTOM_LINE_LOGOUT_BUTTON.getId() &&
widget.getId() != WidgetInfo.RESIZABLE_MINIMAP_LOGOUT_BUTTON.getId())
{
widget.setHidden(enable);
}
}
}
}