com.bitmechanic.maxq
Class SwingMain

java.lang.Object
  extended by com.bitmechanic.maxq.SwingMain
All Implemented Interfaces:
java.awt.event.ActionListener, java.util.EventListener

public class SwingMain
extends java.lang.Object
implements java.awt.event.ActionListener

The GUI for MaxQ. The real work is delegated to currentTest, which is what you might call our "document" (and we are the "view").


Constructor Summary
SwingMain(ProxyServer proxy)
          Called once, to create the window.
 
Method Summary
 void actionPerformed(java.awt.event.ActionEvent e)
           
 void openFile(java.io.File path)
          Opens the script indicated by path for editing.
 void reportException(java.lang.Throwable ex)
          Show an error report in a message box.
static void reportOutsideException(java.lang.Throwable ex)
          Called by other threads to complain about their problems.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SwingMain

public SwingMain(ProxyServer proxy)
          throws java.lang.Exception
Called once, to create the window.

Throws:
java.lang.Exception
Method Detail

actionPerformed

public void actionPerformed(java.awt.event.ActionEvent e)
Specified by:
actionPerformed in interface java.awt.event.ActionListener

openFile

public void openFile(java.io.File path)
              throws java.lang.Exception
Opens the script indicated by path for editing.

Throws:
java.lang.Exception

reportException

public void reportException(java.lang.Throwable ex)
Show an error report in a message box.


reportOutsideException

public static void reportOutsideException(java.lang.Throwable ex)
Called by other threads to complain about their problems. This better than just dumping a stack trace because the user might not notice that.