summaryrefslogtreecommitdiffstats
path: root/examples/widgets/doc
diff options
context:
space:
mode:
authorChristian Ehrlicher <ch.ehrlicher@gmx.de>2018-11-23 20:05:42 +0100
committerChristian Ehrlicher <ch.ehrlicher@gmx.de>2019-01-23 15:13:41 +0000
commitc590aa678d5c27162b0ca7191fa76b1d3a112767 (patch)
treee62a34cee93a761f267347dd2df530832811a21a /examples/widgets/doc
parent7cc6f78dd448992c9a9cb31e001b908d44028516 (diff)
Cleanup SimpleTreeModel example
Cleanup the SimpleTreeModel example: - include own headers first - use nullptr - add sanity checks Change-Id: If57d608e3919368b2022ff86aede8de9c2ba7369 Reviewed-by: Luca Beldi <v.ronin@yahoo.it> Reviewed-by: Sze Howe Koh <szehowe.koh@gmail.com>
Diffstat (limited to 'examples/widgets/doc')
-rw-r--r--examples/widgets/doc/src/simpletreemodel.qdoc5
1 files changed, 2 insertions, 3 deletions
diff --git a/examples/widgets/doc/src/simpletreemodel.qdoc b/examples/widgets/doc/src/simpletreemodel.qdoc
index a50197b04d..f5fe93897c 100644
--- a/examples/widgets/doc/src/simpletreemodel.qdoc
+++ b/examples/widgets/doc/src/simpletreemodel.qdoc
@@ -170,9 +170,8 @@
\snippet itemviews/simpletreemodel/treeitem.cpp 5
- Column data is returned by the \c data() function, taking advantage of
- QList's ability to provide sensible default values if the column number
- is out of range:
+ Column data is returned by the \c data() function. The bounds are checked
+ before accessing the container with the data:
\snippet itemviews/simpletreemodel/treeitem.cpp 6