From c455b9bc29653f2e65af69a66e19b5455653a412 Mon Sep 17 00:00:00 2001 From: nico Date: Sat, 16 Jun 2001 11:06:16 +0000 Subject: [PATCH] When programmatically simulating a mouse click, also change state of the cell git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@10189 72102866-910b-0410-8b05-ffd578937521 --- Source/NSCell.m | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/Source/NSCell.m b/Source/NSCell.m index 7a853dfd7..3dbe861b3 100644 --- a/Source/NSCell.m +++ b/Source/NSCell.m @@ -1112,13 +1112,16 @@ static NSColor *shadowCol; NSView *cv = [self controlView]; if(_cell.is_disabled == YES) - return; + { + return; + } - if (cv) + if (cv != nil) { NSRect cvBounds = [cv bounds]; NSWindow *cvWin = [cv window]; + [self setNextState]; [self highlight: YES withFrame: cvBounds inView: cv]; [cvWin flushWindow]; @@ -1146,6 +1149,8 @@ static NSColor *shadowCol; { if (action) { + [self setNextState]; + NS_DURING { [[NSApplication sharedApplication] sendAction: action