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
TIMOB-6346 Android: allow imageview source to be nullified #797
Conversation
Code reviewed. Request Accepted |
@@ -248,17 +248,15 @@ public class TiUIImageView extends TiUIView implements OnLifecycleEvent, Handler | |||
|
|||
private void setImage(final Bitmap bitmap) | |||
{ | |||
if (bitmap != null) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we need to worry about setting bitmap being null?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
eh? That's the point of this PR, and what we're testing :) In my testing, there are no adverse side-effects.
…de by putting in a handleXXX method. Also make sure default image is used (if available) when regular image source is null.
Code reviewed and functionally tested. Request Accepted |
Code reviewed and accepted. Merging |
TIMOB-6346 Android: allow imageview source to be nullified
http://jira.appcelerator.org/browse/TIMOB-6346
Test case is the fail case in the ticket AND please test all ImageView tests in the KitchenSink.
I've also tested nullifying the image when the imageview is on a row in a TableView, and that also works fine. Not sure why we had the if-block in there in the first place.