aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorJ-P Nurmi <jpnurmi@digia.com>2013-09-20 09:58:06 +0200
committerThe Qt Project <gerrit-noreply@qt-project.org>2013-09-20 19:00:55 +0200
commita0a41735b9aa51142c57fa97eb147c560db736f8 (patch)
tree6da03b29f88f346cc5af09887bbbf02223114c91 /src
parent0eade30f37980c38b14d5cfa475837d15b69a8c5 (diff)
QWinJumpListCategory: fix initialization of member variables
The pDocList member was left uninitialized when not using QWinJumpListCategoryPrivate::create(). Change-Id: I3c443eaf00b8680d76cad710b2bdb8febb451ec7 Reviewed-by: Ivan Vizir <define-true-false@yandex.com> Reviewed-by: J-P Nurmi <jpnurmi@digia.com>
Diffstat (limited to 'src')
-rw-r--r--src/winextras/qwinjumplistcategory.cpp8
-rw-r--r--src/winextras/qwinjumplistcategory_p.h2
2 files changed, 7 insertions, 3 deletions
diff --git a/src/winextras/qwinjumplistcategory.cpp b/src/winextras/qwinjumplistcategory.cpp
index 424f1e4..bab65ca 100644
--- a/src/winextras/qwinjumplistcategory.cpp
+++ b/src/winextras/qwinjumplistcategory.cpp
@@ -72,6 +72,11 @@ QT_BEGIN_NAMESPACE
A jump list category of tasks.
*/
+QWinJumpListCategoryPrivate::QWinJumpListCategoryPrivate() :
+ visible(false), jumpList(0), type(QWinJumpListCategory::Custom), pDocList(0)
+{
+}
+
QWinJumpListCategory *QWinJumpListCategoryPrivate::create(QWinJumpListCategory::Type type, QWinJumpList *jumpList)
{
QWinJumpListCategory *category = new QWinJumpListCategory;
@@ -130,9 +135,6 @@ void QWinJumpListCategoryPrivate::clearRecents()
QWinJumpListCategory::QWinJumpListCategory(const QString &title) :
d_ptr(new QWinJumpListCategoryPrivate)
{
- d_ptr->pDocList = 0;
- d_ptr->type = Custom;
- d_ptr->visible = false;
d_ptr->title = title;
}
diff --git a/src/winextras/qwinjumplistcategory_p.h b/src/winextras/qwinjumplistcategory_p.h
index 6aa23ba..d49c6f6 100644
--- a/src/winextras/qwinjumplistcategory_p.h
+++ b/src/winextras/qwinjumplistcategory_p.h
@@ -53,6 +53,8 @@ class QWinJumpList;
class QWinJumpListCategoryPrivate
{
public:
+ QWinJumpListCategoryPrivate();
+
static QWinJumpListCategoryPrivate *get(QWinJumpListCategory *category)
{
return category->d_func();