Skip to content
This repository was archived by the owner on Sep 3, 2024. It is now read-only.

SwitchBarLayout

Yanndroid edited this page Feb 10, 2022 · 3 revisions

de.dlyt.yanndroid.oneui.layout.SwitchBarLayout

This is an extended ToolbarLayout with SwitchBar. Useful for creating inner preferences layouts in pair with SwitchPreferenceScreen.

<de.dlyt.yanndroid.oneui.layout.SwitchBarLayout
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:layout="...">

</de.dlyt.yanndroid.oneui.layout.SwitchBarLayout>

See ToolbarLayout for all the layout attributes, except for android:layout, here you need to use all the views and ids of this view.


Methods

Additionally, to all the ToolbarLayout methods:

SwitchBar methods.

public SwitchBar getSwitchBar()
public void setChecked(boolean checked)
public boolean isChecked()
public void addOnSwitchChangeListener(SwitchBar.OnSwitchChangeListener onSwitchChangeListener)
Clone this wiki locally