Example usage for android.app ActionBar setSplitBackgroundDrawable

List of usage examples for android.app ActionBar setSplitBackgroundDrawable

Introduction

In this page you can find the example usage for android.app ActionBar setSplitBackgroundDrawable.

Prototype

public void setSplitBackgroundDrawable(Drawable d) 

Source Link

Document

Set the ActionBar's split background.

Usage

From source file:de.vanita5.twittnuker.util.ThemeUtils.java

public static void applyActionBarBackground(final ActionBar actionBar, final Context context,
        final int themeRes) {
    if (actionBar == null || context == null)
        return;/* ww  w  .  j a v  a  2 s . c  o  m*/
    actionBar.setBackgroundDrawable(getActionBarBackground(context, themeRes));
    actionBar.setSplitBackgroundDrawable(getActionBarSplitBackground(context, themeRes));
    actionBar.setStackedBackgroundDrawable(getActionBarStackedBackground(context, themeRes));
}

From source file:de.vanita5.twittnuker.util.ThemeUtils.java

@Deprecated
public static void applyActionBarBackground(final ActionBar actionBar, final Context context,
        final boolean applyAlpha) {
    if (actionBar == null || context == null)
        return;//  w w w.  j  ava2  s  .  c  o m
    actionBar.setBackgroundDrawable(getActionBarBackground(context, applyAlpha));
    actionBar.setSplitBackgroundDrawable(getActionBarSplitBackground(context, applyAlpha));
    actionBar.setStackedBackgroundDrawable(getActionBarStackedBackground(context, applyAlpha));
}

From source file:org.getlantern.firetweet.util.ThemeUtils.java

public static void applyActionBarBackground(final ActionBar actionBar, final Context context,
        final int themeRes) {
    if (actionBar == null || context == null)
        return;//from  w  w  w . j a v  a2  s .com
    actionBar.setBackgroundDrawable(getActionBarBackground(context, themeRes));
    actionBar.setSplitBackgroundDrawable(getActionBarSplitBackground(context, themeRes));
    //        actionBar.setStackedBackgroundDrawable(getActionBarStackedBackground(context, themeRes));
}

From source file:de.vanita5.twittnuker.util.ThemeUtils.java

public static void applyActionBarBackground(final ActionBar actionBar, final Context context,
        final int themeRes, final int actionBarColor) {
    if (actionBar == null || context == null)
        return;/*from  w w  w .  j  a  va 2s . c  om*/
    actionBar.setBackgroundDrawable(getActionBarBackground(context, themeRes, actionBarColor));
    actionBar.setSplitBackgroundDrawable(getActionBarSplitBackground(context, themeRes));
    actionBar.setStackedBackgroundDrawable(getActionBarStackedBackground(context, themeRes));
}

From source file:de.vanita5.twittnuker.util.ThemeUtils.java

public static void applyActionBarBackground(final android.support.v7.app.ActionBar actionBar,
        final Context context, final int themeRes, final int actionBarColor) {
    if (actionBar == null || context == null)
        return;/* w  ww.  j ava 2s  .c  o m*/
    actionBar.setBackgroundDrawable(getActionBarBackground(context, themeRes, actionBarColor));
    actionBar.setSplitBackgroundDrawable(getActionBarSplitBackground(context, themeRes));
    actionBar.setStackedBackgroundDrawable(getActionBarStackedBackground(context, themeRes));
}

From source file:org.getlantern.firetweet.util.ThemeUtils.java

public static void applyActionBarBackground(final ActionBar actionBar, final Context context,
        final int themeRes, final int accentColor, boolean outlineEnabled) {
    if (actionBar == null || context == null)
        return;/* ww w.  j  ava2  s.  c  om*/
    actionBar.setBackgroundDrawable(getActionBarBackground(context, themeRes, accentColor, outlineEnabled));
    actionBar.setSplitBackgroundDrawable(getActionBarSplitBackground(context, themeRes));
    actionBar.setStackedBackgroundDrawable(
            getActionBarBackground(context, themeRes, accentColor, outlineEnabled));
}

From source file:org.getlantern.firetweet.util.ThemeUtils.java

public static void applyActionBarBackground(final android.support.v7.app.ActionBar actionBar,
        final Context context, final int themeRes, final int accentColor, boolean outlineEnabled) {
    if (actionBar == null || context == null)
        return;//from w  w w  . jav a  2 s.  co  m
    actionBar.setBackgroundDrawable(getActionBarBackground(context, themeRes, accentColor, outlineEnabled));
    actionBar.setSplitBackgroundDrawable(getActionBarSplitBackground(context, themeRes));
    actionBar.setStackedBackgroundDrawable(
            getActionBarStackedBackground(context, themeRes, accentColor, outlineEnabled));
}

From source file:za.ac.uct.cs.lwsjam005.eshelf.activities.ReadActivity.java

private void setupActionBar() {
    ActionBar actionBar = getActionBar();

    actionBar.setDisplayHomeAsUpEnabled(true);

    actionBar.setBackgroundDrawable(new ColorDrawable(Color.parseColor("#aa000022")));
    actionBar.setStackedBackgroundDrawable(new ColorDrawable(Color.parseColor("#aa000022")));
    actionBar.setSplitBackgroundDrawable(new ColorDrawable(Color.parseColor("#aa000022")));

    actionBar.setIcon(thisBook.getIcon());
    actionBar.setTitle(thisBook.getTitle());
    actionBar.setSubtitle(thisBook.getAuthor());

}