Views
Gadgets Package API Reference Guide
Product Documentation:
Views Documentation Home
List of all members | Public Member Functions
IlvFileChooser Class Reference

File selector dialog class. More...

#include <ilviews/gadgets/filechoo.h>

Inheritance diagram for IlvFileChooser:
IlvDialog IlvGadgetContainer IlvContainer IlvStylist IlvDrawingView IlvView IlvAbstractView IlvSystemPort IlvStylable IlvPort IlvValueInterface

Public Member Functions

 IlvFileChooser (IlvDisplay *display, const char *dir=0, const char *title=0, IlvFileChooserOptions *options=0, IlvSystemView transientFor=0, IlUInt properties=0)
 Constructor. More...
 
virtual void addFileInListMode (const IlPathName &file, IlvPathGadgetItem *item)
 Adds an item to the sheet in List mode. More...
 
virtual void addFileInMatrixMode (const IlPathName &file, IlvPathGadgetItem *item)
 Adds an item to the sheet in Matrix mode. More...
 
virtual void addFileToSheet (const IlPathName &file)
 Adds an item to the sheet. More...
 
virtual void adjustSheetForMatrixMode ()
 Updates the sheet when the dialog is resized. More...
 
virtual void changePath (const IlPathName &path)
 Called when the user selects a new path. More...
 
virtual void convertSizeToLabel (IlUInt size, IlString &label) const
 Converts a file size to a string. More...
 
virtual IlvButtoncreateApplyButton (const IlvRect &rect, const IlString &label) const
 Creates a dialog Apply button. More...
 
virtual IlvButtoncreateCancelButton (const IlvRect &rect, const IlString &label) const
 Creates a dialog Cancel button. More...
 
virtual IlvButtoncreateCreateButton (const IlvRect &rect) const
 Creates a Create directory dialog button. More...
 
virtual IlvTreePathGadgetItemcreateDeviceItem (const IlPathName &filepath, IlInt genre) const
 Creates a tree gadget item for a device. More...
 
virtual void createDirectoryButtonClicked ()
 Called when the Create directory button has been clicked. More...
 
virtual IlvComboBoxcreateFilterComboBox (const IlvRect &rect) const
 Creates a dialog combobox. More...
 
virtual IlvButtoncreateHiddenButton (const IlvRect &rect) const
 Creates a Hide hidden files dialog button. More...
 
virtual IlvButtoncreateListButton (const IlvRect &rect) const
 Creates a List mode dialog button. More...
 
virtual IlvButtoncreateMatrixButton (const IlvRect &rect) const
 Creates a Matrix mode dialog button. More...
 
virtual IlvMessageLabelcreateMsgLabel (const IlvRect &rect, const IlString &label) const
 Creates a dialog message label. More...
 
virtual IlvFileChooserSheetcreateSheet (const IlvRect &rect) const
 Creates a dialog sheet. More...
 
virtual IlvPathGadgetItemcreateSheetItem (const IlPathName &filepath, IlvFileChooserDisplayMode mode) const
 Creates a gadget item for the sheet. More...
 
virtual IlvButtoncreateShowAllButton (const IlvRect &rect) const
 Creates a Show all files dialog button. More...
 
virtual IlvTextFieldcreateTextField (const IlvRect &rect) const
 Creates a dialog textfield. More...
 
virtual IlvToolBarPathcreateToolBar (const IlvRect &rect) const
 Creates a dialog toolbar. More...
 
virtual IlvFileChooserTreecreateTreeGadget (const IlvRect &rect) const
 Creates a dialog tree gadget. More...
 
virtual IlvTreePathGadgetItemcreateTreeItem (const IlPathName &path) const
 Creates a tree gadget item for a directory. More...
 
virtual IlvButtoncreateUpButton (const IlvRect &rect) const
 Creates an Up directory dialog button. More...
 
virtual IlvTreePathGadgetItemfillTree (IlPathName &path, IlvTreePathGadgetItem *parent, IlPathName *ref=0)
 Expands a directory of the tree gadget. More...
 
virtual void filterChanged ()
 Called when the filter has changed. More...
 
IlInt get (IlBoolean grab=IlFalse, IlvCursor *cursor=0)
 Displays the dialog as a modal dialog. More...
 
IlvButtongetCreateButton () const
 Returns the Create directory dialog button. More...
 
IlvComboBoxgetFilterComboBox () const
 Returns the dialog combobox. More...
 
virtual const IlStringgetFilterExtension () const
 Returns the current filter extension. More...
 
IlvButtongetListButton () const
 Returns the List mode dialog button. More...
 
IlvButtongetMatrixButton () const
 Returns the Matrix mode dialog button. More...
 
virtual IlBoolean getNewDirectoryName (IlString &name)
 Called when the user has clicked the Create directory button. More...
 
IlvFileChooserOptionsgetOptions () const
 Returns the object which describes the dialog. More...
 
const IlStringgetResult (IlInt index=0) const
 Returns a selected path name. More...
 
IlInt getResultCount () const
 Returns the result count. More...
 
IlvFileChooserSheetgetSheet () const
 Returns the dialog sheet. More...
 
IlvFileChooserDisplayMode getSheetMode () const
 Returns the display mode of the sheet. More...
 
IlvButtongetShowAllButton () const
 Returns the Show all files dialog button. More...
 
IlvTextFieldgetTextField () const
 Returns the dialog textfield. More...
 
IlvToolBarPathgetToolBar () const
 Returns the dialog toolbar. More...
 
IlvFileChooserTreegetTreeGadget () const
 Returns the dialog tree gadget. More...
 
IlvButtongetUpButton () const
 Returns the Up directory dialog button. More...
 
virtual void handleSheetDoubleClick (IlvEvent &evt)
 Handles double-clicking in the sheet. More...
 
virtual void initSheet ()
 Initializes the sheet. More...
 
virtual void initSheetForListMode ()
 Initializes the sheet for List mode. More...
 
virtual void initSheetForMatrixMode ()
 Initializes the sheet for Matrix mode. More...
 
virtual void listModeButtonClicked ()
 Called when the List mode button has been clicked. More...
 
virtual void matrixModeButtonClicked ()
 Called when the Matrix mode button has been clicked. More...
 
virtual void newShowAllMode (IlBoolean show)
 Changes the status of the Show files buttons. More...
 
virtual void processApply ()
 Called when the Apply button has been clicked. More...
 
virtual void refreshSheet ()
 Updates the sheet with the current path. More...
 
virtual void rewindPath (const IlPathName &path)
 Called when the user selects a directory of the path. More...
 
virtual void selectionChanged ()
 Called when the sheet selection has been changed. More...
 
void setCurrentPath (const IlPathName &path)
 Sets the current path. More...
 
void setFilterExtension (const IlString &ext)
 Sets the current filter extension. More...
 
void setSortMode (IlPathName::SortMode mode)
 Sets the sort method for entries in the sheet. More...
 
virtual void setTreePath (const IlPathName &path)
 Sets the path of the tree gadget. More...
 
virtual void updateDisplayButtons ()
 Updates the status of the display mode buttons. More...
 
virtual void updateSheet (IlPathName &path)
 Updates the sheet for a path. More...
 
virtual void updateShowAllButton ()
 Updates the status of the Show files buttons. More...
 
virtual void updateToolBar (IlPathName &path)
 Updates the toolbar. More...
 
virtual void updateTree (IlPathName &path, IlvTreePathGadgetItem *item)
 Updates a part of the tree gadget. More...
 
virtual void upDirectoryButtonClicked ()
 Called when the Up directory button has been clicked. More...
 
- Public Member Functions inherited from IlvDialog
 IlvDialog (IlvDisplay *display, const char *name, const char *title, const char *filename, const IlvRect *rect=0)
 Constructor. More...
 
 IlvDialog (IlvDisplay *display, const char *name, const char *title, const char *filename, IlUInt properties, const IlvRect *rect=0, IlvSystemView transientFor=0)
 Constructor. More...
 
 IlvDialog (IlvDisplay *display, const char *name, const char *title, const IlvRect &rect, IlUInt properties=0, IlvSystemView transientFor=0)
 Constructor. More...
 
virtual void apply ()
 Is called when the callback associated with the apply symbol is triggered. More...
 
virtual void cancel ()
 Is called when the callback associated with the cancel symbol is triggered. More...
 
virtual void wait (IlBoolean grab=IlFalse, IlvCursor *cursor=0)
 Displays a modal dialog. More...
 
IlBoolean wasCanceled () const
 Returns the status of the dialog after closing it. More...
 
- Public Member Functions inherited from IlvGadgetContainer
 IlvGadgetContainer (IlvAbstractView *parent, const IlvRect &rect, IlBoolean useacc=IlFalse, IlBoolean visible=IlTrue)
 Initializes a new instance of the IlvGadgetContainer class as a child view of another view. More...
 
 IlvGadgetContainer (IlvDisplay *display, const char *name, const char *title, const IlvRect &rect, IlBoolean useacc=IlFalse, IlBoolean visible=IlTrue)
 Initializes a new instance of the IlvGadgetContainer class as a top view. More...
 
 IlvGadgetContainer (IlvDisplay *display, const char *name, const char *title, const IlvRect &rect, IlUInt properties, IlBoolean useacc=IlFalse, IlBoolean visible=IlTrue, IlvSystemView transientFor=0)
 Initializes a new instance of the IlvGadgetContainer class as a top view. More...
 
 IlvGadgetContainer (IlvDisplay *display, IlvSystemView parent, const IlvRect &rect, IlBoolean useacc=IlFalse, IlBoolean visible=IlTrue)
 Initializes a new instance of the IlvGadgetContainer class as a child view of a system view. More...
 
 IlvGadgetContainer (IlvDisplay *display, IlvSystemView window, IlBoolean useacc=IlFalse)
 Initializes a new instance of the IlvGadgetContainer class using an existing system view. More...
 
virtual IlBoolean allowFocus (IlBoolean value)
 Specifies whether the container manages the focus. More...
 
virtual void applyResize (IlFloat sx, IlFloat sy, IlBoolean redraw=IlTrue)
 Is called to carry out the resize events applying to the gadget container. More...
 
IlBoolean autoResize (IlBoolean a)
 Sets the auto resize mode of the gadget container. More...
 
IlvButtongetDefaultButton () const
 Returns the default button of the gadget container. More...
 
virtual IlvGraphicgetFirstFocusGraphic () const
 Returns the first object that receives the focus in this container. More...
 
virtual IlvGraphicgetFocus () const
 Returns the object that has the keyboard focus in the gadget container. More...
 
virtual IlvGraphicgetGrab () const
 Returns the object that is currently grabbing events in the container. More...
 
virtual IlvGraphicgetLastFocusGraphic () const
 Returns the last object that receives the focus in this container. More...
 
IlvLookFeelHandlergetLookFeelHandler () const
 Returns the look and feel handler associated with this container. More...
 
virtual IlvGraphicgetNextFocusGraphic (IlvGraphic *object) const
 Returns the next object that will receive the focus after the specified object. More...
 
IlvGraphicgetOverriddenFocus () const
 Returns the object that will receive the focus after calling setFocus(). More...
 
virtual IlvGraphicgetPreviousFocusGraphic (IlvGraphic *object) const
 Returns the previous object that received the focus before the specified object. More...
 
IlBoolean isAutoResizing () const
 Indicates whether the gadget container gets resized when loading a file. More...
 
virtual IlBoolean isFocusAllowed () const
 Indicates whether the focus is allowed in the container. More...
 
virtual void moveFocusAfter (IlBoolean redraw=IlTrue)
 Is called to find the next focusable object. More...
 
virtual void moveFocusBefore (IlBoolean redraw=IlTrue)
 Is called to find the previous focusable object. More...
 
void overrideFocus (IlvGraphic *obj)
 Sets the object that will receive the focus after calling setFocus(). More...
 
virtual void removeGrab ()
 Cancels the grabbing settings defined with setGrab(). More...
 
void setDefaultButton (IlvButton *button, IlBoolean redraw=IlTrue)
 Sets the default button of the gadget container. More...
 
virtual void setFocus (IlvGraphic *graphic=0, IlBoolean redraw=IlTrue)
 Sets the focus to the specified object of the gadget container. More...
 
virtual void setGrab (IlvGraphic *object)
 Sets the specified object as the grabbing object. More...
 
void setLookFeelHandler (IlvLookFeelHandler *lfh)
 Sets the look and feel handler of this container. More...
 

Detailed Description

File selector dialog class.

Library: ilvadvgdt

The IlvFileChooser class enables you to browse through a directory hierarchy and select a file name or directory. To modify this dialog, create an IlvFileChooserOptions object with the options you wish to change.

Warning
Note that by default, all the bitmaps that are used by this class are PNG bitmaps. If you plan to statically link an application that uses IlvFileChooser, you will have to explicitly include the header file <ilviews/bitmaps/png.h> in one of your application source file and add the ilvpng library to your link command.
Similarly, if you replace the default bitmaps by your own and wish to link statically, you will have to make sure the appropriate bitmap format header files are included in one of your object files, and that the corresponding libraries are added to the link command for your application.
See also
IlvDialog, IlvFileChooserOptions.

Constructor & Destructor Documentation

◆ IlvFileChooser()

IlvFileChooser::IlvFileChooser ( IlvDisplay display,
const char *  dir = 0,
const char *  title = 0,
IlvFileChooserOptions options = 0,
IlvSystemView  transientFor = 0,
IlUInt  properties = 0 
)

Constructor.

Initializes a new instance of the IlvIFileChooser class.

Parameters
displayThe connection to the display.
dirThe initial directory that will be scanned.
titleThe dialog title. If the value is null then the title from the IlvFileChooserOptions object is used.
optionsThe object which defines the look and behaviour of the dialog.
transientForThe system view for which the dialog is transient.
propertiesThe view properties, as defined in IlvView class.
See also
IlvView constructors.

Member Function Documentation

◆ addFileInListMode()

virtual void IlvFileChooser::addFileInListMode ( const IlPathName file,
IlvPathGadgetItem item 
)
virtual

Adds an item to the sheet in List mode.

Adds a file or directory to the sheet in List mode.

Parameters
fileThe full path for a file or a directory.
itemThe gadget item associated with the file or directory.

◆ addFileInMatrixMode()

virtual void IlvFileChooser::addFileInMatrixMode ( const IlPathName file,
IlvPathGadgetItem item 
)
virtual

Adds an item to the sheet in Matrix mode.

Adds a file or directory to the sheet in Matrix mode.

Parameters
fileThe full path for a file or a directory.
itemThe gadget item associated with the file or directory.

◆ addFileToSheet()

virtual void IlvFileChooser::addFileToSheet ( const IlPathName file)
virtual

Adds an item to the sheet.

Adds a file or directory to the sheet. This method creates a gadget item before calling the addFileInMatrixMode() or addFileInListMode() method to add it.

Parameters
fileThe full path for a file or a directory.

◆ adjustSheetForMatrixMode()

virtual void IlvFileChooser::adjustSheetForMatrixMode ( )
virtual

Updates the sheet when the dialog is resized.

Updates the sheet when the dialog is resized. It is not necessary to call this method if the display mode is List mode as the number of columns does not change.

◆ changePath()

virtual void IlvFileChooser::changePath ( const IlPathName path)
virtual

Called when the user selects a new path.

Called when the user selects a new path from a pop-up menu on the toolbar.

Parameters
pathThe path which corresponds to the selection.

◆ convertSizeToLabel()

virtual void IlvFileChooser::convertSizeToLabel ( IlUInt  size,
IlString label 
) const
virtual

Converts a file size to a string.

Converts a file size to a string.

Parameters
sizeThe file size.
labelThe conversion result.

◆ createApplyButton()

virtual IlvButton* IlvFileChooser::createApplyButton ( const IlvRect rect,
const IlString label 
) const
virtual

Creates a dialog Apply button.

Creates the Apply button.

Parameters
rectThe bounding box of the button.
labelThe button label.
Returns
The created button.

◆ createCancelButton()

virtual IlvButton* IlvFileChooser::createCancelButton ( const IlvRect rect,
const IlString label 
) const
virtual

Creates a dialog Cancel button.

Creates the Cancel button.

Parameters
rectThe bounding box of the button.
labelThe button label.
Returns
The created button.

◆ createCreateButton()

virtual IlvButton* IlvFileChooser::createCreateButton ( const IlvRect rect) const
virtual

Creates a Create directory dialog button.

Creates the Create directory button which is displayed at the right of the toolbar to display the current path.

Parameters
rectThe bounding box of the button.
Returns
The created button.

◆ createDeviceItem()

virtual IlvTreePathGadgetItem* IlvFileChooser::createDeviceItem ( const IlPathName filepath,
IlInt  genre 
) const
virtual

Creates a tree gadget item for a device.

Creates a tree gadget item for a device. This method is called only under Windows. A device has a name (a letter) and a type. Type can take one of the following values:

  • 0 for Unknown
  • 1 for Error
  • 2 for Removable
  • 3 for Fixed
  • 4 for Network
  • 5 for CDRom
  • 6 for Ram disk
Parameters
filepathThe full path name of the device.
genreThe device type.
Returns
A tree gadget item.

◆ createDirectoryButtonClicked()

virtual void IlvFileChooser::createDirectoryButtonClicked ( )
virtual

Called when the Create directory button has been clicked.

Called when the Create directory button has been clicked.

◆ createFilterComboBox()

virtual IlvComboBox* IlvFileChooser::createFilterComboBox ( const IlvRect rect) const
virtual

Creates a dialog combobox.

Creates the combobox which contains the filter list. If no filter is defined, this method is not called.

Parameters
rectThe bounding box of the combobox.
Returns
The created combobox.

◆ createHiddenButton()

virtual IlvButton* IlvFileChooser::createHiddenButton ( const IlvRect rect) const
virtual

Creates a Hide hidden files dialog button.

Creates the Hide hidden files button which is displayed at the right of the toolbar to display the current path.

Parameters
rectThe bounding box of the button.
Returns
The created button.

◆ createListButton()

virtual IlvButton* IlvFileChooser::createListButton ( const IlvRect rect) const
virtual

Creates a List mode dialog button.

Creates the List mode button which is displayed at the right of the toolbar to display the current path.

Parameters
rectThe bounding box of the button.
Returns
The created button.

◆ createMatrixButton()

virtual IlvButton* IlvFileChooser::createMatrixButton ( const IlvRect rect) const
virtual

Creates a Matrix mode dialog button.

Creates the Matrix mode button which is displayed at the right of the toolbar to display the current path.

Parameters
rectThe bounding box of the button.
Returns
The created button.

◆ createMsgLabel()

virtual IlvMessageLabel* IlvFileChooser::createMsgLabel ( const IlvRect rect,
const IlString label 
) const
virtual

Creates a dialog message label.

Creates a message label such as Filename or Filter.

Parameters
rectThe bounding box of the message label.
labelThe text of the message label.
Returns
The created message label.

◆ createSheet()

virtual IlvFileChooserSheet* IlvFileChooser::createSheet ( const IlvRect rect) const
virtual

Creates a dialog sheet.

Creates the sheet which displays the directories and files of the current path.

Parameters
rectThe bounding box of the sheet.
Returns
The created sheet.

◆ createSheetItem()

virtual IlvPathGadgetItem* IlvFileChooser::createSheetItem ( const IlPathName filepath,
IlvFileChooserDisplayMode  mode 
) const
virtual

Creates a gadget item for the sheet.

Creates a gadget item for the list of directories and files.

Parameters
filepathThe full path name of the directory or file.
modeThe display mode of the sheet which can be List or Matrix mode.
Returns
A gadget item.

◆ createShowAllButton()

virtual IlvButton* IlvFileChooser::createShowAllButton ( const IlvRect rect) const
virtual

Creates a Show all files dialog button.

Creates the Show all files button which is displayed at the right of the toolbar to display the current path.

Parameters
rectThe bounding box of the button.
Returns
The created button.

◆ createTextField()

virtual IlvTextField* IlvFileChooser::createTextField ( const IlvRect rect) const
virtual

Creates a dialog textfield.

Creates the textfield which contains the selection.

Parameters
rectThe bounding box of the textfield.
Returns
The created textfield.

◆ createToolBar()

virtual IlvToolBarPath* IlvFileChooser::createToolBar ( const IlvRect rect) const
virtual

Creates a dialog toolbar.

Creates the toolbar which displays the current path.

Parameters
rectThe bounding box of the toolbar.
Returns
The created toolbar.

◆ createTreeGadget()

virtual IlvFileChooserTree* IlvFileChooser::createTreeGadget ( const IlvRect rect) const
virtual

Creates a dialog tree gadget.

Creates the tree gadget which displays the directory tree.

Parameters
rectThe bounding box of the tree gadget.
Returns
The created tree gadget.

◆ createTreeItem()

virtual IlvTreePathGadgetItem* IlvFileChooser::createTreeItem ( const IlPathName path) const
virtual

Creates a tree gadget item for a directory.

Creates a tree gadget item for a directory.

Parameters
pathThe full path name of the directory.
Returns
A tree gadget item.

◆ createUpButton()

virtual IlvButton* IlvFileChooser::createUpButton ( const IlvRect rect) const
virtual

Creates an Up directory dialog button.

Creates the Up directory button which is displayed at the right of the toolbar to display the current path.

Parameters
rectThe bounding box of the button.
Returns
The created button.

◆ fillTree()

virtual IlvTreePathGadgetItem* IlvFileChooser::fillTree ( IlPathName path,
IlvTreePathGadgetItem parent,
IlPathName ref = 0 
)
virtual

Expands a directory of the tree gadget.

Expands a directory of the tree gadget.

Parameters
pathThe full path of the directory.
parentThe tree gadget item associated with the path.
refThe current path of the dialog.
Returns
The new tree gadget item corresponding to the current path of the dialog, otherwise null.

◆ filterChanged()

virtual void IlvFileChooser::filterChanged ( )
virtual

Called when the filter has changed.

Called when the user selects a new filter in the filter combobox.

◆ get()

IlInt IlvFileChooser::get ( IlBoolean  grab = IlFalse,
IlvCursor cursor = 0 
)

Displays the dialog as a modal dialog.

Parameters
grabSpecifies whether the dialog should be system modal. A system modal dialog grabs input events occurring on the entire system so that other applications cannot get any keyboard or mouse events until the member function returns. You can specify the cursor to be displayed with the cursor parameter. If grab is set to IlFalse, the dialog is application modal. In this case, the application does not receive input events in other windows. This is the default value.
cursorThe cursor used to make the selection.
Returns
The number of the selected path.
Note
Some operating systems, such as Windows NT and Windows 95, do not allow system modal dialogs. On these operating system dialogs are always application modal.
See also
getResult(), getResultCount().

◆ getCreateButton()

IlvButton* IlvFileChooser::getCreateButton ( ) const

Returns the Create directory dialog button.

Returns
The Create directory button, or 0 if the button is not visible.

◆ getFilterComboBox()

IlvComboBox* IlvFileChooser::getFilterComboBox ( ) const

Returns the dialog combobox.

Returns
The combobox which contains the list of file types.

◆ getFilterExtension()

virtual const IlString& IlvFileChooser::getFilterExtension ( ) const
virtual

Returns the current filter extension.

Returns
The current filter extension. The default value is an empty string which means no filter or all files.

◆ getListButton()

IlvButton* IlvFileChooser::getListButton ( ) const

Returns the List mode dialog button.

Returns
The List mode button, or 0 if the button is not visible.

◆ getMatrixButton()

IlvButton* IlvFileChooser::getMatrixButton ( ) const

Returns the Matrix mode dialog button.

Returns
The Matrix mode button, or 0 if the button is not visible.

◆ getNewDirectoryName()

virtual IlBoolean IlvFileChooser::getNewDirectoryName ( IlString name)
virtual

Called when the user has clicked the Create directory button.

Called when the user has clicked the Create directory button. By default this method creates a dialog to ask for a directory name. This directory name is not checked.

Parameters
nameThe name of the new directory.
Returns
IlTrue if the user clicked the Apply button and name is not empty.

◆ getOptions()

IlvFileChooserOptions* IlvFileChooser::getOptions ( ) const

Returns the object which describes the dialog.

Returns
The object which describes the dialog.

◆ getResult()

const IlString& IlvFileChooser::getResult ( IlInt  index = 0) const

Returns a selected path name.

Returns a path name from the list of selected path names.

Parameters
indexThe index of the selected path name in the list. The index value starts at 0.
Returns
The selected path name.

◆ getResultCount()

IlInt IlvFileChooser::getResultCount ( ) const

Returns the result count.

Returns the result count. A result is a selected path name. It can be a file or a directory.

Returns
The number of selected path names.

◆ getSheet()

IlvFileChooserSheet* IlvFileChooser::getSheet ( ) const

Returns the dialog sheet.

Returns
The sheet which displays the directories and files of the current path.

◆ getSheetMode()

IlvFileChooserDisplayMode IlvFileChooser::getSheetMode ( ) const

Returns the display mode of the sheet.

Returns
The display mode of the sheet.

◆ getShowAllButton()

IlvButton* IlvFileChooser::getShowAllButton ( ) const

Returns the Show all files dialog button.

Returns
The Show all files button, or 0 if the button is not visible.

◆ getTextField()

IlvTextField* IlvFileChooser::getTextField ( ) const

Returns the dialog textfield.

Returns
The textfield which contains the selection.

◆ getToolBar()

IlvToolBarPath* IlvFileChooser::getToolBar ( ) const

Returns the dialog toolbar.

Returns
The toolbar which displays the current path.

◆ getTreeGadget()

IlvFileChooserTree* IlvFileChooser::getTreeGadget ( ) const

Returns the dialog tree gadget.

Returns
The tree gadget which displays the directory tree.

◆ getUpButton()

IlvButton* IlvFileChooser::getUpButton ( ) const

Returns the Up directory dialog button.

Returns
The Up directory button, or 0 if the button is not visible.

◆ handleSheetDoubleClick()

virtual void IlvFileChooser::handleSheetDoubleClick ( IlvEvent evt)
virtual

Handles double-clicking in the sheet.

Handles double-clicking in the sheet. By default this method calls the processApply() method. param evt The double-click event.

◆ initSheet()

virtual void IlvFileChooser::initSheet ( )
virtual

Initializes the sheet.

Initializes the common features of the sheet before calling the initSheetForMatrixMode() or initSheetForListMode() methods to finalize.

◆ initSheetForListMode()

virtual void IlvFileChooser::initSheetForListMode ( )
virtual

Initializes the sheet for List mode.

Initializes the sheet for List mode. In List mode, each matrix row is a file or a directory.

◆ initSheetForMatrixMode()

virtual void IlvFileChooser::initSheetForMatrixMode ( )
virtual

Initializes the sheet for Matrix mode.

Initializes the sheet for Matrix mode. In Matrix mode, each matrix item is a file or directory.

◆ listModeButtonClicked()

virtual void IlvFileChooser::listModeButtonClicked ( )
virtual

Called when the List mode button has been clicked.

Called when the List mode button has been clicked.

◆ matrixModeButtonClicked()

virtual void IlvFileChooser::matrixModeButtonClicked ( )
virtual

Called when the Matrix mode button has been clicked.

Called when the Matrix mode button has been clicked.

◆ newShowAllMode()

virtual void IlvFileChooser::newShowAllMode ( IlBoolean  show)
virtual

Changes the status of the Show files buttons.

Changes the status of the Show files buttons.

Parameters
showThe Show all files button will be visible if the value is IlTrue, otherwise it will be hidden. The Hide hidden files button will be hidden if the value is IlTrue.

◆ processApply()

virtual void IlvFileChooser::processApply ( )
virtual

Called when the Apply button has been clicked.

Called when the Apply button has been clicked. If the dialog selection type is file only and the selection is a directory, the current path of the dialog is set to the selected directory. If the selection is a file, the result is built and the dialog is closed.

◆ refreshSheet()

virtual void IlvFileChooser::refreshSheet ( )
virtual

Updates the sheet with the current path.

Updates the sheet data with the current path.

◆ rewindPath()

virtual void IlvFileChooser::rewindPath ( const IlPathName path)
virtual

Called when the user selects a directory of the path.

Called when the user selects a directory or the device of the current path of the toolbar.

Parameters
pathThe path which corresponds to the selection.

◆ selectionChanged()

virtual void IlvFileChooser::selectionChanged ( )
virtual

Called when the sheet selection has been changed.

Called when the sheet selection has been changed to update the textfield containing the user selection.

◆ setCurrentPath()

void IlvFileChooser::setCurrentPath ( const IlPathName path)

Sets the current path.

Sets the current path. This method does not update the different gadgets of the dialog.

Parameters
pathThe new current path.

◆ setFilterExtension()

void IlvFileChooser::setFilterExtension ( const IlString ext)

Sets the current filter extension.

Parameters
extThe new filter extension.

◆ setSortMode()

void IlvFileChooser::setSortMode ( IlPathName::SortMode  mode)

Sets the sort method for entries in the sheet.

Specifies how file and directory names are sorted in the file chooser. The sort mode can be any combinaison of the values of the IlPathName::SortMode enumeration.

If IlPathName::GroupDirectories is specified, files are listed afted the directories.

Parameters
modeThe sort method that must be used.

◆ setTreePath()

virtual void IlvFileChooser::setTreePath ( const IlPathName path)
virtual

Sets the path of the tree gadget.

Removes all tree gadget items before rebuilding the directory tree and expanding the tree gadget items to show the new current path. To finalize, the tree gadget item of the directory is selected.

Parameters
pathThe new current path.

◆ updateDisplayButtons()

virtual void IlvFileChooser::updateDisplayButtons ( )
virtual

Updates the status of the display mode buttons.

Updates the status of the display mode buttons. The display mode buttons are: Matrix mode and List mode.

◆ updateSheet()

virtual void IlvFileChooser::updateSheet ( IlPathName path)
virtual

Updates the sheet for a path.

Initializes the sheet before updating the sheet data for a path. See the setSortMode() method to choose the sort algorithm.

Parameters
pathThe path.

◆ updateShowAllButton()

virtual void IlvFileChooser::updateShowAllButton ( )
virtual

Updates the status of the Show files buttons.

Updates the status of the Show files buttons. The Show files buttons are: Show all files and Hide hidden files.

◆ updateToolBar()

virtual void IlvFileChooser::updateToolBar ( IlPathName path)
virtual

Updates the toolbar.

Updates the toolbar which displays the current path.

Parameters
pathThe new path.

◆ updateTree()

virtual void IlvFileChooser::updateTree ( IlPathName path,
IlvTreePathGadgetItem item 
)
virtual

Updates a part of the tree gadget.

Manages the drawing operations of the tree gadget before calling the fillTree() method to update a part of the tree gadget.

Parameters
pathThe path.
itemThe tree gadget item associated with the path.

◆ upDirectoryButtonClicked()

virtual void IlvFileChooser::upDirectoryButtonClicked ( )
virtual

Called when the Up directory button has been clicked.

Called when the Up directory button has been clicked.