|
PTP Release 7.0 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.eclipse.swt.widgets.Widget
org.eclipse.swt.widgets.Control
org.eclipse.swt.widgets.Scrollable
org.eclipse.swt.widgets.Composite
org.eclipse.ptp.remote.ui.widgets.RemoteConnectionWidget
public class RemoteConnectionWidget
Widget to allow the user to select a service provider and connection. Provides a "New" button to create a new connection. If title is supplied then the widget will be placed in a group.
| Nested Class Summary | |
|---|---|
protected class |
RemoteConnectionWidget.WidgetListener
Listener for widget selected events. |
| Field Summary | |
|---|---|
static int |
FLAG_FORCE_PROVIDER_SELECTION
Force the use of a remote provider dialog, regardless of the PRE_REMOTE_SERVICES_ID preference setting. |
static int |
FLAG_NO_LOCAL_SELECTION
Do not provide a selection for local services. |
| Fields inherited from class org.eclipse.swt.widgets.Control |
|---|
view |
| Constructor Summary | |
|---|---|
RemoteConnectionWidget(org.eclipse.swt.widgets.Composite parent,
int style,
java.lang.String title,
int flags,
org.eclipse.jface.operation.IRunnableContext context)
Constructor |
|
| Method Summary | |
|---|---|
void |
addSelectionListener(org.eclipse.swt.events.SelectionListener listener)
Adds the listener to the collection of listeners who will be notified when the user changes the receiver's selection, by sending it one of the messages defined in the SelectionListener interface. |
org.eclipse.swt.widgets.Button |
getButton()
Get the new button from the widget |
IRemoteConnection |
getConnection()
Get the connection that is currently selected in the widget, or null if there is no selected connection. |
protected IRemoteConnectionManager |
getRemoteConnectionManager(IRemoteServices services)
|
protected IRemoteServices |
getRemoteServices(java.lang.String id)
|
protected void |
handleConnectionSelected()
Handle the section of a new connection. |
protected void |
handleNewRemoteConnectionSelected()
Handle creation of a new connection by pressing the 'New...' button. |
protected void |
handleRemoteServiceSelected(IRemoteConnection conn)
Handle selection of a new remote services provider from the remote services combo. |
protected void |
initializeRemoteServicesCombo(java.lang.String id)
Initialize the contents of the remote services combo. |
boolean |
isEnabled()
|
void |
removeSelectionListener(org.eclipse.swt.events.SelectionListener listener)
Remove a listener that will be notified when one of the widget's controls are selected |
void |
setConnection(IRemoteConnection connection)
Set the connection that should be selected in the widget. |
void |
setConnection(java.lang.String id,
java.lang.String name)
Set the connection that should be selected in the widget. |
void |
setEnabled(boolean enabled)
|
void |
setHints(java.lang.String[] attrHints,
java.lang.String[] attrHintValues)
Set hints to use when creating a new connection. |
| Methods inherited from class org.eclipse.swt.widgets.Composite |
|---|
changed, checkSubclass, computeSize, drawBackground, getBackgroundMode, getChildren, getLayout, getLayoutDeferred, getTabList, isLayoutDeferred, layout, layout, layout, layout, layout, setBackgroundMode, setFocus, setLayout, setLayoutDeferred, setTabList |
| Methods inherited from class org.eclipse.swt.widgets.Scrollable |
|---|
computeTrim, getClientArea, getHorizontalBar, getScrollbarsMode, getVerticalBar |
| Methods inherited from class org.eclipse.swt.widgets.Control |
|---|
addControlListener, addDragDetectListener, addFocusListener, addGestureListener, addHelpListener, addKeyListener, addMenuDetectListener, addMouseListener, addMouseMoveListener, addMouseTrackListener, addMouseWheelListener, addPaintListener, addTouchListener, addTraverseListener, computeSize, dragDetect, dragDetect, forceFocus, getAccessible, getBackground, getBackgroundImage, getBorderWidth, getBounds, getCursor, getDragDetect, getEnabled, getFont, getForeground, getLayoutData, getLocation, getMenu, getMonitor, getOrientation, getParent, getRegion, getShell, getSize, getTextDirection, getToolTipText, getTouchEnabled, getVisible, internal_dispose_GC, internal_new_GC, isFocusControl, isReparentable, isVisible, moveAbove, moveBelow, pack, pack, print, redraw, redraw, removeControlListener, removeDragDetectListener, removeFocusListener, removeGestureListener, removeHelpListener, removeKeyListener, removeMenuDetectListener, removeMouseListener, removeMouseMoveListener, removeMouseTrackListener, removeMouseWheelListener, removePaintListener, removeTouchListener, removeTraverseListener, setBackground, setBackgroundImage, setBounds, setBounds, setCapture, setCursor, setDragDetect, setFont, setForeground, setLayoutData, setLocation, setLocation, setMenu, setOrientation, setParent, setRedraw, setRegion, setSize, setSize, setTextDirection, setToolTipText, setTouchEnabled, setVisible, toControl, toControl, toDisplay, toDisplay, traverse, traverse, traverse, update |
| Methods inherited from class org.eclipse.swt.widgets.Widget |
|---|
addDisposeListener, addListener, checkWidget, dispose, getData, getData, getDisplay, getListeners, getStyle, isDisposed, isListening, notifyListeners, removeDisposeListener, removeListener, removeListener, reskin, setData, setData, toString |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static int FLAG_FORCE_PROVIDER_SELECTION
public static int FLAG_NO_LOCAL_SELECTION
| Constructor Detail |
|---|
public RemoteConnectionWidget(org.eclipse.swt.widgets.Composite parent,
int style,
java.lang.String title,
int flags,
org.eclipse.jface.operation.IRunnableContext context)
parent - parent compositestyle - style or SWT.NONEtitle - if a title is supplied then the widget will be placed in a group. Can be null.flags - a combination of flags that modify the behavior of the widget.context - runnable context, or null| Method Detail |
|---|
public void addSelectionListener(org.eclipse.swt.events.SelectionListener listener)
SelectionListener interface.
widgetSelected is called when the user changes the service provider or connection.
listener - the listener which should be notifiedpublic org.eclipse.swt.widgets.Button getButton()
public IRemoteConnection getConnection()
protected IRemoteConnectionManager getRemoteConnectionManager(IRemoteServices services)
protected IRemoteServices getRemoteServices(java.lang.String id)
protected void handleConnectionSelected()
protected void handleNewRemoteConnectionSelected()
protected void handleRemoteServiceSelected(IRemoteConnection conn)
conn - connection to select as current. If conn is null, select the first item in the list.notify - if true, notify handlers that the connection has changed. This should only happen if the user changes the
connection.protected void initializeRemoteServicesCombo(java.lang.String id)
public boolean isEnabled()
isEnabled in class org.eclipse.swt.widgets.Controlpublic void removeSelectionListener(org.eclipse.swt.events.SelectionListener listener)
listener - listener to removepublic void setConnection(IRemoteConnection connection)
connection - connection to select
public void setConnection(java.lang.String id,
java.lang.String name)
id - remote services idname - connection namepublic void setEnabled(boolean enabled)
setEnabled in class org.eclipse.swt.widgets.Control
public void setHints(java.lang.String[] attrHints,
java.lang.String[] attrHintValues)
attrHints - attrHintValues -
|
PTP Release 7.0 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||