Scale the preview close button in proportion to the preview window. Closes #5.
Moved code from service.py into resources/lib