public class DigesterController
extends java.lang.Object
implements java.awt.event.ActionListener, java.awt.event.WindowListener, com.apple.eawt.AboutHandler, com.apple.eawt.PreferencesHandler, com.apple.eawt.QuitHandler
PanelWindow
.
Outsourced from the main class in order to keep the source code handy. To nicely support
application in Mac OS X this class subclasses Apples's bridge between applications and the OS.
The menu bar is not shown by the main window here but by the screen menu.
Constructor and Description |
---|
DigesterController()
Class constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
actionPerformed(java.awt.event.ActionEvent e)
This method is called automatically if an event comes along.
|
protected static boolean |
askRestartJNLP(java.lang.String restart)
Asks the user whether to restart the program or not.
|
protected boolean |
askUninstall(boolean clean)
Asks the user if this software should be uninstalled.
|
static void |
checkDigests()
Load digests from files in various supported formats (GNU, BSD, XML at the moment).
|
boolean |
closeApplication(boolean exit,
boolean saveconfig)
Checks whether the application can be exited (running tasks etc.).
|
protected static void |
doQuickCheck()
Checks for network or local files ("Go" button).
|
static void |
generateDigests()
Generate digests in various supported formats (GNU, BSD, XML at the moment).
|
void |
handleAbout(com.apple.eawt.AppEvent.AboutEvent e)
Called when the application is asked to show it's about dialog (Mac OS X only).
|
void |
handlePreferences(com.apple.eawt.AppEvent.PreferencesEvent e)
Called when the app is asked to show it's preferences UI (Mac OS X only).
|
void |
handleQuitRequestWith(com.apple.eawt.AppEvent.QuitEvent e,
com.apple.eawt.QuitResponse response)
Invoked when the application is asked to quit (Mac OS X only).
|
protected void |
restartApplicationInstaller(boolean close)
Checks whether the application can be exited (installer version with executable).
|
protected void |
restartApplicationJNLP(java.lang.String url,
boolean close)
Checks whether the application can be exited.
|
protected void |
setupMemory()
Displays the memory configuration dialog.
|
protected void |
showManual()
Opens the PDF manual if available.
|
static void |
showOptions()
Shows the dialog presenting the options.
|
static void |
syncFiles()
Starts the synchronization wizard.
|
protected void |
uninstallInstaller()
Asks the user if this installed software should be uninstalled.
|
protected void |
uninstallWebStarter(boolean clean)
Asks the user if this Web Start software should be uninstalled.
|
void |
windowActivated(java.awt.event.WindowEvent e)
Invoked when the window is set to be the active window.
|
void |
windowClosed(java.awt.event.WindowEvent e)
Invoked when a window has been closed as the result of calling dispose on the window.
|
void |
windowClosing(java.awt.event.WindowEvent e)
Invoked when the user attempts to close the window from the window's system menu.
|
void |
windowDeactivated(java.awt.event.WindowEvent e)
Invoked when a Window is no longer the active Window.
|
void |
windowDeiconified(java.awt.event.WindowEvent e)
Invoked when a window is changed from a minimized to a normal state.
|
void |
windowIconified(java.awt.event.WindowEvent e)
Invoked when a window is changed from a normal to a minimized state.
|
void |
windowOpened(java.awt.event.WindowEvent e)
Invoked the first time a window is made visible.
|
public DigesterController()
public void actionPerformed(java.awt.event.ActionEvent e)
actionPerformed
in interface java.awt.event.ActionListener
e
- Event object referencepublic void windowActivated(java.awt.event.WindowEvent e)
windowActivated
in interface java.awt.event.WindowListener
e
- The event objectpublic void windowClosed(java.awt.event.WindowEvent e)
windowClosed
in interface java.awt.event.WindowListener
e
- The event objectpublic void windowClosing(java.awt.event.WindowEvent e)
windowClosing
in interface java.awt.event.WindowListener
e
- The event objectpublic boolean closeApplication(boolean exit, boolean saveconfig)
exit
- Perform final System.exit()
?saveconfig
- Shall configuration be saved?protected void restartApplicationJNLP(java.lang.String url, boolean close)
url
- Restart with this URL (e.g. Web Start), may be null
close
- Close the application first?protected void restartApplicationInstaller(boolean close)
close
- Close the application first?public void windowDeactivated(java.awt.event.WindowEvent e)
windowDeactivated
in interface java.awt.event.WindowListener
e
- The event objectpublic void windowDeiconified(java.awt.event.WindowEvent e)
windowDeiconified
in interface java.awt.event.WindowListener
e
- The event objectpublic void windowIconified(java.awt.event.WindowEvent e)
windowIconified
in interface java.awt.event.WindowListener
e
- The event objectpublic void windowOpened(java.awt.event.WindowEvent e)
windowOpened
in interface java.awt.event.WindowListener
e
- The event objectpublic static void checkDigests()
public static void generateDigests()
public static void syncFiles()
protected static boolean askRestartJNLP(java.lang.String restart)
restart
- The JNLP targetprotected void setupMemory()
protected void showManual()
public void handleAbout(com.apple.eawt.AppEvent.AboutEvent e)
handleAbout
in interface com.apple.eawt.AboutHandler
e
- Event object referencepublic void handlePreferences(com.apple.eawt.AppEvent.PreferencesEvent e)
handlePreferences
in interface com.apple.eawt.PreferencesHandler
e
- Event object referencepublic void handleQuitRequestWith(com.apple.eawt.AppEvent.QuitEvent e, com.apple.eawt.QuitResponse response)
handleQuitRequestWith
in interface com.apple.eawt.QuitHandler
e
- Event object referencepublic static void showOptions()
protected static void doQuickCheck()
protected boolean askUninstall(boolean clean)
clean
- Remove configuration?protected void uninstallWebStarter(boolean clean)
clean
- Remove configuration?protected void uninstallInstaller()
Copyright © 2005-2015 Leisenfels UG. All rights reserved.