1
0
Fork 0
mirror of https://github.com/syncthing/syncthing-android.git synced 2024-11-29 15:51:17 +00:00

Add "folder is unshared" status label (fixes #347) (#351)

* res/colors: Add text_orange

* strings: Add state_unshared

* Imported de translation

* Add "folder is unshared" status label (fixes #347)
This commit is contained in:
Catfriend1 2019-03-06 00:58:34 +01:00 committed by GitHub
parent ce213b9c9e
commit 9ab2f280e0
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 11 additions and 2 deletions

View file

@ -105,8 +105,14 @@ public class FoldersAdapter extends ArrayAdapter<Folder> {
} else {
switch(folderStatus.state) {
case "idle":
binding.state.setText(mContext.getString(R.string.state_idle));
binding.state.setTextColor(ContextCompat.getColor(mContext, R.color.text_green));
if (folder.getDeviceCount() <= 1) {
// Special case: The folder is IDLE and UNSHARED.
binding.state.setText(mContext.getString(R.string.state_unshared));
binding.state.setTextColor(ContextCompat.getColor(mContext, R.color.text_orange));
} else {
binding.state.setText(mContext.getString(R.string.state_idle));
binding.state.setTextColor(ContextCompat.getColor(mContext, R.color.text_green));
}
break;
case "scanning":
binding.state.setText(mContext.getString(R.string.state_scanning));

View file

@ -840,6 +840,7 @@ Bitte melden Sie auftretende Probleme via GitHub.</string>
<string name="state_unknown">Unbekannt</string>
<string name="state_paused">Pausiert</string>
<string name="status_outofsync">Nicht synchronisiert</string>
<string name="state_unshared">Ungeteilt</string>
<!-- Format string for folder size, eg "500 MiB / 1 GiB" -->
<string name="folder_size_format">%1$s / %2$s</string>

View file

@ -9,6 +9,7 @@
<color name="text_red">#ffff4444</color>
<color name="text_blue">#ff33b5e5</color>
<color name="text_green">#ff99cc00</color>
<color name="text_orange">#f57c00</color>
<color name="light_grey">#cccccc</color>
<!-- FirstStartActivity welcome wizard start -->

View file

@ -861,6 +861,7 @@ Please report any problems you encounter via Github.</string>
<string name="state_unknown">Unknown</string>
<string name="state_paused">Paused</string>
<string name="status_outofsync">Out of Sync</string>
<string name="state_unshared">Unshared</string>
<!-- Format string for folder size, eg "500 MiB / 1 GiB" -->
<string name="folder_size_format">%1$s / %2$s</string>