i3mclient.config
Class AddressPanel

java.lang.Object
  |
  +--org.eclipse.swt.widgets.Widget
        |
        +--org.eclipse.swt.widgets.Control
              |
              +--org.eclipse.swt.widgets.Scrollable
                    |
                    +--org.eclipse.swt.widgets.Composite
                          |
                          +--i3mclient.config.AddressPanel
All Implemented Interfaces:
Drawable, EventListener, ModifyListener, org.eclipse.swt.internal.SWTEventListener, UserDataListener

public class AddressPanel
extends Composite
implements UserDataListener, ModifyListener

The address panel to view and edit user addresses

Author:
Henning Schaefer
See Also:
ConfigGUI, Config

Field Summary
static int EDITMODE
           
static int SEARCHMODE
           
static int VIEWMODE
           
 
Fields inherited from class org.eclipse.swt.widgets.Control
handle
 
Constructor Summary
AddressPanel(Composite parent, int style, int setMode, String setAddressCaption)
          Constructor.
 
Method Summary
 void addFormListener(FormListener listener)
          Add a listener for form changes.
 int getMode()
          Returns the current mode.
 void modifyText(ModifyEvent event)
           
 void removeFormListener(FormListener listener)
          Remove a listener for form changes.
 void setFieldContent(int i, String content)
          Set the content of the specified field.
 void userDataChanged(UserData setUserData)
          Called when user detail changed.
 
Methods inherited from class org.eclipse.swt.widgets.Composite
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, getDisplay, getEnabled, getFont, getForeground, getLayoutData, getLocation, getMenu, getParent, getShell, getSize, getToolTipText, getVisible, internal_dispose_GC, internal_new_GC, isDisposed, 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, dispose, getData, getData, getStyle, notifyListeners, removeDisposeListener, removeListener, setData, setData, toString
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

VIEWMODE

public static final int VIEWMODE
See Also:
Constant Field Values

EDITMODE

public static final int EDITMODE
See Also:
Constant Field Values

SEARCHMODE

public static final int SEARCHMODE
See Also:
Constant Field Values
Constructor Detail

AddressPanel

public AddressPanel(Composite parent,
                    int style,
                    int setMode,
                    String setAddressCaption)
Constructor.

Parameters:
parent - The parent composite of this composite
style - The swt-style of this composite
setMode - VIEWMODE, EDITMODE or SEARCHMODE
setAddressCaption - The caption for the address of this address panel
Method Detail

userDataChanged

public void userDataChanged(UserData setUserData)
Description copied from interface: UserDataListener
Called when user detail changed.

Specified by:
userDataChanged in interface UserDataListener
Parameters:
setUserData - the changed userData

setFieldContent

public void setFieldContent(int i,
                            String content)
Set the content of the specified field.

Parameters:
i - The index of the field to set
content - The new content for the field

getMode

public int getMode()
Returns the current mode.

Returns:
The mode of this address panel

addFormListener

public void addFormListener(FormListener listener)
Add a listener for form changes.

Parameters:
listener - The listener which will be informed about form changes

removeFormListener

public void removeFormListener(FormListener listener)
Remove a listener for form changes.

Parameters:
listener - The listener which will be no longer informed about form changes

modifyText

public void modifyText(ModifyEvent event)
Specified by:
modifyText in interface ModifyListener