mirror of
https://github.com/2006-Scape/Parabot.git
synced 2026-07-03 16:49:10 +00:00
[BUGFIX] Fixed merge issues
This commit is contained in:
@@ -151,7 +151,7 @@ public class BotUI extends JFrame implements ActionListener, ComponentListener,
|
||||
this.performCommand(e.getActionCommand());
|
||||
}
|
||||
|
||||
public void performCommand(String command){
|
||||
public void performCommand(String command) {
|
||||
switch (command) {
|
||||
case "Create screenshot":
|
||||
try {
|
||||
@@ -218,6 +218,12 @@ public class BotUI extends JFrame implements ActionListener, ComponentListener,
|
||||
pauseScript = true;
|
||||
break;
|
||||
case "Stop":
|
||||
if (pauseScript) {
|
||||
pauseScript = false;
|
||||
pause.setEnabled(false);
|
||||
run.setEnabled(true);
|
||||
stop.setEnabled(false);
|
||||
}
|
||||
setScriptState(Script.STATE_STOPPED);
|
||||
break;
|
||||
case "Logger":
|
||||
|
||||
@@ -4,6 +4,8 @@ import org.parabot.core.ui.components.GamePanel;
|
||||
|
||||
import javax.swing.*;
|
||||
import java.awt.*;
|
||||
import java.awt.event.ActionEvent;
|
||||
import java.awt.event.ActionListener;
|
||||
|
||||
/**
|
||||
* @author JKetelaar
|
||||
@@ -23,6 +25,16 @@ public class Logger extends JPanel {
|
||||
JScrollPane pane = new JScrollPane(list);
|
||||
add(pane, BorderLayout.CENTER);
|
||||
|
||||
JButton button = new JButton("Clear Logger");
|
||||
button.addActionListener(new ActionListener() {
|
||||
@Override
|
||||
public void actionPerformed(ActionEvent e) {
|
||||
clearLogger();
|
||||
addMessage("Logger cleared", false);
|
||||
}
|
||||
});
|
||||
add(button, BorderLayout.SOUTH);
|
||||
|
||||
list.setCellRenderer(getRenderer());
|
||||
|
||||
model = new DefaultListModel<>();
|
||||
|
||||
Reference in New Issue
Block a user