So I've upgraded to RxBinding4 and want to use the same process from RxBinding2 where i can click a fab button to save a task in a Todo List App the two ways which dont work are like this:
private fun saveTaskIntent(): Observable<SaveTask> {
return view.clicks(fab).map{SaveTask(argumentTaskID, title.text.toString()!!, description.text.toString()!!)}
}
private fun saveTaskIntent2(): Observable<SaveTask> {
return RxView.clicks(fab).map {SaveTask(argumentTaskID, title.text.toString()!!, description.text.toString()!!)}
}
Any idea of how i would do this using 'com.jakewharton.rxbinding4:rxbinding:4.0.0'
Thanks in advance.
That seems to have been converted to Kolin extensions. Use fab.map()
to get the observable now.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.