on xenial help sign in
s/avatar/mascot/
commit6bd97f8ba495b1d7c529024adf2e92a887c5263e authorMichał Sawicz <michal.sawicz@canonical.com> dateFri 6 Dec 2013, 15:45 (13 years ago) parent767338a
2 files changed+11−11
Dash/CardHeader.qml+6−6 tests/qmltests/Dash/tst_CardHeader.qml+5−5
Dash/CardHeader.qml+6−6
@@ -3,14 +3,14 @@ import Ubuntu.Components 0.1
33
44Item {
55 id: root
6− property alias mascot: avatarImage.source
6+ property alias mascot: mascotImage.source
77 property alias title: titleLabel.text
88 property alias subtitle: subtitleLabel.text
99 property alias price: priceLabel.text
1010 property alias oldPrice: oldPriceLabel.text
1111 property alias altPrice: altPriceLabel.text
1212
13− visible: avatarImage.status === Image.Ready || title || price
13+ visible: mascotImage.status === Image.Ready || title || price
1414 height: row.height > 0 ? row.height + row.spacing * 2 : 0
1515
1616 Row {
@@ -20,16 +20,16 @@ Item {
2020 spacing: units.gu(1)
2121
2222 UbuntuShape {
23− id: avatarShape
24− objectName: "avatarShape"
23+ id: mascotShape
24+ objectName: "mascotShape"
2525
2626 width: units.gu(8)
2727 height: units.gu(8)
2828 visible: image.status === Image.Ready
2929
3030 image: Image {
31− id: avatarImage
32− sourceSize { width: avatarShape.width; height: avatarShape.height }
31+ id: mascotImage
32+ sourceSize { width: mascotShape.width; height: mascotShape.height }
3333 }
3434 }
3535
tests/qmltests/Dash/tst_CardHeader.qml+5−5
@@ -26,14 +26,14 @@ Rectangle {
2626
2727 when: windowShown
2828
29− property Item avatar: findChild(cardHeader, "avatarShape")
29+ property Item mascot: findChild(cardHeader, "mascotShape")
3030 property Item titleLabel: findChild(cardHeader, "titleLabel")
3131 property Item subtitleLabel: findChild(cardHeader, "subtitleLabel")
3232 property Item prices: findChild(cardHeader, "prices")
3333 property Item oldPriceLabel: findChild(cardHeader, "oldPriceLabel")
3434
3535 function initTestCase() {
36− verify(testCase.avatar !== undefined, "Couldn't find avatar object.");
36+ verify(testCase.mascot !== undefined, "Couldn't find mascot object.");
3737 verify(testCase.titleLabel !== undefined, "Couldn't find titleLabel object.");
3838 verify(testCase.subtitleLabel !== undefined, "Couldn't find subtitleLabel object.");
3939 verify(testCase.prices !== undefined, "Couldn't find prices object.");
@@ -49,7 +49,7 @@ Rectangle {
4949 cardHeader.altPrice = "";
5050 }
5151
52− function test_avatar_data() {
52+ function test_mascot_data() {
5353 return [
5454 { tag: "Empty", source: "", visible: false },
5555 { tag: "Invalid", source: "bad_path", visible: false },
@@ -57,9 +57,9 @@ Rectangle {
5757 ]
5858 }
5959
60− function test_avatar(data) {
60+ function test_mascot(data) {
6161 cardHeader.mascot = data.source;
62− tryCompare(testCase.avatar, "visible", data.visible);
62+ tryCompare(testCase.mascot, "visible", data.visible);
6363 }
6464
6565 function test_labels_data() {