Overview

 
Package  Use  Tree  Serialized  Deprecated  Index  Help 
SWT LPEX
v3.0.0
 PREV CLASS   NEXT CLASS FRAMES    NO FRAMES  
SUMMARY: NESTED | FIELD | CONSTR | METHOD DETAIL: FIELD | CONSTR | METHOD


 

com.ibm.lpex.core
Class LpexMultiWindow

java.lang.Object
  extended byorg.eclipse.swt.widgets.Widget
      extended byorg.eclipse.swt.widgets.Control
          extended byorg.eclipse.swt.widgets.Scrollable
              extended byorg.eclipse.swt.widgets.Composite
                  extended byorg.eclipse.swt.custom.SashForm
                      extended bycom.ibm.lpex.core.LpexMultiWindow

All Implemented Interfaces:
org.eclipse.swt.graphics.Drawable


public class LpexMultiWindow
extends org.eclipse.swt.custom.SashForm

The split-window parent of one or more LpexWindows. The windows may be stacked side by side (vertical split orientation, the borders between multiple editing views running vertically), or top to bottom (horizontal split orientation, the borders between multiple views running horizontally). The first window is the leftmost or top window.

See also the splitWindow and splitWindow.orientation editor parameters.


Field Summary
protected  int MAX_WINDOWS
          Maximum number of split windows that can be created.
 
Fields inherited from class org.eclipse.swt.custom.SashForm
SASH_WIDTH
 
Fields inherited from class org.eclipse.swt.widgets.Control
handle
 
Constructor Summary
LpexMultiWindow(org.eclipse.swt.widgets.Composite parent, int style)
          Constructs a new multiwindow.
 
Method Summary
protected  void activeWindowChanged(LpexWindow lpexWindow)
          Notification for a change in the active window.
 void closeWindow(LpexWindow lpexWindow)
          Convenience method to close the specified window and dispose of its associated view, if any.
 LpexWindow getFirstWindow()
          Returns the first window.
 LpexWindow getWindow()
          Returns the window that has the input focus, if any, otherwise the first window.
 LpexWindow[] getWindows()
          Returns an array of the windows currently managed by this multiwindow.
 LpexWindow newWindow(LpexView lpexView, int style)
          Creates a new window for the given document view.
 boolean setFocus()
          Gives this multiwindow the keyboard input focus.
 
Methods inherited from class org.eclipse.swt.custom.SashForm
computeSize, getMaximizedControl, getOrientation, getWeights, layout, setBackground, setForeground, setLayout, setMaximizedControl, setOrientation, setWeights
 
Methods inherited from class org.eclipse.swt.widgets.Composite
checkSubclass, getChildren, getLayout, getTabList, layout, setTabList
 
Methods inherited from class org.eclipse.swt.widgets.Scrollable
computeTrim, getClientArea, getHorizontalBar, getVerticalBar
 
Methods inherited from class org.eclipse.swt.widgets.Control
addControlListener, addFocusListener, addHelpListener, addKeyListener, addMouseListener, addMouseMoveListener, addMouseTrackListener, addPaintListener, addTraverseListener, computeSize, forceFocus, getAccessible, getBackground, getBorderWidth, getBounds, getEnabled, getFont, getForeground, getLayoutData, getLocation, getMenu, getMonitor, getParent, getShell, getSize, getToolTipText, getVisible, internal_dispose_GC, internal_new_GC, isEnabled, isFocusControl, isReparentable, isVisible, moveAbove, moveBelow, pack, pack, redraw, redraw, removeControlListener, removeFocusListener, removeHelpListener, removeKeyListener, removeMouseListener, removeMouseMoveListener, removeMouseTrackListener, removePaintListener, removeTraverseListener, setBounds, setBounds, setCapture, setCursor, setEnabled, setFont, setLayoutData, setLocation, setLocation, setMenu, setParent, setRedraw, setSize, setSize, setToolTipText, setVisible, toControl, toControl, toDisplay, toDisplay, traverse, update
 
Methods inherited from class org.eclipse.swt.widgets.Widget
addDisposeListener, addListener, checkWidget, dispose, getData, getData, getDisplay, getStyle, isDisposed, isListening, notifyListeners, removeDisposeListener, removeListener, removeListener, setData, setData, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

 

Field Detail

 

 

MAX_WINDOWS

protected int MAX_WINDOWS

Maximum number of split windows that can be created.

Constructor Detail

 

 

LpexMultiWindow

public LpexMultiWindow(org.eclipse.swt.widgets.Composite parent,
                       int style)

Constructs a new multiwindow. The new multiwindow created has no LpexWindows. Its initial split orientation is determined by the default.splitWindow.orientation editor parameter. Disposing of this multiwindow will also dispose of its associated views, if any.

Parameters:
parent - parent Composite
style - SWT style flags for the multiwindow Composite
Method Detail

 

 

newWindow

public LpexWindow newWindow(LpexView lpexView,
                            int style)

Creates a new window for the given document view.

A new LpexWindow may not be created in certain circumstances. For example, you cannot create more than a preset number MAX_WINDOWS of split windows to be managed by one multiwindow. In such a case null will be returned.

Parameters:
lpexView - the document view to associate with the new window
style - SWT style flags for the LpexWindow Composite
Returns:
the new LpexWindow created, or
null if a new LpexWindow could not be created


 

 

activeWindowChanged

protected void activeWindowChanged(LpexWindow lpexWindow)

Notification for a change in the active window. The active window is the LpexWindow that either has the input focus, or will otherwise be given the input focus on the next setFocus() call.

Note:  This hook may be replaced with a full-fledged listener in a future release.

Parameters:
lpexWindow - the new active window, or null if none
See Also:
setFocus()


 

 

setFocus

public boolean setFocus()

Gives this multiwindow the keyboard input focus. This method sets the input focus to the window that is, or was, previously active. That is the window that one of its child controls has, or had, input focus last. If none of our windows was active yet, it sets focus to the first window.


 

 

getFirstWindow

public LpexWindow getFirstWindow()

Returns the first window. The first window is the leftmost or top window in the current list of windows.

Returns:
the first window, or
null if no windows are currently managed


 

 

getWindow

public LpexWindow getWindow()

Returns the window that has the input focus, if any, otherwise the first window.

Returns:
the active window, or
null if no windows are currently managed


 

 

getWindows

public LpexWindow[] getWindows()

Returns an array of the windows currently managed by this multiwindow.

Returns:
an array of LpexWindows, or an empty array if no windows are available


 

 

closeWindow

public void closeWindow(LpexWindow lpexWindow)

Convenience method to close the specified window and dispose of its associated view, if any. The next window, if any, or else the first window is then given input focus.

Parameters:
lpexWindow - the window to close and dispose


 

Overview

 
Package  Use  Tree  Serialized  Deprecated  Index  Help 
SWT LPEX
v3.0.0
 PREV CLASS   NEXT CLASS FRAMES    NO FRAMES  
SUMMARY: NESTED | FIELD | CONSTR | METHOD DETAIL: FIELD | CONSTR | METHOD