From dd60bef7c93a09a92228574bade084d520e711f9 Mon Sep 17 00:00:00 2001 From: Alan Alpert Date: Thu, 27 Aug 2009 18:16:53 +1000 Subject: Flickr tweak for more generic components Using TitleBar in twitter too, this slight change prevents a copy of the whole component. --- demos/declarative/flickr/mobile/TitleBar.qml | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/demos/declarative/flickr/mobile/TitleBar.qml b/demos/declarative/flickr/mobile/TitleBar.qml index 6d655a6..49d670f 100644 --- a/demos/declarative/flickr/mobile/TitleBar.qml +++ b/demos/declarative/flickr/mobile/TitleBar.qml @@ -3,6 +3,8 @@ import Qt 4.6 Item { id: TitleBar + property string untaggedString: "Uploads from everyone" + property string taggedString: "Recent uploads tagged " BorderImage { source: "images/titlebar2.sci"; width: parent.width; height: parent.height + 14; y: -7 } Item { @@ -22,13 +24,14 @@ Item { anchors.leftMargin: 10; anchors.rightMargin: 10 anchors.verticalCenter: parent.verticalCenter elide: "ElideLeft" - text: (RssModel.tags=="" ? "Uploads from everyone" : "Recent Uploads tagged " + RssModel.tags) + text: (RssModel.tags=="" ? untaggedString : taggedString + RssModel.tags) font.bold: true; color: "white"; style: "Raised"; styleColor: "black" } Button { - id: TagButton; x: TitleBar.width - 50; y: 3; width: 45; height: 32; text: "..." + id: TagButton; x: TitleBar.width - 50; width: 45; height: 32; text: "..." onClicked: if (TitleBar.state == "Tags") accept(); else TitleBar.state = "Tags" + anchors.verticalCenter: parent.verticalCenter } Item { -- cgit v0.12