org.gnu.gtk

Class FileChooserWidget

Implemented Interfaces:
FileChooser

public class FileChooserWidget
extends VBox
implements FileChooser

Constructor Summary

FileChooserWidget(Handle handle)
Create a new Widget with a handle to a native resource returned from a call to the native libraries.
FileChooserWidget(FileChooserAction action)

Method Summary

void
addFilter(FileFilter filter)
void
addListener(FileChooserListener listener)
void
addShortcutFolder(String folder)
void
addShortcutURI(String uri)
FileChooserAction
getAction()
String
getCurrentFolder()
String
getCurrentFolderURI()
Widget
getExtraWidget()
static FileChooserWidget
getFileChooserWidget(Handle handle)
Internal static factory method to be used by Java-Gnome only.
String
getFilename()
String[]
getFilenames()
FileFilter
getFilter()
boolean
getLocalOnly()
String
getPreviewFilename()
String
getPreviewURI()
Widget
getPreviewWidget()
boolean
getPreviewWidgetActive()
boolean
getSelectMultiple()
boolean
getShowHidden()
Sets whether hidden files and folders are displayed in the file selector.
String
getURI()
String[]
getURIs()
boolean
getUsePreviewLabel()
FileFilter[]
listFilters()
String[]
listShortcutFolders()
String[]
listShortcutURIs()
void
removeFilter(FileFilter filter)
void
removeListener(FileChooserListener listener)
void
removeShortcutFolder(String folder)
void
removeShortcutURI(String uri)
void
selectAll()
boolean
selectFilename(String filename)
boolean
selectURI(String uri)
void
setAction(FileChooserAction action)
boolean
setCurrentFolder(String folder)
boolean
setCurrentFolderURI(String folder)
void
setCurrentName(String name)
void
setExtraWidget(Widget extraWidget)
boolean
setFilename(String filename)
void
setFilter(FileFilter filter)
void
setLocalOnly(boolean localOnly)
void
setPreviewWidget(Widget previewWidget)
void
setPreviewWidgetActive(boolean active)
void
setSelectMultiple(boolean selectMultiple)
void
setShowHidden(boolean hidden)
Sets whether hidden files and folders are displayed in the file selector.
boolean
setURI(String uri)
void
setUsePreviewLabel(boolean useLabel)
void
unselectAll()
void
unselectFilename(String filename)
void
unselectURI(String uri)

Methods inherited from class org.gnu.gtk.VBox

getType, getVBox

Methods inherited from class org.gnu.gtk.Box

getHomogeneous, getSpacing, getType, packEnd, packEnd, packStart, packStart, reorderChild, setHomogeneous, setSpacing

Methods inherited from class org.gnu.gtk.Container

add, addListener, getBorderWidth, getChildren, getEventListenerClass, getEventType, getResizeMode, getType, remove, removeListener, resizeChildren, setBorderWidth, setResizeMode

Methods inherited from class org.gnu.gtk.Widget

activate, addAccelerator, addEvents, addListener, addListener, addListener, addListener, addListener, addListener, addListener, addListener, addListener, addListener, addListener, canActivateAccel, createContext, createLayout, draw, drawArea, drawArea, finish, getAccessible, getAllocation, getColormap, getContext, getData, getDisplay, getDragData, getEventListenerClass, getEventType, getExtensionEvents, getModifierStyle, getName, getParent, getParentWindow, getPointer, getRootWindow, getScreen, getSensitive, getStyle, getToplevel, getType, getWidget, getWindow, grabDefault, grabFocus, hasFocus, hasScreen, hide, hideAll, highlight, highlight, intersect, isAncestor, makeWidget, modifyStyle, popColormap, pushColormap, realize, removeAccelerator, removeListener, removeListener, removeListener, removeListener, removeListener, removeListener, removeListener, removeListener, removeListener, removeListener, removeListener, reparent, setBackgroundColor, setBaseColor, setColormap, setDoubleBuffered, setDragDestination, setDragIcon, setDragIconPixbuf, setDragIconStock, setDragSource, setEvents, setExtensionEvents, setFont, setForegroundColor, setMinimumSize, setName, setNoDragDestination, setNoDragSource, setSensitive, setTextColor, shapeCombineMask, show, showAll, unHighlight, unHighlight

Methods inherited from class org.gnu.gtk.GtkObject

destroy, getType, sink

Methods inherited from class org.gnu.glib.GObject

addEventHandler, addEventHandler, addEventHandler, addEventHandler, addEventHandler, addEventHandler, addEventHandler, addListener, collect, freezeNotify, getBooleanProperty, getData, getDoubleProperty, getEventListenerClass, getEventType, getFloatProperty, getGObjectFromHandle, getIntProperty, getJavaObjectProperty, getLongProperty, getPixbufProperty, getProperty, getStringProperty, hasProperty, notify, removeEventHandler, removeListener, setBooleanProperty, setData, setDoubleProperty, setFloatProperty, setIntProperty, setJavaObjectProperty, setLongProperty, setPixbufProperty, setProperty, setStringProperty, thawNotify

Constructor Details

FileChooserWidget

public FileChooserWidget(Handle handle)
Create a new Widget with a handle to a native resource returned from a call to the native libraries.
Parameters:
handle - The handle that represents a pointer to a native resource.

FileChooserWidget

public FileChooserWidget(FileChooserAction action)

Method Details

addFilter

public void addFilter(FileFilter filter)
Specified by:
addFilter in interface FileChooser

addListener

public void addListener(FileChooserListener listener)
Specified by:
addListener in interface FileChooser

addShortcutFolder

public void addShortcutFolder(String folder)
            throws FileChooserException
Specified by:
addShortcutFolder in interface FileChooser

addShortcutURI

public void addShortcutURI(String uri)
            throws FileChooserException
Specified by:
addShortcutURI in interface FileChooser

getAction

public FileChooserAction getAction()
Specified by:
getAction in interface FileChooser

getCurrentFolder

public String getCurrentFolder()
Specified by:
getCurrentFolder in interface FileChooser

getCurrentFolderURI

public String getCurrentFolderURI()
Specified by:
getCurrentFolderURI in interface FileChooser

getExtraWidget

public Widget getExtraWidget()
Specified by:
getExtraWidget in interface FileChooser

getFileChooserWidget

public static FileChooserWidget getFileChooserWidget(Handle handle)
Internal static factory method to be used by Java-Gnome only.

getFilename

public String getFilename()
Specified by:
getFilename in interface FileChooser

getFilenames

public String[] getFilenames()
Specified by:
getFilenames in interface FileChooser

getFilter

public FileFilter getFilter()
Specified by:
getFilter in interface FileChooser

getLocalOnly

public boolean getLocalOnly()
Specified by:
getLocalOnly in interface FileChooser

getPreviewFilename

public String getPreviewFilename()
Specified by:
getPreviewFilename in interface FileChooser

getPreviewURI

public String getPreviewURI()
Specified by:
getPreviewURI in interface FileChooser

getPreviewWidget

public Widget getPreviewWidget()
Specified by:
getPreviewWidget in interface FileChooser

getPreviewWidgetActive

public boolean getPreviewWidgetActive()
Specified by:
getPreviewWidgetActive in interface FileChooser

getSelectMultiple

public boolean getSelectMultiple()
Specified by:
getSelectMultiple in interface FileChooser

getShowHidden

public boolean getShowHidden()
Sets whether hidden files and folders are displayed in the file selector.
Specified by:
getShowHidden in interface FileChooser
Returns:
true if hidden files and folders should be displayed.

getURI

public String getURI()
Specified by:
getURI in interface FileChooser

getURIs

public String[] getURIs()
Specified by:
getURIs in interface FileChooser

getUsePreviewLabel

public boolean getUsePreviewLabel()
Specified by:
getUsePreviewLabel in interface FileChooser

listFilters

public FileFilter[] listFilters()
Specified by:
listFilters in interface FileChooser

listShortcutFolders

public String[] listShortcutFolders()
Specified by:
listShortcutFolders in interface FileChooser

listShortcutURIs

public String[] listShortcutURIs()
Specified by:
listShortcutURIs in interface FileChooser

removeFilter

public void removeFilter(FileFilter filter)
Specified by:
removeFilter in interface FileChooser

removeListener

public void removeListener(FileChooserListener listener)
Specified by:
removeListener in interface FileChooser

removeShortcutFolder

public void removeShortcutFolder(String folder)
            throws FileChooserException
Specified by:
removeShortcutFolder in interface FileChooser

removeShortcutURI

public void removeShortcutURI(String uri)
            throws FileChooserException
Specified by:
removeShortcutURI in interface FileChooser

selectAll

public void selectAll()
Specified by:
selectAll in interface FileChooser

selectFilename

public boolean selectFilename(String filename)
Specified by:
selectFilename in interface FileChooser

selectURI

public boolean selectURI(String uri)
Specified by:
selectURI in interface FileChooser

setAction

public void setAction(FileChooserAction action)
Specified by:
setAction in interface FileChooser

setCurrentFolder

public boolean setCurrentFolder(String folder)
Specified by:
setCurrentFolder in interface FileChooser

setCurrentFolderURI

public boolean setCurrentFolderURI(String folder)
Specified by:
setCurrentFolderURI in interface FileChooser

setCurrentName

public void setCurrentName(String name)
Specified by:
setCurrentName in interface FileChooser

setExtraWidget

public void setExtraWidget(Widget extraWidget)
Specified by:
setExtraWidget in interface FileChooser

setFilename

public boolean setFilename(String filename)
Specified by:
setFilename in interface FileChooser

setFilter

public void setFilter(FileFilter filter)
Specified by:
setFilter in interface FileChooser

setLocalOnly

public void setLocalOnly(boolean localOnly)
Specified by:
setLocalOnly in interface FileChooser

setPreviewWidget

public void setPreviewWidget(Widget previewWidget)
Specified by:
setPreviewWidget in interface FileChooser

setPreviewWidgetActive

public void setPreviewWidgetActive(boolean active)
Specified by:
setPreviewWidgetActive in interface FileChooser

setSelectMultiple

public void setSelectMultiple(boolean selectMultiple)
Specified by:
setSelectMultiple in interface FileChooser

setShowHidden

public void setShowHidden(boolean hidden)
Sets whether hidden files and folders are displayed in the file selector.
Specified by:
setShowHidden in interface FileChooser
Parameters:
hidden - true if hidden files and folders should be displayed.

setURI

public boolean setURI(String uri)
Specified by:
setURI in interface FileChooser

setUsePreviewLabel

public void setUsePreviewLabel(boolean useLabel)
Specified by:
setUsePreviewLabel in interface FileChooser

unselectAll

public void unselectAll()
Specified by:
unselectAll in interface FileChooser

unselectFilename

public void unselectFilename(String filename)
Specified by:
unselectFilename in interface FileChooser

unselectURI

public void unselectURI(String uri)
Specified by:
unselectURI in interface FileChooser