WaveLoading icon indicating copy to clipboard operation
WaveLoading copied to clipboard

Layout - XML

Open patoigz opened this issue 6 years ago • 1 comments

How can i use this library, but setting all the configuration from xml... I.e: Something like this


    <WaveDrawable
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:layout_margin="8dip"
        app:setIndeterminate="true"
        app:level="40"
        app:WaveAmplitude="65"
        app:WaveLength="40"
        app:WaveeSpeed="60" />

patoigz avatar Nov 23 '18 20:11 patoigz

How can i use this library, but setting all the configuration from xml... I.e: Something like this


    <WaveDrawable
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:layout_margin="8dip"
        app:setIndeterminate="true"
        app:level="40"
        app:WaveAmplitude="65"
        app:WaveLength="40"
        app:WaveeSpeed="60" />

this is not an object , you need to have a image view with a image to load the library as ImageView imageView = v.findViewById(R.id.battery); // an image wth battry image Drawable mWaveDrawable = new WaveDrawable(imageView.getDrawable()); ((WaveDrawable) mWaveDrawable).setIndeterminate(true); imageView.setImageDrawable(mWaveDrawable);

moolight-seashell avatar Apr 16 '19 09:04 moolight-seashell