Skip to content

Commit 08621bf

Browse files
committed
Code refactored.
1 parent 688d6b0 commit 08621bf

File tree

7 files changed

+36
-33
lines changed

7 files changed

+36
-33
lines changed

app/src/main/java/com/owncloud/android/ui/activity/ToolbarActivity.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -74,8 +74,8 @@ public abstract class ToolbarActivity extends BaseActivity implements Injectable
7474
private LinearLayout mInfoBox;
7575
private TextView mInfoBoxMessage;
7676
protected AppCompatSpinner mToolbarSpinner;
77-
private ImageView mToolbarBackIcon;
7877
private boolean isHomeSearchToolbarShow = false;
78+
private ImageView mToolbarBackIcon;
7979

8080
@Inject public ThemeColorUtils themeColorUtils;
8181
@Inject public ThemeUtils themeUtils;
@@ -94,8 +94,8 @@ private void setupToolbar(boolean isHomeSearchToolbarShow, boolean showSortListB
9494
mHomeSearchToolbar = findViewById(R.id.home_toolbar);
9595
mMenuButton = findViewById(R.id.menu_button);
9696
mSearchText = findViewById(R.id.search_text);
97-
mSwitchAccountButton = findViewById(R.id.switch_account_button);
9897
mToolbarBackIcon = findViewById(R.id.toolbar_back_icon);
98+
mSwitchAccountButton = findViewById(R.id.switch_account_button);
9999

100100
if (showSortListButtonGroup) {
101101
findViewById(R.id.sort_list_button_group).setVisibility(View.VISIBLE);

app/src/main/java/com/owncloud/android/utils/DisplayUtils.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,7 @@
106106
import java.util.Locale;
107107
import java.util.Map;
108108
import java.util.TimeZone;
109+
import java.util.concurrent.RejectedExecutionException;
109110

110111
import androidx.annotation.NonNull;
111112
import androidx.annotation.Nullable;
@@ -1022,4 +1023,5 @@ public static boolean isTablet() {
10221023
public static boolean isLandscapeOrientation() {
10231024
return MainApp.getAppContext().getResources().getConfiguration().orientation == Configuration.ORIENTATION_LANDSCAPE;
10241025
}
1026+
10251027
}

app/src/main/res/values-de/strings.xml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -111,12 +111,14 @@
111111
<string name="common_cancel">Abbrechen</string>
112112
<string name="common_cancel_sync">Synchronisierung abbrechen</string>
113113
<string name="common_choose_account">Konto auswählen</string>
114+
<string name="common_confirm">Übernehmen</string>
114115
<string name="common_copy">Kopieren</string>
115116
<string name="common_delete">Löschen</string>
116117
<string name="common_error">Fehler</string>
117118
<string name="common_error_out_memory">Nicht genügend Speicher</string>
118119
<string name="common_error_unknown">Unbekannter Fehler</string>
119120
<string name="common_loading">Lade…</string>
121+
<string name="common_next">Weiter</string>
120122
<string name="common_no">Nein</string>
121123
<string name="common_ok">OK</string>
122124
<string name="common_pending">Ausstehend</string>
@@ -129,8 +131,6 @@
129131
<string name="common_skip">Überspringen</string>
130132
<string name="common_switch_account">Konto wechseln</string>
131133
<string name="common_switch_to_account">Zu Konto wechseln</string>
132-
<string name="common_next">Weiter</string>
133-
<string name="common_confirm">Übernehmen</string>
134134
<string name="common_yes">Ja</string>
135135
<string name="community_beta_headline">Testen Sie die Entwickler-Version</string>
136136
<string name="community_beta_text">Dies beinhaltet neue Funktionalitäten und ist nicht komplett qualitätsgesichert. Es können daher Fehler/Bugs auftreten, melden Sie uns solche bitte.</string>
@@ -922,6 +922,10 @@
922922
<string name="write_email">E-Mail senden</string>
923923
<string name="wrong_storage_path">Speicherordner existiert nicht!</string>
924924
<string name="wrong_storage_path_desc">Ursache könnte die Wiederherstellung einer Sicherungskopie auf einem anderen Gerät sein. Der Standard-Ordner wird jetzt wieder verwendet. Bitte überprüfen Sie die Einstellungen bezüglich des Speicherortes.</string>
925+
<plurals name="sync_fail_in_favourites_content">
926+
<item quantity="one">Inhalte von %1$d Datei konnten nicht synchronisiert werden (Konflikte: %2$d)</item>
927+
<item quantity="other">Inhalte von %1$d Dateien konnten nicht synchronisiert werden (Konflikte: %2$d)</item>
928+
</plurals>
925929
<!-- sharing related strings start -->
926930
<string name="share_permission_read_only">Nur lesen</string>
927931
<string name="share_permission_can_edit">Kann Bearbeiten</string>
@@ -959,10 +963,6 @@
959963
<string name="expiration_date">Expiration Date</string>
960964
<string name="empty_shares">Noch keine Freigaben erstellt.</string>
961965
<!-- sharing related strings end -->
962-
<plurals name="sync_fail_in_favourites_content">
963-
<item quantity="one">Inhalte von %1$d Datei konnten nicht synchronisiert werden (Konflikte: %2$d)</item>
964-
<item quantity="other">Inhalte von %1$d Dateien konnten nicht synchronisiert werden (Konflikte: %2$d)</item>
965-
</plurals>
966966
<plurals name="sync_foreign_files_forgotten_content">
967967
<item quantity="one">%1$d Datei im %2$s-Verzeichnis konnten nicht kopiert werden nach </item>
968968
<item quantity="other">%1$d Dateien im %2$s-Verzeichnis konnten nicht kopiert werden nach </item>

app/src/main/res/values-night/colors.xml

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -26,17 +26,7 @@
2626
<color name="secondary_text_color">#A5A5A5</color>
2727
<color name="list_divider_background">#222222</color>
2828
<color name="list_icon_color">@color/grey_30</color>
29-
30-
<!-- Share Colors -->
31-
<color name="share_title_txt_color">#FFFFFF</color>
32-
<color name="share_subtitle_txt_color">@color/grey_30</color>
33-
<color name="share_info_txt_color">@color/grey_0</color>
34-
<color name="share_search_border_color">@color/grey_0</color>
35-
<color name="share_btn_txt_color">@color/grey_0</color>
36-
<color name="share_list_item_txt_color">@color/grey_0</color>
37-
<color name="share_disabled_txt_color">@color/grey_60</color>
38-
<color name="share_txt_color">@color/grey_0</color>
39-
<color name="share_et_divider">#FFFFFF</color>
29+
<color name="warning_icon_color">#CCCCCC</color>
4030

4131
<!-- Colors -->
4232
<color name="dark">#ffffff</color>
@@ -61,6 +51,17 @@
6151
<color name="checkbox_checked_disabled">@color/grey_70</color>
6252
<color name="checkbox_unchecked_disabled">@color/grey_70</color>
6353

54+
<!-- Share Colors -->
55+
<color name="share_title_txt_color">#FFFFFF</color>
56+
<color name="share_subtitle_txt_color">@color/grey_30</color>
57+
<color name="share_info_txt_color">@color/grey_0</color>
58+
<color name="share_search_border_color">@color/grey_0</color>
59+
<color name="share_btn_txt_color">@color/grey_0</color>
60+
<color name="share_list_item_txt_color">@color/grey_0</color>
61+
<color name="share_disabled_txt_color">@color/grey_60</color>
62+
<color name="share_txt_color">@color/grey_0</color>
63+
<color name="share_et_divider">#FFFFFF</color>
64+
6465
<!-- Multiselect backgrounds -->
6566
<color name="action_mode_background">@color/appbar</color>
6667
<color name="selected_item_background">#373535</color>

app/src/main/res/values/colors.xml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@
2121
<color name="list_item_lastmod_and_filesize_text">@color/secondary_text_color</color>
2222
<color name="black">#000000</color>
2323
<color name="white">#ffffff</color>
24+
<color name="search_et_highlight_color">#77c4ff</color>
2425
<color name="white_helper_text">#B3FFFFFF</color>
2526
<color name="text_color">#333333</color>
2627
<color name="drawer_text_color">@color/secondary_text_color</color>
@@ -29,11 +30,10 @@
2930
<color name="list_divider_background">#eeeeee</color>
3031
<color name="fg_inverse">#FFFFFF</color>
3132
<color name="filelist_icon_background">#DDDDDD</color>
33+
<color name="list_icon_color">#191919</color>
3234
<color name="dark_background_text_color">#EEEEEE</color>
3335
<color name="transparent">#00000000</color>
3436
<color name="secondary_text_color">#666666</color>
35-
<color name="search_et_highlight_color">#77c4ff</color>
36-
<color name="list_icon_color">#191919</color>
3737
<color name="highlight_textColor_Warning">#e53935</color>
3838

3939
<!-- Share Colors -->
@@ -125,7 +125,7 @@
125125
<!-- App bar -->
126126
<color name="appbar">@android:color/white</color>
127127
<color name="fontAppbar">#666666</color>
128-
<color name="white_trans_70">#B3FFFFFF</color>
129128
<color name="fontSecondaryAppbar">#A5A5A5</color>
129+
<color name="white_trans_70">#B3FFFFFF</color>
130130
<color name="shared_with_me_color">#0099ff</color>
131131
</resources>

app/src/main/res/values/dimens.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,4 +31,4 @@
3131
<dimen name="notification_row_item_height">145dp</dimen>
3232
<dimen name="button_stroke_width">1dp</dimen>
3333
<dimen name="txt_size_13sp">13sp</dimen>
34-
</resources>
34+
</resources>

app/src/main/res/values/strings.xml

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -126,8 +126,6 @@
126126
<string name="common_share">Share</string>
127127
<string name="common_skip">Skip</string>
128128
<string name="common_copy">Copy</string>
129-
<string name="common_confirm">Confirm</string>
130-
<string name="common_next">Next</string>
131129
<string name="about_title">About</string>
132130
<string name="delete_account">Remove account</string>
133131
<string name="delete_account_warning">Remove account %s and delete all local files?\n\nDeletion cannot be undone.</string>
@@ -947,7 +945,6 @@
947945
<string name="share_link_folder">Link to folder</string>
948946
<string name="share_link_file">Link to file</string>
949947
<string name="allow_resharing">Allow resharing</string>
950-
<string name="link_share_read_only">Read only</string>
951948
<string name="link_share_editing">Editing</string>
952949
<string name="link_share_allow_upload_and_editing">Allow upload and editing</string>
953950
<string name="link_share_file_drop">File drop (upload only)</string>
@@ -981,14 +978,8 @@
981978
<string name="wrong_storage_path">Data storage folder does not exist!</string>
982979
<string name="wrong_storage_path_desc">This might be due to a backup restore on another device. Falling back to default. Please check settings to adjust data storage folder.</string>
983980
<string name="dialog_close">Close</string>
984-
<string name="direct_login_failed">Login via direct link failed!</string>
985-
<string name="login_url_helper_text">The link to your %1$s web interface when you open it in the browser.</string>
986-
<string name="brute_force_delay">Delayed due to too many wrong attempts</string>
987-
<string name="create">Create</string>
988-
<string name="select_one_template">Please select one template</string>
989-
<string name="choose_template_helper_text">Please choose a template and enter a file name.</string>
990-
<string name="share_permission_secure_file_drop">Secure file drop</string>
991981
<!-- sharing related strings start -->
982+
<string name="link_share_read_only">Read only</string>
992983
<string name="share_permission_read_only">Read only</string>
993984
<string name="share_permission_can_edit">Can edit</string>
994985
<string name="share_permission_file_drop">Filedrop only</string>
@@ -1025,6 +1016,15 @@
10251016
<string name="placeholder_receivedMessage">Received</string>
10261017
<string name="placeholder_sharedMessage">Shared</string>
10271018
<!-- sharing related strings end -->
1019+
<string name="direct_login_failed">Login via direct link failed!</string>
1020+
<string name="login_url_helper_text">The link to your %1$s web interface when you open it in the browser.</string>
1021+
<string name="brute_force_delay">Delayed due to too many wrong attempts</string>
1022+
<string name="create">Create</string>
1023+
<string name="select_one_template">Please select one template</string>
1024+
<string name="choose_template_helper_text">Please choose a template and enter a file name.</string>
1025+
<string name="share_permission_secure_file_drop">Secure file drop</string>
1026+
<string name="common_next">Next</string>
1027+
<string name="common_confirm">Confirm</string>
10281028
<string name="strict_mode">Strict mode: no HTTP connection allowed!</string>
10291029
<string name="destination_filename">Destination filename</string>
10301030
<string name="suggest">Suggest</string>

0 commit comments

Comments
 (0)