FileDialog Class Reference

The FileDialog JavaScript global object. A simplified version of the Qt file dialogs. More...

Public Slots

QVariant getOpenFileName (String &filter=String::null, String &title=String::null, QWidget *parent=0)
 Function that returns an existing file selected by the user. More...
 
QVariant getSaveFileName (String &filter=String::null, String &title=String::null, QWidget *parent=0)
 Function that will return a file name selected by the user. More...
 
QVariant getExistingDirectory (String &dir=String::null, String &title=String::null, QWidget *parent=0)
 Function that will return an existing directory selected by the user. More...
 
StringList getOpenFileNames (String &dir=String::null, String &filter=String::null, String &title=String::null, QWidget *parent=0)
 Function that will return one or more existing files selected by the user. More...
 

Detailed Description

The FileDialog JavaScript global object. A simplified version of the Qt file dialogs.

Member Function Documentation

◆ getExistingDirectory

QVariant FileDialog::getExistingDirectory ( String &  dir = String::null,
String &  title = String::null,
QWidget *  parent = 0 
)
slot

Function that will return an existing directory selected by the user.

Parameters
dir: The directory to open the file dialog to.
title: The title for the file dialog.
parent: Unused.
Returns
The path to the selected directory.

◆ getOpenFileName

QVariant FileDialog::getOpenFileName ( String &  filter = String::null,
String &  title = String::null,
QWidget *  parent = 0 
)
slot

Function that returns an existing file selected by the user.

Parameters
filter: The filter for which files to select.
title: The title for the file dialog.
parent: Unused.
Returns
The path to the file selected by the user.

◆ getOpenFileNames

StringList FileDialog::getOpenFileNames ( String &  dir = String::null,
String &  filter = String::null,
String &  title = String::null,
QWidget *  parent = 0 
)
slot

Function that will return one or more existing files selected by the user.

Parameters
dir: The directory to open the file dialog to.
filter: The filter for which files to select.
title: The title for the file dialog.
parent: Unused.
Returns
An array of paths for the selected files.

◆ getSaveFileName

QVariant FileDialog::getSaveFileName ( String &  filter = String::null,
String &  title = String::null,
QWidget *  parent = 0 
)
slot

Function that will return a file name selected by the user.

Parameters
filter: The filter for which files to select.
title: The title for the file dialog.
parent: Unused.
Returns
The path to where the file is saved.