Skip to content

Commit b2ea0d0

Browse files
committed
Get around the random recycled bitmap errors from calling onDraw after a bitmap had been recycled to make room for a new one. This isn't the ideal fix since it will show a blank image, but it is better than just crashing.
1 parent b71b872 commit b2ea0d0

File tree

12 files changed

+68
-11
lines changed

12 files changed

+68
-11
lines changed

res/layout-land/download.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
android:layout_height="fill_parent"
2222
android:layout_weight="1">
2323

24-
<ImageView
24+
<github.daneren2005.dsub.view.RecyclingImageView
2525
android:id="@+id/download_album_art_image"
2626
android:src="@drawable/unknown_album_large"
2727
android:layout_width="wrap_content"

res/layout-large-land/download.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
android:layout_height="0dip"
1616
android:layout_weight="1">
1717

18-
<ImageView
18+
<github.daneren2005.dsub.view.RecyclingImageView
1919
android:id="@+id/download_album_art_image"
2020
android:src="@drawable/unknown_album_large"
2121
android:layout_width="0dp"

res/layout-port/download.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929
android:layout_height="wrap_content"
3030
android:layout_alignParentTop="true">
3131

32-
<ImageView
32+
<github.daneren2005.dsub.view.RecyclingImageView
3333
android:id="@+id/download_album_art_image"
3434
android:layout_width="wrap_content"
3535
android:layout_height="wrap_content"

res/layout/abstract_fragment_activity.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
style="@style/BasicButton"
1919
android:orientation="horizontal">
2020

21-
<ImageView
21+
<github.daneren2005.dsub.view.RecyclingImageView
2222
android:id="@+id/album_art"
2323
android:layout_width="50dip"
2424
android:layout_height="50dip"

res/layout/album_list_item.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
android:layout_width="@dimen/AlbumArt.Small"
1010
android:layout_height="@dimen/AlbumArt.Small">
1111

12-
<ImageView
12+
<github.daneren2005.dsub.view.RecyclingImageView
1313
android:id="@+id/album_coverart"
1414
android:layout_width="@dimen/AlbumArt.Small"
1515
android:layout_height="@dimen/AlbumArt.Small"

res/layout/chat_item.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
android:layout_width="fill_parent"
55
android:layout_height="wrap_content">
66

7-
<ImageView
7+
<github.daneren2005.dsub.view.RecyclingImageView
88
android:id="@+id/chat_avatar"
99
android:src="@drawable/ic_social_person"
1010
android:layout_width="@dimen/AlbumArt.Small"

res/layout/chat_item_reverse.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@
5252
android:layout_gravity="right"/>
5353
</LinearLayout>
5454

55-
<ImageView
55+
<github.daneren2005.dsub.view.RecyclingImageView
5656
android:id="@+id/chat_avatar"
5757
android:src="@drawable/ic_social_person"
5858
android:layout_width="@dimen/AlbumArt.Small"

res/layout/select_album_header.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@
100100
android:layout_gravity="center_vertical"/>
101101
</LinearLayout>
102102

103-
<ImageView
103+
<github.daneren2005.dsub.view.RecyclingImageView
104104
android:id="@+id/select_album_art"
105105
android:layout_width="@dimen/AlbumArt.Header"
106106
android:layout_height="@dimen/AlbumArt.Header"

res/layout/user_header.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
android:layout_width="fill_parent"
55
android:layout_height="wrap_content">
66

7-
<ImageView
7+
<github.daneren2005.dsub.view.RecyclingImageView
88
android:id="@+id/user_avatar"
99
android:src="@drawable/ic_social_person"
1010
android:layout_width="wrap_content"

res/layout/user_list_item.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
android:layout_height="wrap_content"
66
android:background="@android:color/transparent">
77

8-
<ImageView
8+
<github.daneren2005.dsub.view.RecyclingImageView
99
android:id="@+id/item_avatar"
1010
android:src="@drawable/ic_social_person"
1111
android:layout_width="@dimen/AlbumArt.Small"

0 commit comments

Comments
 (0)