Package at.ofai.music.match
Class GUI
- java.lang.Object
-
- java.awt.Component
-
- java.awt.Container
-
- java.awt.Window
-
- java.awt.Frame
-
- javax.swing.JFrame
-
- at.ofai.music.match.GUI
-
- All Implemented Interfaces:
- java.awt.event.ActionListener, java.awt.event.KeyListener, java.awt.event.MouseListener, java.awt.event.MouseMotionListener, java.util.EventListener
public class GUI extends javax.swing.JFrame implements java.awt.event.ActionListener, java.awt.event.MouseListener, java.awt.event.MouseMotionListener, java.awt.event.KeyListener
- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class java.awt.Component
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BaselineResizeBehavior, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy
-
Nested classes/interfaces inherited from class java.awt.Container
java.awt.Container.AccessibleAWTContainer
-
-
Field Summary
Fields Modifier and Type Field and Description protected static java.lang.String
ALIGNING
protected AligningAudioPlayer
audioPlayer
static java.awt.Color
BACKGROUND
static java.awt.Color
BACKGROUND2
protected static int
buttonHt
protected static int
buttonWd
static boolean
DEBUG
protected javax.swing.JFileChooser
fileChooser
protected static int
fileNameHeight
static java.awt.Color
FOREGROUND
protected Help
help
static java.awt.Color
HIGHLIGHT
protected static java.lang.String
loadFile
protected static java.lang.String
LOADING
protected at.ofai.music.match.GUI.MarkDisplay
markDisplay
protected static int
maxSlider
protected javax.swing.JLabel
modeLabel
protected int
oldSlider
protected int
oldTime
protected double
oldTimeDouble
protected int
originX
protected int
originY
protected javax.swing.JSlider
playSlider
protected PerformanceMatcher
pm1
protected PerformanceMatcher
pm2
protected static java.lang.String
READY
protected javax.swing.JLabel
readyLabel
protected at.ofai.music.match.ScrollingMatrix
scrollingMatrix
protected at.ofai.music.match.GUI.TimePanel
timePanel
static java.lang.String
title
static java.lang.String
version
protected static int
xSize
protected static int
ySize
-
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
-
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
-
-
Constructor Summary
Constructors Modifier Constructor and Description protected
GUI(PerformanceMatcher p1, PerformanceMatcher p2, at.ofai.music.match.ScrollingMatrix sm, boolean makeVisible)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description void
actionPerformed(java.awt.event.ActionEvent e)
protected void
addButtons()
protected void
addFile(java.lang.String pathName)
protected at.ofai.music.match.GUI.FileNameSelection
addFile(java.lang.String pathName, boolean addToPlayer)
protected void
addFiles(java.lang.String[] files, int index)
protected javax.swing.JLabel
addLabel(java.lang.String text, int x, int y, int wd, int ht, java.awt.Color c)
protected void
addLabels()
protected void
addMarkDisplay()
protected void
addSlider()
protected void
addTimePanel()
void
keyPressed(java.awt.event.KeyEvent e)
void
keyReleased(java.awt.event.KeyEvent e)
void
keyTyped(java.awt.event.KeyEvent e)
protected void
loadFile()
void
mouseClicked(java.awt.event.MouseEvent e)
void
mouseDragged(java.awt.event.MouseEvent e)
void
mouseEntered(java.awt.event.MouseEvent e)
void
mouseExited(java.awt.event.MouseEvent e)
void
mouseMoved(java.awt.event.MouseEvent e)
void
mousePressed(java.awt.event.MouseEvent e)
void
mouseReleased(java.awt.event.MouseEvent e)
protected void
removeFile(at.ofai.music.match.GUI.FileNameSelection b)
protected void
saveWormFile()
protected void
setMode(boolean fromMark)
void
setSlider(double position)
protected void
setStatus(java.lang.String status)
void
setTimer(double time, AudioFile currentFile)
protected void
showHelp()
void
updateMarks()
-
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, getBaseline, getBaselineResizeBehavior, getBounds, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getGraphicsConfiguration, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocation, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isDoubleBuffered, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, 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, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resize, resize, revalidate, setComponentOrientation, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setMaximumSize, setName, setPreferredSize, show, size, toString, transferFocus, transferFocusBackward, transferFocusUpCycle
-
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalPolicy, getInsets, getLayout, getMaximumSize, getMinimumSize, getMousePosition, getPreferredSize, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, print, printComponents, processContainerEvent, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusTraversalKeys, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setFont, transferFocusDownCycle, validate, validateTree
-
Methods inherited from class java.awt.Frame
addNotify, getCursorType, getExtendedState, getFrames, getIconImage, getMaximizedBounds, getMenuBar, getState, getTitle, isResizable, isUndecorated, remove, removeNotify, setBackground, setCursor, setExtendedState, setMaximizedBounds, setMenuBar, setOpacity, setResizable, setShape, setState, setTitle, setUndecorated
-
Methods inherited from class javax.swing.JFrame
addImpl, createRootPane, frameInit, getAccessibleContext, getContentPane, getDefaultCloseOperation, getGlassPane, getGraphics, getJMenuBar, getLayeredPane, getRootPane, getTransferHandler, isDefaultLookAndFeelDecorated, isRootPaneCheckingEnabled, paramString, processWindowEvent, remove, repaint, setContentPane, setDefaultCloseOperation, setDefaultLookAndFeelDecorated, setGlassPane, setIconImage, setJMenuBar, setLayeredPane, setLayout, setRootPane, setRootPaneCheckingEnabled, setTransferHandler, update
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from class java.awt.Window
addPropertyChangeListener, addPropertyChangeListener, addWindowFocusListener, addWindowListener, addWindowStateListener, applyResourceBundle, applyResourceBundle, createBufferStrategy, createBufferStrategy, dispose, getBackground, getBufferStrategy, getFocusableWindowState, getFocusCycleRootAncestor, getFocusOwner, getFocusTraversalKeys, getIconImages, getInputContext, getListeners, getLocale, getModalExclusionType, getMostRecentFocusOwner, getOpacity, getOwnedWindows, getOwner, getOwnerlessWindows, getShape, getToolkit, getType, getWarningString, getWindowFocusListeners, getWindowListeners, getWindows, getWindowStateListeners, hide, isActive, isAlwaysOnTop, isAlwaysOnTopSupported, isAutoRequestFocus, isFocusableWindow, isFocusCycleRoot, isFocused, isLocationByPlatform, isOpaque, isShowing, isValidateRoot, pack, paint, postEvent, processEvent, processWindowFocusEvent, processWindowStateEvent, removeWindowFocusListener, removeWindowListener, removeWindowStateListener, reshape, setAlwaysOnTop, setAutoRequestFocus, setBounds, setBounds, setCursor, setFocusableWindowState, setFocusCycleRoot, setIconImages, setLocation, setLocation, setLocationByPlatform, setLocationRelativeTo, setMinimumSize, setModalExclusionType, setSize, setSize, setType, setVisible, show, toBack, toFront
-
-
-
-
Field Detail
-
ALIGNING
protected static final java.lang.String ALIGNING
- See Also:
- Constant Field Values
-
audioPlayer
protected AligningAudioPlayer audioPlayer
-
BACKGROUND
public static final java.awt.Color BACKGROUND
-
BACKGROUND2
public static final java.awt.Color BACKGROUND2
-
buttonHt
protected static final int buttonHt
- See Also:
- Constant Field Values
-
buttonWd
protected static final int buttonWd
- See Also:
- Constant Field Values
-
DEBUG
public static boolean DEBUG
-
fileChooser
protected javax.swing.JFileChooser fileChooser
-
fileNameHeight
protected static final int fileNameHeight
- See Also:
- Constant Field Values
-
FOREGROUND
public static final java.awt.Color FOREGROUND
-
help
protected Help help
-
HIGHLIGHT
public static final java.awt.Color HIGHLIGHT
-
loadFile
protected static java.lang.String loadFile
-
LOADING
protected static final java.lang.String LOADING
- See Also:
- Constant Field Values
-
markDisplay
protected at.ofai.music.match.GUI.MarkDisplay markDisplay
-
maxSlider
protected static final int maxSlider
- See Also:
- Constant Field Values
-
modeLabel
protected javax.swing.JLabel modeLabel
-
oldSlider
protected int oldSlider
-
oldTime
protected int oldTime
-
oldTimeDouble
protected double oldTimeDouble
-
originX
protected int originX
-
originY
protected int originY
-
playSlider
protected javax.swing.JSlider playSlider
-
pm1
protected PerformanceMatcher pm1
-
pm2
protected PerformanceMatcher pm2
-
READY
protected static final java.lang.String READY
- See Also:
- Constant Field Values
-
readyLabel
protected javax.swing.JLabel readyLabel
-
scrollingMatrix
protected at.ofai.music.match.ScrollingMatrix scrollingMatrix
-
timePanel
protected at.ofai.music.match.GUI.TimePanel timePanel
-
title
public static final java.lang.String title
- See Also:
- Constant Field Values
-
version
public static final java.lang.String version
- See Also:
- Constant Field Values
-
xSize
protected static final int xSize
- See Also:
- Constant Field Values
-
ySize
protected static final int ySize
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
GUI
protected GUI(PerformanceMatcher p1, PerformanceMatcher p2, at.ofai.music.match.ScrollingMatrix sm, boolean makeVisible)
-
-
Method Detail
-
addFiles
protected void addFiles(java.lang.String[] files, int index)
-
addFile
protected void addFile(java.lang.String pathName)
-
addFile
protected at.ofai.music.match.GUI.FileNameSelection addFile(java.lang.String pathName, boolean addToPlayer)
-
removeFile
protected void removeFile(at.ofai.music.match.GUI.FileNameSelection b)
-
addSlider
protected void addSlider()
-
addMarkDisplay
protected void addMarkDisplay()
-
addLabels
protected void addLabels()
-
addLabel
protected javax.swing.JLabel addLabel(java.lang.String text, int x, int y, int wd, int ht, java.awt.Color c)
-
addTimePanel
protected void addTimePanel()
-
addButtons
protected void addButtons()
-
setStatus
protected void setStatus(java.lang.String status)
-
setMode
protected void setMode(boolean fromMark)
-
setTimer
public void setTimer(double time, AudioFile currentFile)
-
setSlider
public void setSlider(double position)
-
updateMarks
public void updateMarks()
-
showHelp
protected void showHelp()
-
loadFile
protected void loadFile()
-
saveWormFile
protected void saveWormFile()
-
actionPerformed
public void actionPerformed(java.awt.event.ActionEvent e)
- Specified by:
actionPerformed
in interfacejava.awt.event.ActionListener
-
mouseMoved
public void mouseMoved(java.awt.event.MouseEvent e)
- Specified by:
mouseMoved
in interfacejava.awt.event.MouseMotionListener
-
mouseDragged
public void mouseDragged(java.awt.event.MouseEvent e)
- Specified by:
mouseDragged
in interfacejava.awt.event.MouseMotionListener
-
mouseEntered
public void mouseEntered(java.awt.event.MouseEvent e)
- Specified by:
mouseEntered
in interfacejava.awt.event.MouseListener
-
mouseExited
public void mouseExited(java.awt.event.MouseEvent e)
- Specified by:
mouseExited
in interfacejava.awt.event.MouseListener
-
mouseClicked
public void mouseClicked(java.awt.event.MouseEvent e)
- Specified by:
mouseClicked
in interfacejava.awt.event.MouseListener
-
mouseReleased
public void mouseReleased(java.awt.event.MouseEvent e)
- Specified by:
mouseReleased
in interfacejava.awt.event.MouseListener
-
mousePressed
public void mousePressed(java.awt.event.MouseEvent e)
- Specified by:
mousePressed
in interfacejava.awt.event.MouseListener
-
keyPressed
public void keyPressed(java.awt.event.KeyEvent e)
- Specified by:
keyPressed
in interfacejava.awt.event.KeyListener
-
keyTyped
public void keyTyped(java.awt.event.KeyEvent e)
- Specified by:
keyTyped
in interfacejava.awt.event.KeyListener
-
keyReleased
public void keyReleased(java.awt.event.KeyEvent e)
- Specified by:
keyReleased
in interfacejava.awt.event.KeyListener
-
-