mirror of
https://github.com/nextcloud/android.git
synced 2024-11-29 02:38:58 +03:00
Replace Test with Snackbar
This commit is contained in:
parent
86340913a8
commit
a9b231e64d
2 changed files with 7 additions and 2 deletions
|
@ -47,6 +47,7 @@ import android.preference.PreferenceManager;
|
|||
import android.preference.PreferenceScreen;
|
||||
import android.preference.SwitchPreference;
|
||||
import android.support.annotation.LayoutRes;
|
||||
import android.support.design.widget.Snackbar;
|
||||
import android.support.v4.content.res.ResourcesCompat;
|
||||
import android.support.v7.app.ActionBar;
|
||||
import android.support.v7.app.AppCompatDelegate;
|
||||
|
@ -193,7 +194,8 @@ public class Preferences extends PreferenceActivity
|
|||
Log_OC.e(TAG, "Error detecting app version", e);
|
||||
}
|
||||
if (latestVersion == -1 || currentVersion == -1) {
|
||||
Toast.makeText(getApplicationContext(), "No information available!", Toast.LENGTH_SHORT).show();
|
||||
Snackbar.make(getListView(), R.string.dev_version_no_information_available,
|
||||
Snackbar.LENGTH_SHORT).show();
|
||||
}
|
||||
if (latestVersion > currentVersion) {
|
||||
String devApkLink = (String) getText(R.string.dev_link) + latestVersion + ".apk";
|
||||
|
@ -202,7 +204,8 @@ public class Preferences extends PreferenceActivity
|
|||
startActivity(intent);
|
||||
return true;
|
||||
} else {
|
||||
Toast.makeText(getApplicationContext(), "No new version available!", Toast.LENGTH_SHORT).show();
|
||||
Snackbar.make(getListView(), R.string.dev_version_no_new_version_available,
|
||||
Snackbar.LENGTH_SHORT).show();
|
||||
return true;
|
||||
}
|
||||
});
|
||||
|
|
|
@ -720,4 +720,6 @@
|
|||
<string name="store_full_dev_desc">The Open Source Nextcloud Android app allows you to access all your files on your Nextcloud.\nThis is a dev version of the official Nextcloud app and includes brand-new, untested features which might lead to instabilities and data loss. The app is designed for users willing to test the new features and to report bugs if they occur. Do not use it for your productive work!\n\nThe dev version can be installed alongside the official Nextcloud app which is available at F-Droid, too. Once a day it is checked if the source code was updated, so there can be longer pauses between builds.</string>
|
||||
|
||||
<string name="prefs_category_dev">Dev</string>
|
||||
<string name="dev_version_no_information_available">No information available!</string>
|
||||
<string name="dev_version_no_new_version_available">No new version available!</string>
|
||||
</resources>
|
||||
|
|
Loading…
Reference in a new issue