diff options
author | Kavindra Devi Palaraja <kavindra.palaraja@nokia.com> | 2009-07-06 13:33:10 (GMT) |
---|---|---|
committer | Kavindra Devi Palaraja <kavindra.palaraja@nokia.com> | 2009-07-06 13:33:34 (GMT) |
commit | ba25bdcb9122d45ccdd06f281a5f49999eaff089 (patch) | |
tree | 26394400e7fc164c286fb86124ec3329fe7f3d8d /doc/src | |
parent | 8a72074b0ab146942512b37439ffc8618e3f7d06 (diff) | |
download | Qt-ba25bdcb9122d45ccdd06f281a5f49999eaff089.zip Qt-ba25bdcb9122d45ccdd06f281a5f49999eaff089.tar.gz Qt-ba25bdcb9122d45ccdd06f281a5f49999eaff089.tar.bz2 |
Doc - beautified some of the existing sentences in Part 6
Reviewed-By: TrustMe
Diffstat (limited to 'doc/src')
-rw-r--r-- | doc/src/tutorials/addressbook.qdoc | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/doc/src/tutorials/addressbook.qdoc b/doc/src/tutorials/addressbook.qdoc index 33832da..95394eb 100644 --- a/doc/src/tutorials/addressbook.qdoc +++ b/doc/src/tutorials/addressbook.qdoc @@ -876,7 +876,7 @@ \image addressbook-tutorial-part6-save.png - If \c fileName is not empty, we create a QFile object, \c file with + If \c fileName is not empty, we create a QFile object, \c file, with \c fileName. QFile works with QDataStream as QFile is a QIODevice. Next, we attempt to open the file in \l{QIODevice::}{WriteOnly} mode. @@ -906,18 +906,18 @@ \image addressbook-tutorial-part6-load.png If \c fileName is not empty, again, we use a QFile object, \c file, and - attempt to open it in \l{QIODevice::}{ReadOnly} mode. In a similar way - to our implementation of \c saveToFile(), if this attempt is unsuccessful, - we display a QMessageBox to inform the user. + attempt to open it in \l{QIODevice::}{ReadOnly} mode. Similar to our + implementation of \c saveToFile(), if this attempt is unsuccessful, we + display a QMessageBox to inform the user. \snippet tutorials/addressbook/part6/addressbook.cpp loadFromFile() function part2 Otherwise, we instantiate a QDataStream object, \c in, set its version as above and read the serialized data into the \c contacts data structure. - Note that we empty \c contacts before reading data into it to simplify the - file reading process. A more advanced method would be to read the contacts - into temporary QMap object, and copy only the contacts that do not already - exist in \c contacts. + The \c contacts object is emptied before data is read into it to simplify + the file reading process. A more advanced method would be to read the + contacts into a temporary QMap object, and copy over non-duplicate contacts + into \c contacts. \snippet tutorials/addressbook/part6/addressbook.cpp loadFromFile() function part3 |