marimba.gui
Class PopupWidget

java.lang.Object
  |
  +--marimba.gui.Widget
        |
        +--marimba.gui.ContainerWidget
              |
              +--marimba.gui.GroupWidget
                    |
                    +--marimba.gui.PopupWidget
All Implemented Interfaces:
java.awt.image.ImageObserver, PropertyObject, TimerClient, WidgetConstants
Direct Known Subclasses:
ColorPaletteWidget, PopupMenu, Tip

public class PopupWidget
extends GroupWidget

This class represents a widget that can be temporarily shown on top of everything else.

Version:
1.26, 12/17/97
Author:
Arthur van Hoff

Field Summary
protected  PlayerPanel player
          The PlayerPanel in which this widget is embedded.
 
Fields inherited from class marimba.gui.GroupWidget
editing, fillMode, fillOptions, lineMode, lineOptions, patsrc, pattern, prevtx, prevty
 
Fields inherited from class marimba.gui.ContainerWidget
content
 
Fields inherited from class marimba.gui.Widget
adapter, background, clazz, defaultBackground, defaultFont, defaultForeground, defaultHilite, directGraphics, disabled, east, editor, focus, font, foreground, height, hilite, layoutMgr, name, north, nwidgets, parent, script, south, tip, transparent, tx, ty, valid, visible, wBackground, west, wFont, wForeground, wHilite, widgets, width, wScript, wTip, x, y
 
Fields inherited from interface marimba.gui.WidgetConstants
ALWAYS, ANYWHERE, APPLET, ASCENDING, BLINK, BLUE, BONGO_EVENT, BOTH, BOTTOM, BOXED, BUTTON, CENTER, CHAR, CHECK, COLLAPSE_EVENT, CONTENT, DESCENDING, DETACHED, DIAGONAL, DOWN, DRAG, EXCLUSIVE, EXPAND_EVENT, FILL, FILLED, GREEN, HORIZONTAL, INSIDE, INVISIBLE, JAVA_VERSION, JAVAOS, JDK10, JDK11, LAYERS, LEFT, LOWERED, MAC, MULTIPLE, NETCASTER, NETSCAPE, NEVER, NONE, NT, OPTIONAL, OS_ARCH, OS_NAME, OS_VERSION, OUTLINE, PAGE_DOWN, PAGE_EVENT, PAGE_UP, PATTERN, PC, PICTURE, PLAIN, PROPORTIONAL, RADIO, RAISED, RED, REST_EVENT, RIGHT, ROUNDED, SCALE, SCROLLBAR, SCROLLING, SOLID, SQUARE, TEXT_CHANGED_EVENT, TOP, TOPLEFT, TRUNCATE, UNDERLINE, UNIX, UP, VERTICAL, WAKE_EVENT, WIN95, WINDOWS, WORD
 
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
 
Constructor Summary
PopupWidget()
          Create a popup.
 
Method Summary
 void fit()
          Fit the menu in the visible area of the parent window.
 PlayerPanel getPlayerPanel()
          Get the player.
 boolean isShowing()
          True if the player is set.
 void paramString(java.lang.StringBuffer buf)
          For debugging only.
 void popdown()
          Hide the PopupWidget.
 void popup(Widget parent, int x, int y)
          Show the Popup Widget.
 void popup(Widget parent, int x, int y, int width, int height)
          Show the Popup Widget.
 boolean postEvent(java.awt.Event evt)
          Post an event to this widget.
 void repaint(long tm, int x, int y, int width, int height)
          This will repaint part of the screen.
protected  void repaint(long tm, Widget w, Widget c, int x, int y, int width, int height)
          Repaint a specific widget.
 void repaintParent(long tm, int x, int y, int width, int height)
          This will repaint part of the screen.
 void replace(Widget newWidget)
          Replace the widget with a newer version.
 
Methods inherited from class marimba.gui.GroupWidget
getEditing, getEditor, getFillMode, getFillOptions, getLineMode, getLineOptions, getPattern, getPatternSource, getProperties, init, paint, setEditing, setFillMode, setLineMode, setPattern, setProperties, update, updateArea, waitForPattern
 
Methods inherited from class marimba.gui.ContainerWidget
findInFocus, findWidget, firstInFocus, getChildProperties, getContent, getPreferredSize, layout, newContent, nextInFocus, previousInFocus
 
Methods inherited from class marimba.gui.Widget
action, action, add, add, adjustFont, adjustFont, applyProperties, audioLoop, audioLoop, audioPlay, audioPlay, audioStop, audioStop, bounds, clearFocus, clearPopups, clone, contains, contains, createImage, createImage, currentFocus, destroy, disable, disable, enable, firstFocus, focusInterest, getAudioClip, getAudioClipAt, getBackground, getBounds, getCancelButton, getCursor, getDefaultButton, getDescription, getEncoding, getFocusColor, getFont, getFontMetrics, getForeground, getHilite, getImage, getKey, getKey, getKey, getLayoutMgr, getLocale, getLocation, getName, getParent, getPlayerFrame, getPresentation, getSelBackground, getSelFocusColor, getSelForeground, getSize, getText, getText, getTip, getTip, getTipFont, getValue, getValue, getWidget, getWidgetAt, getWidgetAt, getWidgetClass, getWidgetsAt, getWidgetsAt, getWidgetsAt, gotFocus, gotoPage, gotoPage, handleEvent, hasFocus, hide, imageUpdate, inheritFont, inside, inside, invalidate, isDisabled, isTransparent, isVisible, keyDown, keyUp, list, list, locateWidget, locateWidgets, locateWidgets, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, overlap, paint, paintAll, previousFocus, remove, remove, remove, removeAll, repaint, repaint, repaint, replace, replace, requestFocus, resetCursor, reshape, reshape, resize, resize, rmove, rscroll, scroll, setAttach, setBackground, setBounds, setBounds, setCursor, setDisabled, setEditor, setEncoding, setFont, setForeground, setHilite, setLayoutMgr, setLocale, setLocation, setName, setSize, setSize, setText, setText, setTip, setTipFont, setTransparent, setValue, setValue, setVisible, show, show, size, start, stop, sync, tick, toBack, toBack, toFront, toFront, toString, validate
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

player

protected PlayerPanel player
The PlayerPanel in which this widget is embedded.
Constructor Detail

PopupWidget

public PopupWidget()
Create a popup. This does not show it.
Method Detail

isShowing

public boolean isShowing()
True if the player is set.
Overrides:
isShowing in class Widget
Following copied from class: marimba.gui.Widget
See Also:
Widget.setVisible(boolean)

getPlayerPanel

public PlayerPanel getPlayerPanel()
Get the player.
Overrides:
getPlayerPanel in class Widget
Following copied from class: marimba.gui.Widget
Returns:
null, if no PlayerPanel was found
See Also:
#getFrame , Widget.getPresentation()

repaintParent

public void repaintParent(long tm,
                          int x,
                          int y,
                          int width,
                          int height)
This will repaint part of the screen.
Overrides:
repaintParent in class Widget

repaint

public void repaint(long tm,
                    int x,
                    int y,
                    int width,
                    int height)
This will repaint part of the screen.
Overrides:
repaint in class Widget

repaint

protected void repaint(long tm,
                       Widget w,
                       Widget c,
                       int x,
                       int y,
                       int width,
                       int height)
Repaint a specific widget.

replace

public void replace(Widget newWidget)
Replace the widget with a newer version. This means installing a new version in the player when appropriate.
Overrides:
replace in class Widget
Following copied from class: marimba.gui.Widget
Parameters:
newWidget - the widget that will replace this widget in the parent

popup

public void popup(Widget parent,
                  int x,
                  int y)
Show the Popup Widget.

popup

public void popup(Widget parent,
                  int x,
                  int y,
                  int width,
                  int height)
Show the Popup Widget.

fit

public void fit()
Fit the menu in the visible area of the parent window.

popdown

public void popdown()
Hide the PopupWidget.

postEvent

public boolean postEvent(java.awt.Event evt)
Post an event to this widget. If the widget does not handle the event, it is passed to the parent.
Overrides:
postEvent in class Widget
Following copied from class: marimba.gui.Widget
Parameters:
evt - the event that needs to be posted to this widget
See Also:
Widget.handleEvent(java.awt.Event)

paramString

public void paramString(java.lang.StringBuffer buf)
For debugging only.
Overrides:
paramString in class GroupWidget
Following copied from class: marimba.gui.Widget
See Also:
Widget.toString()