LibreOffice
LibreOffice 24.2 SDK API Reference
|
Specifies an interface for a FilePicker. More...
import"XFilePicker.idl";
Public Member Functions | |
void | setMultiSelectionMode ([in] boolean bMode) |
Enable/disable multi-selection mode. More... | |
void | setDefaultName ([in] string aName) |
Sets the default string that appears in the file name box of a FilePicker. More... | |
void | setDisplayDirectory ([in] string aDirectory) raises ( ::com::sun::star::lang::IllegalArgumentException ) |
Sets the directory that the file dialog initially displays. More... | |
string | getDisplayDirectory () |
Returns the directory that the file dialog is currently showing or was last showing before closing the dialog with Ok. More... | |
sequence< string > | getFiles () |
Returns a sequence of the selected files including path information in URL format, conforming to Rfc1738. More... | |
Public Member Functions inherited from XExecutableDialog | |
void | setTitle ([in] string aTitle) |
Sets the title of the dialog. More... | |
short | execute () |
Executes (shows) the dialog. More... | |
Public Member Functions inherited from XInterface | |
any | queryInterface ([in] type aType) |
queries for a new interface to an existing UNO object. More... | |
void | acquire () |
increases the reference counter by one. More... | |
void | release () |
decreases the reference counter by one. More... | |
Specifies an interface for a FilePicker.
string getDisplayDirectory | ( | ) |
Returns the directory that the file dialog is currently showing or was last showing before closing the dialog with Ok.
If the user did cancel the dialog, the returned value is undefined.
sequence< string > getFiles | ( | ) |
Returns a sequence of the selected files including path information in URL format, conforming to Rfc1738.
If the user closed the dialog with cancel an empty sequence will be returned.
If the dialog is in execution mode and a single file is selected the complete URL of this file will be returned.
If the dialog is in execution mode and the selected file name is false or any other error occurs an empty sequence will be returned.
The complete path of the file or directory currently selected in URL format. This always returns only the first entry of the sequence.
Notes for the implementation of a FileSave dialog:If there exists a checkbox "Automatic File Extension" which is checked and a valid filter is currently selected the dialog may automatically add an extension to the selected file name.
void setDefaultName | ( | [in] string | aName | ) |
Sets the default string that appears in the file name box of a FilePicker.
aName |
Specifies the default file name, displayed when the FilePicker is shown. The implementation may accept any string, and does not have to check for a valid file name or if the file really exists.
void setDisplayDirectory | ( | [in] string | aDirectory | ) | |
raises | ( | ::com::sun::star::lang::IllegalArgumentException | |||
) |
Sets the directory that the file dialog initially displays.
aDirectory | Specifies the initial directory in URL format. The given URL must conform to Rfc1738). |
com::sun::star::lang::IllegalArgumentException | if the URL is invalid (doesn't conform to Rfc1738). |
void setMultiSelectionMode | ( | [in] boolean | bMode | ) |
Enable/disable multi-selection mode.
If the multi-selection mode is enabled, multiple files may be selected by the user else only one file selection at a time is possible
bMode |
A value of TRUE
enables the multi-selection mode.
A value of FALSE
disables the multi-selection mode, this is the default.