From fb703aea697b12de4810deec9f8605fd062208bd Mon Sep 17 00:00:00 2001 From: Alessandro Portale Date: Tue, 23 Jul 2019 14:47:07 +0200 Subject: Docs: Fix the snippet lookup for QFileDialog::getOpenFileContent MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit src_gui_dialogs_qfiledialog.cpp had two snippets labeled "14". This change bumps one of them to "15" and fixes the the snippet lookup for QFileDialog::getOpenFileContent accordingly. Also, fix two typos: "QSting" -> "QString" and "contents has" -> "contents have". Change-Id: Ic018c23b6ca585f30c116b8a6eb29293560c7a35 Reviewed-by: Morten Johan Sørvig --- src/widgets/doc/snippets/code/src_gui_dialogs_qfiledialog.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/widgets/doc') diff --git a/src/widgets/doc/snippets/code/src_gui_dialogs_qfiledialog.cpp b/src/widgets/doc/snippets/code/src_gui_dialogs_qfiledialog.cpp index 1e9daf824b..39aca459db 100644 --- a/src/widgets/doc/snippets/code/src_gui_dialogs_qfiledialog.cpp +++ b/src/widgets/doc/snippets/code/src_gui_dialogs_qfiledialog.cpp @@ -145,8 +145,8 @@ dialog.exec(); "Images (*.png *.xpm *.jpg);;Text files (*.txt);;XML files (*.xml)" //! [14] -//! [14] -auto fileOpenCompleted = [](const QSting &fileName, const QByteArray &fileContent) { +//! [15] +auto fileOpenCompleted = [](const QString &fileName, const QByteArray &fileContent) { if (fileName.isEmpty()) { // No file was selected } else { @@ -154,4 +154,4 @@ auto fileOpenCompleted = [](const QSting &fileName, const QByteArray &fileConten } } QFileDialog::getOpenFileContent("Images (*.png *.xpm *.jpg)", fileContentReady); -//! [14] +//! [15] -- cgit v1.2.3