Static Public Member Functions | |
static void | setFrameType (int frameType) |
static Mode | openInMode (TopComponent component, String modeName) |
static Mode | openInMode (Workspace workspace, TopComponent component, String modeName) |
static Mode | openInMode (TopComponent component, String modeName, int frameType) |
static Mode | openInMode (Workspace workspace, TopComponent component, String modeName, int frameType) |
static void | setPersistMode (TopComponent comp, int option) |
static int | getPersistMode (TopComponent comp) |
static void | frameResidesInDesktop (Mode mode) |
static void | frameResidesInDesktop (Mode mode, int frameType) |
static TopComponent | findTopComponent (String componentName) |
static TopComponent | findTopComponent (Workspace workspace, String componentName) |
static Workspace | createWorkspace (String codeName, String displayName) |
Static Public Attributes | |
static final int | INTERNAL_FRAME = 0 |
static final int | TOP_FRAME = 1 |
static final int | DESKTOP_FRAME = 2 |
static final int | PERSIST_ONLY_OPENED = 1 |
static final int | PERSIST_NEVER = 0 |
static final int | PERSIST_ALWAYS = 2 |
static final int | PERSIST_UNKNOWN = -1 |
Provides utility methods for windowing in NetBeans.
static Workspace cern.gp.windows.WindowUtils.createWorkspace | ( | String | codeName, | |
String | displayName | |||
) | [static] |
Utility method: creates a workspace and adds it to the WindowManager's list of workspaces. The new workspace will appear as the last one in the list.
codeName | the code name of the new workspace | |
displayName | the display name of the new workspace |
static TopComponent cern.gp.windows.WindowUtils.findTopComponent | ( | Workspace | workspace, | |
String | componentName | |||
) | [static] |
Utility method: Returns the TopComponent with the given programmatic name in the given workspace, or null
if there is no such TopComponent.
workspace | the workspace in which to look for the TopComponent | |
componentName | the programmatic name of the TopComponent |
null
if there is no such TopComponent static TopComponent cern.gp.windows.WindowUtils.findTopComponent | ( | String | componentName | ) | [static] |
Utility method: Returns the TopComponent with the given programmatic name in the current workspace, or null
if there is no such TopComponent.
componentName | the programmatic name of the TopComponent |
null
if there is no such TopComponent static void cern.gp.windows.WindowUtils.frameResidesInDesktop | ( | Mode | mode | ) | [static] |
Utility method: makes the given mode reside in the desktop instead of as a separate window.
mode | the mode to make reside in the desktop |
Referenced by cern.gp.windows.WindowUtils.openInMode().
static void cern.gp.windows.WindowUtils.frameResidesInDesktop | ( | Mode | mode, | |
int | frameType | |||
) | [static] |
Utility method: makes the given mode either reside in the desktop or display a separate window.
mode | the mode to make reside in the desktop | |
frameType | indicates the type of frame, MDI or SDI |
References cern.gp.windows.WindowUtils.DESKTOP_FRAME, and cern.gp.windows.WindowUtils.INTERNAL_FRAME.
static int cern.gp.windows.WindowUtils.getPersistMode | ( | TopComponent | comp | ) | [static] |
Get the persistence mode of the given TopComponent
comp | the component |
References cern.gp.windows.WindowUtils.PERSIST_ALWAYS, cern.gp.windows.WindowUtils.PERSIST_NEVER, cern.gp.windows.WindowUtils.PERSIST_ONLY_OPENED, and cern.gp.windows.WindowUtils.PERSIST_UNKNOWN.
static Mode cern.gp.windows.WindowUtils.openInMode | ( | Workspace | workspace, | |
TopComponent | component, | |||
String | modeName | |||
) | [static] |
Utility method: opens a topcomponent in the given workspace in a mode with the indicated name. This method first looks if the mode already exists, or else creates it. Opens the topcomponent in the desktop.
workspace | the workspace top open the component in | |
component | the component to open | |
modeName | the (code) name of the mode |
References cern.gp.windows.WindowUtils.openInMode().
static Mode cern.gp.windows.WindowUtils.openInMode | ( | TopComponent | component, | |
String | modeName, | |||
int | frameType | |||
) | [static] |
Utility method: opens a topcomponent in the current workspace in a mode with the indicated name. This method first looks if the mode already exists, or else creates it
component | the component to open | |
modeName | the (code) name of the mode | |
frameType | indicates the type of the window frame, should be one of INTERNAL_FRAME, TOP_FRAME, or DESKTOP_FRAME |
References cern.gp.windows.WindowUtils.openInMode().
static Mode cern.gp.windows.WindowUtils.openInMode | ( | Workspace | workspace, | |
TopComponent | component, | |||
String | modeName, | |||
int | frameType | |||
) | [static] |
Utility method: opens a topcomponent in the given workspace in a mode with the indicated name. This method first looks if the mode already exists, or else creates it.
workspace | the workspace top open the component in | |
component | the component to open | |
modeName | the (code) name of the mode | |
frameType | indicates the type of the window frame, should be one of INTERNAL_FRAME, TOP_FRAME, or DESKTOP_FRAME |
References cern.gp.windows.WindowUtils.frameResidesInDesktop(), org.openide.windows.TopComponent.open(), cern.gp.windows.WindowUtils.PERSIST_NEVER, org.openide.windows.TopComponent.requestFocus(), and cern.gp.windows.WindowUtils.setPersistMode().
static Mode cern.gp.windows.WindowUtils.openInMode | ( | TopComponent | component, | |
String | modeName | |||
) | [static] |
Utility method: opens a topcomponent in the current workspace in a mode with the indicated name. This method first looks if the mode already exists, or else creates it. Opens the topcomponent in the desktop.
component | the component to open | |
modeName | the (code) name of the mode |
Referenced by cern.gp.windows.WindowUtils.openInMode().
static void cern.gp.windows.WindowUtils.setFrameType | ( | int | frameType | ) | [static] |
Utility method: Sets the default windowing behavior, MDI or SDI. If set to true
the default behavior for new windows is to reside in the desktop.
type | indicates that the default windowing behavior, should be one of INTERNAL_FRAME, TOP_FRAME, or DESKTOP_FRAME |
static void cern.gp.windows.WindowUtils.setPersistMode | ( | TopComponent | comp, | |
int | option | |||
) | [static] |
Determine under which conditions the TopComponent is persisted to the NetBeans system directory
comp | the component | |
option | one of PERSIST_NEVER or PERSIST_ONLY_OPENED |
References cern.gp.windows.WindowUtils.PERSIST_ALWAYS, cern.gp.windows.WindowUtils.PERSIST_NEVER, and cern.gp.windows.WindowUtils.PERSIST_ONLY_OPENED.
Referenced by cern.gp.windows.WindowUtils.openInMode().
final int cern.gp.windows.WindowUtils.DESKTOP_FRAME = 2 [static] |
The frame resides docked left, right, top, or bottom
Referenced by cern.gp.windows.WindowUtils.frameResidesInDesktop().
final int cern.gp.windows.WindowUtils.INTERNAL_FRAME = 0 [static] |
A frame that resides in the desktop
Referenced by cern.gp.windows.WindowUtils.frameResidesInDesktop().
final int cern.gp.windows.WindowUtils.PERSIST_ALWAYS = 2 [static] |
always persist the TopComponent
Referenced by cern.gp.windows.WindowUtils.getPersistMode(), and cern.gp.windows.WindowUtils.setPersistMode().
final int cern.gp.windows.WindowUtils.PERSIST_NEVER = 0 [static] |
dont persist the TopComponent
Referenced by cern.gp.windows.WindowUtils.getPersistMode(), cern.gp.windows.WindowUtils.openInMode(), and cern.gp.windows.WindowUtils.setPersistMode().
final int cern.gp.windows.WindowUtils.PERSIST_ONLY_OPENED = 1 [static] |
persist a TopComponent only if it is opened
Referenced by cern.gp.windows.WindowUtils.getPersistMode(), and cern.gp.windows.WindowUtils.setPersistMode().
final int cern.gp.windows.WindowUtils.PERSIST_UNKNOWN = -1 [static] |
unkown persistence mode the TopComponent
Referenced by cern.gp.windows.WindowUtils.getPersistMode().
final int cern.gp.windows.WindowUtils.TOP_FRAME = 1 [static] |
A frame that resides as a separate window