diff --git a/sailfish/qml/harbour-sailfin.qml b/sailfish/qml/harbour-sailfin.qml index 0f1fbda..28a6651 100644 --- a/sailfish/qml/harbour-sailfin.qml +++ b/sailfish/qml/harbour-sailfin.qml @@ -148,6 +148,7 @@ ApplicationWindow { id: config path: "/nl/netsoj/chris/Sailfin" property bool showDebugInfo: false + property bool musicMode: false } function navigateToItem(jellyfinId, mediaType, type, isFolder) { @@ -196,7 +197,13 @@ ApplicationWindow { } ScriptAction { - script: pageStack.replace(Qt.resolvedUrl("pages/MainPage.qml"), {}, PageStackAction.Immediate) + script: { + if (config.musicMode) { + pageStack.replace(Qt.resolvedUrl("pages/itemdetails/MusicLibraryPage.qml"), {}, PageStackAction.Immediate) + } else { + pageStack.replace(Qt.resolvedUrl("pages/MainPage.qml"), {}, PageStackAction.Immediate) + } + } } } diff --git a/sailfish/qml/pages/SettingsPage.qml b/sailfish/qml/pages/SettingsPage.qml index a70449c..9ec3074 100644 --- a/sailfish/qml/pages/SettingsPage.qml +++ b/sailfish/qml/pages/SettingsPage.qml @@ -18,6 +18,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA */ import QtQuick 2.6 import Sailfish.Silica 1.0 +import Nemo.Configuration 1.0 import nl.netsoj.chris.Jellyfin 1.0 as J @@ -30,6 +31,17 @@ Page { property alias loggedInUser: userLoader.data + ConfigurationGroup { + id: config + path: "/nl/netsoj/chris/Sailfin" + property bool showDebugInfo: false + property bool musicMode: false + } + + Component.onCompleted: { + btnMusicMode.checked = config.musicMode; + } + SilicaFlickable { anchors.fill: parent contentHeight: content.height @@ -117,6 +129,14 @@ Page { text: qsTr("Other") } + IconTextSwitch { + id: btnMusicMode + text: qsTr("Music Mode") + icon.source: "image://theme/icon-m-music" + description: "Toggle UI into music only mode" + onCheckedChanged: config.musicMode = checked + } + IconListItem { //: Settings list item for settings related to streaming text: qsTr("Streaming settings")