diff --git a/qml/delegates/FavoriteStations.qml b/qml/delegates/FavoriteStations.qml
index 69f99d3..68fd8f8 100644
--- a/qml/delegates/FavoriteStations.qml
+++ b/qml/delegates/FavoriteStations.qml
@@ -171,7 +171,7 @@ ListItem {
anchors.rightMargin: Theme.paddingMedium
elide: Text.ElideRight
width: parent.width - (favIcon.width + (Theme.paddingLarge * 2))
- text: lastcheckok == "1" ? name : " [DOWN] "+name
+ text: lastcheckok == "1" ? name : " ["+qsTr("DOWN")+"] "+name
color: lastcheckok == "1" ? Theme.primaryColor : Theme.secondaryColor
font.strikeout: lastcheckok == "1" ? false : true
font.pixelSize: Theme.fontSizeSmall
diff --git a/qml/delegates/RadioImage.qml b/qml/delegates/RadioImage.qml
index 8d11d9b..6716814 100644
--- a/qml/delegates/RadioImage.qml
+++ b/qml/delegates/RadioImage.qml
@@ -75,7 +75,7 @@ Column {
elide: Text.ElideRight
width: parent.width - (parent.border.width * 2)
height: width
- text: stationLabel ? stationLabel : "AllRadio"//lastcheckok == "1" ? name : " [DOWN] "+name
+ text: stationLabel ? stationLabel : "AllRadio2"//lastcheckok == "1" ? name : " [DOWN] "+name
color: Theme.primaryColor//stationlabel === "1" ? Theme.lightPrimaryColor : Theme.secondaryColor
wrapMode: Text.WordWrap
maximumLineCount: 4
diff --git a/qml/delegates/SmallStationsDelegate.qml b/qml/delegates/SmallStationsDelegate.qml
index e0e3a44..38ec27d 100644
--- a/qml/delegates/SmallStationsDelegate.qml
+++ b/qml/delegates/SmallStationsDelegate.qml
@@ -23,7 +23,7 @@ ListItem {
elide: Text.ElideRight
width: stationimage.width
height: Theme.itemSizeExtraSmall
- text: lastcheckok === "1" ? name : " [DOWN] "+name
+ text: lastcheckok === "1" ? name : " "+qsTr([DOWN])+" "+name
color: lastcheckok === "1" ? Theme.primaryColor : Theme.secondaryColor
wrapMode: Text.WordWrap
maximumLineCount: 2
diff --git a/qml/delegates/SmallTagsDelegate.qml b/qml/delegates/SmallTagsDelegate.qml
index e84ce07..8e8229a 100644
--- a/qml/delegates/SmallTagsDelegate.qml
+++ b/qml/delegates/SmallTagsDelegate.qml
@@ -23,7 +23,7 @@ ListItem {
elide: Text.ElideRight
width: stationimage.width
height: Theme.itemSizeExtraSmall
- text: tag ? tag : "No Tag"
+ text: tag ? tag : qsTr("No Tag")
color: Theme.primaryColor
wrapMode: Text.WordWrap
maximumLineCount: 2
diff --git a/qml/delegates/StationsDelegate.qml b/qml/delegates/StationsDelegate.qml
index 7e93bc0..9f03b0c 100644
--- a/qml/delegates/StationsDelegate.qml
+++ b/qml/delegates/StationsDelegate.qml
@@ -84,7 +84,7 @@ ListItem {
anchors.rightMargin: Theme.paddingMedium
elide: Text.ElideRight
width: parent.width - (favIcon.width + (Theme.paddingLarge * 2))
- text: lastcheckok == "1" ? name : " [DOWN] "+name
+ text: lastcheckok == "1" ? name : " "+qsTr([DOWN])+" "+name
color: lastcheckok == "1" ? Theme.primaryColor : Theme.secondaryColor
font.strikeout: lastcheckok == "1" ? false : true
font.pixelSize: Theme.fontSizeSmall
@@ -107,7 +107,7 @@ ListItem {
anchors.leftMargin: Theme.paddingMedium
font.pixelSize: Theme.fontSizeExtraSmall
- text: countrycode ? radioBrowser.getCountryName(countrycode) : "No country"//"Country name"//getAll(hls,codec,bitrate)
+ text: countrycode ? radioBrowser.getCountryName(countrycode) : qsTr("No country")//"Country name"//getAll(hls,codec,bitrate)
color: delegate.highlighted ? Theme.highlightColor : Theme.secondaryColor
}
Label {
@@ -117,7 +117,7 @@ ListItem {
anchors.leftMargin: Theme.paddingLarge
anchors.rightMargin: Theme.paddingSmall
font.pixelSize: Theme.fontSizeExtraSmall
- text: lastcheckok ? JSfunctions.getAll(hls,codec,bitrate) : "[OFFLINES]"
+ text: lastcheckok ? JSfunctions.getAll(hls,codec,bitrate) : qsTr("[OFFLINE]")
color: delegate.highlighted ? Theme.highlightColor : Theme.secondaryColor
}
Label {
diff --git a/qml/delegates/TabDelegate.qml b/qml/delegates/TabDelegate.qml
index e9f3d13..7b01908 100644
--- a/qml/delegates/TabDelegate.qml
+++ b/qml/delegates/TabDelegate.qml
@@ -16,7 +16,7 @@ Item {
down: tab === 0
width: parent.width / 3
// icon: "image://theme/icon-m-home" //"image://theme/icon-m-video"
- text: "Favorites"
+ text: qsTr("Favorites")
onButtonClick: {showP=0.0;tab = 0}
}
TabButton {
@@ -24,7 +24,7 @@ Item {
down: tab === 1
width: parent.width / 3
// icon: "image://theme/icon-m-search"
- text: "History"
+ text: qsTr("History")
onButtonClick: {showP=0.0;tab = 1}
}
TabButton {
@@ -32,7 +32,7 @@ Item {
down: tab === 2
width: parent.width / 3
// icon: "image://theme/icon-m-favorite"
- text: "Search"
+ text: qsTr("Search")
onButtonClick: {showP=0.0;tab = 2;console.log("CLICK")}
}
}
diff --git a/qml/delegates/TagImage.qml b/qml/delegates/TagImage.qml
index dbaa530..abe7ade 100644
--- a/qml/delegates/TagImage.qml
+++ b/qml/delegates/TagImage.qml
@@ -69,7 +69,7 @@ Column {
elide: Text.ElideRight
width: parent.width - (parent.border.width * 2)
height: width
- text: stationLabel ? stationLabel : "No Tag"//lastcheckok == "1" ? name : " [DOWN] "+name
+ text: stationLabel ? stationLabel : qsTr("No Tag")//lastcheckok == "1" ? name : " [DOWN] "+name
color: stationlabel === "1" ? Theme.lightPrimaryColor : Theme.secondaryColor
wrapMode: Text.WordWrap
maximumLineCount: 4
diff --git a/qml/harbour-allradio.qml b/qml/harbour-allradio.qml
index 8c0409c..e7086e8 100644
--- a/qml/harbour-allradio.qml
+++ b/qml/harbour-allradio.qml
@@ -18,8 +18,8 @@ ApplicationWindow
property string _version: "2.0.16"
property string _language: Qt.locale().name.slice(0,2)
property string _country: Qt.locale().name.slice(-2)
- property int currentListIndex: -1
- property int currentListCount: -1
+ //property int currentListIndex: -1
+ //property int currentListCount: -1
property int sleepTime: 0
//property alias settings: allradioSettings
property alias mediaPlayerPanel: mediaPlayerPanel
diff --git a/qml/helpers/jsFunctions.js b/qml/helpers/jsFunctions.js
index 43a54f9..94fd081 100644
--- a/qml/helpers/jsFunctions.js
+++ b/qml/helpers/jsFunctions.js
@@ -5,13 +5,13 @@ function getGreeting() {
datetoday.setTime(timenow);
var thehour = datetoday.getHours();
- if (thehour >= 2 && thehour < 12) display = "morning";
- else if (thehour >= 12 && thehour <=17) display = "afternoon";
- else display = "evening"
+ if (thehour >= 2 && thehour < 12) display = qsTr("morning");
+ else if (thehour >= 12 && thehour <=17) display = qsTr("afternoon");
+ else display = qsTr("evening")
- var greeting = ("Good " + display + "!");
+ var greeting = (qsTr("Good")+" " + display + "!");
return greeting//document.write(greeting);
}
diff --git a/qml/items/RadioPlayer.qml b/qml/items/RadioPlayer.qml
index 8441312..f5f6770 100644
--- a/qml/items/RadioPlayer.qml
+++ b/qml/items/RadioPlayer.qml
@@ -44,9 +44,9 @@ MediaPlayer {
property bool isPaused: false
property int stationOk: 3
property int maxTagClicks: 0
- property int playlistCount: playlist.count - 1
- //property int playlistIndex: Favorites.getSetting("playlistIndex",-1)
- property int playlistIndex: -1
+ property int playlistCount: playlist.count -1
+ property int playlistIndex: Favorites.getSetting("playlistIndex",-1)
+ //property int playlistIndex: playlistCount = Favorites.getSetting("playlistIndex",-1)
property QDtimer timer: QDtimer {
id: qdTimer
interval: 200; running: false; repeat: false
@@ -155,12 +155,12 @@ MediaPlayer {
function playNext() {
- if (playlistIndex < playlistCount && playlistIndex < playlist.count) playlistIndex = playlistIndex + 1
+ if (playlistIndex < playlistCount) playlistIndex = playlistIndex + 1
loadPlaylistSelected()
}
function playPrev() {
- if (playlistIndex <= playlistCount && playlistIndex > -1) playlistIndex = playlistIndex - 1 //: playlistIndex = 0
+ if (playlistIndex <= playlistCount) playlistIndex = playlistIndex - 1 //: playlistIndex = 0
loadPlaylistSelected()
}
@@ -196,7 +196,7 @@ MediaPlayer {
isPlaying = true
isPaused = false
qdTimer.start()
- //Favorites.setSetting("playlistIndex",playlistIndex)
+ if (_favorite) Favorites.setSetting("playlistIndex",playlistIndex)
}
onError: {
@@ -383,6 +383,7 @@ MediaPlayer {
_favorite = playHistory.get(0).favorite
isPlaying = false
isPaused = true
+ ///if (_favorite) playlistCount = Favorites.getSetting("playlistIndex",-1)
//playlistIndex = allradioSettings.value("currentFavorite",-1)
// pageStack.push("RadioPlayerPage.qml")
}
@@ -434,6 +435,6 @@ MediaPlayer {
- Component.onCompleted: {reloadDbData();loadRecentPlay()}
+ Component.onCompleted: {reloadDbData();_favorite ? loadPlaylistSelected() : loadRecentPlay()}
}
diff --git a/qml/items/Splash.qml b/qml/items/Splash.qml
index 2300352..628f4b6 100644
--- a/qml/items/Splash.qml
+++ b/qml/items/Splash.qml
@@ -29,12 +29,12 @@ Column {
}
Label {
- text: radioBrowser.serversModel.count > 0 ? "Found: "+radioBrowser.serversModel.count + " servers" : "Searching for servers..."
+ text: radioBrowser.serversModel.count > 0 ? qsTr("Found")+": "+radioBrowser.serversModel.count + " "+qsTr("servers") : qsTr("Searching for servers...")
anchors.horizontalCenter: parent.horizontalCenter
}
Label {
visible: radioBrowser.serversModel.count > 0
- text: "Connecting to:"
+ text: qsTr("Connecting to:")
anchors.horizontalCenter: parent.horizontalCenter
}
Label {
diff --git a/qml/pages/AboutPage.qml b/qml/pages/AboutPage.qml
index 0123139..9527605 100644
--- a/qml/pages/AboutPage.qml
+++ b/qml/pages/AboutPage.qml
@@ -16,13 +16,13 @@ Page {
Label {
font.pixelSize: Theme.fontSizeExtraLarge
font.bold: true
- text: "AllRadio v"+ _version
+ text: "AllRadio2 v"+ _version
anchors.horizontalCenter: parent.horizontalCenter
}
Label {
- text: "License: GPL"
+ text: qsTr("License: GPLv2")
anchors.horizontalCenter: parent.horizontalCenter
}
diff --git a/qml/pages/AllRadio.qml b/qml/pages/AllRadio.qml
index 5117a12..13d479c 100644
--- a/qml/pages/AllRadio.qml
+++ b/qml/pages/AllRadio.qml
@@ -324,7 +324,7 @@ Page {
HeaderButton {
visible: playedCountries.count > 1
// headerText: playedCountries.count > 0 ? "Trending in " + radioBrowser.getCountryName(playedCountries.get(1).alpha_2) : "Trending in " + radioBrowser.getCountryName(_country)
- headerText: playedCountries.count > 1 ? "Trending in " + radioBrowser.getCountryName(playedCountries.get(1).alpha_2) : "Trending in " + radioBrowser.getCountryName(_country)
+ headerText: playedCountries.count > 1 ? qsTr("Trending in")+" " + radioBrowser.getCountryName(playedCountries.get(1).alpha_2) : qsTr("Trending in")+" " + radioBrowser.getCountryName(_country)
onClicked: pageStack.push("CountryStationsPage.qml",{searchby:"clicktrend",_countrycode: playedCountries.get(1).alpha_2})
}
@@ -364,7 +364,7 @@ Page {
Item {height: Theme.paddingLarge;width: parent.width}
HeaderButton {
- headerText: "Trending in the world"//playedCountries.count > 0 ? "Trending in " + radioBrowser.getCountryName(playedCountries.get(0).alpha_2) : "Trending in " + radioBrowser.getCountryName(_country)
+ headerText: qsTr("Trending in the world")//playedCountries.count > 0 ? "Trending in " + radioBrowser.getCountryName(playedCountries.get(0).alpha_2) : "Trending in " + radioBrowser.getCountryName(_country)
onClicked: pageStack.push("CountryStationsPage.qml",{searchby:"clicktrend",_countrycode: ""})
}
diff --git a/translations/harbour-allradio-de.ts b/translations/harbour-allradio-de.ts
index 556a0c7..19dde3e 100644
--- a/translations/harbour-allradio-de.ts
+++ b/translations/harbour-allradio-de.ts
@@ -7,6 +7,10 @@
AllRadio is an internet radio station player
+
+ License: GPLv2
+
+
AllRadio
@@ -46,6 +50,10 @@
Trending in
+
+ Trending in the world
+
+
CountryNameModel
@@ -1068,6 +1076,10 @@
Add to favorites
+
+ DOWN
+
+
SecondPage
@@ -1114,11 +1126,86 @@
+
+ SmallTagsDelegate
+
+ No Tag
+
+
+
+
+ Splash
+
+ Found
+
+
+
+ servers
+
+
+
+ Searching for servers...
+
+
+
+ Connecting to:
+
+
+
StationsDelegate
Vote on Community Radio Browser
+
+ No country
+
+
+
+ [OFFLINE]
+
+
+
+
+ TabDelegate
+
+ Favorites
+
+
+
+ History
+
+
+
+ Search
+
+
+
+
+ TagImage
+
+ No Tag
+
+
+
+
+ jsFunctions
+
+ morning
+
+
+
+ afternoon
+
+
+
+ evening
+
+
+
+ Good
+
+
diff --git a/translations/harbour-allradio.ts b/translations/harbour-allradio.ts
index e1a3c23..829a564 100644
--- a/translations/harbour-allradio.ts
+++ b/translations/harbour-allradio.ts
@@ -7,6 +7,10 @@
AllRadio is an internet radio station player
+
+ License: GPLv2
+
+
AllRadio
@@ -46,6 +50,10 @@
Trending in
+
+ Trending in the world
+
+
CountryNameModel
@@ -1068,6 +1076,10 @@
Add to favorites
+
+ DOWN
+
+
SecondPage
@@ -1114,11 +1126,86 @@
+
+ SmallTagsDelegate
+
+ No Tag
+
+
+
+
+ Splash
+
+ Found
+
+
+
+ servers
+
+
+
+ Searching for servers...
+
+
+
+ Connecting to:
+
+
+
StationsDelegate
Vote on Community Radio Browser
+
+ No country
+
+
+
+ [OFFLINE]
+
+
+
+
+ TabDelegate
+
+ Favorites
+
+
+
+ History
+
+
+
+ Search
+
+
+
+
+ TagImage
+
+ No Tag
+
+
+
+
+ jsFunctions
+
+ morning
+
+
+
+ afternoon
+
+
+
+ evening
+
+
+
+ Good
+
+