summaryrefslogtreecommitdiff
path: root/app/src/normal/java/se/leap/bitmaskclient
diff options
context:
space:
mode:
authorcyberta <cyberta@riseup.net>2022-12-02 02:08:55 +0100
committercyberta <cyberta@riseup.net>2022-12-02 20:25:19 +0100
commit5afe57ab868ee9e2e27f5b26b9b14de3519c0402 (patch)
treeba0d8c4b31d47be1506b3a89843494b67470c1ca /app/src/normal/java/se/leap/bitmaskclient
parent905cf37dc3e5e7a3a3ffdd80b09cb4be3ccfc806 (diff)
rearranging assets, split them into normal and custom flavor
Diffstat (limited to 'app/src/normal/java/se/leap/bitmaskclient')
-rw-r--r--app/src/normal/java/se/leap/bitmaskclient/base/views/MainButton.java57
1 files changed, 0 insertions, 57 deletions
diff --git a/app/src/normal/java/se/leap/bitmaskclient/base/views/MainButton.java b/app/src/normal/java/se/leap/bitmaskclient/base/views/MainButton.java
deleted file mode 100644
index 715063b5..00000000
--- a/app/src/normal/java/se/leap/bitmaskclient/base/views/MainButton.java
+++ /dev/null
@@ -1,57 +0,0 @@
-package se.leap.bitmaskclient.base.views;
-
-import android.annotation.TargetApi;
-import android.content.Context;
-import android.util.AttributeSet;
-import android.view.LayoutInflater;
-import android.widget.RelativeLayout;
-
-import androidx.appcompat.widget.AppCompatImageView;
-import androidx.core.content.ContextCompat;
-
-import se.leap.bitmaskclient.R;
-import se.leap.bitmaskclient.databinding.VMainButtonBinding;
-
-public class MainButton extends RelativeLayout {
-
- private static final String TAG = MainButton.class.getSimpleName();
-
- AppCompatImageView button;
-
- public MainButton(Context context) {
- super(context);
- initLayout(context);
- }
-
- public MainButton(Context context, AttributeSet attrs) {
- super(context, attrs);
- initLayout(context);
- }
-
- public MainButton(Context context, AttributeSet attrs, int defStyleAttr) {
- super(context, attrs, defStyleAttr);
- initLayout(context);
- }
-
-
- @TargetApi(21)
- public MainButton(Context context, AttributeSet attrs, int defStyleAttr, int defStyleRes) {
- super(context, attrs, defStyleAttr, defStyleRes);
- initLayout(context);
- }
-
- private void initLayout(Context context) {
- VMainButtonBinding binding = VMainButtonBinding.inflate(LayoutInflater.from(context), this, true);
- button = binding.button;
- }
-
- public void updateState(boolean isOn, boolean isProcessing, boolean isError) {
- if (isProcessing) {
- button.setImageDrawable(ContextCompat.getDrawable(getContext(), R.drawable.button_circle_cancel));
- } else {
- button.setImageDrawable(
- ContextCompat.getDrawable(getContext(),
- isOn ? R.drawable.button_circle_stop : R.drawable.button_circle_start));
- }
- }
-}