Auto Save and Versions is a good feature for my document-based app.  But a 
large group of users keep all of their data in one document, and having to 
think about a document is a poor experience and has contributed to bad reviews 
by these users.  So I am making a "lite" version of the app for these users 
which, among other things, will appear to the user as a shoebox app (not 
document-based).

I've chosen to continue using the document architecture under the hood, though, 
and simply hide the document-ness from the user.  I think this reduces the 
development and maintenance cost for the shoebox app by 90%.  (Actually, both 
apps are going to ship with almost all of the same code and resources.)  As a 
bonus, the shoebox app will have Apple's familiar Auto Save and Versions in the 
title bar.

One issue which I ran into is that the Auto Save / Versions menu which appears 
when the user clicks the disclosure triangle in the title bar looks like this…

Rename…
Move To…
Duplicate
Lock
Revert to…
Last Opened
Browse All Versions…

Arghh.  The first 3-4 items are not applicable to a shoebox app.  I've found 
that I can eliminate the items I don't want by overriding -menuNeedsUpdate: in 
my document subclass, but this is kind of fragile because I had to 
reverse-engineer which menu items to delete based on their actions (selectors). 
 These selectors are Apple implementation detail.  The fact that the document 
is the delegate for that menu, and thus the fact that -menuNeedsUpdate: even 
gets invoked, is probably an implementation detail also.

I've decided that the benefits outweigh the risks, and am proceeding.  (The 
worst-case outcome is that those top menu items will reappear in, say, Mac OS X 
10.10, but clicking them won't have any effect.)

Does anyone know a better way to do this?

Thank you,

Jerry Krinock



_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to