Thread fix

Thread now closes when application closes. File transfer works as long as network connection don't go down mid transfer. Also class diagrams and stuff.