From 1a0859527f7ec56bc03884bcd5c2ad8e2a37e6f8 Mon Sep 17 00:00:00 2001 From: Anmol Gautam Date: Mon, 21 May 2018 10:25:18 +0530 Subject: [PATCH] Converted Q_INVOKABLE to Q_PROPERTY in QmlBookmarkTreeNode --- src/lib/plugins/qml/api/qmlbookmarktreenode.h | 28 +++++++++++++------ 1 file changed, 19 insertions(+), 9 deletions(-) diff --git a/src/lib/plugins/qml/api/qmlbookmarktreenode.h b/src/lib/plugins/qml/api/qmlbookmarktreenode.h index 4d83d5365..467994a66 100644 --- a/src/lib/plugins/qml/api/qmlbookmarktreenode.h +++ b/src/lib/plugins/qml/api/qmlbookmarktreenode.h @@ -36,15 +36,25 @@ public: Q_ENUMS(Type) - Q_INVOKABLE Type type() const; - Q_INVOKABLE QString title() const; - Q_INVOKABLE QString url() const; - Q_INVOKABLE QString description() const; - Q_INVOKABLE QString keyword() const; - Q_INVOKABLE int visitCount() const; - Q_INVOKABLE QmlBookmarkTreeNode *parent() const; - Q_INVOKABLE bool unmodifiable() const; - Q_INVOKABLE QList children() const; + Q_PROPERTY(Type type READ type CONSTANT) + Q_PROPERTY(QString title READ title CONSTANT) + Q_PROPERTY(QString url READ url CONSTANT) + Q_PROPERTY(QString description READ description CONSTANT) + Q_PROPERTY(QString keyword READ keyword CONSTANT) + Q_PROPERTY(int visitCount READ visitCount CONSTANT) + Q_PROPERTY(QmlBookmarkTreeNode* parent READ parent CONSTANT) + Q_PROPERTY(bool unmodifiable READ unmodifiable CONSTANT) + Q_PROPERTY(QList children READ children CONSTANT) + + Type type() const; + QString title() const; + QString url() const; + QString description() const; + QString keyword() const; + int visitCount() const; + QmlBookmarkTreeNode *parent() const; + bool unmodifiable() const; + QList children() const; static QmlBookmarkTreeNode *fromBookmarkItem(BookmarkItem *item);