Skip to content

Instantly share code, notes, and snippets.

@Nimrodda
Created June 6, 2019 07:27
Show Gist options
  • Select an option

  • Save Nimrodda/6e355d5bfed875e5f7f712d4321d41be to your computer and use it in GitHub Desktop.

Select an option

Save Nimrodda/6e355d5bfed875e5f7f712d4321d41be to your computer and use it in GitHub Desktop.
class GamesListController : TypedEpoxyController<Container>() {
override fun buildModels(container: Container?) {
container?.genres?.forEach {
header {
id(it.header.id)
genre(it.genre)
onHeaderExpanded { model, _, _, _ ->
container.onGenreExpanded(model.genre())
}
}
if (it.genre.isExpanded) {
it.games.forEach { game ->
onelineWithIcon {
id(game.id)
game(game)
}
}
}
}
}
}
@Mankesh71

Copy link
Copy Markdown

Hi
How onelineWithIcon this generated i am not able to get this.
Thanks,

@Mankesh71

Copy link
Copy Markdown

I got the header for expandable list but unable to get item inside the header.
As i am not sure about onelineWithIcon in controller.
Can you please help me out.
Thanks in advance.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment