public class PhantomMenu extends Object
| Modifier and Type | Field and Description |
|---|---|
static int |
FLAG_ALWAYSUPDATE
Always update the text.
|
static int |
FLAG_DISABLE
Disable from start.
|
static int |
FLAG_NODISABLE
Don't disable for host field.
|
static int |
FLAG_TEXTIDSTRING
Text ID string
|
int |
index
The index of this menu.
|
PhantomMenuItem[] |
menuItems
The menu items.
|
PhantomPanelData |
panelData
The panel data.
|
String |
text
The text of the menu.
|
String |
tooltipText
The tool-tip text connected to the menu item.
|
| Constructor and Description |
|---|
PhantomMenu(PhantomPanelData panelData,
int index,
PhantomFile file)
Loads the menu definition from the Phantom Panel file.
|
PhantomMenu(PhantomPanelData panelData,
int index,
PhantomMenuItem[] menuItems,
String text)
Creates a menu for Gui-on-the-fly.
|
| Modifier and Type | Method and Description |
|---|---|
PhantomMenuItem[] |
getMenuItems()
Gets menu items for this menu, returns MenuItems[]
|
int |
getSaveSize()
Calculates the size of the object when saved to file.
|
void |
reloadObject()
Reloads objects for the menu items.
|
void |
resolveComponentReferences()
Resolves references of all menu items to other panel components,
after the panel has been loaded.
|
void |
save(PhantomOutputFile file)
Saves the menu definition from the Phantom Panel file.
|
public static final int FLAG_NODISABLE
public static final int FLAG_ALWAYSUPDATE
public static final int FLAG_DISABLE
public static final int FLAG_TEXTIDSTRING
public String text
public PhantomMenuItem[] menuItems
public PhantomPanelData panelData
public int index
public String tooltipText
public PhantomMenu(PhantomPanelData panelData, int index, PhantomFile file) throws IOException
This routine also corrects the data from the Phantom Panel file that existed in Phantom Hurricane for OS/2 versions 2.xx (the sub-menu count).
Base: + Text BYTE [32] + Count of menu items USHORT + Reserved BYTE [16]
IOException - if an I/O error occurs.public PhantomMenu(PhantomPanelData panelData, int index, PhantomMenuItem[] menuItems, String text)
public void save(PhantomOutputFile file) throws IOException
Base: + Text BYTE [32] + Count of menu items USHORT + Reserved BYTE [16]
file - the open file to write the dfinition to.IOException - if an I/O error occurs.public int getSaveSize()
public void reloadObject()
throws IOException
IOExceptionpublic void resolveComponentReferences()
public PhantomMenuItem[] getMenuItems()
Phantom® and NetPhantom® are registered trademarks of Nexum Technologies SARL.
© Copyright Nexum Technologies SARL, 2011. All rights reserved.