Main Page | Packages | Class Hierarchy | Class List | Directories | File List | Class Members | Related Pages

pkgMcj.MenuBar Class Reference

Collaboration diagram for pkgMcj.MenuBar:

Collaboration graph
[legend]
List of all members.

Detailed Description

Definition at line 20 of file MenuBar.java.

Public Member Functions

 MenuBar (Mcj parent)
void redraw ()
void setColors (int color1, int color2)
boolean checkKey (boolean flag, int keyItem)


Constructor & Destructor Documentation

pkgMcj.MenuBar.MenuBar Mcj  parent  ) 
 

Constructs a menubar, sets it's position, and color

param y ..row position param x ..column position param numCols .. param color1 .. param color2 ..

Definition at line 50 of file MenuBar.java.

References pkgView.ScreenKit.PAIR_BLACK_CYAN, pkgView.ScreenKit.PAIR_WHITE_BLACK, pkgView.TextItem.setAttribute(), pkgView.TextItem.setColors(), pkgView.TextItem.setPosition(), pkgView.TextItem.setSelected(), pkgView.TextItem.setText(), and pkgView.ScreenKit.SK_BOLD.


Member Function Documentation

void pkgMcj.MenuBar.redraw  ) 
 

redraw the menubar and its menuitems

Definition at line 83 of file MenuBar.java.

References pkgMcj.DropMenu.redraw(), pkgView.TextItem.redraw(), pkgView.ScreenKit.ttyDrawHline(), pkgView.ScreenKit.ttyRefresh(), pkgMcj.RowCol.xPos, and pkgMcj.RowCol.yPos.

Referenced by pkgMcj.MenuBar.checkKey(), and pkgMcj.Mcj.Mcj().

void pkgMcj.MenuBar.setColors int  color1,
int  color2
 

set/change default color and active color. Only the default color is applied to the menubar. Both colors are needed for the menu items.

Parameters:
color1 .. default color
color2 .. highlighted color

Definition at line 129 of file MenuBar.java.

boolean pkgMcj.MenuBar.checkKey boolean  flag,
int  keyItem
 

updates the widget according to keyboard item and system mode.

Parameters:
flag ..
keyItem .. key was pressed
Returns:
true .. if key was handled here

Definition at line 141 of file MenuBar.java.

References pkgView.Keyboard.KEY_ESC, pkgView.Keyboard.KEY_F9, pkgView.Keyboard.KEY_NEWMODE, pkgMcj.MenuBar.redraw(), pkgMcj.Mcj.setState(), pkgMcj.Mcj.STATE_2PL, pkgMcj.Mcj.STATE_NULL, and pkgMcj.Mcj.STATE_PULDN.


The documentation for this class was generated from the following file:
SourceForge.net Logo