Currently, for file Open & Save dialogs, any view settings you've changed are only remembered if you actually open or save the file; they're ignored if you cancel the dialog using the Cancel button. there's no particular reason why a user should want to discard any view changes just because they decided not to open or save the file, so we should fix that.
This patch fixes a bug causing the issue: the attempt to write the changed view config settings was issued after the KDirOperator had already been destroyed, so its settings were unavailable to be saved. Reversing the ordering of the statements fixes the issue.
BUG: 209559
FIXED-IN: 5.46