Minor adjustments

This commit is contained in:
Bart De Vries 2021-04-08 17:06:10 +02:00
parent 5d6f05e55e
commit b9433a348a
3 changed files with 10 additions and 7 deletions

View File

@ -18,11 +18,13 @@ Kirigami.SwipeListItem {
contentItem: RowLayout { contentItem: RowLayout {
Image { Image {
asynchronous: true asynchronous: true
source: entry.image === "" ? "rss" : "file://"+Fetcher.image(entry.image) source: entry.image === "" ? "logo.png" : "file://"+Fetcher.image(entry.image)
fillMode: Image.PreserveAspectFit fillMode: Image.PreserveAspectFit
property int size: Kirigami.Units.gridUnit * 3 property int size: Kirigami.Units.gridUnit * 3
Layout.maximumHeight: size Layout.maximumHeight: size
Layout.maximumWidth: size Layout.maximumWidth: size
height: size
width: size
sourceSize.width: size sourceSize.width: size
sourceSize.height: size sourceSize.height: size
Layout.rightMargin: Kirigami.Units.smallSpacing Layout.rightMargin: Kirigami.Units.smallSpacing
@ -61,7 +63,7 @@ Kirigami.SwipeListItem {
Component { Component {
id: subtitle id: subtitle
Controls.Label { Controls.Label {
text: (Math.floor(entry.enclosure.duration/3600) < 10 ? "0" : "") + Math.floor(entry.enclosure.duration/3600) + ":" + (Math.floor(entry.enclosure.duration/60) % 60 < 10 ? "0" : "") + Math.floor(entry.enclosure.duration/60) % 60 + ":" + (Math.floor(entry.enclosure.duration) % 60 < 10 ? "0" : "") + Math.floor(entry.enclosure.duration) % 60 text: entry.enclosure ? ((Math.floor(entry.enclosure.duration/3600) < 10 ? "0" : "") + Math.floor(entry.enclosure.duration/3600) + ":" + (Math.floor(entry.enclosure.duration/60) % 60 < 10 ? "0" : "") + Math.floor(entry.enclosure.duration/60) % 60 + ":" + (Math.floor(entry.enclosure.duration) % 60 < 10 ? "0" : "") + Math.floor(entry.enclosure.duration) % 60) : ""
Layout.fillWidth: true Layout.fillWidth: true
elide: Text.ElideRight elide: Text.ElideRight
font: Kirigami.Theme.smallFont font: Kirigami.Theme.smallFont

View File

@ -79,7 +79,7 @@ Kirigami.ScrollablePage {
sourceComponent: entryListDelegate sourceComponent: entryListDelegate
} }
onOriginYChanged: contentY = originY // Why is this needed? //onOriginYChanged: contentY = originY // Why is this needed?
//headerPositioning: ListView.OverlayHeader // seems broken //headerPositioning: ListView.OverlayHeader // seems broken
header: Item { header: Item {
@ -97,13 +97,13 @@ Kirigami.ScrollablePage {
} }
Image { Image {
id: backgroundimage id: backgroundimage
source: page.feed.image === "" ? "rss" : "file://"+Fetcher.image(page.feed.image) source: page.feed.image === "" ? "logo.png" : "file://"+Fetcher.image(page.feed.image)
fillMode: Image.PreserveAspectCrop fillMode: Image.PreserveAspectCrop
anchors.fill: parent anchors.fill: parent
asynchronous: true asynchronous: true
} }
GaussianBlur { GaussianBlur {
id: blur id: blur
anchors.fill: backgroundimage anchors.fill: backgroundimage
source: backgroundimage source: backgroundimage
radius: 12 radius: 12
@ -128,7 +128,7 @@ Kirigami.ScrollablePage {
Image { Image {
id: frontimage id: frontimage
source: page.feed.image === "" ? "rss" : "file://"+Fetcher.image(page.feed.image) source: page.feed.image === "" ? "logo.png" : "file://"+Fetcher.image(page.feed.image)
Layout.maximumHeight: parent.size Layout.maximumHeight: parent.size
Layout.maximumWidth: parent.size Layout.maximumWidth: parent.size
asynchronous: true asynchronous: true

View File

@ -14,6 +14,7 @@
<file alias="FooterBar.qml">qml/FooterBar.qml</file> <file alias="FooterBar.qml">qml/FooterBar.qml</file>
<file alias="QueuePage.qml">qml/QueuePage.qml</file> <file alias="QueuePage.qml">qml/QueuePage.qml</file>
<file alias="QueueDelegate.qml">qml/QueueDelegate.qml</file> <file alias="QueueDelegate.qml">qml/QueueDelegate.qml</file>
<file alias="logo.png">../logo.png</file>
<file>qtquickcontrols2.conf</file> <file>qtquickcontrols2.conf</file>
</qresource> </qresource>
</RCC> </RCC>