mirror of
https://thingvellir.net/git/overte
synced 2025-03-27 23:52:03 +01:00
More work on second launch UI
This commit is contained in:
parent
68f52584cf
commit
b25c874e5f
3 changed files with 59 additions and 53 deletions
|
@ -22,7 +22,6 @@ Rectangle {
|
|||
// TODO figure out why and fix
|
||||
color: "#ffffff"
|
||||
anchors.fill: parent
|
||||
z: 1
|
||||
|
||||
Component.onCompleted: {
|
||||
if (Settings.getValue("simplifiedUI/alreadyAutoSelectedAvatar", false)) {
|
||||
|
@ -38,7 +37,6 @@ Rectangle {
|
|||
anchors.left: parent.left
|
||||
anchors.top: parent.top
|
||||
source: "images/defaultTopLeft.png"
|
||||
z: 3
|
||||
}
|
||||
|
||||
Image {
|
||||
|
@ -48,7 +46,6 @@ Rectangle {
|
|||
anchors.right: parent.right
|
||||
anchors.bottom: parent.bottom
|
||||
source: "images/defaultBottomRight.png"
|
||||
z: 3
|
||||
}
|
||||
|
||||
Item {
|
||||
|
@ -76,7 +73,6 @@ Rectangle {
|
|||
text: "We know this isn't you..."
|
||||
color: "#000000"
|
||||
size: 48
|
||||
z: 2
|
||||
}
|
||||
|
||||
HifiStylesUit.RalewaySemiBold {
|
||||
|
@ -91,7 +87,6 @@ Rectangle {
|
|||
outfits! Available now on iOS and Android Platforms."
|
||||
color: "#000000"
|
||||
size: 24
|
||||
z: 2
|
||||
}
|
||||
|
||||
Item {
|
||||
|
@ -100,7 +95,6 @@ Rectangle {
|
|||
height: avatarAppQRCodeImage.height
|
||||
width: parent.width
|
||||
anchors.topMargin: 50
|
||||
z: 2
|
||||
|
||||
Image {
|
||||
id: avatarAppQRCodeImage
|
||||
|
@ -128,7 +122,7 @@ Rectangle {
|
|||
color: "#000000"
|
||||
opacity: continueMouseArea.containsMouse ? 1.0 : 0.7
|
||||
size: 36
|
||||
z: 2
|
||||
z: 1
|
||||
|
||||
MouseArea {
|
||||
id: continueMouseArea
|
||||
|
@ -151,8 +145,6 @@ Rectangle {
|
|||
// these don't change when the window resizes
|
||||
width: tempAvatarImage.width
|
||||
height: tempAvatarImage.height
|
||||
z: 1
|
||||
|
||||
|
||||
Image {
|
||||
id: tempAvatarImage
|
||||
|
@ -257,7 +249,7 @@ Rectangle {
|
|||
|
||||
onClicked: {
|
||||
Tablet.playSound(TabletEnums.ButtonClick);
|
||||
Print("GOOD GRIP CLICKED");
|
||||
print("GOOD GRIP CLICKED");
|
||||
sendToScript({
|
||||
"source": "InitialLaunchWindow.qml",
|
||||
"method": "closeInitialLaunchWindow"
|
||||
|
|
|
@ -23,8 +23,8 @@ Rectangle {
|
|||
|
||||
Image {
|
||||
id: topLeftAccentImage
|
||||
width: 60
|
||||
height: 150
|
||||
width: 400
|
||||
height: 180
|
||||
anchors.left: parent.left
|
||||
anchors.top: parent.top
|
||||
source: "images/standOutTopLeft.png"
|
||||
|
@ -32,87 +32,93 @@ Rectangle {
|
|||
|
||||
Image {
|
||||
id: bottomRightAccentImage
|
||||
width: 30
|
||||
height: 100
|
||||
width: 80
|
||||
height: 250
|
||||
anchors.right: parent.right
|
||||
anchors.bottom: parent.bottom
|
||||
source: "images/standOutBottomRight.png"
|
||||
}
|
||||
|
||||
Item {
|
||||
id: tempAvatarPageContainer
|
||||
|
||||
GridLayout {
|
||||
id: controlsPageGrid
|
||||
id: tempAvatarPageGrid
|
||||
anchors.fill: parent
|
||||
flow: root.width < root.height ? GridLayout.LeftToRight : GridLayout.TopToBottom
|
||||
columns: root.width > root.height ? 2 : 1
|
||||
rows: root.width > root.height ? 1 : 2
|
||||
anchors.leftMargin: 180
|
||||
anchors.topMargin: 50
|
||||
anchors.bottomMargin: 50
|
||||
anchors.rightMargin: 100
|
||||
|
||||
Item {
|
||||
id: textAndQRContainer
|
||||
width: 650
|
||||
Layout.topMargin: 80
|
||||
|
||||
HifiStylesUit.GraphikSemiBold {
|
||||
id: headerText
|
||||
width: 700
|
||||
height: 120
|
||||
text: "Stand out from the crowd!"
|
||||
anchors.fill: parent
|
||||
horizontalAlignment: Text.AlignHCenter
|
||||
verticalAlignment: Text.AlignVCenter
|
||||
color: "#000000"
|
||||
size: 36
|
||||
size: 48
|
||||
}
|
||||
|
||||
HifiStylesUit.GraphikSemiBold {
|
||||
width: 700
|
||||
height: 250
|
||||
id: descriptionText
|
||||
anchors.top: headerText.bottom
|
||||
anchors.topMargin: 20
|
||||
text: "You can create and upload custom avatars from our<br></br>
|
||||
Avatar Creator App. It's as easy as taking a selfie.<br></br>
|
||||
Available now on iOS and Android Platforms."
|
||||
anchors.top: headerText.bottom
|
||||
horizontalAlignment: Text.AlignHCenter
|
||||
verticalAlignment: Text.AlignVCenter
|
||||
color: "#000000"
|
||||
size: 24
|
||||
}
|
||||
|
||||
Item {
|
||||
id: qrAndInstructionsContainer
|
||||
anchors.top: descriptionText.bottom
|
||||
height: avatarAppQRCodeImage.height
|
||||
width: parent.width
|
||||
anchors.topMargin: 50
|
||||
|
||||
Image {
|
||||
id: avatarAppQRCodeImage
|
||||
width: 200
|
||||
height: 200
|
||||
source: "images/qrCode.jpg"
|
||||
height: 200
|
||||
width: 200
|
||||
}
|
||||
|
||||
HifiStylesUit.GraphikSemiBold {
|
||||
width: 600
|
||||
height: 80
|
||||
text: "Use your mobile phone to scan this QR code."
|
||||
id: instructionText
|
||||
anchors.top: avatarAppQRCodeImage.bottom
|
||||
horizontalAlignment: Text.AlignHCenter
|
||||
verticalAlignment: Text.AlignVCenter
|
||||
anchors.horizontalCenter: avatarAppQRCodeImage.horizontalCenter
|
||||
anchors.topMargin: 50
|
||||
text: "Use your mobile phone to scan this QR code."
|
||||
color: "#000000"
|
||||
size: 24
|
||||
}
|
||||
}
|
||||
|
||||
HifiStylesUit.GraphikSemiBold {
|
||||
HifiStylesUit.RalewayBold {
|
||||
text: "No thanks, I'll keep using my default avatar."
|
||||
anchors.fill: parent
|
||||
horizontalAlignment: Text.AlignHCenter
|
||||
verticalAlignment: Text.AlignVCenter
|
||||
anchors.top: qrAndInstructionsContainer.bottom
|
||||
anchors.topMargin: 50
|
||||
anchors.horizontalCenter: qrAndInstructionsContainer.horizontalCenter
|
||||
color: "#000000"
|
||||
opacity: noThanksMouseArea.containsMouse ? 1.0 : 0.8
|
||||
size: 12
|
||||
opacity: continueMouseArea.containsMouse ? 1.0 : 0.8
|
||||
size: 20
|
||||
z: 1
|
||||
|
||||
MouseArea {
|
||||
id: noThanksMouseArea
|
||||
hoverEnabled: false
|
||||
id: continueMouseArea
|
||||
hoverEnabled: true
|
||||
anchors.fill: parent
|
||||
|
||||
onClicked: {
|
||||
Tablet.playSound(TabletEnums.ButtonClick);
|
||||
Print("NO THANKS CLICKED");
|
||||
print("NO THANKS CLICKED");
|
||||
sendToScript({
|
||||
"source": "SecondLaunchWindow.qml",
|
||||
"method": "closeInitialLaunchWindow"
|
||||
|
@ -125,10 +131,16 @@ Rectangle {
|
|||
|
||||
Item {
|
||||
id: heroImageContainer
|
||||
Layout.leftMargin: 50
|
||||
// these don't change when the window resizes
|
||||
width: tempAvatarImage.width
|
||||
height: tempAvatarImage.height
|
||||
|
||||
Image {
|
||||
id: heroImage
|
||||
width: 600
|
||||
height: 350
|
||||
// if I use preferred width and height, the image does not update when window changes size
|
||||
width: tempAvatarPageGrid.flow === GridLayout.LeftToRight ? 400 : 100
|
||||
height: tempAvatarPageGrid.flow === GridLayout.LeftToRight ? 748 : 187
|
||||
source: "images/hero.png"
|
||||
}
|
||||
}
|
||||
|
|
|
@ -421,7 +421,7 @@ function displaySecondLaunchWindow() {
|
|||
return;
|
||||
}
|
||||
|
||||
secondLaunchWindow = Desktop.createWindow(INITIAL_LAUNCH_QML_PATH, {
|
||||
secondLaunchWindow = Desktop.createWindow(SECOND_LAUNCH_QML_PATH, {
|
||||
title: SECOND_LAUNCH_WINDOW_TITLE,
|
||||
presentationMode: SECOND_LAUNCH_PRESENTATION_MODE,
|
||||
size: {
|
||||
|
@ -442,19 +442,21 @@ function displaySecondLaunchWindow() {
|
|||
|
||||
function closeInitialLaunchWindow() {
|
||||
initialLaunchWindow.fromQml.disconnect(onMessageFromInitialLaunchWindow);
|
||||
var homeLocation = LocationBookmarks.getAddress("hqhome");
|
||||
if (homeLocation) {
|
||||
Window.location = "hqhome";
|
||||
}
|
||||
// TODO Add this bookmark? Then uncomment this code
|
||||
//var homeLocation = LocationBookmarks.getAddress("hqhome");
|
||||
//if (homeLocation) {
|
||||
// Window.location = "hqhome";
|
||||
//}
|
||||
initialLaunchWindow.close();
|
||||
}
|
||||
|
||||
function closeSecondLaunchWindow() {
|
||||
secondLaunchWindow.fromQml.disconnect(onMessageFromSecondLaunchWindow);
|
||||
var homeLocation = LocationBookmarks.getAddress("hqhome");
|
||||
if (homeLocation) {
|
||||
Window.location = "hqhome";
|
||||
}
|
||||
// TODO Add this bookmark? Then uncomment this code
|
||||
//var homeLocation = LocationBookmarks.getAddress("hqhome");
|
||||
//if (homeLocation) {
|
||||
// Window.location = "hqhome";
|
||||
//}
|
||||
secondLaunchWindow.close();
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue