From 4797970ef328b890dba703808b8fc4ec0df00097 Mon Sep 17 00:00:00 2001 From: zagum Date: Thu, 23 Mar 2017 12:18:16 +0300 Subject: [PATCH] fixed reading si_enabled attribute --- .../main/java/com/github/zagum/switchicon/SwitchIconView.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/switchicon/src/main/java/com/github/zagum/switchicon/SwitchIconView.java b/switchicon/src/main/java/com/github/zagum/switchicon/SwitchIconView.java index df0ad8e..759f0df 100644 --- a/switchicon/src/main/java/com/github/zagum/switchicon/SwitchIconView.java +++ b/switchicon/src/main/java/com/github/zagum/switchicon/SwitchIconView.java @@ -88,7 +88,7 @@ public SwitchIconView(@NonNull Context context, @Nullable AttributeSet attrs, in animationDuration = array.getInteger(R.styleable.SwitchIconView_si_animation_duration, DEFAULT_ANIMATION_DURATION); disabledStateAlpha = array.getFloat(R.styleable.SwitchIconView_si_disabled_alpha, DEFAULT_DISABLED_ALPHA); disabledStateColor = array.getColor(R.styleable.SwitchIconView_si_disabled_color, iconTintColor); - enabled = array.getBoolean(R.styleable.SwitchIconView_si_disabled_alpha, true); + enabled = array.getBoolean(R.styleable.SwitchIconView_si_enabled, true); noDash = array.getBoolean(R.styleable.SwitchIconView_si_no_dash, false); } finally { array.recycle();