UTPassMirror/qml/pages/headers/MainHeader.qml
2019-03-16 09:02:12 +01:00

41 lines
1.1 KiB
QML

import QtQuick 2.4
import Ubuntu.Components 1.3
PageHeader {
id: mainHeader
width: parent.width
height: units.gu(6)
title: i18n.tr("UTPass")
trailingActionBar.height: units.gu(4)
trailingActionBar.numberOfSlots: 2
trailingActionBar.actions: [
Action {
iconName: "search"
text: i18n.tr("Search")
onTriggered: {
mainHeader.contents = TextField {
id: searchBar
placeholderText: i18n.tr("Search")
height: units.gu(4)
visible: false
anchors.verticalCenter: parent.verticalCenter
}
}
},
Action {
iconName: "settings"
text: i18n.tr("Settings")
onTriggered: {
pageStack.push(Qt.resolvedUrl("../Settings.qml"))
}
},
Action {
iconName: "info"
text: i18n.tr("Info")
onTriggered: {
pageStack.push(Qt.resolvedUrl("../Info.qml"))
}
}
]
}