Fix saving palette on quit, specifically avoiding the potential crash.
The save-with-user-input flow requires a widget to parent it's potential messages and other widgets to, but when we're closing the application no such potential widgets exists anymore, leading to a crash. Therefore, we'll just save the palette regularly, but only if it already has a resource-version. I don't think it's currently possible to have a palette without resource version, so that should suffice. This also seems to fix actually saving the resource upon close, which was the original bug to begin with. BUG:444309
Loading