Rename 'stringify' to 'uid' where it pertains to unique action IDs.
[enjoyable.git] / TargetController.m
index 9f85fd9..074c487 100644 (file)
@@ -37,7 +37,7 @@
                case 0: // none
                        return NULL;
                case 1: // key
-                       if([keyInput hasKey]) {
+                       if(keyInput.hasKey) {
                                TargetKeyboard* k = [[TargetKeyboard alloc] init];
                                [k setVk: [keyInput vk]];
                                [k setDescr: [keyInput descr]];
 }
 
 -(void) commit {
-       id action = [joystickController selectedAction];
-       if(action) {
-               Target* target = [self state];
-               [[configsController currentConfig] setTarget: target forAction: action];
+       JSAction *action = [joystickController selectedAction];
+       if (action) {
+        configsController.currentConfig[action] = self.state;
        }
 }
 
        } else {
                [self setEnabled: YES];
        }
-       Target* target = [[configsController currentConfig] getTargetForAction: jsaction];
+       Target* target = configsController.currentConfig[jsaction];
        
        id act = jsaction;
        NSString* actFullName = [act name];