# Class JSPopupHelper

java.lang.Object
org.jmol.awtjs2d.JSPopupHelper

All Implemented Interfaces:
  `PopupHelper`

public class JSPopupHelper extends Object implements PopupHelper
For menus, popup-related awt/swing class references are in this file. We can ignore all the event/listener references because JSmol will create a simple object with just the elements getSource and getActionCommand. No need to have the entire classes fleshed out.

## Constructor Summary

Constructors
Constructor
Description
`JSPopupHelper(GenericPopup popup)`

## Method Summary

Modifier and Type
Method
Description
`void`
`actionPerformed(ActionEvent e)`
`void`
`dispose(SC popupMenu)`
`Object`
`getButtonGroup()`
`SC`
`getCheckBox(String name)`
`int`
`getItemType(SC m)`
`SC`
`getMenu(String name)`
`SC`
`getMenuItem(String text)`
`SC`
`getRadio(String name)`
`SC`
`getSwingComponent(Object component)`
`void`
`handleEvent(MouseEvent e)`
`void`
`itemStateChanged(ItemEvent e)`
`void`
`menuAddButtonGroup(SC item)`
`void`
`menuClearListeners(SC menu)`
`SC`
`menuCreatePopup(String name, Object applet)`
`void`
`menuInsertSubMenu(SC menu, SC subMenu, int index)`
`void`
`mouseEntered(MouseEvent e)`
`void`
`mouseExited(MouseEvent e)`

### Methods inherited from class Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Constructor Details

### JSPopupHelper

public JSPopupHelper(GenericPopup popup)

## Method Details

### menuCreatePopup

public SC menuCreatePopup(String name, Object applet)

Specified by:
  `menuCreatePopup` in interface `PopupHelper`

### getMenu

public SC getMenu(String name)

Specified by:
  `getMenu` in interface `PopupHelper`

### getMenuItem

public SC getMenuItem(String text)

Specified by:
  `getMenuItem` in interface `PopupHelper`

### getRadio

public SC getRadio(String name)

Specified by:
  `getRadio` in interface `PopupHelper`

### getCheckBox

public SC getCheckBox(String name)

Specified by:
  `getCheckBox` in interface `PopupHelper`

### menuAddButtonGroup

public void menuAddButtonGroup(SC item)

Specified by:
  `menuAddButtonGroup` in interface `PopupHelper`

### getItemType

public int getItemType(SC m)

Specified by:
  `getItemType` in interface `PopupHelper`

### menuInsertSubMenu

public void menuInsertSubMenu(SC menu, SC subMenu, int index)

Specified by:
  `menuInsertSubMenu` in interface `PopupHelper`

### getSwingComponent

public SC getSwingComponent(Object component)

Specified by:
  `getSwingComponent` in interface `PopupHelper`

### menuClearListeners

public void menuClearListeners(SC menu)

Specified by:
  `menuClearListeners` in interface `PopupHelper`

### itemStateChanged

public void itemStateChanged(ItemEvent e)

### actionPerformed

public void actionPerformed(ActionEvent e)

### getButtonGroup

public Object getButtonGroup()

Specified by:
  `getButtonGroup` in interface `PopupHelper`

### handleEvent

public void handleEvent(MouseEvent e)

### mouseEntered

public void mouseEntered(MouseEvent e)

### mouseExited

public void mouseExited(MouseEvent e)

### dispose

public void dispose(SC popupMenu)

Specified by:
  `dispose` in interface `PopupHelper`