Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build fails while using Databinding #48

Open
rajBopche opened this issue Jul 16, 2020 · 4 comments
Open

Build fails while using Databinding #48

rajBopche opened this issue Jul 16, 2020 · 4 comments

Comments

@rajBopche
Copy link

For some reason, the build fails while using databindng feature with the progress bar.

I was using the binding variable to set the progress value on the progressbar. The code is as follows

<com.mikhaellopez.circularprogressbar.CircularProgressBar 
            app:cpb_background_progressbar_color="@color/c_light_orange_ff"
            app:cpb_background_progressbar_width="@dimen/spacing_4"
            .
            .
            .
            app:cpb_progress="@{vm.progress}" 
/>

Above vm is the binding variable and progress is a variable of type Float

I use databinding in my project heavily and every other databinding expression is working fine. Only when I try to use the binding with CircularProgressBar the build fails with a very generic error BindingClassImpl symbol not found(Thanks DataBinding it was very helpful -_- ).

Can someone please guide what am I probably doing wrong?

Environment Specs:
Dependency:implementation 'com.mikhaellopez:circularprogressbar:3.0.3'
Android Studio: 3.5.2
Gradle Distribution: gradle-5.1.1-all.zip
Mac Os: Catalina 10.15.5
Model: MacBook Pro (13-inch, 2017, Two Thunderbolt 3 ports)
Processor: 2.3 GHz Dual-Core Intel Core i5

@secretshardul
Copy link

secretshardul commented Aug 2, 2020

+1
@rajBopche you were able to get data binding running?

@hossein-no1
Copy link

this is my problem too. there isn't respond yet?

@congpeijun
Copy link

What's the state of this issue? I got the issue too.

@congpeijun
Copy link

I create a bindingAdapter, and it works

 @BindingAdapter(value = ["cpb_progress"])
    @JvmStatic
    fun setProgress(circularProgressBar: CircularProgressBar, process: Float?) {
        circularProgressBar.setProgressWithAnimation(process ?: 0f, 1000)
    }

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants