mirror of
https://github.com/M66B/FairEmail.git
synced 2026-03-28 11:55:20 +01:00
Sign in with Google (2)
This commit is contained in:
@@ -122,19 +122,11 @@ public class PopupMenuLifecycle extends PopupMenu {
|
||||
if (icon == null)
|
||||
icon = new ColorDrawable(Color.TRANSPARENT);
|
||||
else {
|
||||
Intent intent = menuItem.getIntent();
|
||||
boolean gmail = (intent != null &&
|
||||
ActivitySetup.ACTION_QUICK_OAUTH.equals(intent.getAction()) &&
|
||||
"gmail".equals(intent.getStringExtra("id")));
|
||||
if (gmail)
|
||||
icon.setState(new int[]{android.R.attr.state_enabled, android.R.attr.state_focused});
|
||||
else {
|
||||
icon = icon.getConstantState().newDrawable().mutate();
|
||||
int color = Helper.resolveColor(context, R.attr.colorAccent);
|
||||
icon.setTint(color);
|
||||
if (!menuItem.isEnabled())
|
||||
icon.setAlpha(Math.round(Helper.LOW_LIGHT * 255));
|
||||
}
|
||||
icon = icon.getConstantState().newDrawable().mutate();
|
||||
int color = Helper.resolveColor(context, R.attr.colorAccent);
|
||||
icon.setTint(color);
|
||||
if (!menuItem.isEnabled())
|
||||
icon.setAlpha(Math.round(Helper.LOW_LIGHT * 255));
|
||||
}
|
||||
|
||||
int iconSize = context.getResources().getDimensionPixelSize(R.dimen.menu_item_icon_size);
|
||||
|
||||
Reference in New Issue
Block a user