mirror of
https://github.com/QRouland/UTPass.git
synced 2024-12-22 01:42:39 +00:00
Add search bar
This commit is contained in:
parent
16f8f70692
commit
7458507c9b
@ -8,7 +8,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: utpass.qrouland\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2019-03-15 17:28+0000\n"
|
||||
"POT-Creation-Date: 2019-03-16 09:07+0000\n"
|
||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
@ -17,8 +17,9 @@ msgstr ""
|
||||
"Content-Type: text/plain; charset=CHARSET\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
|
||||
#: ../qml/pages/Settings.qml:8 ../qml/pages/headers/MainHeader.qml:28
|
||||
msgid "Settings"
|
||||
#: ../qml/components/Search.qml:6 ../qml/pages/headers/MainHeader.qml:23
|
||||
#: ../qml/pages/headers/MainHeader.qml:36
|
||||
msgid "Search"
|
||||
msgstr ""
|
||||
|
||||
#: ../qml/pages/PasswordList.qml:17
|
||||
@ -29,20 +30,19 @@ msgstr ""
|
||||
msgid "No password found in the current folder"
|
||||
msgstr ""
|
||||
|
||||
#: ../qml/pages/Info.qml:9 ../qml/pages/headers/MainHeader.qml:35
|
||||
msgid "Info"
|
||||
#: ../qml/pages/Settings.qml:8 ../qml/pages/headers/MainHeader.qml:44
|
||||
msgid "Settings"
|
||||
msgstr ""
|
||||
|
||||
#: ../qml/pages/Info.qml:43 ../qml/pages/headers/MainHeader.qml:8
|
||||
#: ../qml/pages/headers/StackHeader.qml:7 UTPass.desktop.in.h:1
|
||||
#: ../qml/pages/headers/MainHeader.qml:8 ../qml/pages/headers/StackHeader.qml:8
|
||||
#: ../qml/pages/Info.qml:43 UTPass.desktop.in.h:1
|
||||
msgid "UTPass"
|
||||
msgstr ""
|
||||
|
||||
#: ../qml/pages/headers/MainHeader.qml:51 ../qml/pages/Info.qml:9
|
||||
msgid "Info"
|
||||
msgstr ""
|
||||
|
||||
#: ../qml/pages/Info.qml:53
|
||||
msgid "Suggest improvement(s) or report a bug(s)"
|
||||
msgstr ""
|
||||
|
||||
#: ../qml/pages/headers/MainHeader.qml:15
|
||||
#: ../qml/pages/headers/MainHeader.qml:19
|
||||
msgid "Search"
|
||||
msgstr ""
|
||||
|
12
qml/components/Search.qml
Normal file
12
qml/components/Search.qml
Normal file
@ -0,0 +1,12 @@
|
||||
import QtQuick 2.4
|
||||
|
||||
Item {
|
||||
TextField {
|
||||
id: searchBar
|
||||
placeholderText: i18n.tr("Search")
|
||||
height: units.gu(4)
|
||||
visible: false
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
}
|
||||
Component.onCompleted: ;
|
||||
}
|
@ -1,2 +1,3 @@
|
||||
FileDir 1.0 FileDir.qml
|
||||
Link 1.0 Link.qml
|
||||
Link 1.0 Link.qml
|
||||
Search 1.0 Search.qml
|
@ -7,6 +7,26 @@ PageHeader {
|
||||
height: units.gu(6)
|
||||
title: i18n.tr("UTPass")
|
||||
|
||||
contents: Item {
|
||||
height : parent.height
|
||||
width: parent.width
|
||||
Label {
|
||||
id : labelTitle
|
||||
text: mainHeader.title
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
visible: true
|
||||
}
|
||||
TextField {
|
||||
id: searchBar
|
||||
anchors.right : parent.right
|
||||
anchors.left : parent.left
|
||||
placeholderText: i18n.tr("Search")
|
||||
height: units.gu(4)
|
||||
visible: false
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
}
|
||||
}
|
||||
|
||||
trailingActionBar.height: units.gu(4)
|
||||
trailingActionBar.numberOfSlots: 2
|
||||
trailingActionBar.actions: [
|
||||
@ -14,13 +34,8 @@ PageHeader {
|
||||
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
|
||||
}
|
||||
searchBar.visible = searchBar.visible ? false : true;
|
||||
labelTitle.visible = labelTitle.visible ? false : true;
|
||||
}
|
||||
},
|
||||
Action {
|
||||
|
@ -2,10 +2,21 @@ import QtQuick 2.4
|
||||
import Ubuntu.Components 1.3
|
||||
|
||||
PageHeader {
|
||||
id: stackHeader
|
||||
width: parent.width
|
||||
height: units.gu(6)
|
||||
title: i18n.tr("UTPass")
|
||||
|
||||
contents: Item {
|
||||
height : parent.height
|
||||
width: parent.width
|
||||
Label {
|
||||
id : labelTitle
|
||||
text: stackHeader.title
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
}
|
||||
}
|
||||
|
||||
leadingActionBar.height: units.gu(4)
|
||||
leadingActionBar.actions: [
|
||||
Action {
|
||||
|
Loading…
Reference in New Issue
Block a user