From 9117b20d1805757d79a62b0b6df6aa711221bc1f Mon Sep 17 00:00:00 2001 From: Ben Harris Date: Sat, 5 Apr 2003 22:03:06 +0000 Subject: [PATCH] dd support for list boxes in Mac OS 8. Not entirely solid, but largely working. [ bits missed in the first commit ] [originally from svn r3069] --- mac/mac.h | 2 ++ mac/mac_res.r | 15 ++++++++++++++- mac/macresid.h | 5 ++++- 3 files changed, 20 insertions(+), 2 deletions(-) diff --git a/mac/mac.h b/mac/mac.h index 0f089229..55763768 100644 --- a/mac/mac.h +++ b/mac/mac.h @@ -78,6 +78,8 @@ struct macctrls { unsigned int curpanel; union macctrl **panels; /* lists of controls by panel */ union macctrl *focus; /* Input focus for System 7 */ + union macctrl *defbutton; /* Default button */ + union macctrl *canbutton; /* Cancel button */ }; typedef struct Session { diff --git a/mac/mac_res.r b/mac/mac_res.r index b375e8c7..b18dbdea 100644 --- a/mac/mac_res.r +++ b/mac/mac_res.r @@ -1,4 +1,4 @@ -/* $Id: mac_res.r,v 1.37 2003/03/29 22:04:21 ben Exp $ */ +/* $Id: mac_res.r,v 1.38 2003/04/05 22:03:06 ben Exp $ */ /* * Copyright (c) 1999, 2002, 2003 Ben Harris * All rights reserved. @@ -1128,3 +1128,16 @@ data 'CDEF' (CDEF_EditBox) { data 'CDEF' (CDEF_Default) { $"4EF9 00000000" }; + +/* List box template */ + +resource 'ldes' (ldes_Default) { + versionZero { + 0, /* rows */ + 1, /* cols */ + 0, 0, /* default cell size */ + hasVertScroll, noHorizScroll, + 0, /* LDEF number */ + noGrowSpace + } +}; \ No newline at end of file diff --git a/mac/macresid.h b/mac/macresid.h index bb39097e..b73ccfaf 100644 --- a/mac/macresid.h +++ b/mac/macresid.h @@ -1,4 +1,4 @@ -/* $Id: macresid.h,v 1.14 2003/03/29 22:04:21 ben Exp $ */ +/* $Id: macresid.h,v 1.15 2003/04/05 22:03:06 ben Exp $ */ /* * macresid.h -- Mac resource IDs @@ -59,6 +59,9 @@ /* Controls */ #define cVScroll 128 +/* ldes for list box controls */ +#define ldes_Default 128 + /* xDEFs */ #define CDEF_EditBox 129 #define SYS7_EDITBOX_VARIANT 0