Skip to content

Commit

Permalink
Windows: Silence warning in QWindowsFileDialogHelper::selectFile().
Browse files Browse the repository at this point in the history
The function is invoked from the QFileDialog constructor in
save file mode when passing a non-existing file.

Task-number: QTBUG-35703

Change-Id: I5c13efb9b6789404b28739f6ce88ed87b594b6e4
Reviewed-by: Joerg Bornemann <[email protected]>
  • Loading branch information
Friedemann Kleint authored and The Qt Project committed Jan 9, 2014
1 parent 131a511 commit b4c2885
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/plugins/platforms/windows/qwindowsdialoghelpers.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1633,8 +1633,8 @@ void QWindowsFileDialogHelper::selectFile(const QUrl &fileName)
if (QWindowsContext::verboseDialogs)
qDebug("%s %s" , __FUNCTION__, qPrintable(fileName.toString()));

if (QWindowsNativeFileDialogBase *nfd = nativeFileDialog())
nfd->selectFile(fileName.toLocalFile()); // ## should use QUrl::fileName() once it exists
if (hasNativeDialog()) // Might be invoked from the QFileDialog constructor.
nativeFileDialog()->selectFile(fileName.toLocalFile()); // ## should use QUrl::fileName() once it exists
}

QList<QUrl> QWindowsFileDialogHelper::selectedFiles() const
Expand Down

0 comments on commit b4c2885

Please sign in to comment.