diff --git a/android/res/values-aa/strings.xml b/android/res/values-aa/strings.xml new file mode 100644 index 0000000000..314c00f03b --- /dev/null +++ b/android/res/values-aa/strings.xml @@ -0,0 +1,4 @@ + + + afrikaans.lng + \ No newline at end of file diff --git a/android/res/values-ar/strings.xml b/android/res/values-ar/strings.xml new file mode 100644 index 0000000000..04af168476 --- /dev/null +++ b/android/res/values-ar/strings.xml @@ -0,0 +1,4 @@ + + + arabic.lng + \ No newline at end of file diff --git a/android/res/values-bg/strings.xml b/android/res/values-bg/strings.xml new file mode 100644 index 0000000000..ae515eaa36 --- /dev/null +++ b/android/res/values-bg/strings.xml @@ -0,0 +1,4 @@ + + + bulgarian.lng + \ No newline at end of file diff --git a/android/res/values-br/strings.xml b/android/res/values-br/strings.xml new file mode 100644 index 0000000000..285c510c33 --- /dev/null +++ b/android/res/values-br/strings.xml @@ -0,0 +1,4 @@ + + + portugues-brasileiro.lng + \ No newline at end of file diff --git a/android/res/values-ca/strings.xml b/android/res/values-ca/strings.xml new file mode 100644 index 0000000000..5de38c17b7 --- /dev/null +++ b/android/res/values-ca/strings.xml @@ -0,0 +1,4 @@ + + + catala.lng + \ No newline at end of file diff --git a/android/res/values-ch-rVS/strings.xml b/android/res/values-ch-rVS/strings.xml new file mode 100644 index 0000000000..a520c52071 --- /dev/null +++ b/android/res/values-ch-rVS/strings.xml @@ -0,0 +1,4 @@ + + + wallisertitsch.lng + \ No newline at end of file diff --git a/android/res/values-cs/strings.xml b/android/res/values-cs/strings.xml new file mode 100644 index 0000000000..5a949e597b --- /dev/null +++ b/android/res/values-cs/strings.xml @@ -0,0 +1,4 @@ + + + czech.lng + \ No newline at end of file diff --git a/android/res/values-da/strings.xml b/android/res/values-da/strings.xml new file mode 100644 index 0000000000..71b29abc69 --- /dev/null +++ b/android/res/values-da/strings.xml @@ -0,0 +1,4 @@ + + + dansk.lng + \ No newline at end of file diff --git a/android/res/values-de/strings.xml b/android/res/values-de/strings.xml new file mode 100644 index 0000000000..9a2a7be4d8 --- /dev/null +++ b/android/res/values-de/strings.xml @@ -0,0 +1,4 @@ + + + deutsch.lng + \ No newline at end of file diff --git a/android/res/values-el/strings.xml b/android/res/values-el/strings.xml new file mode 100644 index 0000000000..6850726fa9 --- /dev/null +++ b/android/res/values-el/strings.xml @@ -0,0 +1,4 @@ + + + greek.lng + \ No newline at end of file diff --git a/android/res/values-eo/strings.xml b/android/res/values-eo/strings.xml new file mode 100644 index 0000000000..464c7f482c --- /dev/null +++ b/android/res/values-eo/strings.xml @@ -0,0 +1,4 @@ + + + esperanto.lng + \ No newline at end of file diff --git a/android/res/values-es/strings.xml b/android/res/values-es/strings.xml new file mode 100644 index 0000000000..04d6ece261 --- /dev/null +++ b/android/res/values-es/strings.xml @@ -0,0 +1,4 @@ + + + espanol.lng + \ No newline at end of file diff --git a/android/res/values-et/strings.xml b/android/res/values-et/strings.xml new file mode 100644 index 0000000000..fa9092c91b --- /dev/null +++ b/android/res/values-et/strings.xml @@ -0,0 +1,4 @@ + + + eesti.lng + \ No newline at end of file diff --git a/android/res/values-fi/strings.xml b/android/res/values-fi/strings.xml new file mode 100644 index 0000000000..af426f7ca2 --- /dev/null +++ b/android/res/values-fi/strings.xml @@ -0,0 +1,4 @@ + + + finnish.lng + \ No newline at end of file diff --git a/android/res/values-fr/strings.xml b/android/res/values-fr/strings.xml new file mode 100644 index 0000000000..8b448b23a5 --- /dev/null +++ b/android/res/values-fr/strings.xml @@ -0,0 +1,4 @@ + + + francais.lng + \ No newline at end of file diff --git a/android/res/values-gl/strings.xml b/android/res/values-gl/strings.xml new file mode 100644 index 0000000000..e77adbf271 --- /dev/null +++ b/android/res/values-gl/strings.xml @@ -0,0 +1,4 @@ + + + galego.lng + \ No newline at end of file diff --git a/android/res/values-he/strings.xml b/android/res/values-he/strings.xml new file mode 100644 index 0000000000..675de06090 --- /dev/null +++ b/android/res/values-he/strings.xml @@ -0,0 +1,4 @@ + + + hebrew.lng + \ No newline at end of file diff --git a/android/res/values-hi/strings.xml b/android/res/values-hi/strings.xml new file mode 100644 index 0000000000..6e3abd14ea --- /dev/null +++ b/android/res/values-hi/strings.xml @@ -0,0 +1,4 @@ + + + hindi.lng + \ No newline at end of file diff --git a/android/res/values-hr/strings.xml b/android/res/values-hr/strings.xml new file mode 100644 index 0000000000..ea93afa2c0 --- /dev/null +++ b/android/res/values-hr/strings.xml @@ -0,0 +1,4 @@ + + + hrvatski.lng + \ No newline at end of file diff --git a/android/res/values-hu/strings.xml b/android/res/values-hu/strings.xml new file mode 100644 index 0000000000..6b9d88c078 --- /dev/null +++ b/android/res/values-hu/strings.xml @@ -0,0 +1,4 @@ + + + magyar.lng + \ No newline at end of file diff --git a/android/res/values-is/strings.xml b/android/res/values-is/strings.xml new file mode 100644 index 0000000000..363c192ad0 --- /dev/null +++ b/android/res/values-is/strings.xml @@ -0,0 +1,4 @@ + + + islenska.lng + \ No newline at end of file diff --git a/android/res/values-it/strings.xml b/android/res/values-it/strings.xml new file mode 100644 index 0000000000..60fef119f0 --- /dev/null +++ b/android/res/values-it/strings.xml @@ -0,0 +1,4 @@ + + + italiano.lng + \ No newline at end of file diff --git a/android/res/values-ja/strings.xml b/android/res/values-ja/strings.xml new file mode 100644 index 0000000000..051ba60275 --- /dev/null +++ b/android/res/values-ja/strings.xml @@ -0,0 +1,4 @@ + + + japanese.lng + \ No newline at end of file diff --git a/android/res/values-ko/strings.xml b/android/res/values-ko/strings.xml new file mode 100644 index 0000000000..7ae1fd1c26 --- /dev/null +++ b/android/res/values-ko/strings.xml @@ -0,0 +1,4 @@ + + + korean.lng + \ No newline at end of file diff --git a/android/res/values-lt/strings.xml b/android/res/values-lt/strings.xml new file mode 100644 index 0000000000..568aaf2360 --- /dev/null +++ b/android/res/values-lt/strings.xml @@ -0,0 +1,4 @@ + + + lietuviu.lng + \ No newline at end of file diff --git a/android/res/values-nl/strings.xml b/android/res/values-nl/strings.xml new file mode 100644 index 0000000000..c5c88d5c83 --- /dev/null +++ b/android/res/values-nl/strings.xml @@ -0,0 +1,4 @@ + + +nederlands.lng + diff --git a/android/res/values-nn/strings.xml b/android/res/values-nn/strings.xml new file mode 100644 index 0000000000..38390decf8 --- /dev/null +++ b/android/res/values-nn/strings.xml @@ -0,0 +1,4 @@ + + + norsk-nynorsk.lng + \ No newline at end of file diff --git a/android/res/values-no/strings.xml b/android/res/values-no/strings.xml new file mode 100644 index 0000000000..fa5adabbda --- /dev/null +++ b/android/res/values-no/strings.xml @@ -0,0 +1,4 @@ + + + norsk.lng + \ No newline at end of file diff --git a/android/res/values-pl/strings.xml b/android/res/values-pl/strings.xml new file mode 100644 index 0000000000..c06a5aaf4d --- /dev/null +++ b/android/res/values-pl/strings.xml @@ -0,0 +1,4 @@ + + + polski.lng + \ No newline at end of file diff --git a/android/res/values-pt/strings.xml b/android/res/values-pt/strings.xml new file mode 100644 index 0000000000..345e9ae593 --- /dev/null +++ b/android/res/values-pt/strings.xml @@ -0,0 +1,4 @@ + + + portugues.lng + \ No newline at end of file diff --git a/android/res/values-ro/strings.xml b/android/res/values-ro/strings.xml new file mode 100644 index 0000000000..48a6ebe6c2 --- /dev/null +++ b/android/res/values-ro/strings.xml @@ -0,0 +1,4 @@ + + + romaneste.lng + \ No newline at end of file diff --git a/android/res/values-ru/strings.xml b/android/res/values-ru/strings.xml new file mode 100644 index 0000000000..5b8dcd6c05 --- /dev/null +++ b/android/res/values-ru/strings.xml @@ -0,0 +1,4 @@ + + + russian.lng + \ No newline at end of file diff --git a/android/res/values-sk/strings.xml b/android/res/values-sk/strings.xml new file mode 100644 index 0000000000..c0aea1cefe --- /dev/null +++ b/android/res/values-sk/strings.xml @@ -0,0 +1,4 @@ + + + slovak.lng + \ No newline at end of file diff --git a/android/res/values-sl/strings.xml b/android/res/values-sl/strings.xml new file mode 100644 index 0000000000..471acf31b7 --- /dev/null +++ b/android/res/values-sl/strings.xml @@ -0,0 +1,4 @@ + + + slovenscina.lng + \ No newline at end of file diff --git a/android/res/values-sr/strings.xml b/android/res/values-sr/strings.xml new file mode 100644 index 0000000000..6c000a8703 --- /dev/null +++ b/android/res/values-sr/strings.xml @@ -0,0 +1,4 @@ + + + srpski.lng + \ No newline at end of file diff --git a/android/res/values-sv/strings.xml b/android/res/values-sv/strings.xml new file mode 100644 index 0000000000..fa3687130d --- /dev/null +++ b/android/res/values-sv/strings.xml @@ -0,0 +1,4 @@ + + + svenska.lng + \ No newline at end of file diff --git a/android/res/values-th/strings.xml b/android/res/values-th/strings.xml new file mode 100644 index 0000000000..f0d2670e4b --- /dev/null +++ b/android/res/values-th/strings.xml @@ -0,0 +1,4 @@ + + + thai.lng + \ No newline at end of file diff --git a/android/res/values-tl/strings.xml b/android/res/values-tl/strings.xml new file mode 100644 index 0000000000..4c53400336 --- /dev/null +++ b/android/res/values-tl/strings.xml @@ -0,0 +1,4 @@ + + + tagalog.lng + \ No newline at end of file diff --git a/android/res/values-tr/strings.xml b/android/res/values-tr/strings.xml new file mode 100644 index 0000000000..f5a656a1ea --- /dev/null +++ b/android/res/values-tr/strings.xml @@ -0,0 +1,4 @@ + + + turkce.lng + \ No newline at end of file diff --git a/android/res/values-uk/strings.xml b/android/res/values-uk/strings.xml new file mode 100644 index 0000000000..6ba7324651 --- /dev/null +++ b/android/res/values-uk/strings.xml @@ -0,0 +1,4 @@ + + + ukrainian.lng + \ No newline at end of file diff --git a/android/res/values-wa/strings.xml b/android/res/values-wa/strings.xml new file mode 100644 index 0000000000..24212670e2 --- /dev/null +++ b/android/res/values-wa/strings.xml @@ -0,0 +1,4 @@ + + + walon.lng + \ No newline at end of file diff --git a/android/res/values-zh-rCN/strings.xml b/android/res/values-zh-rCN/strings.xml new file mode 100644 index 0000000000..7bc6d06de5 --- /dev/null +++ b/android/res/values-zh-rCN/strings.xml @@ -0,0 +1,4 @@ + + + chinese-simp.lng + \ No newline at end of file diff --git a/android/res/values-zh-rTW/strings.xml b/android/res/values-zh-rTW/strings.xml new file mode 100644 index 0000000000..f6981b410e --- /dev/null +++ b/android/res/values-zh-rTW/strings.xml @@ -0,0 +1,4 @@ + + + chinese-trad.lng + \ No newline at end of file diff --git a/android/res/values/strings.xml b/android/res/values/strings.xml index c92e955edf..615e3d1ebf 100644 --- a/android/res/values/strings.xml +++ b/android/res/values/strings.xml @@ -11,6 +11,9 @@ Error occured during extraction! Rockbox is loading. Please wait... + +english.lng + Rockbox (line) Rockbox (square) diff --git a/android/src/org/rockbox/RockboxService.java b/android/src/org/rockbox/RockboxService.java index fb7c0437fc..c474044c0b 100644 --- a/android/src/org/rockbox/RockboxService.java +++ b/android/src/org/rockbox/RockboxService.java @@ -24,7 +24,9 @@ package org.rockbox; import java.io.BufferedInputStream; import java.io.BufferedOutputStream; import java.io.File; +import java.io.FileNotFoundException; import java.io.FileOutputStream; +import java.io.OutputStreamWriter; import java.util.Enumeration; import java.util.Timer; import java.util.TimerTask; @@ -41,6 +43,7 @@ import android.content.Context; import android.content.Intent; import android.content.IntentFilter; import android.os.Bundle; +import android.os.Environment; import android.os.IBinder; import android.os.ResultReceiver; import android.util.Log; @@ -245,6 +248,26 @@ public class RockboxService extends Service } } + /* Generate default config if none exists yet */ + File rockboxConfig = new File(Environment.getExternalStorageDirectory(), "rockbox/config.cfg"); + if (!rockboxConfig.exists()) { + File rbDir = new File(rockboxConfig.getParent()); + if (!rbDir.exists()) + rbDir.mkdirs(); + + OutputStreamWriter strm; + try { + strm = new OutputStreamWriter(new FileOutputStream(rockboxConfig)); + strm.write("# config generated by RockboxService\n"); + strm.write("start directory: " + Environment.getExternalStorageDirectory().getAbsolutePath() + "/" + "\n"); + strm.write("lang: /.rockbox/langs/" + getString(R.string.rockbox_language_file) + "\n"); + strm.close(); + } catch(Exception e) { + LOG("Exception when writing default config", e); + } + } + + /* Start native code */ if (resultReceiver != null) resultReceiver.send(RESULT_INVOKING_MAIN, null);