CoreDataUtility icon indicating copy to clipboard operation
CoreDataUtility copied to clipboard

Transform to Document-Based application

Open limejelly opened this issue 11 years ago • 8 comments

It will be nice to create document based application.

http://developer.apple.com/library/mac/#documentation/DataManagement/Conceptual/DocBasedAppProgrammingGuideForOSX/Introduction/Introduction.html

The Cocoa document architecture provides your app with many built-in features, such as autosaving, asynchronous document reading and writing, file coordination, and multilevel undo support. In most cases, it is trivial to opt-in to these behaviors. If your app has particular requirements beyond the defaults, the document architecture provides many opportunities for extending and customizing your app’s capabilities through mechanisms such as delegation, subclassing and overriding existing methods with custom implementations, and integration of custom objects.

limejelly avatar Mar 09 '13 12:03 limejelly

That is a good idea. The plan is for CoreDataPro to edit the data and not just view it. Many of the features you mentioned above would be an advantage.

yepher avatar Mar 09 '13 14:03 yepher

The first way to do it is recreate xcode project with needed type. Another way - do it manually. Unfortunately, I dont know how to do it manually, so I suggest to recreate project and import all files.

limejelly avatar Mar 09 '13 14:03 limejelly

I think you are right the easiest way to make an MDI is to create a new project and import the files. I expect there will need to be some significant surgery to MFLMainWindowController.

Are you planning on trying to code this up?

yepher avatar Mar 09 '13 14:03 yepher

I can do it, but not soon.

limejelly avatar Mar 09 '13 15:03 limejelly

I suggest create new branch to begin transforming to document-based app.

limejelly avatar Mar 11 '13 18:03 limejelly

Done. See "feature/multiDocSupport"

yepher avatar Mar 11 '13 18:03 yepher

I think we are almost done. Please, check my pull request in feature/multiDocSupport branch. Now it support saving/opening documents and other DBA-things.

limejelly avatar Mar 13 '13 21:03 limejelly

I gave it a try. When I try to create a new project I get stuck in the dialog. Neither the "open" or "close" buttons dismiss the dialog.

Here are the steps I am performing:

  1. Launch CDP (Core Data Pro)
  2. Click Menu File->New Project
  3. Select iOS Simulator Tab
  4. Pick an app that supports Core Data
  5. Select the apps persistence file
  6. Select 'Open"
  7. Problem: The dialog does not disappear

Expected Result:

The dialog should disappear and the project should open.

yepher avatar Mar 14 '13 12:03 yepher