Package com.zendesk.sdk.ui
Class ToolbarSherlock
- java.lang.Object
-
- com.zendesk.sdk.ui.ToolbarSherlock
-
public class ToolbarSherlock extends java.lang.Object
Helper for detecting the presence of anActionBar
.
-
-
Constructor Summary
Constructors Constructor and Description ToolbarSherlock()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method and Description static void
installToolBar(AppCompatActivity activity)
Ensures that there is anActionBar
available in theAppCompatActivity
that was passed in as argument.
-
-
-
Method Detail
-
installToolBar
public static void installToolBar(AppCompatActivity activity)
Ensures that there is anActionBar
available in theAppCompatActivity
that was passed in as argument.If the Activity's theme has an
ActionBar
it will be used. In case that the Activity uses a theme without anActionBar
,ToolbarSherlock
looks for aToolbar
. IfToolbarSherlock
finds aToolbar
, it will install it by callingAppCompatActivity#setSupportActionBar(Toolbar)
.Every
AppCompatActivity
that usesToolbarSherlock
must include the layout<include layout="@layout/zendesk_toolbar" />
.- Parameters:
activity
- TheAppCompatActivity
,ToolbarSherlock
should take care about.
-
-