align progress bar and clean up code;
add upload/download switch;
remember user's choices;