mirror of
https://gitlab.com/kelteseth/ScreenPlay.git
synced 2024-09-18 16:32:33 +02:00
Remove download button from workshop item
This commit is contained in:
parent
be32f15548
commit
37d2a2879f
@ -160,42 +160,24 @@ Item {
|
|||||||
Text {
|
Text {
|
||||||
id: txtTitle
|
id: txtTitle
|
||||||
text: root.name
|
text: root.name
|
||||||
|
|
||||||
opacity: 0
|
opacity: 0
|
||||||
height: 30
|
height: 30
|
||||||
width: 180
|
width: 180
|
||||||
verticalAlignment: Text.AlignVCenter
|
verticalAlignment: Text.AlignVCenter
|
||||||
color: "white"
|
color: "white"
|
||||||
font.pointSize: 18
|
font.pointSize: 14
|
||||||
wrapMode: Text.WordWrap
|
wrapMode: Text.WrapAtWordBoundaryOrAnywhere
|
||||||
font.family: ScreenPlay.settings.font
|
font.family: ScreenPlay.settings.font
|
||||||
anchors {
|
anchors {
|
||||||
bottom: parent.bottom
|
bottom: parent.bottom
|
||||||
right: button.left
|
right: parent.right
|
||||||
rightMargin: 10
|
rightMargin: 20
|
||||||
left: parent.left
|
left: parent.left
|
||||||
leftMargin: 20
|
leftMargin: 20
|
||||||
bottomMargin: -50
|
bottomMargin: -50
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Button {
|
|
||||||
id: button
|
|
||||||
text: qsTr("Download")
|
|
||||||
anchors {
|
|
||||||
right: parent.right
|
|
||||||
rightMargin: 20
|
|
||||||
bottom: parent.bottom
|
|
||||||
bottomMargin: -50
|
|
||||||
}
|
|
||||||
opacity: 0
|
|
||||||
Material.background: Material.Orange
|
|
||||||
Material.foreground: "white"
|
|
||||||
icon.source: "qrc:/assets/icons/icon_download.svg"
|
|
||||||
icon.width: 12
|
|
||||||
icon.height: 12
|
|
||||||
}
|
|
||||||
|
|
||||||
Item {
|
Item {
|
||||||
id: openInWorkshop
|
id: openInWorkshop
|
||||||
height: 20
|
height: 20
|
||||||
@ -249,7 +231,8 @@ Item {
|
|||||||
onClicked: {
|
onClicked: {
|
||||||
isDownloading = true
|
isDownloading = true
|
||||||
root.state = "downloading"
|
root.state = "downloading"
|
||||||
SP.Workshop.steamWorkshop.subscribeItem(root.publishedFileID)
|
SP.Workshop.steamWorkshop.subscribeItem(
|
||||||
|
root.publishedFileID)
|
||||||
ScreenPlay.setTrackerSendEvent("subscribeItem",
|
ScreenPlay.setTrackerSendEvent("subscribeItem",
|
||||||
root.publishedFileID)
|
root.publishedFileID)
|
||||||
}
|
}
|
||||||
@ -321,12 +304,6 @@ Item {
|
|||||||
State {
|
State {
|
||||||
name: "hover"
|
name: "hover"
|
||||||
|
|
||||||
PropertyChanges {
|
|
||||||
target: button
|
|
||||||
opacity: 1
|
|
||||||
anchors.bottomMargin: 10
|
|
||||||
}
|
|
||||||
|
|
||||||
PropertyChanges {
|
PropertyChanges {
|
||||||
target: openInWorkshop
|
target: openInWorkshop
|
||||||
opacity: .75
|
opacity: .75
|
||||||
@ -350,10 +327,6 @@ Item {
|
|||||||
State {
|
State {
|
||||||
name: "downloading"
|
name: "downloading"
|
||||||
|
|
||||||
PropertyChanges {
|
|
||||||
target: button
|
|
||||||
opacity: 0
|
|
||||||
}
|
|
||||||
PropertyChanges {
|
PropertyChanges {
|
||||||
target: openInWorkshop
|
target: openInWorkshop
|
||||||
opacity: 0
|
opacity: 0
|
||||||
@ -383,11 +356,6 @@ Item {
|
|||||||
State {
|
State {
|
||||||
name: "installed"
|
name: "installed"
|
||||||
|
|
||||||
PropertyChanges {
|
|
||||||
target: button
|
|
||||||
opacity: 0
|
|
||||||
}
|
|
||||||
|
|
||||||
PropertyChanges {
|
PropertyChanges {
|
||||||
target: txtTitle
|
target: txtTitle
|
||||||
opacity: 0
|
opacity: 0
|
||||||
@ -420,11 +388,6 @@ Item {
|
|||||||
to: "hover"
|
to: "hover"
|
||||||
reversible: true
|
reversible: true
|
||||||
|
|
||||||
PropertyAnimation {
|
|
||||||
target: button
|
|
||||||
duration: 100
|
|
||||||
properties: "opacity, anchors.bottomMargin"
|
|
||||||
}
|
|
||||||
PropertyAnimation {
|
PropertyAnimation {
|
||||||
target: openInWorkshop
|
target: openInWorkshop
|
||||||
duration: 100
|
duration: 100
|
||||||
@ -446,11 +409,6 @@ Item {
|
|||||||
to: "downloading"
|
to: "downloading"
|
||||||
reversible: true
|
reversible: true
|
||||||
|
|
||||||
PropertyAnimation {
|
|
||||||
target: button
|
|
||||||
duration: 100
|
|
||||||
properties: "opacity"
|
|
||||||
}
|
|
||||||
PropertyAnimation {
|
PropertyAnimation {
|
||||||
target: txtTitle
|
target: txtTitle
|
||||||
duration: 100
|
duration: 100
|
||||||
|
Loading…
Reference in New Issue
Block a user