Skip to content

Commit

Permalink
buttons now momentarily go the the pressed state when clicked program…
Browse files Browse the repository at this point in the history
…matically. Closes cappuccino#187
  • Loading branch information
luddep authored and Ross Boucher committed Jan 8, 2010
1 parent d791a18 commit fe2599e
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions AppKit/CPControl.j
Expand Up @@ -308,6 +308,12 @@ var CPControlBlackColor = [CPColor blackColor];
[self highlight:YES];
[self setState:[self nextState]];
[self sendAction:[self action] to:[self target]];

[CPTimer scheduledTimerWithTimeInterval:0.1 target:self selector:@selector(unhighlightButtonTimerDidFinish:) userInfo:nil repeats:NO];
}

- (void)unhighlightButtonTimerDidFinish:(id)sender
{
[self highlight:NO];
}

Expand Down

0 comments on commit fe2599e

Please sign in to comment.