Swift with NSDocument and Revert To... browse all versions.


Bill Pitcher
 

I've been trying track the correct path from document to Control and back again.

Document automatically loads WindowController.document I use didSet to loop down the ViewControllers and set there ViewController.representedObject and use didSet  to UpdateMyControls
After user changes the data in controls I update the ViewController.representedObject and all is good. Save makes versions.

After returning from Revert To... restoring an old document, my document flicks back to displaying the original data when went into the version browser, BUT the backing document has been resorted correctly. Doing an UpdateMyControls in windowDidExitVersionBrowser does a bad visual, from new to old then new again. Any help or pointers with this really appreciated!

Thanks
Bill

Join cocoa@apple-dev.groups.io to automatically receive all group messages.