keyremappinig: replace some lambdas with method references
This commit is contained in:
@@ -178,10 +178,7 @@ class KeyRemappingListener extends MouseAdapter implements KeyListener
|
|||||||
case KeyEvent.VK_COLON:
|
case KeyEvent.VK_COLON:
|
||||||
// refocus chatbox
|
// refocus chatbox
|
||||||
plugin.setTyping(true);
|
plugin.setTyping(true);
|
||||||
clientThread.invoke(() ->
|
clientThread.invoke(plugin::unlockChat);
|
||||||
{
|
|
||||||
plugin.unlockChat();
|
|
||||||
});
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -192,10 +189,7 @@ class KeyRemappingListener extends MouseAdapter implements KeyListener
|
|||||||
{
|
{
|
||||||
case KeyEvent.VK_ENTER:
|
case KeyEvent.VK_ENTER:
|
||||||
plugin.setTyping(false);
|
plugin.setTyping(false);
|
||||||
clientThread.invoke(() ->
|
clientThread.invoke(plugin::lockChat);
|
||||||
{
|
|
||||||
plugin.lockChat();
|
|
||||||
});
|
|
||||||
break;
|
break;
|
||||||
case KeyEvent.VK_ESCAPE:
|
case KeyEvent.VK_ESCAPE:
|
||||||
plugin.setTyping(false);
|
plugin.setTyping(false);
|
||||||
@@ -209,7 +203,7 @@ class KeyRemappingListener extends MouseAdapter implements KeyListener
|
|||||||
if (Strings.isNullOrEmpty(client.getVar(VarClientStr.CHATBOX_TYPED_TEXT)))
|
if (Strings.isNullOrEmpty(client.getVar(VarClientStr.CHATBOX_TYPED_TEXT)))
|
||||||
{
|
{
|
||||||
plugin.setTyping(false);
|
plugin.setTyping(false);
|
||||||
clientThread.invoke(() -> plugin.lockChat());
|
clientThread.invoke(plugin::lockChat);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user