public BrainPanelTest() throws HeadlessException
    {
        super();

        setDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE);

        JLayeredPane layeredPane = new JLayeredPane();
        setLayeredPane(layeredPane);

        final BrainPanel brainPanel = new BrainPanel();
        layeredPane.add(brainPanel, JLayeredPane.DEFAULT_LAYER);

        layeredPane.addComponentListener(new ComponentAdapter()
        {
            @Override
            public void componentResized(ComponentEvent e)
            {
                Component component = e.getComponent();
                brainPanel.setSize(component.getSize());
                brainPanel.validate();
            }
        });

        pack();

        setVisible(true);
        setSize(800, 600);//unity hack

        setFullScreen();

        KeyboardFocusManager.getCurrentKeyboardFocusManager().addKeyEventDispatcher(new KeyboardDispatcher());

        Toolkit.getDefaultToolkit().addAWTEventListener(new org.i4qwee.chgk.trainer.new_brain.actionlisteners.MouseListener(), AWTEvent.MOUSE_EVENT_MASK);

        PropertyConfigurator.configure(getClass().getResource("/config/log4j.properties"));

        try
        {
            setIconImage(ImageIO.read(getClass().getResource("/img/icon.png")));
        }
        catch (IOException e)
        {
            LOGGER.error("Cannot get icon!", e);
        }

        setTitle("Буйный лосось");
    }