mirror of
https://github.com/nextcloud/android.git
synced 2024-11-28 02:17:43 +03:00
tint action bar icon
Signed-off-by: tobiasKaminsky <tobias@kaminsky.me>
This commit is contained in:
parent
1c6fec7192
commit
ebb04db951
1 changed files with 9 additions and 1 deletions
|
@ -30,6 +30,7 @@ import android.accounts.AccountManagerFuture;
|
||||||
import android.content.Context;
|
import android.content.Context;
|
||||||
import android.content.Intent;
|
import android.content.Intent;
|
||||||
import android.content.res.Configuration;
|
import android.content.res.Configuration;
|
||||||
|
import android.graphics.PorterDuff;
|
||||||
import android.graphics.drawable.ColorDrawable;
|
import android.graphics.drawable.ColorDrawable;
|
||||||
import android.graphics.drawable.Drawable;
|
import android.graphics.drawable.Drawable;
|
||||||
import android.graphics.drawable.LayerDrawable;
|
import android.graphics.drawable.LayerDrawable;
|
||||||
|
@ -39,6 +40,7 @@ import android.support.design.widget.NavigationView;
|
||||||
import android.support.v4.view.GravityCompat;
|
import android.support.v4.view.GravityCompat;
|
||||||
import android.support.v4.widget.DrawerLayout;
|
import android.support.v4.widget.DrawerLayout;
|
||||||
import android.support.v7.app.ActionBarDrawerToggle;
|
import android.support.v7.app.ActionBarDrawerToggle;
|
||||||
|
import android.support.v7.graphics.drawable.DrawerArrowDrawable;
|
||||||
import android.text.Html;
|
import android.text.Html;
|
||||||
import android.text.TextUtils;
|
import android.text.TextUtils;
|
||||||
import android.view.Menu;
|
import android.view.Menu;
|
||||||
|
@ -718,12 +720,18 @@ public abstract class DrawerActivity extends ToolbarActivity implements DisplayU
|
||||||
protected void updateActionBarTitleAndHomeButton(OCFile chosenFile) {
|
protected void updateActionBarTitleAndHomeButton(OCFile chosenFile) {
|
||||||
super.updateActionBarTitleAndHomeButton(chosenFile);
|
super.updateActionBarTitleAndHomeButton(chosenFile);
|
||||||
|
|
||||||
/// set home button properties
|
// set home button properties
|
||||||
if (mDrawerToggle != null && chosenFile != null) {
|
if (mDrawerToggle != null && chosenFile != null) {
|
||||||
mDrawerToggle.setDrawerIndicatorEnabled(isRoot(chosenFile));
|
mDrawerToggle.setDrawerIndicatorEnabled(isRoot(chosenFile));
|
||||||
} else if (mDrawerToggle != null){
|
} else if (mDrawerToggle != null){
|
||||||
mDrawerToggle.setDrawerIndicatorEnabled(false);
|
mDrawerToggle.setDrawerIndicatorEnabled(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (mDrawerToggle != null) {
|
||||||
|
DrawerArrowDrawable icon = mDrawerToggle.getDrawerArrowDrawable();
|
||||||
|
icon.setColorFilter(ThemeUtils.fontColor(this), PorterDuff.Mode.SRC_ATOP);
|
||||||
|
mDrawerToggle.setDrawerArrowDrawable(icon);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Reference in a new issue