Dbrant has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/371038 )

Change subject: No longer use color states for edit toolbar buttons.
......................................................................

No longer use color states for edit toolbar buttons.

This makes it more compatible with lower API versions.

Bug: T172903
Change-Id: Idbf6b7a602f4f0b3d475e9ddb30f10338ce027f2
---
M app/src/main/java/org/wikipedia/edit/EditSectionActivity.java
1 file changed, 2 insertions(+), 6 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/apps/android/wikipedia 
refs/changes/38/371038/1

diff --git a/app/src/main/java/org/wikipedia/edit/EditSectionActivity.java 
b/app/src/main/java/org/wikipedia/edit/EditSectionActivity.java
index 9e0edb1..77ee6a9 100644
--- a/app/src/main/java/org/wikipedia/edit/EditSectionActivity.java
+++ b/app/src/main/java/org/wikipedia/edit/EditSectionActivity.java
@@ -10,7 +10,6 @@
 import android.support.annotation.NonNull;
 import android.support.annotation.Nullable;
 import android.support.v4.content.ContextCompat;
-import android.support.v4.view.ViewCompat;
 import android.support.v7.app.ActionBar;
 import android.support.v7.app.AlertDialog;
 import android.text.Editable;
@@ -581,11 +580,8 @@
             }
         });
 
-        if (editPreviewFragment.isActive()) {
-            ViewCompat.setBackgroundTintList(v, 
ContextCompat.getColorStateList(this, R.color.color_state_blue));
-        } else {
-            ViewCompat.setBackgroundTintList(v, 
ContextCompat.getColorStateList(this, R.color.color_state_green));
-        }
+        v.setBackgroundColor(ContextCompat.getColor(this, item.isEnabled()
+                ? (editPreviewFragment.isActive() ? R.color.accent50 : 
R.color.green50) : R.color.base50));
 
         return true;
     }

-- 
To view, visit https://gerrit.wikimedia.org/r/371038
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Idbf6b7a602f4f0b3d475e9ddb30f10338ce027f2
Gerrit-PatchSet: 1
Gerrit-Project: apps/android/wikipedia
Gerrit-Branch: master
Gerrit-Owner: Dbrant <dbr...@wikimedia.org>

_______________________________________________
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to