Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions library/src/main/java/com/cocosw/bottomsheet/BottomSheet.java
Original file line number Diff line number Diff line change
Expand Up @@ -532,6 +532,21 @@ public Builder sheet(@MenuRes int xmlRes) {
return this;
}

/**
* Add one item into BottomSheet
*
* @param group ID of group
* @param id ID of item
* @param iconRes icon resource
* @param textRes icon resource
* @return This Builder object to allow for chaining of calls to set methods
*/
public Builder sheet(int group, int id, @DrawableRes int iconRes, @StringRes int textRes) {
ActionMenuItem item = new ActionMenuItem(context, group, id, 0, 0, context.getText(textRes));
item.setIcon(iconRes);
menu.add(item);
return this;
}

/**
* Add one item into BottomSheet
Expand Down