Commit d9e55e40 authored by Friedemann Kleint's avatar Friedemann Kleint
Browse files

QFileDialogPrivate: Move inline to declaration

Fixes MSVC warning:

src/widgets/dialogs/qfiledialog_p.h(412): warning C4273: 'QFileDialogPrivate::selectedMimeTypeFilter_sys': inconsistent dll linkage

while building tst_qfiledialog2.

Amends change 34f82b8a

.

Change-Id: I7306535000af73ee3a027b14a2d5cfce4f889e85
Reviewed-by: Marc Mutz's avatarMarc Mutz <marc.mutz@kdab.com>
parent b5883a16
......@@ -253,15 +253,15 @@ public:
bool canBeNativeDialog() const Q_DECL_OVERRIDE;
inline bool usingWidgets() const;
void setDirectory_sys(const QUrl &directory);
QUrl directory_sys() const;
void selectFile_sys(const QUrl &filename);
QList<QUrl> selectedFiles_sys() const;
void setFilter_sys();
void selectMimeTypeFilter_sys(const QString &filter);
QString selectedMimeTypeFilter_sys() const;
void selectNameFilter_sys(const QString &filter);
QString selectedNameFilter_sys() const;
inline void setDirectory_sys(const QUrl &directory);
inline QUrl directory_sys() const;
inline void selectFile_sys(const QUrl &filename);
inline QList<QUrl> selectedFiles_sys() const;
inline void setFilter_sys();
inline void selectMimeTypeFilter_sys(const QString &filter);
inline QString selectedMimeTypeFilter_sys() const;
inline void selectNameFilter_sys(const QString &filter);
inline QString selectedNameFilter_sys() const;
//////////////////////////////////////////////
QScopedPointer<Ui_QFileDialog> qFileDialogUi;
......@@ -341,14 +341,14 @@ private:
QFileDialogPrivate *d_ptr;
};
inline QModelIndex QFileDialogPrivate::mapToSource(const QModelIndex &index) const {
QModelIndex QFileDialogPrivate::mapToSource(const QModelIndex &index) const {
#ifdef QT_NO_PROXYMODEL
return index;
#else
return proxyModel ? proxyModel->mapToSource(index) : index;
#endif
}
inline QModelIndex QFileDialogPrivate::mapFromSource(const QModelIndex &index) const {
QModelIndex QFileDialogPrivate::mapFromSource(const QModelIndex &index) const {
#ifdef QT_NO_PROXYMODEL
return index;
#else
......@@ -356,11 +356,12 @@ inline QModelIndex QFileDialogPrivate::mapFromSource(const QModelIndex &index) c
#endif
}
inline QString QFileDialogPrivate::rootPath() const {
QString QFileDialogPrivate::rootPath() const
{
return (model ? model->rootPath() : QStringLiteral("/"));
}
inline void QFileDialogPrivate::setDirectory_sys(const QUrl &directory)
void QFileDialogPrivate::setDirectory_sys(const QUrl &directory)
{
QPlatformFileDialogHelper *helper = platformFileDialogHelper();
......@@ -371,14 +372,14 @@ inline void QFileDialogPrivate::setDirectory_sys(const QUrl &directory)
helper->setDirectory(directory);
}
inline QUrl QFileDialogPrivate::directory_sys() const
QUrl QFileDialogPrivate::directory_sys() const
{
if (QPlatformFileDialogHelper *helper = platformFileDialogHelper())
return helper->directory();
return QUrl();
}
inline void QFileDialogPrivate::selectFile_sys(const QUrl &filename)
void QFileDialogPrivate::selectFile_sys(const QUrl &filename)
{
QPlatformFileDialogHelper *helper = platformFileDialogHelper();
......@@ -389,20 +390,20 @@ inline void QFileDialogPrivate::selectFile_sys(const QUrl &filename)
helper->selectFile(filename);
}
inline QList<QUrl> QFileDialogPrivate::selectedFiles_sys() const
QList<QUrl> QFileDialogPrivate::selectedFiles_sys() const
{
if (QPlatformFileDialogHelper *helper = platformFileDialogHelper())
return helper->selectedFiles();
return QList<QUrl>();
}
inline void QFileDialogPrivate::setFilter_sys()
void QFileDialogPrivate::setFilter_sys()
{
if (QPlatformFileDialogHelper *helper = platformFileDialogHelper())
helper->setFilter();
}
inline void QFileDialogPrivate::selectMimeTypeFilter_sys(const QString &filter)
void QFileDialogPrivate::selectMimeTypeFilter_sys(const QString &filter)
{
if (QPlatformFileDialogHelper *helper = platformFileDialogHelper())
helper->selectMimeTypeFilter(filter);
......@@ -416,13 +417,13 @@ QString QFileDialogPrivate::selectedMimeTypeFilter_sys() const
return QString();
}
inline void QFileDialogPrivate::selectNameFilter_sys(const QString &filter)
void QFileDialogPrivate::selectNameFilter_sys(const QString &filter)
{
if (QPlatformFileDialogHelper *helper = platformFileDialogHelper())
helper->selectNameFilter(filter);
}
inline QString QFileDialogPrivate::selectedNameFilter_sys() const
QString QFileDialogPrivate::selectedNameFilter_sys() const
{
if (QPlatformFileDialogHelper *helper = platformFileDialogHelper())
return helper->selectedNameFilter();
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment