udacity / Android_Me

App that lets you style your own Android! This uses Fragments to create a flexible and responsive UI.
259 stars 1k forks source link

Creating Intent every time the user selects a body part. #49

Open galamdring opened 6 years ago

galamdring commented 6 years ago

It seems to me that creating the intent each time a body part is clicked is much more expensive than holding onto the selected positions and creating the intent when the user clicks next. This can be accomplished by simply moving the Intent creation logic to the onClick even for the next button.

fede118 commented 5 years ago

I agree, I also moved the Button click listener to OnCreated (with the intent inside) and put it onCreate, that way we are not setting up the listener on each click on an image.