razir / ProgressButton

Android Progress Button
856 stars 77 forks source link

Question: Use with data binding #12

Closed michaelbukachi closed 4 years ago

michaelbukachi commented 5 years ago

Hello. Do I still need to call bindProgressButton if I'm using databining? See the snippet below.

        val binding = FragmentSignInBinding.bind(view)
        binding.viewModel = viewModel
        binding.lifecycleOwner = this
        binding.signIn.attachTextChangeAnimator()
        binding.signIn.showProgress { ... }
.....
vermotr commented 5 years ago

Hello, I also would like to use it with data binding. Can we have some help to do this?

razir commented 4 years ago

Hi @michaelbukachi ,

Unfortunately, the view doesn't have an access to LifecycleOwner from Data Binding, so you still need to call bindProgressButton