Skip to content

Commit

Permalink
Force the theme to be saved after a colour is changed
Browse files Browse the repository at this point in the history
  • Loading branch information
ciaran committed Dec 1, 2008
1 parent 4ba0d35 commit ff67a5f
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions TerminalColours.m
Expand Up @@ -52,8 +52,9 @@ - (void)setColour:(id)value forKey:(NSString*)key
[self performSelector:@selector(setScriptCursorColor:) withObject:[self performSelector:@selector(scriptCursorColor)]];

// Saves the value
id prefsController = [NSClassFromString(@"TTAppPrefsController") sharedPreferencesController];
[prefsController observeValueForKeyPath:key ofObject:self change:nil context:NULL];
id cursorType = [values objectForKey:@"CursorType"];
[self setValue:[NSNumber numberWithInt:-1] forKey:@"CursorType"];
[self setValue:cursorType forKey:@"CursorType"];
}

- (id)colourForKey:(NSString*)key
Expand Down

0 comments on commit ff67a5f

Please sign in to comment.