use the checked property of TabButton

remotes/origin/KDE/4.10
Marco Martin 14 years ago
parent edf2019b84
commit f4a775ff69
  1. 17
      active/app/package/contents/ui/Browser.qml

@ -212,31 +212,30 @@ MobileComponents.OverlayDrawer {
id: thumbnailsButton
text: i18n("Thumbnails")
tab: thumbnails
property bool current: mainTabBar.currentTab == thumbnailsButton
onCurrentChanged: {
if (current) {
onCheckedChanged: {
if (checked) {
pageStack.replace(Qt.createComponent("Thumbnails.qml"))
}
}
}
PlasmaComponents.TabButton {
id: tocButton
//enabled:
text: i18n("Table of contents")
tab: tableOfContents
property bool current: mainTabBar.currentTab == tocButton
onCurrentChanged: {
if (current) {
onCheckedChanged: {
if (checked) {
pageStack.replace(Qt.createComponent("TableOfContents.qml"))
}
}
}
PlasmaComponents.TabButton {
id: bookmarksButton
enabled: documentItem.bookmarks.length > 0
text: i18n("Bookmarks")
tab: tableOfContents
property bool current: mainTabBar.currentTab == bookmarksButton
onCurrentChanged: {
if (current) {
onCheckedChanged: {
if (checked) {
pageStack.replace(Qt.createComponent("Bookmarks.qml"))
}
}

Loading…
Cancel
Save