Prevent NPE when thumbnail click not set

Fixes #3042
Fixes #3044
Closes #3046
// FREEBIE
This commit is contained in:
Jake McGinty 2015-04-23 13:33:34 -05:00 committed by Moxie Marlinspike
parent d8521637bb
commit a330f6f689

View File

@ -177,7 +177,11 @@ public class ThumbnailView extends ForegroundImageView {
@Override @Override
public void onClick(View view) { public void onClick(View view) {
listener.onClick(view, slide); if (listener != null) {
listener.onClick(view, slide);
} else {
Log.w(TAG, "onClick, but no thumbnail click listener attached.");
}
} }
} }