2006-12-04 07:04:24 +00:00
|
|
|
//
|
2007-04-27 06:41:34 +00:00
|
|
|
// File: VLKeyValueUndo.h - Automatically handle undo functionality for
|
|
|
|
// key-value paths
|
2006-12-04 07:04:24 +00:00
|
|
|
//
|
2007-04-27 06:41:34 +00:00
|
|
|
// Author(s):
|
|
|
|
//
|
|
|
|
// (MN) Matthias Neeracher
|
|
|
|
//
|
2011-09-06 01:15:51 +00:00
|
|
|
// Copyright © 2007-2011 Matthias Neeracher
|
2006-12-04 07:04:24 +00:00
|
|
|
//
|
|
|
|
|
|
|
|
#import <Cocoa/Cocoa.h>
|
|
|
|
|
2011-09-06 01:15:51 +00:00
|
|
|
typedef void (^VLKeyValueUpdateHook)(NSString * keyPath);
|
|
|
|
|
2006-12-04 07:04:24 +00:00
|
|
|
@interface VLKeyValueUndo : NSObject {
|
2011-09-06 01:15:51 +00:00
|
|
|
id owner;
|
|
|
|
NSDictionary * keysAndNames;
|
|
|
|
VLKeyValueUpdateHook updateHook;
|
2006-12-04 07:04:24 +00:00
|
|
|
}
|
|
|
|
|
2011-09-06 01:15:51 +00:00
|
|
|
- (id)initWithOwner:(id)owner keysAndNames:(NSDictionary *)keysAndNames update:(VLKeyValueUpdateHook)hook;
|
2006-12-04 07:04:24 +00:00
|
|
|
- (id)initWithOwner:(id)owner keysAndNames:(NSDictionary *)keysAndNames;
|
|
|
|
|
|
|
|
@end
|