Defines a component for choosing a file or directory. More...
#include <ResourceChooser.h>
Public Member Functions | |
QString | getSelectedResource () |
Returns the selected resource. More... | |
ResourceChooser (QWidget *parent=0) | |
Constructor. More... | |
void | setFilterPattern (const QString &filter) |
Setts a pattern for filtering the searched files. More... | |
~ResourceChooser () | |
Destructor. More... | |
Static Public Member Functions | |
static QString | getResource (const QString &initialPath, const QString &filter, QWidget *parent=0) |
use the static when the ResourceChooser have to be presented as a Dialog. More... | |
Protected Slots | |
void | setResource (int id) |
This is called when the user changes the type of resource to search. More... | |
Protected Attributes | |
FileChooser * | m_fchooser |
File chooser component. More... | |
Defines a component for choosing a file or directory.
This class is used for choosing a file or a directory. Its also possible to inform the file extensions to be searched. This way the client can change the filter for the files to be listed when searching. The component is composed of a line edit containing the complete path of the file or directory selected and a tool button used to open de choose file / directory dialog.
Definition at line 51 of file ResourceChooser.h.
te::qt::widgets::ResourceChooser::ResourceChooser | ( | QWidget * | parent = 0 | ) |
Constructor.
te::qt::widgets::ResourceChooser::~ResourceChooser | ( | ) |
Destructor.
|
static |
use the static when the ResourceChooser have to be presented as a Dialog.
initialPath | |
parent |
QString te::qt::widgets::ResourceChooser::getSelectedResource | ( | ) |
Returns the selected resource.
void te::qt::widgets::ResourceChooser::setFilterPattern | ( | const QString & | filter | ) |
Setts a pattern for filtering the searched files.
This class uses internally the FileChooser component. For more details about on how define filter pattern see its documentation.
filter | Pattern to be applied. |
|
protectedslot |
This is called when the user changes the type of resource to search.
id |
|
protected |
File chooser component.
Definition at line 98 of file ResourceChooser.h.