artisynth.core.driver
Class MenuBarHandler

java.lang.Object
  extended by artisynth.core.driver.MenuBarHandler
All Implemented Interfaces:
SchedulerListener, java.awt.event.ActionListener, java.util.EventListener, GLViewerListener, ValueChangeListener

public class MenuBarHandler
extends java.lang.Object
implements java.awt.event.ActionListener, ValueChangeListener, SchedulerListener, GLViewerListener

to create a class that handles the main menu interactions responds to the events and calls appropriate functions to deal with the events


Field Summary
static int MAX_MENU_ROWS
           
 
Constructor Summary
MenuBarHandler(Main parent, MainFrame theFrame)
           
 
Method Summary
 void actionPerformed(java.awt.event.ActionEvent event)
          action performed to process all the menu and button actions in this class
 void attachModeSelectionToolbar(javax.swing.JPanel panel)
           
 void attachToolbar()
           
 void attachViewerToolbar(javax.swing.JPanel panel)
          author: andreio create a camera toolbar to control the view of the camera on the GlViewer
 void createMenus()
          creates menu items
 void detachToolbar()
           
 void detachViewerToolbar(javax.swing.JPanel panel)
           
 void disableShowPlay()
           
 void enableShowPlay()
           
 GLViewer getMainViewer()
           
 void initToolbar()
           
 void renderOccurred(GLViewerEvent e)
          A render occurred on the viewer.
 void runScript(java.lang.String scriptName)
           
 void schedulerActionPerformed(Scheduler.Action action)
           
 void setBackgroundColor()
           
 void setTimelineVisible(boolean visible)
           
 void updateWidgets()
           
 void valueChange(ValueChangeEvent e)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

MAX_MENU_ROWS

public static final int MAX_MENU_ROWS
See Also:
Constant Field Values
Constructor Detail

MenuBarHandler

public MenuBarHandler(Main parent,
                      MainFrame theFrame)
Method Detail

initToolbar

public void initToolbar()

createMenus

public void createMenus()
creates menu items


valueChange

public void valueChange(ValueChangeEvent e)
Specified by:
valueChange in interface ValueChangeListener

actionPerformed

public void actionPerformed(java.awt.event.ActionEvent event)
action performed to process all the menu and button actions in this class

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

runScript

public void runScript(java.lang.String scriptName)

enableShowPlay

public void enableShowPlay()

disableShowPlay

public void disableShowPlay()

detachToolbar

public void detachToolbar()

attachToolbar

public void attachToolbar()

attachModeSelectionToolbar

public void attachModeSelectionToolbar(javax.swing.JPanel panel)

attachViewerToolbar

public void attachViewerToolbar(javax.swing.JPanel panel)
author: andreio create a camera toolbar to control the view of the camera on the GlViewer


detachViewerToolbar

public void detachViewerToolbar(javax.swing.JPanel panel)

getMainViewer

public GLViewer getMainViewer()

setBackgroundColor

public void setBackgroundColor()

updateWidgets

public void updateWidgets()

setTimelineVisible

public void setTimelineVisible(boolean visible)

schedulerActionPerformed

public void schedulerActionPerformed(Scheduler.Action action)
Specified by:
schedulerActionPerformed in interface SchedulerListener

renderOccurred

public void renderOccurred(GLViewerEvent e)
Description copied from interface: GLViewerListener
A render occurred on the viewer.

Specified by:
renderOccurred in interface GLViewerListener