Skip to content

Commit 0ca5d85

Browse files
authored
Update README.md
1 parent e6e3408 commit 0ca5d85

1 file changed

Lines changed: 22 additions & 0 deletions

File tree

README.md

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -116,6 +116,28 @@ app:hv_add_icon="@drawable/ic_action_settings"
116116
headerView.setShowAddButton(true);
117117
app:hv_show_add_button="true"
118118
```
119+
#### Callback
120+
```Java
121+
headerView.setCallback(new HeaderCallback() {
122+
123+
@Override
124+
public boolean onSelect(int id, boolean isActive) {
125+
//return profile id selected and if is the active profile
126+
return true; //true for close the dialog, false for do nothing
127+
}
128+
129+
@Override
130+
public boolean onItem(int id) {
131+
//return witch buttom item is selected
132+
return true; //true for close the dialog, false for do nothing
133+
}
134+
135+
@Override
136+
public boolean onAdd() {
137+
return true; //true for close the dialog, false for do nothing
138+
}
139+
});
140+
```
119141
#### Loading image from network
120142
Just add this in your class Application (of course you can use your preferred libs for load images)
121143
```Java

0 commit comments

Comments
 (0)