Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/stefan-niedermann/nextcloud-notes.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/app
diff options
context:
space:
mode:
authorAndy Scherzinger <info@andy-scherzinger.de>2023-04-11 11:53:01 +0300
committerAndy Scherzinger <info@andy-scherzinger.de>2023-04-11 11:53:23 +0300
commit5cab30bcf19aa97dd9df8ca8096e1e6874e05f1b (patch)
treed20b8ce06882ef190dfa022215caea1563314e4a /app
parentfc4ed90d2f47cb308d6d0f1ee605162edd2a8579 (diff)
reformat for 120 characters line length
Signed-off-by: Andy Scherzinger <info@andy-scherzinger.de>
Diffstat (limited to 'app')
-rw-r--r--app/src/main/java/it/niedermann/owncloud/notes/branding/NotesViewThemeUtils.java15
1 files changed, 11 insertions, 4 deletions
diff --git a/app/src/main/java/it/niedermann/owncloud/notes/branding/NotesViewThemeUtils.java b/app/src/main/java/it/niedermann/owncloud/notes/branding/NotesViewThemeUtils.java
index f1862e4f..d3970b33 100644
--- a/app/src/main/java/it/niedermann/owncloud/notes/branding/NotesViewThemeUtils.java
+++ b/app/src/main/java/it/niedermann/owncloud/notes/branding/NotesViewThemeUtils.java
@@ -88,7 +88,9 @@ public class NotesViewThemeUtils extends ViewThemeUtilsBase {
* @deprecated should be replaced by {@link MaterialViewThemeUtils#themeToolbar(MaterialToolbar)}.
*/
@Deprecated(forRemoval = true)
- public void applyBrandToPrimaryToolbar(@NonNull AppBarLayout appBarLayout, @NonNull Toolbar toolbar, @ColorInt int color) {
+ public void applyBrandToPrimaryToolbar(@NonNull AppBarLayout appBarLayout,
+ @NonNull Toolbar toolbar,
+ @ColorInt int color) {
// FIXME Workaround for https://github.com/nextcloud/notes-android/issues/889
appBarLayout.setBackgroundColor(ContextCompat.getColor(appBarLayout.getContext(), R.color.primary));
@@ -118,7 +120,10 @@ public class NotesViewThemeUtils extends ViewThemeUtilsBase {
}
@ColorInt
- public int getTextHighlightBackgroundColor(@NonNull Context context, @ColorInt int mainColor, @ColorInt int colorPrimary, @ColorInt int colorAccent) {
+ public int getTextHighlightBackgroundColor(@NonNull Context context,
+ @ColorInt int mainColor,
+ @ColorInt int colorPrimary,
+ @ColorInt int colorAccent) {
if (isDarkMode(context)) { // Dark background
if (ColorUtil.INSTANCE.isColorDark(mainColor)) { // Dark brand color
if (NotesColorUtil.contrastRatioIsSufficient(mainColor, colorPrimary)) { // But also dark text
@@ -162,7 +167,8 @@ public class NotesViewThemeUtils extends ViewThemeUtilsBase {
}
/**
- * @deprecated Should be replaced with {@link com.google.android.material.search.SearchBar} or {@link MaterialViewThemeUtils#themeToolbar(MaterialToolbar)}
+ * @deprecated Should be replaced with {@link com.google.android.material.search.SearchBar} or
+ * {@link MaterialViewThemeUtils#themeToolbar(MaterialToolbar)}
*/
@Deprecated
public void themeSearchToolbar(@NonNull MaterialToolbar toolbar) {
@@ -181,7 +187,8 @@ public class NotesViewThemeUtils extends ViewThemeUtilsBase {
public void themeToolbarSearchView(@NonNull SearchView searchView) {
withScheme(searchView, scheme -> {
// hacky as no default way is provided
- final var editText = (SearchView.SearchAutoComplete) searchView.findViewById(androidx.appcompat.R.id.search_src_text);
+ final var editText = (SearchView.SearchAutoComplete) searchView
+ .findViewById(androidx.appcompat.R.id.search_src_text);
final var closeButton = (ImageView) searchView.findViewById(androidx.appcompat.R.id.search_close_btn);
final var searchButton = (ImageView) searchView.findViewById(androidx.appcompat.R.id.search_button);
editText.setHintTextColor(scheme.getOnSurfaceVariant());