summaryrefslogtreecommitdiff
path: root/src/controls/Tab.qml
diff options
context:
space:
mode:
authorJ-P Nurmi <jpnurmi@digia.com>2013-04-30 14:18:03 +0200
committerThe Qt Project <gerrit-noreply@qt-project.org>2013-05-07 14:32:46 +0200
commita6deb27ba0252bc06fd6f28fb76b552e6320853f (patch)
tree1eaadd966e87d195c7113d4332c21443cd9e7cdc /src/controls/Tab.qml
parentbb7e55b798a3e75d4ccb2d1e4c9c9705bcb1c4d8 (diff)
downloadqtquickcontrols-a6deb27ba0252bc06fd6f28fb76b552e6320853f.tar.gz
Fix TabView not to insert duplicate tabs
There are three ways to add tabs: - declare 'static' Tab { } child elements - call addTab() / insertTab() - Component::createObject(tabView) => Do not rely on the calling order of Component.onCompleted() and make sure that the same tabs are not accidentally re-inserted. Task-number: QTBUG-30873 Change-Id: Ib30cfb676debbb302c5e9f7d757f66aab6fcc684 Reviewed-by: Caroline Chao <caroline.chao@digia.com>
Diffstat (limited to 'src/controls/Tab.qml')
-rw-r--r--src/controls/Tab.qml4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/controls/Tab.qml b/src/controls/Tab.qml
index 0f88e238..0cf26341 100644
--- a/src/controls/Tab.qml
+++ b/src/controls/Tab.qml
@@ -57,6 +57,10 @@ Loader {
/*! This property holds the title of the tab. */
property string title
+
+ /*! \internal */
+ property bool __inserted: false
+
Accessible.role: Accessible.LayeredPane
active: false
visible: false