Clean up code: using switch instead of if-else, privatize members,
making intent_filter static final, use yield() instead of sleep()
for download waiting