PTP
Release 5.0

org.eclipse.ptp.remote.ui.widgets
Class RemoteDirectoryWidget

java.lang.Object
  extended by org.eclipse.swt.widgets.Widget
      extended by org.eclipse.swt.widgets.Control
          extended by org.eclipse.swt.widgets.Scrollable
              extended by org.eclipse.swt.widgets.Composite
                  extended by org.eclipse.ptp.remote.ui.widgets.RemoteDirectoryWidget
All Implemented Interfaces:
org.eclipse.swt.graphics.Drawable

public class RemoteDirectoryWidget
extends org.eclipse.swt.widgets.Composite

Widget to allow the user to select a remote directory. Provides a "Browse" button that uses the currently specified connection and a "Restore Default" button to revert to the initial setting. If title is supplied then the widget will be placed in a group. The browse message can be modified using setBrowseMessage(String)


Field Summary
 
Fields inherited from class org.eclipse.swt.widgets.Composite
embeddedHandle
 
Fields inherited from class org.eclipse.swt.widgets.Widget
handle
 
Constructor Summary
RemoteDirectoryWidget(org.eclipse.swt.widgets.Composite parent, int style, java.lang.String title, java.lang.String defaultPath)
           
 
Method Summary
 void addModifyListener(org.eclipse.swt.events.ModifyListener listener)
          Add a listener that will be notified when the directory path is modified.
 java.lang.String getLocationPath()
          Get the directory location path.
 void removeModifyListener(org.eclipse.swt.events.ModifyListener listener)
          Remove a listener that will be notified when the directory path is modified.
 void setBrowseMessage(java.lang.String message)
          Set the message that will be displayed in the remote directory browser dialog.
 void setConnection(IRemoteConnection conn)
          Set the remote connection to use for browsing for the remote directory.
 void setLocationPath(java.lang.String path)
          Set the initial remote location that will be displayed in the widget.
 
Methods inherited from class org.eclipse.swt.widgets.Composite
changed, checkSubclass, computeSize, drawBackground, getBackgroundMode, getChildren, getClientArea, getLayout, getLayoutDeferred, getTabList, isLayoutDeferred, layout, layout, layout, layout, layout, setBackgroundMode, setFocus, setLayout, setLayoutDeferred, setTabList
 
Methods inherited from class org.eclipse.swt.widgets.Scrollable
computeTrim, getBorderWidth, getHorizontalBar, 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, getBounds, getCursor, getDragDetect, getEnabled, getFont, getForeground, getLayoutData, getLocation, getMenu, getMonitor, getOrientation, getParent, getRegion, getShell, getSize, getToolTipText, getVisible, internal_dispose_GC, internal_new_GC, isEnabled, isFocusControl, isReparentable, isTouchEnabled, 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, setEnabled, setFont, setForeground, setLayoutData, setLocation, setLocation, setMenu, setOrientation, setParent, setRedraw, setRegion, setSize, setSize, setToolTipText, setTouchEventsEnabled, 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
 

Constructor Detail

RemoteDirectoryWidget

public RemoteDirectoryWidget(org.eclipse.swt.widgets.Composite parent,
                             int style,
                             java.lang.String title,
                             java.lang.String defaultPath)
Method Detail

addModifyListener

public void addModifyListener(org.eclipse.swt.events.ModifyListener listener)
Add a listener that will be notified when the directory path is modified.

Parameters:
listener - listener to add

getLocationPath

public java.lang.String getLocationPath()
Get the directory location path. This path will be relative to the remote machine.

Returns:
directory location path

removeModifyListener

public void removeModifyListener(org.eclipse.swt.events.ModifyListener listener)
Remove a listener that will be notified when the directory path is modified.

Parameters:
listener - listener to remove

setBrowseMessage

public void setBrowseMessage(java.lang.String message)
Set the message that will be displayed in the remote directory browser dialog.

Parameters:
message - message to be displayed

setConnection

public void setConnection(IRemoteConnection conn)
Set the remote connection to use for browsing for the remote directory.

Parameters:
conn - remote connection
Since:
4.0

setLocationPath

public void setLocationPath(java.lang.String path)
Set the initial remote location that will be displayed in the widget.

Parameters:
path -

PTP
Release 5.0

Copyright (c) 2011 IBM Corporation and others. All Rights Reserved.