diff --git a/src/app/release/app-release.apk b/src/app/release/LocateMyDevice.apk
similarity index 59%
rename from src/app/release/app-release.apk
rename to src/app/release/LocateMyDevice.apk
index 494d202..266ecc5 100644
Binary files a/src/app/release/app-release.apk and b/src/app/release/LocateMyDevice.apk differ
diff --git a/src/app/release/output-metadata.json b/src/app/release/output-metadata.json
index 38f41b8..d9eb4ff 100644
--- a/src/app/release/output-metadata.json
+++ b/src/app/release/output-metadata.json
@@ -11,8 +11,8 @@
"type": "SINGLE",
"filters": [],
"attributes": [],
- "versionCode": 2,
- "versionName": "1.0",
+ "versionCode": 3,
+ "versionName": "1.0.2",
"outputFile": "app-release.apk"
}
],
diff --git a/src/app/src/main/java/com/xfarrow/locatemydevice/MainActivity.java b/src/app/src/main/java/com/xfarrow/locatemydevice/MainActivity.java
index 0a75e9c..999e19f 100644
--- a/src/app/src/main/java/com/xfarrow/locatemydevice/MainActivity.java
+++ b/src/app/src/main/java/com/xfarrow/locatemydevice/MainActivity.java
@@ -69,9 +69,8 @@ public class MainActivity extends AppCompatActivity {
public void displayDrawOverlayPermissionDialog(){
AlertDialog.Builder alert = new AlertDialog.Builder(this);
- alert.setTitle("Display over other apps");
- alert.setMessage("Please, enable 'Display over other apps' permission. " +
- "It is required for using the option 'callme'");
+ alert.setTitle(R.string.display_over_other_apps);
+ alert.setMessage(R.string.display_over_other_apps_request_description);
alert.setPositiveButton("Settings", new DialogInterface.OnClickListener() {
public void onClick(DialogInterface dialog, int whichButton) {
@@ -80,7 +79,7 @@ public class MainActivity extends AppCompatActivity {
}
});
- alert.setNeutralButton("Cancel", new DialogInterface.OnClickListener() {
+ alert.setNeutralButton(R.string.cancel, new DialogInterface.OnClickListener() {
@Override
public void onClick(DialogInterface dialogInterface, int i) {
dialogInterface.cancel();
@@ -92,8 +91,7 @@ public class MainActivity extends AppCompatActivity {
public void requestAdminPermission(ComponentName cn){
Intent intent= new Intent(DevicePolicyManager.ACTION_ADD_DEVICE_ADMIN);
intent.putExtra(DevicePolicyManager.EXTRA_DEVICE_ADMIN, cn);
- intent.putExtra(DevicePolicyManager.EXTRA_ADD_EXPLANATION, "The app requires this" +
- " permission to provide the 'lock' feature.");
+ intent.putExtra(DevicePolicyManager.EXTRA_ADD_EXPLANATION, R.string.admin_permission_request_description);
startActivity(intent);
}
diff --git a/src/app/src/main/java/com/xfarrow/locatemydevice/SettingsActivity.java b/src/app/src/main/java/com/xfarrow/locatemydevice/SettingsActivity.java
index d3f4f84..09d2acb 100644
--- a/src/app/src/main/java/com/xfarrow/locatemydevice/SettingsActivity.java
+++ b/src/app/src/main/java/com/xfarrow/locatemydevice/SettingsActivity.java
@@ -59,8 +59,8 @@ public class SettingsActivity extends AppCompatActivity {
@Override
public void onClick(View v) {
AlertDialog.Builder alert = new AlertDialog.Builder(SettingsActivity.this);
- alert.setTitle("Password");
- alert.setMessage("Enter Password");
+ alert.setTitle(R.string.password);
+ alert.setMessage(R.string.choose_a_password);
EditText input = new EditText(SettingsActivity.this);
input.setTransformationMethod(new PasswordTransformationMethod());
alert.setView(input);
@@ -72,12 +72,12 @@ public class SettingsActivity extends AppCompatActivity {
settings.set(Settings.PASSWORD, CipherUtils.get256Sha(text));
}
else{
- Toast.makeText(SettingsActivity.this, "Cannot use a blank password. Aborted!", Toast.LENGTH_LONG).show();
+ Toast.makeText(SettingsActivity.this, R.string.cannot_use_a_blank_password, Toast.LENGTH_LONG).show();
}
}
});
- alert.setNeutralButton("Cancel", new DialogInterface.OnClickListener() {
+ alert.setNeutralButton(R.string.cancel, new DialogInterface.OnClickListener() {
@Override
public void onClick(DialogInterface dialogInterface, int i) {
dialogInterface.cancel();
@@ -114,7 +114,7 @@ public class SettingsActivity extends AppCompatActivity {
@Override
public void afterTextChanged(Editable s) {
if (s.toString().isEmpty()) {
- Toast.makeText(SettingsActivity.this, "Empty SMS command not allowed, reverted to default (LMD)", Toast.LENGTH_LONG).show();
+ Toast.makeText(SettingsActivity.this, R.string.empty_sms_command_not_allowed, Toast.LENGTH_LONG).show();
settings.set(Settings.SMS_COMMAND, settings.defaultValues(Settings.SMS_COMMAND));
} else {
settings.set(Settings.SMS_COMMAND, s.toString());
diff --git a/src/app/src/main/java/com/xfarrow/locatemydevice/WhitelistContactsActivity.java b/src/app/src/main/java/com/xfarrow/locatemydevice/WhitelistContactsActivity.java
index 8b4f9f2..16fb7a4 100644
--- a/src/app/src/main/java/com/xfarrow/locatemydevice/WhitelistContactsActivity.java
+++ b/src/app/src/main/java/com/xfarrow/locatemydevice/WhitelistContactsActivity.java
@@ -31,7 +31,7 @@ public class WhitelistContactsActivity extends AppCompatActivity {
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_whitelist_contacts);
- setTitle("Whitelist");
+ setTitle(R.string.whitelist);
setViews();
setListeners();
@@ -50,7 +50,7 @@ public class WhitelistContactsActivity extends AppCompatActivity {
contactsListView.setOnItemClickListener(new AdapterView.OnItemClickListener() {
@Override
public void onItemClick(AdapterView> adapterView, View view, int i, long l) {
- Toast.makeText(WhitelistContactsActivity.this, "Long click to delete", Toast.LENGTH_SHORT).show();
+ Toast.makeText(WhitelistContactsActivity.this, R.string.long_click_to_delete, Toast.LENGTH_SHORT).show();
}
});
@@ -106,7 +106,7 @@ public class WhitelistContactsActivity extends AppCompatActivity {
private void addNumberToWhiteList(String phoneNo){
phoneNo = Utils.normalizePhoneNumber(phoneNo);
if(contactsListView_datasource.contains(phoneNo)){
- Toast.makeText(this, "Contact already in the list", Toast.LENGTH_SHORT).show();
+ Toast.makeText(this, R.string.contact_already_in_the_list, Toast.LENGTH_SHORT).show();
return;
}
whitelistDbHandler.addContact(phoneNo);
diff --git a/src/app/src/main/res/layout/activity_app_info.xml b/src/app/src/main/res/layout/activity_app_info.xml
index 47c264d..d3bddca 100644
--- a/src/app/src/main/res/layout/activity_app_info.xml
+++ b/src/app/src/main/res/layout/activity_app_info.xml
@@ -35,7 +35,7 @@
android:layout_height="wrap_content"
android:layout_marginLeft="10dp"
android:layout_marginRight="10dp"
- android:text="This software is open source licensed under General Public License v3.0\n\nSource code and instructions at\nhttps://www.github.com/xfarrow/locatemydevice"
+ android:text="@string/app_open_source_description"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.0"
diff --git a/src/app/src/main/res/layout/activity_main.xml b/src/app/src/main/res/layout/activity_main.xml
index be7a530..7272471 100644
--- a/src/app/src/main/res/layout/activity_main.xml
+++ b/src/app/src/main/res/layout/activity_main.xml
@@ -10,7 +10,7 @@
android:id="@+id/textView"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
- android:text="Locate my device is running"
+ android:text="@string/locate_my_device_is_running"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.497"
@@ -22,13 +22,13 @@
android:id="@+id/imageView"
android:layout_width="181dp"
android:layout_height="171dp"
- android:contentDescription="logo"
android:src="@drawable/logo"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_bias="0.5"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent"
- app:layout_constraintVertical_bias="0.5" />
+ app:layout_constraintVertical_bias="0.5"
+ android:contentDescription="logo" />
\ No newline at end of file
diff --git a/src/app/src/main/res/layout/settings.xml b/src/app/src/main/res/layout/settings.xml
index f945363..20c0859 100644
--- a/src/app/src/main/res/layout/settings.xml
+++ b/src/app/src/main/res/layout/settings.xml
@@ -21,13 +21,13 @@
android:layout_marginStart="10dp"
android:layout_marginTop="10dp"
android:textSize="17sp"
- android:text="SMS command" />
+ android:text="@string/sms_command" />
+ android:text="@string/sms_command_description" />
+ android:text="@string/password" />
+ android:text="@string/choose_a_password" />
+ android:text="@string/enter_password"/>
+ android:text="@string/whitelist" />
@@ -92,7 +92,7 @@
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginStart="10dp"
- android:text="Only contacts in the whitelist are allowed to communicate with this smartphone"/>
+ android:text="@string/whitelist_description"/>
+ android:text="@string/whitelist_contacts"/>
+ android:text="@string/info" />
+ android:text="@string/click_here_for_more_info"/>
-
-
+
diff --git a/src/app/src/main/res/values-it-rIT/strings.xml b/src/app/src/main/res/values-it-rIT/strings.xml
new file mode 100644
index 0000000..8fb41d9
--- /dev/null
+++ b/src/app/src/main/res/values-it-rIT/strings.xml
@@ -0,0 +1,26 @@
+
+
+ Comando SMS
+ Scegli un comando con cui inizializzare la conversazione con lo smartphone
+ Scegli una password
+ Inserisci password
+ Lista bianca
+ Abilitata
+ Solo i contatti nella lista bianca sono autorizzati a comunicare con questo smartphone
+ Contatti in lista bianca
+ Info
+ Clicca qui per più info
+ Password
+ Versione app:
+ Questo software è open source ed è sotto licenza GPLv3\n\nCodice sorgente ed istruzioni a\nhttps://www.github.com/xfarrow/locatemydevice
+ Trova il mio dispositivo
+ Trova il mio dispositivo è in esecuzione
+ Mostra sulle altre app
+ Per favore, abilita l\'opzione \'mostra sulle altre app\'. Ciò è richiesto per le opzioni \'callme\' e \'show\'
+ Annulla
+ L\'app richiede questo permesso per utilizzare l\'opzione \'lock\'
+ Non è possibile usare una password vuota. Operazione annullata.
+ Non è consentito usare un comando SMS vuoto. Ripristinato il valore di default (LMD)
+ Click prolungato per cancellare
+ Contatto già presente nella lista
+
\ No newline at end of file
diff --git a/src/app/src/main/res/values/strings.xml b/src/app/src/main/res/values/strings.xml
index 72240ef..2e5cc96 100644
--- a/src/app/src/main/res/values/strings.xml
+++ b/src/app/src/main/res/values/strings.xml
@@ -1,3 +1,25 @@
Locate my device
+ SMS command
+ Choose a command to initialize the conversation with the smartphone
+ Password
+ Choose a password
+ Enter password
+ Whitelist
+ Enabled
+ Only contacts in the whitelist are allowed to communicate with this smartphone
+ Whitelist contacts
+ Info
+ Click here for more info
+ App version:
+ This software is open source and licensed under GPLv3\n\nSource code and instructions at\nhttps://www.github.com/xfarrow/locatemydevice
+ Locate my device is running
+ Display over other apps
+ Please, enable \'Display over other apps\' permission. It is required for using the options \'callme\' and \'show\'
+ Cancel
+ The app requires this permission to provide the \'lock\' feature.
+ Cannot use a blank password. Aborted.
+ Empty SMS command not allowed, reverted to default (LMD)
+ Long click to delete
+ Contact already in the list
\ No newline at end of file