mirror of
https://github.com/nextcloud/android.git
synced 2024-11-27 17:46:37 +03:00
Show maintenance mode message while downloading, removing, renaming or creating folder operations
This commit is contained in:
parent
ad6d867971
commit
c47970857c
2 changed files with 14 additions and 1 deletions
|
@ -106,6 +106,9 @@ public class ErrorMessageAdapter {
|
||||||
if (result.getCode() == ResultCode.FILE_NOT_FOUND) {
|
if (result.getCode() == ResultCode.FILE_NOT_FOUND) {
|
||||||
message = res.getString(R.string.downloader_download_file_not_found);
|
message = res.getString(R.string.downloader_download_file_not_found);
|
||||||
|
|
||||||
|
} else if (result.getCode() == ResultCode.MAINTENANCE_MODE) {
|
||||||
|
message = res.getString(R.string.maintenance_mode);
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
message = String.format(
|
message = String.format(
|
||||||
res.getString(R.string.downloader_download_failed_content), new File(
|
res.getString(R.string.downloader_download_failed_content), new File(
|
||||||
|
@ -122,6 +125,9 @@ public class ErrorMessageAdapter {
|
||||||
// Error --> No permissions
|
// Error --> No permissions
|
||||||
message = String.format(res.getString(R.string.forbidden_permissions),
|
message = String.format(res.getString(R.string.forbidden_permissions),
|
||||||
res.getString(R.string.forbidden_permissions_delete));
|
res.getString(R.string.forbidden_permissions_delete));
|
||||||
|
} else if (result.getCode() == ResultCode.MAINTENANCE_MODE) {
|
||||||
|
message = res.getString(R.string.maintenance_mode);
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
message = res.getString(R.string.remove_fail_msg);
|
message = res.getString(R.string.remove_fail_msg);
|
||||||
}
|
}
|
||||||
|
@ -142,6 +148,9 @@ public class ErrorMessageAdapter {
|
||||||
} else if (result.getCode() == ResultCode.INVALID_CHARACTER_DETECT_IN_SERVER) {
|
} else if (result.getCode() == ResultCode.INVALID_CHARACTER_DETECT_IN_SERVER) {
|
||||||
message = res.getString(R.string.filename_forbidden_charaters_from_server);
|
message = res.getString(R.string.filename_forbidden_charaters_from_server);
|
||||||
|
|
||||||
|
} else if (result.getCode() == ResultCode.MAINTENANCE_MODE) {
|
||||||
|
message = res.getString(R.string.maintenance_mode);
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
message = res.getString(R.string.rename_server_fail_msg);
|
message = res.getString(R.string.rename_server_fail_msg);
|
||||||
}
|
}
|
||||||
|
@ -161,6 +170,10 @@ public class ErrorMessageAdapter {
|
||||||
|
|
||||||
} else if (result.getCode() == ResultCode.INVALID_CHARACTER_DETECT_IN_SERVER) {
|
} else if (result.getCode() == ResultCode.INVALID_CHARACTER_DETECT_IN_SERVER) {
|
||||||
message = res.getString(R.string.filename_forbidden_charaters_from_server);
|
message = res.getString(R.string.filename_forbidden_charaters_from_server);
|
||||||
|
|
||||||
|
} else if (result.getCode() == ResultCode.MAINTENANCE_MODE) {
|
||||||
|
message = res.getString(R.string.maintenance_mode);
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
message = res.getString(R.string.create_dir_fail_msg);
|
message = res.getString(R.string.create_dir_fail_msg);
|
||||||
}
|
}
|
||||||
|
|
|
@ -543,7 +543,7 @@
|
||||||
<string name="local_file_not_found_toast">File not found in local file system</string>
|
<string name="local_file_not_found_toast">File not found in local file system</string>
|
||||||
<string name="confirmation_remove_files_alert">Do you really want to remove the selected items?</string>
|
<string name="confirmation_remove_files_alert">Do you really want to remove the selected items?</string>
|
||||||
<string name="confirmation_remove_folders_alert">Do you really want to remove the selected items and their contents?</string>
|
<string name="confirmation_remove_folders_alert">Do you really want to remove the selected items and their contents?</string>
|
||||||
<string name="maintenance_mode">This Owncloud instance is in maintenance mode, so it may take a while.</string>
|
<string name="maintenance_mode">This Owncloud instance is in maintenance mode, please try again later or contact your system administrator.</string>
|
||||||
|
|
||||||
<string name="uploads_view_upload_status_waiting_for_charging">Awaiting charge</string>
|
<string name="uploads_view_upload_status_waiting_for_charging">Awaiting charge</string>
|
||||||
<string name="actionbar_search">Search</string>
|
<string name="actionbar_search">Search</string>
|
||||||
|
|
Loading…
Reference in a new issue