Publish activated/deactivated as notifications.
[enjoyable.git] / JSAction.m
index f96c10d..1cdbeb2 100644 (file)
@@ -9,14 +9,7 @@
 
 @implementation JSAction
 
-@synthesize cookie;
-@synthesize index;
-@synthesize children;
-@synthesize base;
-@synthesize name;
-@synthesize active;
-
-- (id)initWithName:(NSString *)newName base:(JSAction *)newBase {
+- (id)initWithName:(NSString *)newName base:(id <NJActionPathElement>)newBase {
     if ((self = [super init])) {
         self.name = newName;
         self.base = newBase;
     return NULL;
 }
 
-- (NSString *)stringify {
-    if (cookie)
-        return [NSString stringWithFormat: @"%@~%p", [base stringify], cookie];
-    else
-        return [NSString stringWithFormat: @"%@~%@", [base stringify], name];
+- (NSString *)uid {
+    return [NSString stringWithFormat:@"%@~%@", [_base uid], _name];
 }
 
 - (void)notifyEvent:(IOHIDValueRef)value {