// Path: src/lib/jxbrowser-5/demo/src/com/teamdev/jxbrowser/chromium/demo/resources/Resources.java
// public class Resources {
// 
//     public static ImageIcon getIcon(String fileName) {
//         return new ImageIcon(Resources.class.getResource(fileName));
//     }
// }


import com.teamdev.jxbrowser.chromium.Browser;
import com.teamdev.jxbrowser.chromium.JSValue;
import com.teamdev.jxbrowser.chromium.demo.resources.Resources;
import javax.swing.*;
import java.awt.*;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import java.util.concurrent.ExecutorService;
import java.util.concurrent.Executors;
        console = new JTextArea();
        console.setFont(new Font("Consolas", Font.PLAIN, 12));
        console.setBorder(BorderFactory.createEmptyBorder(4, 4, 4, 4));
        console.setEditable(false);
        console.setWrapStyleWord(true);
        console.setLineWrap(true);
        console.setText("");
        JScrollPane scrollPane = new JScrollPane(console);
        scrollPane.setBorder(BorderFactory.createMatteBorder(0, 0, 1, 0, Color.GRAY));
        return scrollPane;
    }

    private JComponent createTitle() {
        JPanel panel = new JPanel(new BorderLayout());
//        panel.setBackground(new Color(182, 191, 207));
        panel.setBorder(BorderFactory.createEmptyBorder(4, 4, 4, 4));
        panel.add(createTitleLabel(), BorderLayout.WEST);
        panel.add(createCloseButton(), BorderLayout.EAST);
        return panel;
    }

    private static JComponent createTitleLabel() {
        return new JLabel("JavaScript Console");
    }

    private JComponent createCloseButton() {
        JButton closeButton = new JButton();
        closeButton.setOpaque(false);
        closeButton.setToolTipText("Close JavaScript Console");
        closeButton.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0));
// Path: src/lib/jxbrowser-5/demo/src/com/teamdev/jxbrowser/chromium/demo/resources/Resources.java
// public class Resources {
// 
//     public static ImageIcon getIcon(String fileName) {
//         return new ImageIcon(Resources.class.getResource(fileName));
//     }
// }


// Path: src/lib/jxbrowser-5/demo/src/com/teamdev/jxbrowser/chromium/demo/JSConsole.java
import com.teamdev.jxbrowser.chromium.Browser;
import com.teamdev.jxbrowser.chromium.JSValue;
import com.teamdev.jxbrowser.chromium.demo.resources.Resources;
import javax.swing.*;
import java.awt.*;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import java.util.concurrent.ExecutorService;
import java.util.concurrent.Executors;

        console = new JTextArea();
        console.setFont(new Font("Consolas", Font.PLAIN, 12));
        console.setBorder(BorderFactory.createEmptyBorder(4, 4, 4, 4));
        console.setEditable(false);
        console.setWrapStyleWord(true);
        console.setLineWrap(true);
        console.setText("");
        JScrollPane scrollPane = new JScrollPane(console);
        scrollPane.setBorder(BorderFactory.createMatteBorder(0, 0, 1, 0, Color.GRAY));
        return scrollPane;
    }

    private JComponent createTitle() {
        JPanel panel = new JPanel(new BorderLayout());
//        panel.setBackground(new Color(182, 191, 207));
        panel.setBorder(BorderFactory.createEmptyBorder(4, 4, 4, 4));
        panel.add(createTitleLabel(), BorderLayout.WEST);
        panel.add(createCloseButton(), BorderLayout.EAST);
        return panel;
    }

    private static JComponent createTitleLabel() {
        return new JLabel("JavaScript Console");
    }

    private JComponent createCloseButton() {
        JButton closeButton = new JButton();
        closeButton.setOpaque(false);
        closeButton.setToolTipText("Close JavaScript Console");
        closeButton.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0));
        closeButton.setPressedIcon(Resources.getIcon("close-pressed.png"));