mirror of
https://github.com/AleziaKurdis/overte.git
synced 2025-04-07 04:53:28 +02:00
bring back 'get more' wearables button
This commit is contained in:
parent
1771e4c742
commit
9234813e08
2 changed files with 57 additions and 2 deletions
|
@ -1,5 +1,6 @@
|
|||
import Hifi 1.0 as Hifi
|
||||
import QtQuick 2.5
|
||||
import QtQuick.Layouts 1.3
|
||||
import "../../styles-uit"
|
||||
import "../../controls-uit" as HifiControlsUit
|
||||
import "../../controls" as HifiControls
|
||||
|
@ -124,7 +125,10 @@ Rectangle {
|
|||
Column {
|
||||
width: parent.width
|
||||
|
||||
Row {
|
||||
RowLayout {
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
|
||||
RalewayBold {
|
||||
size: 15;
|
||||
lineHeightMode: Text.FixedHeight
|
||||
|
@ -139,9 +143,31 @@ Rectangle {
|
|||
size: 15;
|
||||
lineHeightMode: Text.FixedHeight
|
||||
lineHeight: 18;
|
||||
text: "<a href='#'>Add custom</a>"
|
||||
text: "<a href='#'>Get more</a>"
|
||||
linkColor: hifi.colors.blueHighlight
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
onLinkActivated: {
|
||||
popup.showGetWearables(function() {
|
||||
emitSendToScript({'method' : 'navigate', 'url' : 'hifi://AvatarIsland/11.5848,-8.10862,-2.80195'})
|
||||
}, function(link) {
|
||||
emitSendToScript({'method' : 'navigate', 'url' : link})
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
Layout.fillWidth: true
|
||||
Layout.fillHeight: true
|
||||
|
||||
RalewayBold {
|
||||
size: 15;
|
||||
lineHeightMode: Text.FixedHeight
|
||||
lineHeight: 18;
|
||||
text: "<a href='#'>Add custom</a>"
|
||||
linkColor: hifi.colors.blueHighlight
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
anchors.right: parent.right
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -33,6 +33,35 @@ MessageBox {
|
|||
popup.inputText.forceActiveFocus();
|
||||
}
|
||||
|
||||
property url getWearablesUrl: '../../../images/avatarapp/AvatarIsland.jpg'
|
||||
|
||||
function showGetWearables(callback, linkCallback) {
|
||||
popup.button2text = 'AvatarIsland'
|
||||
popup.dialogButtons.yesButton.fontCapitalization = Font.MixedCase;
|
||||
popup.button1text = 'CANCEL'
|
||||
popup.titleText = 'Get Wearables'
|
||||
popup.bodyText = 'Buy wearables from <b><a href="app://marketplace">Marketplace.</a></b>' + '<br/>' +
|
||||
'Wear wearables from <b><a href="app://purchases">My Purchases.</a></b>' + '<br/>' + '<br/>' +
|
||||
'Visit “AvatarIsland” to get wearables'
|
||||
|
||||
popup.imageSource = getWearablesUrl;
|
||||
popup.onButton2Clicked = function() {
|
||||
popup.close();
|
||||
|
||||
if(callback)
|
||||
callback();
|
||||
}
|
||||
|
||||
popup.onLinkClicked = function(link) {
|
||||
popup.close();
|
||||
|
||||
if(linkCallback)
|
||||
linkCallback(link);
|
||||
}
|
||||
|
||||
popup.open();
|
||||
}
|
||||
|
||||
function showDeleteFavorite(favoriteName, callback) {
|
||||
popup.titleText = 'Delete Favorite: {AvatarName}'.replace('{AvatarName}', favoriteName)
|
||||
popup.bodyText = 'This will delete your favorite. You will retain access to the wearables and avatar that made up the favorite from My Purchases.'
|
||||
|
|
Loading…
Reference in a new issue