public abstract class PreferenceFragmentCompatDividers extends PreferenceFragmentCompat
| Modifier and Type | Class and Description |
|---|---|
protected class |
PreferenceFragmentCompatDividers.DividerItemDecoration |
protected static interface |
PreferenceFragmentCompatDividers.DividerPrefFlags |
| Modifier and Type | Field and Description |
|---|---|
static int |
DIVIDER_CATEGORY_AFTER_LAST
Draws a divider after the last item in a category group.
|
static int |
DIVIDER_CATEGORY_BEFORE_FIRST
Draws a divider before the first item in a category group.
|
static int |
DIVIDER_CATEGORY_BETWEEN
Draws a divider between adjacent categories.
|
static int |
DIVIDER_DEFAULT
Draws the material guidelines compatible divider implementation.
|
static int |
DIVIDER_NO_AFTER_LAST
Won't draw a divider after the very last item.
|
static int |
DIVIDER_NO_BEFORE_FIRST
Won't draw a divider before the very first item.
|
static int |
DIVIDER_NONE
Draws no dividers.
|
static int |
DIVIDER_OFFICIAL
Draws the divider implementation of the official support library.
|
static int |
DIVIDER_PADDING_CHILD
Draws the divider according to the preferences' padding.
|
static int |
DIVIDER_PADDING_PARENT
Draws a divider using the parent's (RecyclerView) padding.
|
static int |
DIVIDER_PREFERENCE_AFTER_LAST
Draws a divider after the last item in a preference group.
|
static int |
DIVIDER_PREFERENCE_BEFORE_FIRST
Draws a divider before the first item in a preference group.
|
static int |
DIVIDER_PREFERENCE_BETWEEN
Draws a divider between adjacent preferences.
|
dialogPreferences| Constructor and Description |
|---|
PreferenceFragmentCompatDividers() |
| Modifier and Type | Method and Description |
|---|---|
void |
onDestroyView() |
void |
onViewCreated(android.view.View view,
android.os.Bundle savedInstanceState) |
void |
setDivider(android.graphics.drawable.Drawable divider) |
void |
setDividerHeight(int height) |
protected void |
setDividerPreferences(int flags)
Sets the divider decoration flags.
|
displayPreferenceDialog, displayPreferenceDialog, onActivityResult, onActivityResult, onCreate, onCreateAdapter, onCreatePreferences, onCreatePreferencesFix, onDisplayPreferenceDialog, onPreferenceTreeClick, registerPreferenceFragmentpublic static final int DIVIDER_OFFICIAL
public static final int DIVIDER_NONE
public static final int DIVIDER_CATEGORY_BETWEEN
public static final int DIVIDER_CATEGORY_BEFORE_FIRST
For example: in case of multiple adjacent categories (so there are empty ones), this flag will let the divider be drawn before the first category in this group.
Note that in some situations this behaves the same as DIVIDER_PREFERENCE_AFTER_LAST.
public static final int DIVIDER_CATEGORY_AFTER_LAST
For example: in case of multiple adjacent categories (so there are empty ones), this flag will let the divider be drawn after the last category in this group.
Note that in some situations this behaves the same as DIVIDER_PREFERENCE_BEFORE_FIRST.
public static final int DIVIDER_PREFERENCE_BETWEEN
public static final int DIVIDER_PREFERENCE_BEFORE_FIRST
Note that in some situations this behaves the same as DIVIDER_CATEGORY_AFTER_LAST.
public static final int DIVIDER_PREFERENCE_AFTER_LAST
Note that in some situations this behaves the same as DIVIDER_CATEGORY_BEFORE_FIRST.
public static final int DIVIDER_PADDING_CHILD
DIVIDER_PADDING_PARENT.public static final int DIVIDER_PADDING_PARENT
DIVIDER_PADDING_CHILD.public static final int DIVIDER_NO_BEFORE_FIRST
DIVIDER_CATEGORY_BEFORE_FIRST and the first item in the list is a preference
category).public static final int DIVIDER_NO_AFTER_LAST
DIVIDER_PREFERENCE_AFTER_LAST and the last item in the list is a preference).public static final int DIVIDER_DEFAULT
protected void setDividerPreferences(int flags)
DIVIDER_DEFAULTDIVIDER_OFFICIALDIVIDER_NONENote that you should not combine DIVIDER_DEFAULT, DIVIDER_OFFICIAL, and DIVIDER_NONE with each other nor the other flags mentioned above.
flags - The preferred divider drawing flags. Check PreferenceFragmentCompatDividers for possible values.public void onViewCreated(android.view.View view,
android.os.Bundle savedInstanceState)
public void onDestroyView()
public void setDivider(android.graphics.drawable.Drawable divider)
public void setDividerHeight(int height)