From b9b320d01c89ac2dca1726e0f95d0c8f74437b7f Mon Sep 17 00:00:00 2001 From: Zach Fox Date: Fri, 31 May 2019 11:43:13 -0700 Subject: [PATCH] DEV-92: Add a Home button to the Avatar app --- .../hifi/simplifiedUI/avatarApp/AvatarApp.qml | 21 +++++++++++++++++++ .../avatarApp/images/homeIcon.svg | 4 ++++ 2 files changed, 25 insertions(+) create mode 100644 interface/resources/qml/hifi/simplifiedUI/avatarApp/images/homeIcon.svg diff --git a/interface/resources/qml/hifi/simplifiedUI/avatarApp/AvatarApp.qml b/interface/resources/qml/hifi/simplifiedUI/avatarApp/AvatarApp.qml index d6ee593edd..b7186b885c 100644 --- a/interface/resources/qml/hifi/simplifiedUI/avatarApp/AvatarApp.qml +++ b/interface/resources/qml/hifi/simplifiedUI/avatarApp/AvatarApp.qml @@ -99,6 +99,27 @@ Rectangle { } } + Image { + id: homeButton + source: "images/homeIcon.svg" + opacity: homeButtonMouseArea.containsMouse ? 1.0 : 0.7 + anchors.top: parent.top + anchors.topMargin: 15 + anchors.right: parent.right + anchors.rightMargin: 24 + width: 14 + height: 13 + + MouseArea { + id: homeButtonMouseArea + anchors.fill: parent + hoverEnabled: true + onClicked: { + Window.location = LocationBookmarks.getHomeLocationAddress(); + } + } + } + AvatarAppComponents.DisplayNameHeader { id: displayNameHeader previewUrl: root.avatarPreviewUrl diff --git a/interface/resources/qml/hifi/simplifiedUI/avatarApp/images/homeIcon.svg b/interface/resources/qml/hifi/simplifiedUI/avatarApp/images/homeIcon.svg new file mode 100644 index 0000000000..1aae14e2dd --- /dev/null +++ b/interface/resources/qml/hifi/simplifiedUI/avatarApp/images/homeIcon.svg @@ -0,0 +1,4 @@ + + + +