task 6 implementing, FileMainWindow refactored