summaryrefslogtreecommitdiffstats
path: root/android/src
diff options
context:
space:
mode:
authorThomas Martitz <kugel@rockbox.org>2010-11-06 01:40:24 +0000
committerThomas Martitz <kugel@rockbox.org>2010-11-06 01:40:24 +0000
commit739d76cfda5793256e849acd082d90f1e09c9494 (patch)
tree4fb4f027e296040fcd8e36722709f7762285c2d3 /android/src
parent93640fc22847e70f0070061ed1effc5d063dd600 (diff)
downloadrockbox-739d76cfda5793256e849acd082d90f1e09c9494.tar.gz
rockbox-739d76cfda5793256e849acd082d90f1e09c9494.tar.bz2
rockbox-739d76cfda5793256e849acd082d90f1e09c9494.zip
Android: Use our translations for the yes/no/ok/cancel buttons in the yesno and keyboard dialog.
Second part of FS#11708. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@28515 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'android/src')
-rw-r--r--android/src/org/rockbox/RockboxKeyboardInput.java7
-rw-r--r--android/src/org/rockbox/RockboxYesno.java7
2 files changed, 6 insertions, 8 deletions
diff --git a/android/src/org/rockbox/RockboxKeyboardInput.java b/android/src/org/rockbox/RockboxKeyboardInput.java
index b7dd812f35..9cb5683a57 100644
--- a/android/src/org/rockbox/RockboxKeyboardInput.java
+++ b/android/src/org/rockbox/RockboxKeyboardInput.java
@@ -33,12 +33,11 @@ import android.widget.EditText;
public class RockboxKeyboardInput
{
- public void kbd_input(final String text)
+ public void kbd_input(final String text, final String ok, final String cancel)
{
final Activity c = RockboxService.get_instance().get_activity();
c.runOnUiThread(new Runnable() {
- @Override
public void run()
{
LayoutInflater inflater = LayoutInflater.from(c);
@@ -50,7 +49,7 @@ public class RockboxKeyboardInput
.setView(addView)
.setIcon(R.drawable.icon)
.setCancelable(false)
- .setPositiveButton(R.string.OK, new DialogInterface.OnClickListener()
+ .setPositiveButton(ok, new DialogInterface.OnClickListener()
{
public void onClick(DialogInterface dialog, int whichButton) {
EditText input = (EditText)((Dialog)dialog)
@@ -59,7 +58,7 @@ public class RockboxKeyboardInput
put_result(true, s.toString());
}
})
- .setNegativeButton(R.string.Cancel, new DialogInterface.OnClickListener()
+ .setNegativeButton(cancel, new DialogInterface.OnClickListener()
{
public void onClick(DialogInterface dialog, int whichButton)
{
diff --git a/android/src/org/rockbox/RockboxYesno.java b/android/src/org/rockbox/RockboxYesno.java
index 9481d69d01..df8c54b7d9 100644
--- a/android/src/org/rockbox/RockboxYesno.java
+++ b/android/src/org/rockbox/RockboxYesno.java
@@ -28,12 +28,11 @@ import android.content.DialogInterface;
public class RockboxYesno
{
@SuppressWarnings("unused")
- private void yesno_display(final String text)
+ private void yesno_display(final String text, final String yes, final String no)
{
final Activity c = RockboxService.get_instance().get_activity();
c.runOnUiThread(new Runnable() {
- @Override
public void run()
{
new AlertDialog.Builder(c)
@@ -41,14 +40,14 @@ public class RockboxYesno
.setIcon(R.drawable.icon)
.setCancelable(false)
.setMessage(text)
- .setPositiveButton(R.string.Yes, new DialogInterface.OnClickListener()
+ .setPositiveButton(yes, new DialogInterface.OnClickListener()
{
public void onClick(DialogInterface dialog, int whichButton)
{
put_result(true);
}
})
- .setNegativeButton(R.string.No, new DialogInterface.OnClickListener()
+ .setNegativeButton(no, new DialogInterface.OnClickListener()
{
public void onClick(DialogInterface dialog, int whichButton)
{