Unnecessary setNeedsDisplay
Removed pointless setter
Better check for filePathOptimized
setFilePathOptimized returning whether it takes ownership of the file
Delete temp file even if it's not set filePathOptimized