6#include <QtCore/qlist.h>
95 if (
mode == m_fileMode)
134 return addDefaultSuffix(m_files.
value(0));
157 return addDefaultSuffixes(m_files);
162 if (m_files ==
files)
207 return fileDialog->selectedFiles();
215 fileDialog->selectFile(
file);
231 return fileDialog->directory();
238 fileDialog->setDirectory(
folder);
310 if (m_selectedNameFilter) {
312 if (index < 0 || index >=
filters.size())
369 if (!m_selectedNameFilter) {
374 return m_selectedNameFilter;
481 fileDialog->setOptions(m_options);
489 fileDialog->setOptions(m_options);
492 if (m_selectedNameFilter) {
493 const int index = m_selectedNameFilter->
index();
496 fileDialog->selectNameFilter(
filter);
507 if (m_selectedNameFilter)
515 setFiles(fileDialog->selectedFiles());
519QUrl QQuickLabsPlatformFileDialog::addDefaultSuffix(
const QUrl &
file)
const
526 const bool isContentScheme =
url.
scheme() == u
"content"_s;
539 urls += addDefaultSuffix(
file);
555 if (m_index ==
index)
597 if (from >= 0 && from < to) {
611 const int oldIndex = m_index;
612 const QString oldName = m_name;
619 if (oldIndex != m_index)
621 if (oldName != m_name)
623 if (oldExtensions != m_extensions)
627QStringList QQuickLabsPlatformFileNameFilter::nameFilters()
const
632QString QQuickLabsPlatformFileNameFilter::nameFilter(
int index)
const
639#include "moc_qquicklabsplatformfiledialog_p.cpp"
QList< QUrl > initiallySelectedFiles() const
void setWindowTitle(const QString &)
QString labelText(DialogLabel label) const
void setNameFilters(const QStringList &filters)
void setOptions(FileDialogOptions options)
QString defaultSuffix() const
void setInitiallySelectedNameFilter(const QString &)
QUrl initialDirectory() const
QStringList nameFilters() const
FileDialogOptions options() const
void setLabelText(DialogLabel label, const QString &text)
void setFileMode(FileMode mode)
void setAcceptMode(AcceptMode mode)
void setInitialDirectory(const QUrl &)
bool testOption(FileDialogOption option) const
void setDefaultSuffix(const QString &suffix)
void setInitiallySelectedFiles(const QList< QUrl > &)
qsizetype size() const noexcept
T value(qsizetype i) const
void reserve(qsizetype size)
static QMetaObject::Connection connect(const QObject *sender, const char *signal, const QObject *receiver, const char *member, Qt::ConnectionType=Qt::AutoConnection)
\threadsafe
constexpr QStringView mid(qsizetype pos, qsizetype n=-1) const noexcept
Returns the substring of length length starting at position start in this object.
\macro QT_RESTRICTED_CAST_FROM_ASCII
QString mid(qsizetype position, qsizetype n=-1) const
Returns a string that contains n characters of this string, starting at the specified position index.
bool isEmpty() const
Returns true if the string has no characters; otherwise returns false.
QString left(qsizetype n) const
Returns a substring that contains the n leftmost characters of the string.
bool isValid() const
Returns true if the URL is non-empty and valid; otherwise returns false.
QString scheme() const
Returns the scheme of the URL.
void setPath(const QString &path, ParsingMode mode=DecodedMode)
Sets the path of the URL to path.
QString path(ComponentFormattingOptions options=FullyDecoded) const
Returns the path of the URL.
Combined button and popup list for selecting options.
SharedPointerFileDialogOptions m_options
QStringList * m_selectedNameFilter
GLuint GLsizei const GLchar * label
[43]
GLint GLint GLint GLint GLint GLint GLint GLbitfield GLenum filter
GLsizei const GLchar *const * path
QUrl url("example.com")
[constructor-url-reference]
myObject disconnect()
[26]
QFileDialog dialog(this)
[1]
const QStringList filters({"Image files (*.png *.xpm *.jpg)", "Text files (*.txt)", "Any files (*)" })
[6]
\inmodule QtCore \reentrant
IUIAutomationTreeWalker __RPC__deref_out_opt IUIAutomationElement ** parent