diff options
author | Timur Pocheptsov <[email protected]> | 2017-09-29 13:57:43 +0200 |
---|---|---|
committer | Timur Pocheptsov <[email protected]> | 2017-10-05 03:45:26 +0000 |
commit | aeee3be166aff737990fe2cade05bff7b39dfebc (patch) | |
tree | d1e5a2085bd0df3cd204a4b0121e5178f1a61862 /examples/network/googlesuggest/searchbox.h | |
parent | 5b4cf7af6a492b6ef5b7c718b346b38ddad4c990 (diff) |
QtNetwork (examples) - update googlesuggest example
Mainly cosmetic - nullptr, explicit, QVector<QString> etc.
Plus: do not leak SearchBox.
Task-number: QTBUG-60628
Change-Id: I4c538ced64a469fbe4627f44d2d883e6dcd2362e
Reviewed-by: MÃ¥rten Nordheim <[email protected]>
Reviewed-by: Edward Welbourne <[email protected]>
Diffstat (limited to 'examples/network/googlesuggest/searchbox.h')
-rw-r--r-- | examples/network/googlesuggest/searchbox.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/examples/network/googlesuggest/searchbox.h b/examples/network/googlesuggest/searchbox.h index eea5854de84..fbd33011b7b 100644 --- a/examples/network/googlesuggest/searchbox.h +++ b/examples/network/googlesuggest/searchbox.h @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2016 The Qt Company Ltd. +** Copyright (C) 2017 The Qt Company Ltd. ** Contact: https://www.qt.io/licensing/ ** ** This file is part of the examples of the Qt Toolkit. @@ -61,13 +61,13 @@ class SearchBox: public QLineEdit Q_OBJECT public: - SearchBox(QWidget *parent = 0); + explicit SearchBox(QWidget *parent = nullptr); protected slots: void doSearch(); private: - GSuggestCompletion *completer; + GSuggestCompletion *completer = nullptr; //! [1] }; |