Skip to content

Commit a45fd51

Browse files
committed
Fix readme. Add information for #480.
1 parent d11ac66 commit a45fd51

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

README.md

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ android-gif-drawable
55
[![Android Arsenal](https://img.shields.io/badge/Android%20Arsenal-android--gif--drawable-brightgreen.svg?style=flat)](https://android-arsenal.com/details/1/1147)
66
[![Android-Libs](https://img.shields.io/badge/Android--Libs-android--gif--drawable-orange.svg?style=flat)](http://android-libs.com/lib/android-gif-drawable)
77
[![Android Weekly](http://img.shields.io/badge/Android%20Weekly-%2393-2CB3E5.svg?style=flat)](http://androidweekly.net/issues/issue-93)
8-
[![API](https://img.shields.io/badge/API-9%2B-blue.svg?style=flat)](https://android-arsenal.com/api?level=14)
8+
[![API](https://img.shields.io/badge/API-14%2B-blue.svg?style=flat)](https://android-arsenal.com/api?level=14)
99
[![Javadocs](http://www.javadoc.io/badge/pl.droidsonroids.gif/android-gif-drawable.svg)](http://www.javadoc.io/doc/pl.droidsonroids.gif/android-gif-drawable)
1010

1111
`View`s and `Drawable` for animated GIFs in Android.
@@ -203,7 +203,7 @@ protected void onCreate(Bundle savedInstanceState) {
203203
#### Associating single `GifDrawable` instance with multiple `View`s
204204
205205
Normally single `GifDrawable` instance associated with multiple `View`s will animate only on the last one.
206-
To solve that create `MultiCallback` instance, add `View`s to it and set callback for given drawable, eg.:
206+
To solve that create `MultiCallback` instance, add `View`s to it and set callback for given drawable, e.g.:
207207
```java
208208
MultiCallback multiCallback = new MultiCallback();
209209
@@ -216,6 +216,9 @@ multiCallback.addView(anotherImageView);
216216
gifDrawable.setCallback(multiCallback);
217217
```
218218
219+
Note that if you change a drawable of e.g. `ImageView`, the callback will be removed from the previous
220+
drawable. Thereafter, you have to reassign callback or the same `GifDrawable` instance will stop animating.
221+
219222
#### Advanced
220223
221224
+ `recycle()` - provided to speed up freeing memory (like in `android.graphics.Bitmap`)

0 commit comments

Comments
 (0)