resized svg back to original hackish fix

This commit is contained in:
ykeara
2019-01-12 14:44:43 -06:00
parent 50fe6748e9
commit d308c6005f
11 changed files with 48 additions and 28 deletions
+43 -23
View File
@@ -349,12 +349,17 @@ MyStackViewPage {
property bool playButtonIsPlay: false
MyPushButton2 {
id: previousSongButton
Layout.preferredHeight: 50
Layout.preferredWidth: 50
Layout.preferredHeight: 48
Layout.preferredWidth: 48
contentItem: Image {
source: "media_keys/outline_skip_previous_white_24dp.png"
sourceSize.width: 50
sourceSize.height: 50
source: "media_keys/outline_skip_previous_white_24dp.svg"
sourceSize: Qt.size( imgSP.sourceSize.width*2, imgSP.sourceSize.height*2 )
Image{
id: imgSP
source: parent.source
width:0
height:0
}
anchors.fill: parent
}
onClicked: {
@@ -370,18 +375,23 @@ MyStackViewPage {
}
MyPushButton2 {
id: stopSongButton
Layout.preferredHeight: 50
Layout.preferredWidth: 50
Layout.preferredHeight: 48
Layout.preferredWidth: 48
contentItem: Image {
source: "media_keys/outline_stop_white_24dp.png"
sourceSize.width: 50
sourceSize.height: 50
source: "media_keys/outline_stop_white_24dp.svg"
sourceSize: Qt.size( imgS.sourceSize.width*2, imgS.sourceSize.height*2 )
Image{
id: imgS
source: parent.source
width:0
height:0
}
anchors.fill: parent
}
onClicked: {
UtilitiesTabController.sendMediaStopSong()
playPauseSongButton.contentItem.source = "media_keys/outline_play_arrow_white_24dp.png"
playPauseSongButton.contentItem.source = "media_keys/outline_play_arrow_white_24dp.svg"
parent.playButtonIsPlay = true
}
@@ -394,23 +404,28 @@ MyStackViewPage {
}
MyPushButton2 {
id: playPauseSongButton
Layout.preferredHeight: 50
Layout.preferredWidth: 50
Layout.preferredHeight: 48
Layout.preferredWidth: 48
contentItem: Image {
// Assume that music is playing when people enter VR.
source: "media_keys/outline_pause_white_24dp.png"
sourceSize.width: 50
sourceSize.height: 50
source: "media_keys/outline_pause_white_24dp.svg"
sourceSize: Qt.size( imgP.sourceSize.width*2, imgP.sourceSize.height*2 )
Image{
id: imgP
source: parent.source
width:0
height:0
}
anchors.fill: parent
}
onClicked: {
UtilitiesTabController.sendMediaPausePlay()
if (parent.playButtonIsPlay) {
playPauseSongButton.contentItem.source = "media_keys/outline_pause_white_24dp.png"
playPauseSongButton.contentItem.source = "media_keys/outline_pause_white_24dp.svg"
parent.playButtonIsPlay = false
} else {
playPauseSongButton.contentItem.source = "media_keys/outline_play_arrow_white_24dp.png"
playPauseSongButton.contentItem.source = "media_keys/outline_play_arrow_white_24dp.svg"
parent.playButtonIsPlay = true
}
@@ -425,13 +440,18 @@ MyStackViewPage {
}
MyPushButton2 {
id: nextSongButton
Layout.preferredHeight: 50
Layout.preferredWidth: 50
Layout.preferredHeight: 48
Layout.preferredWidth: 48
contentItem: Image {
source: "media_keys/outline_skip_next_white_24dp.png"
sourceSize.width: 50
sourceSize.height: 50
source: "media_keys/outline_skip_next_white_24dp.svg"
sourceSize: Qt.size( imgSN.sourceSize.width*2, imgSN.sourceSize.height*2 )
Image{
id: imgSN
source: parent.source
width:0
height:0
}
anchors.fill: parent
}
onClicked: {
@@ -1 +0,0 @@
<svg xmlns="http://www.w3.org/2000/svg" width="50" height="50" viewBox="0 0 50 50"><path fill="none" d="M0 0h24v24H0V0z"/><path fill="white" d="M6 19h4V5H6v14zm8-14v14h4V5h-4z"/></svg>

Before

Width:  |  Height:  |  Size: 184 B

@@ -1 +0,0 @@
<svg xmlns="http://www.w3.org/2000/svg" width="50" height="50" viewBox="0 0 50 50"><path fill="none" d="M0 0h24v24H0V0z"/><path fill="white" d="M10 8.64L15.27 12 10 15.36V8.64M8 5v14l11-7L8 5z"/></svg>

Before

Width:  |  Height:  |  Size: 201 B

@@ -1 +0,0 @@
<svg xmlns="http://www.w3.org/2000/svg" width="50" height="50" viewBox="0 0 50 50"><path fill="none" d="M0 0h24v24H0V0z"/><path fill="white" d="M6 18l8.5-6L6 6v12zm2-8.14L11.03 12 8 14.14V9.86zM16 6h2v12h-2z"/></svg>

Before

Width:  |  Height:  |  Size: 216 B

@@ -1 +0,0 @@
<svg xmlns="http://www.w3.org/2000/svg" width="50" height="50" viewBox="0 0 50 50"><path fill="none" d="M0 0h24v24H0V0z"/><path fill="white" d="M6 6h2v12H6zm3.5 6l8.5 6V6l-8.5 6zm6.5 2.14L12.97 12 16 9.86v4.28z"/></svg>

Before

Width:  |  Height:  |  Size: 219 B

@@ -1 +0,0 @@
<svg xmlns="http://www.w3.org/2000/svg" width="50" height="50" viewBox="0 0 50 50"><path fill="none" d="M0 0h24v24H0V0z"/><path fill="white" d="M16 8v8H8V8h8m2-2H6v12h12V6z"/></svg>

Before

Width:  |  Height:  |  Size: 181 B

@@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><path fill="none" d="M0 0h24v24H0V0z"/><path fill="white" d="M6 19h4V5H6v14zm8-14v14h4V5h-4z"/></svg>

After

Width:  |  Height:  |  Size: 184 B

@@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><path fill="none" d="M0 0h24v24H0V0z"/><path fill="white" d="M10 8.64L15.27 12 10 15.36V8.64M8 5v14l11-7L8 5z"/></svg>

After

Width:  |  Height:  |  Size: 201 B

@@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><path fill="none" d="M0 0h24v24H0V0z"/><path fill="white" d="M6 18l8.5-6L6 6v12zm2-8.14L11.03 12 8 14.14V9.86zM16 6h2v12h-2z"/></svg>

After

Width:  |  Height:  |  Size: 216 B

@@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><path fill="none" d="M0 0h24v24H0V0z"/><path fill="white" d="M6 6h2v12H6zm3.5 6l8.5 6V6l-8.5 6zm6.5 2.14L12.97 12 16 9.86v4.28z"/></svg>

After

Width:  |  Height:  |  Size: 219 B

@@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><path fill="none" d="M0 0h24v24H0V0z"/><path fill="white" d="M16 8v8H8V8h8m2-2H6v12h12V6z"/></svg>

After

Width:  |  Height:  |  Size: 181 B