Merge pull request #8277 from Abextm/chatboxpanel-resilient
ChatboxPanelManager: Be more resilient when scripts mismatch
This commit is contained in:
@@ -93,6 +93,10 @@ public class ChatboxPanelManager
|
|||||||
0,
|
0,
|
||||||
1
|
1
|
||||||
);
|
);
|
||||||
|
if (currentInput != null)
|
||||||
|
{
|
||||||
|
killCurrentPanel();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private void unsafeOpenInput(ChatboxInput input)
|
private void unsafeOpenInput(ChatboxInput input)
|
||||||
@@ -113,6 +117,11 @@ public class ChatboxPanelManager
|
|||||||
mouseManager.registerMouseWheelListener((MouseWheelListener) input);
|
mouseManager.registerMouseWheelListener((MouseWheelListener) input);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (currentInput != null)
|
||||||
|
{
|
||||||
|
killCurrentPanel();
|
||||||
|
}
|
||||||
|
|
||||||
currentInput = input;
|
currentInput = input;
|
||||||
client.setVar(VarClientInt.INPUT_TYPE, InputType.RUNELITE_CHATBOX_PANEL.getType());
|
client.setVar(VarClientInt.INPUT_TYPE, InputType.RUNELITE_CHATBOX_PANEL.getType());
|
||||||
client.getWidget(WidgetInfo.CHATBOX_TITLE).setHidden(true);
|
client.getWidget(WidgetInfo.CHATBOX_TITLE).setHidden(true);
|
||||||
|
|||||||
Reference in New Issue
Block a user