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

Quick Search    Search Deep

org.chordcast.ui
Class ChordEditor  view ChordEditor download ChordEditor.java

java.lang.Object
  extended byjava.awt.Component
      extended byjava.awt.Container
          extended byjava.awt.Window
              extended byjava.awt.Dialog
                  extended byjavax.swing.JDialog
                      extended byorg.chordcast.ui.ChordEditor
All Implemented Interfaces:
javax.accessibility.Accessible, java.awt.event.ActionListener, java.util.EventListener, java.awt.image.ImageObserver, java.awt.event.KeyListener, java.awt.MenuContainer, javax.swing.RootPaneContainer, java.io.Serializable, javax.swing.WindowConstants, java.awt.event.WindowListener

public class ChordEditor
extends javax.swing.JDialog
implements java.awt.event.ActionListener, java.awt.event.WindowListener, java.awt.event.KeyListener

The dialog for Chord edition mode.


Nested Class Summary
 
Nested classes inherited from class javax.swing.JDialog
javax.swing.JDialog.AccessibleJDialog
 
Nested classes inherited from class java.awt.Dialog
java.awt.Dialog.AccessibleAWTDialog
 
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  javax.swing.JButton barredButton
           
private  javax.swing.JPanel buttonPanel
           
private  ChordUI chordUI
           
private  ChordUIEditable chordUIEditable
           
private  javax.swing.JButton dotButton
           
private  javax.swing.JMenuItem downMenuItem
           
private  javax.swing.JButton emptyButton
           
private  javax.swing.JMenu fretMenu
           
private  javax.swing.JButton ixeButton
           
private  javax.swing.JMenuBar menuBar
           
private  javax.swing.JButton okButton
           
private  java.awt.Color pressedColor
           
private  javax.swing.JMenuItem shiftDownMenuItem
           
private  javax.swing.JMenuItem shiftUpMenuItem
           
private  javax.swing.JButton squareButton
           
private  java.awt.Color unPressedColor
           
private  javax.swing.JMenuItem upMenuItem
           
private  javax.swing.JButton zeroButton
           
 
Fields inherited from class javax.swing.JDialog
accessibleContext, rootPane, rootPaneCheckingEnabled
 
Fields inherited from class java.awt.Dialog
 
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, EXIT_ON_CLOSE, HIDE_ON_CLOSE
 
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
 
Constructor Summary
ChordEditor(ChordUI hisChordUI)
          Construct and Show the Chord edition dialog.
 
Method Summary
 void actionPerformed(java.awt.event.ActionEvent actionEvent)
          Process the buttons events.
private  void initializeMenu()
           
 void keyPressed(java.awt.event.KeyEvent keyEvent)
          Manage key event.
 void keyReleased(java.awt.event.KeyEvent keyEvent)
          This method is called when a key is released.
 void keyTyped(java.awt.event.KeyEvent keyEvent)
          This method is called when a key is typed.
protected  void setButtonsState(javax.swing.JButton pressed)
          Manage the button pressed state
private  void setPressed(javax.swing.JButton pressed)
           
 void setState(int state)
          Permit to other classes to modify the button states
private  void setUnPressed(javax.swing.JButton unPressed)
           
 void windowActivated(java.awt.event.WindowEvent windowEvent)
          This method is called when a window is activated.
 void windowClosed(java.awt.event.WindowEvent windowEvent)
          This method is called when the window is closed.
 void windowClosing(java.awt.event.WindowEvent windowEvent)
          This method is called when the user calls the system menu close function, giving the program a chance to cancel the close.
 void windowDeactivated(java.awt.event.WindowEvent windowEvent)
          This method is called when the window is deactivated.
 void windowDeiconified(java.awt.event.WindowEvent windowEvent)
          This method is called when the window is deiconified.
 void windowIconified(java.awt.event.WindowEvent windowEvent)
          This method is called when the window is iconified.
 void windowOpened(java.awt.event.WindowEvent windowEvent)
          This method is called when the window is made visible.
 
Methods inherited from class javax.swing.JDialog
addImpl, createRootPane, dialogInit, getAccessibleContext, getContentPane, getDefaultCloseOperation, getGlassPane, getJMenuBar, getLayeredPane, getPreferredSize, getRootPane, isDefaultLookAndFeelDecorated, isRootPaneCheckingEnabled, paramString, processWindowEvent, remove, setContentPane, setDefaultCloseOperation, setDefaultLookAndFeelDecorated, setGlassPane, setJMenuBar, setLayeredPane, setLayout, setRootPane, setRootPaneCheckingEnabled, update
 
Methods inherited from class java.awt.Dialog
addNotify, dispose, getTitle, hide, isModal, isResizable, isUndecorated, setModal, setResizable, setTitle, setUndecorated, show
 
Methods inherited from class java.awt.Window
addWindowFocusListener, addWindowListener, addWindowStateListener, applyResourceBundle, applyResourceBundle, createBufferStrategy, createBufferStrategy, getBufferStrategy, getFocusableWindowState, getFocusCycleRootAncestor, getFocusOwner, getGraphicsConfiguration, getListeners, getLocale, getMostRecentFocusOwner, getOwnedWindows, getOwner, getToolkit, getWarningString, getWindowFocusListeners, getWindowListeners, getWindowStateListeners, isActive, isFocusableWindow, isFocusCycleRoot, isFocused, isShowing, pack, postEvent, processEvent, processWindowFocusEvent, processWindowStateEvent, removeWindowFocusListener, removeWindowListener, removeWindowStateListener, setCursor, setFocusableWindowState, setFocusCycleRoot, setLocationRelativeTo, 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, removeNotify, 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, processKeyEvent, processMouseEvent, processMouseMotionEvent, processMouseWheelEvent, remove, 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
 

Field Detail

chordUI

private ChordUI chordUI

chordUIEditable

private ChordUIEditable chordUIEditable

menuBar

private javax.swing.JMenuBar menuBar

fretMenu

private javax.swing.JMenu fretMenu

upMenuItem

private javax.swing.JMenuItem upMenuItem

downMenuItem

private javax.swing.JMenuItem downMenuItem

shiftUpMenuItem

private javax.swing.JMenuItem shiftUpMenuItem

shiftDownMenuItem

private javax.swing.JMenuItem shiftDownMenuItem

emptyButton

private final javax.swing.JButton emptyButton

dotButton

private final javax.swing.JButton dotButton

ixeButton

private final javax.swing.JButton ixeButton

zeroButton

private final javax.swing.JButton zeroButton

squareButton

private final javax.swing.JButton squareButton

barredButton

private final javax.swing.JButton barredButton

buttonPanel

private final javax.swing.JPanel buttonPanel

okButton

private final javax.swing.JButton okButton

pressedColor

private java.awt.Color pressedColor

unPressedColor

private java.awt.Color unPressedColor
Constructor Detail

ChordEditor

public ChordEditor(ChordUI hisChordUI)
Construct and Show the Chord edition dialog.

Method Detail

initializeMenu

private void initializeMenu()

actionPerformed

public void actionPerformed(java.awt.event.ActionEvent actionEvent)
Process the buttons events.

Specified by:
actionPerformed in interface java.awt.event.ActionListener

setState

public void setState(int state)
Permit to other classes to modify the button states


setPressed

private void setPressed(javax.swing.JButton pressed)

setUnPressed

private void setUnPressed(javax.swing.JButton unPressed)

setButtonsState

protected void setButtonsState(javax.swing.JButton pressed)
Manage the button pressed state


keyPressed

public void keyPressed(java.awt.event.KeyEvent keyEvent)
Manage key event.

Specified by:
keyPressed in interface java.awt.event.KeyListener

keyReleased

public void keyReleased(java.awt.event.KeyEvent keyEvent)
Description copied from interface: java.awt.event.KeyListener
This method is called when a key is released.

Specified by:
keyReleased in interface java.awt.event.KeyListener

windowClosing

public void windowClosing(java.awt.event.WindowEvent windowEvent)
Description copied from interface: java.awt.event.WindowListener
This method is called when the user calls the system menu close function, giving the program a chance to cancel the close.

Specified by:
windowClosing in interface java.awt.event.WindowListener

windowActivated

public void windowActivated(java.awt.event.WindowEvent windowEvent)
Description copied from interface: java.awt.event.WindowListener
This method is called when a window is activated. Only Frames and Dialogs can be active, and the active window always contains the component with focus.

Specified by:
windowActivated in interface java.awt.event.WindowListener

windowDeiconified

public void windowDeiconified(java.awt.event.WindowEvent windowEvent)
Description copied from interface: java.awt.event.WindowListener
This method is called when the window is deiconified.

Specified by:
windowDeiconified in interface java.awt.event.WindowListener

windowDeactivated

public void windowDeactivated(java.awt.event.WindowEvent windowEvent)
Description copied from interface: java.awt.event.WindowListener
This method is called when the window is deactivated.

Specified by:
windowDeactivated in interface java.awt.event.WindowListener

windowIconified

public void windowIconified(java.awt.event.WindowEvent windowEvent)
Description copied from interface: java.awt.event.WindowListener
This method is called when the window is iconified.

Specified by:
windowIconified in interface java.awt.event.WindowListener

windowClosed

public void windowClosed(java.awt.event.WindowEvent windowEvent)
Description copied from interface: java.awt.event.WindowListener
This method is called when the window is closed.

Specified by:
windowClosed in interface java.awt.event.WindowListener

windowOpened

public void windowOpened(java.awt.event.WindowEvent windowEvent)
Description copied from interface: java.awt.event.WindowListener
This method is called when the window is made visible.

Specified by:
windowOpened in interface java.awt.event.WindowListener

keyTyped

public void keyTyped(java.awt.event.KeyEvent keyEvent)
Description copied from interface: java.awt.event.KeyListener
This method is called when a key is typed. A key is considered typed when it and all modifiers have been pressed and released, mapping to a single virtual key.

Specified by:
keyTyped in interface java.awt.event.KeyListener