com.tensegrity.gui.swt.control.panels
Class FormatPanel

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 bycom.tensegrity.gui.swt.control.panels.FormatPanel
All Implemented Interfaces:
org.eclipse.swt.graphics.Drawable
Direct Known Subclasses:
PaintFormatPanel, StrokeFormatPanel

public abstract class FormatPanel
extends org.eclipse.swt.widgets.Composite

This abstract class simply covers the event handling of any FormatPanels. Furthermore it requires that the widgetDisposed(DisposeEvent) method is implemented by any deriving class. This is done to force extending classes to release their occupied resources.

Each registered listeners will be notified on a format value change.

Simply extend this class and implement the abstract method widgetDisposed(DisposeEvent)

Version:
$Id: FormatPanel.java,v 1.3 2005/03/21 11:54:51 ArndHouben Exp $
Author:
Arnd Houben

Field Summary
protected  UIManager uiManager
          reference to the globaly used UIManager for internationalization
 
Fields inherited from class org.eclipse.swt.widgets.Control
handle
 
Constructor Summary
FormatPanel(org.eclipse.swt.widgets.Composite parent, int style, UIManager uiManager)
          Constructor which requires a UIManager instance
 
Method Summary
 void addFormatChangedListener(FormatChangedListener l)
          Adds the specified FormatChangedListener to the list of all listeners
protected  void notifyListeners(FormatChangedEvent event)
          Notifies all registered listeners of a format change
 void removeFormatChangedListener(FormatChangedListener l)
          Removes the specified FormatChangedListener from the list of all listeners
abstract  void widgetDisposed(org.eclipse.swt.events.DisposeEvent de)
          Gets called when this panel is disposed.
 
Methods inherited from class org.eclipse.swt.widgets.Composite
checkSubclass, computeSize, getChildren, getLayout, getTabList, layout, layout, setFocus, setLayout, 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, setBackground, setBounds, setBounds, setCapture, setCursor, setEnabled, setFont, setForeground, 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

uiManager

protected final UIManager uiManager
reference to the globaly used UIManager for internationalization

Constructor Detail

FormatPanel

public FormatPanel(org.eclipse.swt.widgets.Composite parent,
                   int style,
                   UIManager uiManager)
Constructor which requires a UIManager instance

Parameters:
parent - the Composite to add this FormatPanel to
style - the style bits of this composite
uiManager - the UIManager to use
Method Detail

widgetDisposed

public abstract void widgetDisposed(org.eclipse.swt.events.DisposeEvent de)
Gets called when this panel is disposed. Implementing classes should free their resources here.

Parameters:
de - the DisposedEvent

addFormatChangedListener

public final void addFormatChangedListener(FormatChangedListener l)
Adds the specified FormatChangedListener to the list of all listeners

Parameters:
l - an arbitrary FormatChangedListener

removeFormatChangedListener

public final void removeFormatChangedListener(FormatChangedListener l)
Removes the specified FormatChangedListener from the list of all listeners

Parameters:
l - a FormatChangedListener

notifyListeners

protected final void notifyListeners(FormatChangedEvent event)
Notifies all registered listeners of a format change

Parameters:
event - a FormatChangedEvent with additional informations


Copyright © 2005 Tensegrity Software GmbH. All Rights Reserved. Date of creation: 09.06.2006.