Merge pull request #8277 from Abextm/chatboxpanel-resilient

ChatboxPanelManager: Be more resilient when scripts mismatch
This commit is contained in:
Adam
2019-03-21 09:44:26 -04:00
committed by GitHub

View File

@@ -93,6 +93,10 @@ public class ChatboxPanelManager
0,
1
);
if (currentInput != null)
{
killCurrentPanel();
}
}
private void unsafeOpenInput(ChatboxInput input)
@@ -113,6 +117,11 @@ public class ChatboxPanelManager
mouseManager.registerMouseWheelListener((MouseWheelListener) input);
}
if (currentInput != null)
{
killCurrentPanel();
}
currentInput = input;
client.setVar(VarClientInt.INPUT_TYPE, InputType.RUNELITE_CHATBOX_PANEL.getType());
client.getWidget(WidgetInfo.CHATBOX_TITLE).setHidden(true);