Skip to content

Commit

Permalink
Allow for nulls
Browse files Browse the repository at this point in the history
  • Loading branch information
Mateusz Klimek committed Aug 24, 2016
1 parent fb96d3e commit cd3b343
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ class TabBarController(context: Context, val tabs: List<Tab>, val tabBarView: Ta

private var tabs = mutableListOf<Tab>()

fun addTab(title: String, iconId: Drawable, backgroundId: Drawable, backgroundSelectedId: Drawable): TabBuilder{
fun addTab(title: String, iconId: Drawable?, backgroundId: Drawable?, backgroundSelectedId: Drawable?): TabBuilder{
tabs.add(Tab(title, iconId, backgroundId, backgroundSelectedId))
return this
}
Expand All @@ -64,7 +64,7 @@ class TabBarController(context: Context, val tabs: List<Tab>, val tabBarView: Ta
}
}

class Tab(val title: String, val iconId: Drawable, val background: Drawable, val backgroundSelected: Drawable){
class Tab(val title: String, val iconId: Drawable?, val background: Drawable?, val backgroundSelected: Drawable?){
}

}
Expand Down

0 comments on commit cd3b343

Please sign in to comment.