add close button to move note and preference dialog