From e250c4d7436671d5de803fcfab62565f54506ee8 Mon Sep 17 00:00:00 2001 From: M66B Date: Tue, 1 Oct 2019 10:13:22 +0200 Subject: [PATCH] Refactoring --- app/src/main/java/eu/faircode/email/FragmentAccount.java | 2 +- app/src/main/java/eu/faircode/email/FragmentIdentity.java | 2 +- app/src/main/java/eu/faircode/email/FragmentPop.java | 2 +- app/src/main/java/eu/faircode/email/FragmentRule.java | 2 +- .../email/{ButtonColor.java => ViewButtonColor.java} | 8 ++++---- app/src/main/res/layout/fragment_account.xml | 2 +- app/src/main/res/layout/fragment_identity.xml | 2 +- app/src/main/res/layout/fragment_pop.xml | 2 +- app/src/main/res/layout/fragment_rule.xml | 2 +- 9 files changed, 12 insertions(+), 12 deletions(-) rename app/src/main/java/eu/faircode/email/{ButtonColor.java => ViewButtonColor.java} (92%) diff --git a/app/src/main/java/eu/faircode/email/FragmentAccount.java b/app/src/main/java/eu/faircode/email/FragmentAccount.java index fb361b96e7..6ea7809224 100644 --- a/app/src/main/java/eu/faircode/email/FragmentAccount.java +++ b/app/src/main/java/eu/faircode/email/FragmentAccount.java @@ -91,7 +91,7 @@ public class FragmentAccount extends FragmentBase { private EditText etRealm; private EditText etName; - private ButtonColor btnColor; + private ViewButtonColor btnColor; private TextView tvColorPro; private Button btnAdvanced; diff --git a/app/src/main/java/eu/faircode/email/FragmentIdentity.java b/app/src/main/java/eu/faircode/email/FragmentIdentity.java index 44142f34a8..a1665685cf 100644 --- a/app/src/main/java/eu/faircode/email/FragmentIdentity.java +++ b/app/src/main/java/eu/faircode/email/FragmentIdentity.java @@ -82,7 +82,7 @@ public class FragmentIdentity extends FragmentBase { private Spinner spAccount; private EditText etDisplay; - private ButtonColor btnColor; + private ViewButtonColor btnColor; private TextView tvColorPro; private EditText etSignature; private Button btnHtml; diff --git a/app/src/main/java/eu/faircode/email/FragmentPop.java b/app/src/main/java/eu/faircode/email/FragmentPop.java index dfbd17e610..f1835e6eee 100644 --- a/app/src/main/java/eu/faircode/email/FragmentPop.java +++ b/app/src/main/java/eu/faircode/email/FragmentPop.java @@ -67,7 +67,7 @@ public class FragmentPop extends FragmentBase { private TextInputLayout tilPassword; private EditText etName; - private ButtonColor btnColor; + private ViewButtonColor btnColor; private TextView tvColorPro; private CheckBox cbSynchronize; diff --git a/app/src/main/java/eu/faircode/email/FragmentRule.java b/app/src/main/java/eu/faircode/email/FragmentRule.java index e35abc6785..42814c8a00 100644 --- a/app/src/main/java/eu/faircode/email/FragmentRule.java +++ b/app/src/main/java/eu/faircode/email/FragmentRule.java @@ -110,7 +110,7 @@ public class FragmentRule extends FragmentBase { private NumberPicker npDuration; private CheckBox cbScheduleEnd; - private ButtonColor btnColor; + private ViewButtonColor btnColor; private Spinner spTarget; private CheckBox cbMoveSeen; diff --git a/app/src/main/java/eu/faircode/email/ButtonColor.java b/app/src/main/java/eu/faircode/email/ViewButtonColor.java similarity index 92% rename from app/src/main/java/eu/faircode/email/ButtonColor.java rename to app/src/main/java/eu/faircode/email/ViewButtonColor.java index 901399b5f1..dbc1e89707 100644 --- a/app/src/main/java/eu/faircode/email/ButtonColor.java +++ b/app/src/main/java/eu/faircode/email/ViewButtonColor.java @@ -30,18 +30,18 @@ import android.view.View; import androidx.appcompat.widget.AppCompatButton; import androidx.core.graphics.ColorUtils; -public class ButtonColor extends AppCompatButton { +public class ViewButtonColor extends AppCompatButton { private int color = Color.TRANSPARENT; - public ButtonColor(Context context) { + public ViewButtonColor(Context context) { super(context); } - public ButtonColor(Context context, AttributeSet attrs) { + public ViewButtonColor(Context context, AttributeSet attrs) { super(context, attrs); } - public ButtonColor(Context context, AttributeSet attrs, int defStyleAttr) { + public ViewButtonColor(Context context, AttributeSet attrs, int defStyleAttr) { super(context, attrs, defStyleAttr); } diff --git a/app/src/main/res/layout/fragment_account.xml b/app/src/main/res/layout/fragment_account.xml index bfb3ccb560..53647cd0d2 100644 --- a/app/src/main/res/layout/fragment_account.xml +++ b/app/src/main/res/layout/fragment_account.xml @@ -320,7 +320,7 @@ app:layout_constraintStart_toStartOf="parent" app:layout_constraintTop_toBottomOf="@id/etName" /> - - - -