mirror of
https://github.com/2006-Scape/Parabot.git
synced 2026-07-02 16:49:10 +00:00
Optional press enter flag for sendKeys
This commit is contained in:
@@ -44,6 +44,10 @@ public class Keyboard implements KeyListener {
|
||||
}
|
||||
|
||||
public void sendKeys(String s) {
|
||||
sendKeys(s, true);
|
||||
}
|
||||
|
||||
public void sendKeys(String s, boolean enterAfter) {
|
||||
|
||||
pressTime = System.currentTimeMillis();
|
||||
for (char c : s.toCharArray()) {
|
||||
@@ -56,7 +60,9 @@ public class Keyboard implements KeyListener {
|
||||
sendKeyEvent(ke);
|
||||
}
|
||||
}
|
||||
clickKey(10);
|
||||
if (enterAfter) {
|
||||
clickKey(10);
|
||||
}
|
||||
}
|
||||
|
||||
public void clickKey(char c) {
|
||||
|
||||
Reference in New Issue
Block a user