Mobile Tools for Java
Release 1.0

org.eclipse.mtj.ui.devices
Class DeviceSelector

java.lang.Object
  extended by org.eclipse.mtj.ui.devices.DeviceSelector

public class DeviceSelector
extends Object

A device selector provides user interface functionality for selecting a device from the registry.


Constructor Summary
DeviceSelector()
           
 
Method Summary
 void createContents(Composite parent, boolean includeGroup, boolean includeManageButton)
          Fill in the user interface components into the parent.
 void dispose()
          Dispose as necessary.
 void enableFireSelectionChanged(boolean fireSelectionChangedListener)
           
 String getDeviceGroupComentLabel()
           
 String getDeviceGroupLabel()
           
 IDevice getSelectedDevice()
          Return the device selected by the user or null if the user has not yet selected a device.
 boolean isFireSelectionChangedEnabled()
           
 void setDeviceGroupComentLabel(String deviceGroupComentLabel)
           
 void setDeviceGroupLabel(String deviceGroupLabel)
           
 void setEnabled(boolean enabled)
          Set the controls to the specified state of enablement.
 void setSelectedDevice(IDevice device)
          Select the specified device within the selector if possible.
 void setSelectionChangedListener(ISelectionChangedListener listener)
          Set the listener for changes in the device selection.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DeviceSelector

public DeviceSelector()
Method Detail

createContents

public void createContents(Composite parent,
                           boolean includeGroup,
                           boolean includeManageButton)
Fill in the user interface components into the parent. Specify whether to use a device group box in the layout.

Parameters:
parent -
includeGroup -
includeManageButton - TODO

dispose

public void dispose()
Dispose as necessary.


enableFireSelectionChanged

public void enableFireSelectionChanged(boolean fireSelectionChangedListener)
Parameters:
fireSelectionChangedListener - the fireSelectionChangedListener to set

getDeviceGroupComentLabel

public String getDeviceGroupComentLabel()
Returns:
the deviceGroupComentLabel

getDeviceGroupLabel

public String getDeviceGroupLabel()
Returns:
the deviceGroupLabel

getSelectedDevice

public IDevice getSelectedDevice()
Return the device selected by the user or null if the user has not yet selected a device.

Returns:

isFireSelectionChangedEnabled

public boolean isFireSelectionChangedEnabled()
Returns:
the fireSelectionChangedListener

setDeviceGroupComentLabel

public void setDeviceGroupComentLabel(String deviceGroupComentLabel)
Parameters:
deviceGroupComentLabel - the deviceGroupComentLabel to set

setDeviceGroupLabel

public void setDeviceGroupLabel(String deviceGroupLabel)
Parameters:
deviceGroupLabel - the deviceGroupLabel to set

setEnabled

public void setEnabled(boolean enabled)
Set the controls to the specified state of enablement.

Parameters:
enabled -

setSelectedDevice

public void setSelectedDevice(IDevice device)
Select the specified device within the selector if possible. This method is not guaranteed to make a valid selection depending on the state of the device registry.

Parameters:
device -

setSelectionChangedListener

public void setSelectionChangedListener(ISelectionChangedListener listener)
Set the listener for changes in the device selection.

Parameters:
listener -

Mobile Tools for Java
Release 1.0