diff options
author | Tobias Hunger <tobias.hunger@qt.io> | 2019-04-16 16:32:08 +0200 |
---|---|---|
committer | Tobias Hunger <tobias.hunger@qt.io> | 2019-04-16 16:32:08 +0200 |
commit | 6630937e63ae5797487b86743a7733c8ae5cc42c (patch) | |
tree | 3d53dacf6430f9099e1fb20835881205de674961 /examples/widgets/doc/src/addressbook.qdoc | |
parent | 37ed6dae00640f9cc980ffda05347c12a7eb5d7e (diff) | |
parent | c7af193d2e49e9f10b86262e63d8d13abf72b5cf (diff) | |
download | qtbase-6630937e63ae5797487b86743a7733c8ae5cc42c.tar.gz |
Merge commit 'dev' into 'wip/cmake-merge'
Change-Id: I176c40d031be26a1dd1cf08843e448a660598783
Diffstat (limited to 'examples/widgets/doc/src/addressbook.qdoc')
-rw-r--r-- | examples/widgets/doc/src/addressbook.qdoc | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/examples/widgets/doc/src/addressbook.qdoc b/examples/widgets/doc/src/addressbook.qdoc index 1fa0bfa9d4..e5e7fe5c2c 100644 --- a/examples/widgets/doc/src/addressbook.qdoc +++ b/examples/widgets/doc/src/addressbook.qdoc @@ -90,8 +90,8 @@ \snippet itemviews/addressbook/tablemodel.h 0 Two constructors are used, a default constructor which uses - \c TableModel's own \c {QList<Contact>} and one that takes - \c {QList<Contact>} as an argument, for convenience. + \c TableModel's own \c {QVector<Contact>} and one that takes + \c {QVector<Contact>} as an argument, for convenience. \section1 TableModel Class Implementation @@ -108,9 +108,6 @@ \c columnCount()'s value is always 2 because we only need space for the \b Name and \b Address columns. - \note The \c Q_UNUSED() macro prevents the compiler from - generating warnings regarding unused parameters. - \snippet itemviews/addressbook/tablemodel.cpp 1 The \c data() function returns either a \b Name or @@ -164,7 +161,7 @@ them here so that we can reuse the model in other programs. The last function in \c {TableModel}, \c getContacts() returns the - QList<Contact> object that holds all the contacts in the address + QVector<Contact> object that holds all the contacts in the address book. We use this function later to obtain the list of contacts to check for existing entries, write the contacts to a file and read them back. Further explanation is given with \c AddressWidget. @@ -233,7 +230,7 @@ \image addressbook-signals.png Signals and Slots Connections - We provide 2 \c addEntry() functions: 1 which is intended to be + We provide two \c addEntry() functions: One which is intended to be used to accept user input, and the other which performs the actual task of adding new entries to the address book. We divide the responsibility of adding entries into two parts to allow |