|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--java.awt.Component | +--java.awt.Container | +--java.awt.Window | +--java.awt.Frame | +--javax.swing.JFrame | +--org.relayirc.swingui.ChatApp
Main class of the Relay-JFC chat application.
The contents of this file are subject to the Mozilla Public License Version 1.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.mozilla.org/MPL
Original Code: Relay IRC Chat EngineInner classes inherited from class javax.swing.JFrame |
javax.swing.JFrame.AccessibleJFrame |
Inner classes inherited from class java.awt.Frame |
java.awt.Frame.AccessibleAWTFrame |
Inner classes inherited from class java.awt.Window |
java.awt.Window.AccessibleAWTWindow |
Inner classes inherited from class java.awt.Container |
java.awt.Container.AccessibleAWTContainer |
Inner classes inherited from class java.awt.Component |
java.awt.Component.AccessibleAWTComponent |
Field Summary | |
protected Server |
_server
|
static java.lang.String |
ABOUT
Action name for the ABOUT action. |
static java.lang.String |
CASCADE
Action name for the CASCADE action. |
static java.lang.String |
CONNECT
Action name for CONNECT action. |
static java.lang.String |
CUSTOMIZE_ACTIONS
Action name for the CUSTOMIZER_ACTIONS action. |
static java.lang.String |
CUSTOMIZE_LISTENERS
Action name for the CUSTOMIZE_LISTENERS action. |
static java.lang.String |
DISCONNECT
Action name for the DISCONNECT action. |
static java.lang.String |
EDIT_SERVER_LIST
Action name for the EDIT_SERVER_LIST action. |
static java.lang.String |
EXIT
Action name for the EXIT action. |
static java.lang.String |
JOIN_CHANNEL
Action name for the JOIN_CHANNEL action. |
static java.lang.String |
LIST_CHANNELS
Action name for the LIST_CHANNELS action. |
static java.lang.String |
SETUP
Action name for the SETUP action. |
static java.lang.String |
TILE_HORZ
Action name for the TILE_HORZ action. |
static java.lang.String |
TILE_VERT
Action name for the TILE_VERT action. |
static java.lang.String |
WHOIS
Action name for the WHOIS action. |
Fields inherited from class javax.swing.JFrame |
accessibleContext, EXIT_ON_CLOSE, rootPane, rootPaneCheckingEnabled |
Fields inherited from class java.awt.Frame |
CROSSHAIR_CURSOR, DEFAULT_CURSOR, E_RESIZE_CURSOR, HAND_CURSOR, ICONIFIED, MOVE_CURSOR, N_RESIZE_CURSOR, NE_RESIZE_CURSOR, NORMAL, NW_RESIZE_CURSOR, S_RESIZE_CURSOR, SE_RESIZE_CURSOR, SW_RESIZE_CURSOR, TEXT_CURSOR, W_RESIZE_CURSOR, WAIT_CURSOR |
Fields inherited from class java.awt.Component |
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
Fields inherited from interface javax.swing.WindowConstants |
DISPOSE_ON_CLOSE, DO_NOTHING_ON_CLOSE, HIDE_ON_CLOSE |
Fields inherited from interface java.awt.image.ImageObserver |
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
Constructor Summary | |
ChatApp()
Construct a chat application. |
Method Summary | |
void |
cascade()
Arrange windows in cascade formation. |
void |
closeApp()
Disconnect from the IRC server, save options and exit applicatin. |
void |
connect()
Present connection dialog to user and allow connection. |
void |
connect(Server server)
Connect to the specified chat server. |
void |
display(java.lang.String str)
Display text on the main console. |
void |
dock(MDIClientPanel panel)
To dock/undock a MDIClientPanel, first set the panel's dock state then call this function to register that dock state. |
IChatAction |
getAction(java.lang.String actionName)
Get action by name. |
java.lang.String |
getAppName()
Returns the name of the chat application. |
java.lang.String |
getAppVersion()
Returns the version of the chat application. |
static ChatApp |
getChatApp()
Returns the one-and-only chat application object. |
static javax.swing.text.Style |
getChatStyle(java.lang.String st)
|
ChatOptions |
getOptions()
|
org.python.util.PythonInterpreter |
getPythonInterpreter()
|
Server |
getServer()
|
static java.util.Hashtable |
initActions(java.lang.Object[][] actionArray,
java.lang.Object declaringObject)
|
void |
initGUI()
|
boolean |
isConnected()
|
boolean |
isConnecting()
|
void |
layoutGUI()
|
void |
listChannels()
Show the channel search window. |
void |
loadLookAndFeel(java.lang.String name)
Load a Swing pluggable look and feel specified by name |
static void |
main(java.lang.String[] args)
Main method for the Relay-JFC chat application. |
void |
onChannelAdd(ServerEvent event)
Handle channel object addition. |
void |
onChannelJoin(ServerEvent event)
Create channel window for this new channel |
void |
onChannelPart(ServerEvent event)
Does nothing as channel objects take care of parting. |
void |
onConnect(ServerEvent event)
On connection, ask actions to update themselves. |
void |
onDisconnect(ServerEvent event)
On disconnection, ask actions to update themselves. |
void |
onInvite(ServerEvent event)
Display information from INVITE message. |
void |
onIsOn(ServerEvent event)
Display information from ISON reply. |
void |
onStatus(ServerEvent event)
Respond to onStatus() event from chat engine by displaying status message on console. |
void |
onWhoIs(ServerEvent event)
Respond to WhoIs message. |
void |
removeChatPanel(ChannelPanel panel)
Remove chat channel panel from MDI panel and close, hide and dispose of channel's frame as well. |
void |
run()
The main application thread, for internal use only. |
void |
sendWhoIs(java.lang.String nick,
boolean popup)
Request whois information for user specified by nick name. |
void |
sendWhoIs(User user,
boolean popup)
Request whois information for user specified by user object. |
static void |
setChatApp(ChatApp a)
Returns the one-and-only chat application object. |
static void |
setChatFont(java.awt.Font font)
|
void |
setOptions(ChatOptions options)
|
void |
setServer(Server server)
|
void |
setShowConsole(boolean show)
|
void |
setShowFavorites(boolean show)
|
void |
setShowPython(boolean show)
|
void |
setStatusBarEnabled(boolean flag)
|
void |
showJoinChannelDlg()
Present the join channel dialog and if the user specifies a channel then send join command to chat server. |
void |
showServerListDlg()
Present the server list dialog. |
void |
shutdown()
Currenly, does nothing. |
void |
tileHorizontal()
Tile windows horizontally. |
void |
tileVertical()
Tile windows vertically. |
void |
updateActions()
|
void |
updateLookAndFeel()
Sets look and feel according to current ChatOptions settings. |
Methods inherited from class javax.swing.JFrame |
addImpl, createRootPane, frameInit, getAccessibleContext, getContentPane, getDefaultCloseOperation, getGlassPane, getJMenuBar, getLayeredPane, getRootPane, isRootPaneCheckingEnabled, paramString, processKeyEvent, processWindowEvent, remove, setContentPane, setDefaultCloseOperation, setGlassPane, setJMenuBar, setLayeredPane, setLayout, setRootPane, setRootPaneCheckingEnabled, update |
Methods inherited from class java.awt.Frame |
addNotify, finalize, getCursorType, getFrames, getIconImage, getMenuBar, getState, getTitle, isResizable, remove, removeNotify, setCursor, setIconImage, setMenuBar, setResizable, setState, setTitle |
Methods inherited from class java.awt.Window |
addWindowListener, applyResourceBundle, applyResourceBundle, dispose, getFocusOwner, getGraphicsConfiguration, getInputContext, getListeners, getLocale, getOwnedWindows, getOwner, getToolkit, getWarningString, hide, isShowing, pack, postEvent, processEvent, removeWindowListener, setCursor, show, toBack, toFront |
Methods inherited from class java.awt.Container |
add, add, add, add, add, addContainerListener, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getInsets, getLayout, getMaximumSize, getMinimumSize, getPreferredSize, insets, invalidate, isAncestorOf, layout, list, list, locate, minimumSize, paint, paintComponents, preferredSize, print, printComponents, processContainerEvent, remove, removeAll, removeContainerListener, setFont, validate, validateTree |
Methods inherited from class java.awt.Component |
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addPropertyChangeListener, addPropertyChangeListener, bounds, checkImage, checkImage, coalesceEvents, contains, contains, createImage, createImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, getBackground, getBounds, getBounds, getColorModel, getComponentOrientation, getCursor, getDropTarget, getFont, getFontMetrics, getForeground, getGraphics, getHeight, getInputMethodRequests, getLocation, getLocation, getLocationOnScreen, getName, getParent, getPeer, getSize, getSize, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isDisplayable, isDoubleBuffered, isEnabled, isFocusTraversable, isLightweight, isOpaque, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, prepareImage, prepareImage, printAll, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseEvent, processMouseMotionEvent, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, repaint, requestFocus, reshape, resize, resize, setBackground, setBounds, setBounds, setComponentOrientation, setDropTarget, setEnabled, setForeground, setLocale, setLocation, setLocation, setName, setSize, setSize, setVisible, show, size, toString, transferFocus |
Methods inherited from class java.lang.Object |
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface java.awt.MenuContainer |
getFont, postEvent |
Field Detail |
protected Server _server
public static final java.lang.String ABOUT
public static final java.lang.String CASCADE
public static final java.lang.String CONNECT
public static final java.lang.String CUSTOMIZE_ACTIONS
public static final java.lang.String CUSTOMIZE_LISTENERS
public static final java.lang.String DISCONNECT
public static final java.lang.String EDIT_SERVER_LIST
public static final java.lang.String EXIT
public static final java.lang.String JOIN_CHANNEL
public static final java.lang.String LIST_CHANNELS
public static final java.lang.String SETUP
public static final java.lang.String TILE_HORZ
public static final java.lang.String TILE_VERT
public static final java.lang.String WHOIS
Constructor Detail |
public ChatApp()
Method Detail |
public static void main(java.lang.String[] args)
public static ChatApp getChatApp()
public static void setChatApp(ChatApp a)
public void run()
public IChatAction getAction(java.lang.String actionName)
public static java.util.Hashtable initActions(java.lang.Object[][] actionArray, java.lang.Object declaringObject)
public java.lang.String getAppName()
public java.lang.String getAppVersion()
public static javax.swing.text.Style getChatStyle(java.lang.String st)
public static void setChatFont(java.awt.Font font)
public boolean isConnected()
public boolean isConnecting()
public Server getServer()
public void setServer(Server server)
public void setOptions(ChatOptions options)
public ChatOptions getOptions()
public org.python.util.PythonInterpreter getPythonInterpreter()
public void setStatusBarEnabled(boolean flag)
public void setShowConsole(boolean show)
public void setShowFavorites(boolean show)
public void setShowPython(boolean show)
public void connect(Server server)
public void connect()
public void display(java.lang.String str)
public void closeApp()
public void showJoinChannelDlg()
public void showServerListDlg()
public void cascade()
public void tileHorizontal()
public void tileVertical()
public void shutdown()
public void onStatus(ServerEvent event)
onStatus
in interface ServerListener
public void onChannelAdd(ServerEvent event)
onChannelAdd
in interface ServerListener
public void onChannelJoin(ServerEvent event)
onChannelJoin
in interface ServerListener
public void onIsOn(ServerEvent event)
onIsOn
in interface ServerListener
public void onInvite(ServerEvent event)
onInvite
in interface ServerListener
public void onChannelPart(ServerEvent event)
onChannelPart
in interface ServerListener
public void onConnect(ServerEvent event)
onConnect
in interface ServerListener
public void onDisconnect(ServerEvent event)
onDisconnect
in interface ServerListener
public void sendWhoIs(java.lang.String nick, boolean popup)
public void sendWhoIs(User user, boolean popup)
public void onWhoIs(ServerEvent event)
onWhoIs
in interface ServerListener
public void initGUI()
public void layoutGUI()
public void dock(MDIClientPanel panel)
MDIPanel
public void removeChatPanel(ChannelPanel panel)
public void listChannels()
public void updateLookAndFeel()
public void loadLookAndFeel(java.lang.String name)
public void updateActions()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |