Keyboard events in Mac OS 8 list boxes should generate EVENT_SELCHANGE,
authorben <ben@cda61777-01e9-0310-a592-d414129be87e>
Mon, 14 Apr 2003 21:34:46 +0000 (21:34 +0000)
committerben <ben@cda61777-01e9-0310-a592-d414129be87e>
Mon, 14 Apr 2003 21:34:46 +0000 (21:34 +0000)
not EVENT_VALCHANGE.

git-svn-id: svn://svn.tartarus.org/sgt/putty@3118 cda61777-01e9-0310-a592-d414129be87e

mac/macctrls.c

index 16c6ee1..a654d63 100644 (file)
@@ -1,4 +1,4 @@
-/* $Id: macctrls.c,v 1.33 2003/04/13 14:37:07 ben Exp $ */
+/* $Id: macctrls.c,v 1.34 2003/04/14 21:34:46 ben Exp $ */
 /*
  * Copyright (c) 2003 Ben Harris
  * All rights reserved.
@@ -1264,7 +1264,14 @@ void macctrl_key(WindowPtr window, EventRecord *event)
            HandleControlKey(control, (event->message & keyCodeMask) >> 8,
                             event->message & charCodeMask, event->modifiers);
            mc = (union macctrl *)GetControlReference(control);
-           ctrlevent(mcs, mc, EVENT_VALCHANGE);
+           switch (mc->generic.type) {
+             case MACCTRL_LISTBOX:
+               ctrlevent(mcs, mc, EVENT_SELCHANGE);
+               break;
+             default:
+               ctrlevent(mcs, mc, EVENT_VALCHANGE);
+               break;
+           }
        }
     }
 #if !TARGET_API_MAC_CARBON