Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

org.dma.ihm.gui
Class Desktop  view Desktop download Desktop.java

java.lang.Object
  extended byjava.awt.Component
      extended byjava.awt.Container
          extended byjava.awt.Window
              extended byjava.awt.Frame
                  extended byjavax.swing.JFrame
                      extended byorg.dma.ihm.gui.Desktop
All Implemented Interfaces:
javax.accessibility.Accessible, java.awt.image.ImageObserver, java.awt.MenuContainer, javax.swing.RootPaneContainer, java.io.Serializable, javax.swing.WindowConstants

public class Desktop
extends javax.swing.JFrame

Main frame for the game Contains: - Functions to provide a gui to users - Functions called by the controller - Menu


Nested Class Summary
 
Nested classes inherited from class javax.swing.JFrame
javax.swing.JFrame.AccessibleJFrame
 
Nested classes inherited from class java.awt.Frame
java.awt.Frame.AccessibleAWTFrame
 
Nested classes inherited from class java.awt.Window
java.awt.Window.AccessibleAWTWindow
 
Nested classes inherited from class java.awt.Container
java.awt.Container.AccessibleAWTContainer
 
Nested classes inherited from class java.awt.Component
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy
 
Field Summary
private  java.util.Vector actionListeners
           
(package private)  java.awt.BorderLayout borderLayout1
          Controls
(package private)  org.dma.ihm.controller.data.User currentUser
          Pointer on the current user
(package private)  org.dma.ihm.gui.lib.JIhmDesktopPane desktop
           
(package private)  org.dma.ihm.gui.message.FrameMessage frameShortMessage
          FrameMessage is shown while desktop is disabled
(package private)  javax.swing.JMenuItem menuAbout
           
(package private)  javax.swing.JMenuBar menuBar
           
(package private)  javax.swing.JMenuItem menuDebug
           
(package private)  javax.swing.JMenuItem menuExit
           
(package private)  javax.swing.JMenu menuFile
           
(package private)  javax.swing.JMenu menuHelp
           
(package private)  javax.swing.JMenu menuLeagues
           
(package private)  javax.swing.JMenuItem menuMain
           
(package private)  javax.swing.JMenu menuManager
           
(package private)  javax.swing.JMenuItem menuShowCalendar
           
(package private)  javax.swing.JMenuItem menuShowPlayersAttributes
           
(package private)  javax.swing.JMenuItem menuShowPlayerStats
           
(package private)  javax.swing.JMenuItem menuShowStandings
           
(package private)  javax.swing.JMenuItem menuShowTeam
           
(package private)  javax.swing.JMenuItem menuShowTeamsAttributes
           
(package private)  javax.swing.JMenuItem menuShowTeamsStats
           
(package private)  javax.swing.JMenuItem menuShowUser
           
(package private)  javax.swing.JMenu menuTools
           
 
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, MAXIMIZED_BOTH, MAXIMIZED_HORIZ, MAXIMIZED_VERT, 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.Window
 
Fields inherited from class java.awt.Container
 
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
Desktop()
          Construct the frame, call ihmInit
 
Method Summary
 void addActionListener(java.awt.event.ActionListener l)
          Adds a feature to the ActionListener attribute of the Desktop object
private  void centerFrame(org.dma.ihm.gui.lib.JIhmInternalFrame doc)
          Centers a frame on the desktop
 void closeAllFrames()
          Removes all frames
 void doGameCalendarDisplayGuiEvent(org.dma.ihm.game.calendar.events.GameCalendarDisplayGuiEvent event)
          Show desktop for a single user
 void doGameCalendarGameDayEvent(org.dma.ihm.game.calendar.events.GameCalendarGameDayEvent event)
          Show Matches online
 void doGameCalendarStopBeforeGameDayEvent(org.dma.ihm.controller.data.User user, org.dma.ihm.game.calendar.events.GameCalendarStopBeforeGamedayEvent event)
          Stop gui before gameday
private  void enableMenus(boolean enabled)
          Enables/disables menus in the menubar
protected  void fireActionPerformed(java.awt.event.ActionEvent e)
          Description of the Method
private  void ihmInit()
          IHM init, switch frame visible, display FrameControl
private  void jbInit()
          JBuilder stuff (construct frame
(package private)  void menuAbout_actionPerformed(java.awt.event.ActionEvent e)
          Fancy About screen
(package private)  void menuDebug_actionPerformed(java.awt.event.ActionEvent e)
          Debug screen
(package private)  void menuExit_actionPerformed(java.awt.event.ActionEvent e)
          Exit game
(package private)  void menuMain_actionPerformed(java.awt.event.ActionEvent e)
          Show Main Menu
(package private)  void menuShowCalendar_actionPerformed(java.awt.event.ActionEvent e)
          Create new Calendar frame for the current user
(package private)  void menuShowPlayersAttributes_actionPerformed(java.awt.event.ActionEvent e)
          Create new PlayerAttributes frame for the current user
(package private)  void menuShowPlayerStats_actionPerformed(java.awt.event.ActionEvent e)
          Create new PlayerStats frame for the current user
(package private)  void menuShowStandings_actionPerformed(java.awt.event.ActionEvent e)
          Create new Standings frame for the current user
(package private)  void menuShowTeam_actionPerformed(java.awt.event.ActionEvent e)
          Create new Team frame for the current user
(package private)  void menuShowTeamsAttributes_actionPerformed(java.awt.event.ActionEvent e)
          Create new TeamAttributes frame for the current user
(package private)  void menuShowTeamsStats_actionPerformed(java.awt.event.ActionEvent e)
          Create new TeamStats frame for the current user
(package private)  void menuShowUser_actionPerformed(java.awt.event.ActionEvent e)
          Create new User frame for the current user
protected  void processWindowEvent(java.awt.event.WindowEvent e)
          Overridden so we can exit when window is closed
 void removeActionListener(java.awt.event.ActionListener l)
          Description of the Method
 void showFrameDebug(java.lang.Object obj, java.lang.String name)
          Shows a DebugFrame
 void showFramePlayer(org.dma.ihm.game.player.Player player)
          Shows a PlayerFrame
 void showFrameScoreSheet(org.dma.ihm.game.match.Match match)
          Shows a TeamScoreSheet
 void showFrameTeam(org.dma.ihm.game.team.Team team)
          Shows a TeamFrame
 void showOnlineMessage(java.lang.String title, java.lang.String msg)
          Show online Message
 void showShortMessage(java.lang.String title, java.lang.String msg)
          Show short Message
private  void turnDesktopOff()
          Starts desktop wiht menus
private  void turnDesktopOn()
          Starts desktop wiht menus
private  void turnShortMessagesOff()
          Stops short message frame
private  void turnShortMessagesOn()
          Starts the short message frame
 
Methods inherited from class javax.swing.JFrame
addImpl, createRootPane, frameInit, getAccessibleContext, getContentPane, getDefaultCloseOperation, getGlassPane, getJMenuBar, getLayeredPane, getPreferredSize, getRootPane, isDefaultLookAndFeelDecorated, isRootPaneCheckingEnabled, paramString, processKeyEvent, remove, setContentPane, setDefaultCloseOperation, setDefaultLookAndFeelDecorated, setGlassPane, setJMenuBar, setLayeredPane, setLayout, setRootPane, setRootPaneCheckingEnabled, update
 
Methods inherited from class java.awt.Frame
addNotify, getCursorType, getExtendedState, getFrames, getIconImage, getMaximizedBounds, getMenuBar, getState, getTitle, isResizable, isUndecorated, remove, removeNotify, setCursor, setExtendedState, setIconImage, setMaximizedBounds, setMenuBar, setResizable, setState, setTitle, setUndecorated
 
Methods inherited from class java.awt.Window
addWindowFocusListener, addWindowListener, addWindowStateListener, applyResourceBundle, applyResourceBundle, createBufferStrategy, createBufferStrategy, dispose, getBufferStrategy, getFocusableWindowState, getFocusCycleRootAncestor, getFocusOwner, getGraphicsConfiguration, getListeners, getLocale, getMostRecentFocusOwner, getOwnedWindows, getOwner, getToolkit, getWarningString, getWindowFocusListeners, getWindowListeners, getWindowStateListeners, hide, isActive, isFocusableWindow, isFocusCycleRoot, isFocused, isShowing, pack, postEvent, processEvent, processWindowFocusEvent, processWindowStateEvent, removeWindowFocusListener, removeWindowListener, removeWindowStateListener, setCursor, setFocusableWindowState, setFocusCycleRoot, setLocationRelativeTo, show, toBack, toFront
 
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getInsets, getLayout, getMaximumSize, getMinimumSize, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paint, paintComponents, preferredSize, print, printComponents, processContainerEvent, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusTraversalKeys, setFocusTraversalPolicy, setFont, transferFocusDownCycle, validate, validateTree
 
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, contains, createImage, createImage, createVolatileImage, createVolatileImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getGraphics, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocation, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isDoubleBuffered, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, 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, processMouseWheelEvent, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, reshape, resize, resize, setBackground, setBounds, setBounds, setComponentOrientation, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, setVisible, show, size, toString, transferFocus, transferFocusBackward, transferFocusUpCycle
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface java.awt.MenuContainer
getFont, postEvent
 

Field Detail

frameShortMessage

org.dma.ihm.gui.message.FrameMessage frameShortMessage
FrameMessage is shown while desktop is disabled


currentUser

org.dma.ihm.controller.data.User currentUser
Pointer on the current user


borderLayout1

java.awt.BorderLayout borderLayout1
Controls


desktop

org.dma.ihm.gui.lib.JIhmDesktopPane desktop

menuBar

javax.swing.JMenuBar menuBar

menuFile

javax.swing.JMenu menuFile

menuExit

javax.swing.JMenuItem menuExit

menuMain

javax.swing.JMenuItem menuMain

menuTools

javax.swing.JMenu menuTools

menuShowUser

javax.swing.JMenuItem menuShowUser

menuManager

javax.swing.JMenu menuManager

menuShowTeam

javax.swing.JMenuItem menuShowTeam

menuLeagues

javax.swing.JMenu menuLeagues

menuShowCalendar

javax.swing.JMenuItem menuShowCalendar

menuShowStandings

javax.swing.JMenuItem menuShowStandings

menuShowTeamsAttributes

javax.swing.JMenuItem menuShowTeamsAttributes

menuShowTeamsStats

javax.swing.JMenuItem menuShowTeamsStats

menuShowPlayersAttributes

javax.swing.JMenuItem menuShowPlayersAttributes

menuShowPlayerStats

javax.swing.JMenuItem menuShowPlayerStats

menuHelp

javax.swing.JMenu menuHelp

menuDebug

javax.swing.JMenuItem menuDebug

menuAbout

javax.swing.JMenuItem menuAbout

actionListeners

private transient java.util.Vector actionListeners
Constructor Detail

Desktop

public Desktop()
Construct the frame, call ihmInit

Method Detail

jbInit

private void jbInit()
             throws java.lang.Exception
JBuilder stuff (construct frame


ihmInit

private void ihmInit()
IHM init, switch frame visible, display FrameControl


turnShortMessagesOff

private void turnShortMessagesOff()
Stops short message frame


turnShortMessagesOn

private void turnShortMessagesOn()
Starts the short message frame


turnDesktopOn

private void turnDesktopOn()
Starts desktop wiht menus


turnDesktopOff

private void turnDesktopOff()
Starts desktop wiht menus


enableMenus

private void enableMenus(boolean enabled)
Enables/disables menus in the menubar


closeAllFrames

public void closeAllFrames()
Removes all frames


centerFrame

private void centerFrame(org.dma.ihm.gui.lib.JIhmInternalFrame doc)
Centers a frame on the desktop


showFrameScoreSheet

public void showFrameScoreSheet(org.dma.ihm.game.match.Match match)
Shows a TeamScoreSheet


showFrameTeam

public void showFrameTeam(org.dma.ihm.game.team.Team team)
Shows a TeamFrame


showFramePlayer

public void showFramePlayer(org.dma.ihm.game.player.Player player)
Shows a PlayerFrame


showFrameDebug

public void showFrameDebug(java.lang.Object obj,
                           java.lang.String name)
Shows a DebugFrame


processWindowEvent

protected void processWindowEvent(java.awt.event.WindowEvent e)
Overridden so we can exit when window is closed


menuExit_actionPerformed

void menuExit_actionPerformed(java.awt.event.ActionEvent e)
Exit game


menuMain_actionPerformed

void menuMain_actionPerformed(java.awt.event.ActionEvent e)
Show Main Menu


menuShowStandings_actionPerformed

void menuShowStandings_actionPerformed(java.awt.event.ActionEvent e)
Create new Standings frame for the current user


menuShowTeamsAttributes_actionPerformed

void menuShowTeamsAttributes_actionPerformed(java.awt.event.ActionEvent e)
Create new TeamAttributes frame for the current user


menuShowTeamsStats_actionPerformed

void menuShowTeamsStats_actionPerformed(java.awt.event.ActionEvent e)
Create new TeamStats frame for the current user


menuShowPlayerStats_actionPerformed

void menuShowPlayerStats_actionPerformed(java.awt.event.ActionEvent e)
Create new PlayerStats frame for the current user


menuShowPlayersAttributes_actionPerformed

void menuShowPlayersAttributes_actionPerformed(java.awt.event.ActionEvent e)
Create new PlayerAttributes frame for the current user


menuShowUser_actionPerformed

void menuShowUser_actionPerformed(java.awt.event.ActionEvent e)
Create new User frame for the current user


menuShowTeam_actionPerformed

void menuShowTeam_actionPerformed(java.awt.event.ActionEvent e)
Create new Team frame for the current user


menuShowCalendar_actionPerformed

void menuShowCalendar_actionPerformed(java.awt.event.ActionEvent e)
Create new Calendar frame for the current user


menuAbout_actionPerformed

void menuAbout_actionPerformed(java.awt.event.ActionEvent e)
Fancy About screen


menuDebug_actionPerformed

void menuDebug_actionPerformed(java.awt.event.ActionEvent e)
Debug screen


showShortMessage

public void showShortMessage(java.lang.String title,
                             java.lang.String msg)
Show short Message


doGameCalendarDisplayGuiEvent

public void doGameCalendarDisplayGuiEvent(org.dma.ihm.game.calendar.events.GameCalendarDisplayGuiEvent event)
Show desktop for a single user


showOnlineMessage

public void showOnlineMessage(java.lang.String title,
                              java.lang.String msg)
Show online Message


doGameCalendarGameDayEvent

public void doGameCalendarGameDayEvent(org.dma.ihm.game.calendar.events.GameCalendarGameDayEvent event)
Show Matches online


doGameCalendarStopBeforeGameDayEvent

public void doGameCalendarStopBeforeGameDayEvent(org.dma.ihm.controller.data.User user,
                                                 org.dma.ihm.game.calendar.events.GameCalendarStopBeforeGamedayEvent event)
Stop gui before gameday


removeActionListener

public void removeActionListener(java.awt.event.ActionListener l)
Description of the Method


addActionListener

public void addActionListener(java.awt.event.ActionListener l)
Adds a feature to the ActionListener attribute of the Desktop object


fireActionPerformed

protected void fireActionPerformed(java.awt.event.ActionEvent e)
Description of the Method