This commit is contained in:
Zach Fox 2017-08-15 15:42:53 -07:00
parent 29a9ae28e9
commit ccf2d71036
3 changed files with 23 additions and 4 deletions

View file

@ -66,6 +66,9 @@ Rectangle {
}
}
}
onSecurityImageResult: {
securityImage.source = securityImageSelection.getImagePathFromImageID(imageID);
}
}
SecurityImageSelection {
@ -92,8 +95,11 @@ Rectangle {
// Text size
size: hifi.fontSizes.overlayTitle;
// Anchors
anchors.fill: parent;
anchors.top: parent.top;
anchors.left: parent.left;
anchors.leftMargin: 16;
anchors.bottom: parent.bottom;
width: paintedWidth;
// Style
color: hifi.colors.lightGrayText;
// Alignment
@ -101,6 +107,19 @@ Rectangle {
verticalAlignment: Text.AlignVCenter;
}
// Security Image
Image {
id: securityImage;
// Anchors
anchors.top: parent.top;
anchors.left: titleBarText.right;
anchors.leftMargin: 16;
height: parent.height - 5;
width: height;
anchors.verticalCenter: parent.verticalCenter;
fillMode: Image.PreserveAspectFit;
}
// Separator
HifiControlsUit.Separator {
anchors.left: parent.left;
@ -432,6 +451,7 @@ Rectangle {
itemHref = message.params.itemHref;
commerce.balance();
commerce.inventory();
commerce.getSecurityImage();
break;
default:
console.log('Unrecognized message from marketplaces.js:', JSON.stringify(message));

View file

@ -93,7 +93,6 @@ Rectangle {
anchors.leftMargin: 16;
height: parent.height - 5;
width: height;
anchors.horizontalCenter: parent.horizontalCenter;
anchors.verticalCenter: parent.verticalCenter;
fillMode: Image.PreserveAspectFit;
}

View file

@ -161,8 +161,8 @@ Rectangle {
// Anchors
anchors.fill: parent;
currentIndex: -1;
cellWidth: width/2;
cellHeight: height/3;
cellWidth: width / 2;
cellHeight: height / 3;
model: gridModel;
delegate: Item {
width: securityImageGrid.cellWidth;