comparison win/dw.c @ 119:1cad81b7cc4c

Implemented initial splitbar code on Unix. And made some fixes for setting the ID on all platforms, but specifically windows.
author bsmith@81767d24-ef19-dc11-ae90-00e081727c95
date Sat, 19 Oct 2002 06:36:41 +0000
parents c170181668b7
children edf615d8266e
comparison
equal deleted inserted replaced
118:c170181668b7 119:1cad81b7cc4c
3568 hwndframe = CreateWindow("MDICLIENT", 3568 hwndframe = CreateWindow("MDICLIENT",
3569 "", 3569 "",
3570 WS_VISIBLE | WS_CHILD | WS_CLIPSIBLINGS, 3570 WS_VISIBLE | WS_CHILD | WS_CLIPSIBLINGS,
3571 0,0,2000,1000, 3571 0,0,2000,1000,
3572 DW_HWND_OBJECT, 3572 DW_HWND_OBJECT,
3573 NULL, 3573 (HMENU)id,
3574 DWInstance, 3574 DWInstance,
3575 &ccs); 3575 &ccs);
3576 return hwndframe; 3576 return hwndframe;
3577 } 3577 }
3578 3578
3587 "", 3587 "",
3588 SS_BITMAP | WS_VISIBLE | 3588 SS_BITMAP | WS_VISIBLE |
3589 WS_CHILD | WS_CLIPCHILDREN, 3589 WS_CHILD | WS_CLIPCHILDREN,
3590 0,0,2000,1000, 3590 0,0,2000,1000,
3591 DW_HWND_OBJECT, 3591 DW_HWND_OBJECT,
3592 NULL, 3592 (HMENU)id,
3593 DWInstance, 3593 DWInstance,
3594 NULL); 3594 NULL);
3595 } 3595 }
3596 3596
3597 /* 3597 /*
3612 tmp = CreateWindow(WC_TABCONTROL, 3612 tmp = CreateWindow(WC_TABCONTROL,
3613 "", 3613 "",
3614 WS_VISIBLE | WS_CHILD | WS_CLIPCHILDREN, 3614 WS_VISIBLE | WS_CHILD | WS_CLIPCHILDREN,
3615 0,0,2000,1000, 3615 0,0,2000,1000,
3616 DW_HWND_OBJECT, 3616 DW_HWND_OBJECT,
3617 NULL, 3617 (HMENU)id,
3618 DWInstance, 3618 DWInstance,
3619 NULL); 3619 NULL);
3620 SetWindowLong(tmp, GWL_USERDATA, (ULONG)array); 3620 SetWindowLong(tmp, GWL_USERDATA, (ULONG)array);
3621 dw_window_set_font(tmp, DefaultFont); 3621 dw_window_set_font(tmp, DefaultFont);
3622 return tmp; 3622 return tmp;
4219 "", 4219 "",
4220 WS_CHILD | WS_CLIPCHILDREN | WS_VISIBLE | 4220 WS_CHILD | WS_CLIPCHILDREN | WS_VISIBLE |
4221 (vertical ? TBS_VERT : TBS_HORZ), 4221 (vertical ? TBS_VERT : TBS_HORZ),
4222 0,0,2000,1000, 4222 0,0,2000,1000,
4223 DW_HWND_OBJECT, 4223 DW_HWND_OBJECT,
4224 NULL, 4224 (HMENU)id,
4225 DWInstance, 4225 DWInstance,
4226 NULL); 4226 NULL);
4227 ColorInfo *cinfo = calloc(1, sizeof(ColorInfo)); 4227 ColorInfo *cinfo = calloc(1, sizeof(ColorInfo));
4228 4228
4229 cinfo->back = cinfo->fore = -1; 4229 cinfo->back = cinfo->fore = -1;
4246 return CreateWindow(PROGRESS_CLASS, 4246 return CreateWindow(PROGRESS_CLASS,
4247 "", 4247 "",
4248 WS_VISIBLE | WS_CHILD | WS_CLIPCHILDREN, 4248 WS_VISIBLE | WS_CHILD | WS_CLIPCHILDREN,
4249 0,0,2000,1000, 4249 0,0,2000,1000,
4250 DW_HWND_OBJECT, 4250 DW_HWND_OBJECT,
4251 NULL, 4251 (HMENU)id,
4252 DWInstance, 4252 DWInstance,
4253 NULL); 4253 NULL);
4254 } 4254 }
4255 4255
4256 /* 4256 /*
4266 text, 4266 text,
4267 WS_CHILD | BS_AUTOCHECKBOX | 4267 WS_CHILD | BS_AUTOCHECKBOX |
4268 BS_TEXT | WS_CLIPCHILDREN | WS_VISIBLE, 4268 BS_TEXT | WS_CLIPCHILDREN | WS_VISIBLE,
4269 0,0,2000,1000, 4269 0,0,2000,1000,
4270 DW_HWND_OBJECT, 4270 DW_HWND_OBJECT,
4271 NULL, 4271 (HMENU)id,
4272 DWInstance, 4272 DWInstance,
4273 NULL); 4273 NULL);
4274 bubble->id = id; 4274 bubble->id = id;
4275 bubble->checkbox = 1; 4275 bubble->checkbox = 1;
4276 bubble->pOldProc = (WNDPROC)SubclassWindow(tmp, _BtProc); 4276 bubble->pOldProc = (WNDPROC)SubclassWindow(tmp, _BtProc);
4295 WS_CHILD | LBS_HASSTRINGS | 4295 WS_CHILD | LBS_HASSTRINGS |
4296 LBS_NOTIFY | WS_BORDER | WS_CLIPCHILDREN | 4296 LBS_NOTIFY | WS_BORDER | WS_CLIPCHILDREN |
4297 WS_VSCROLL | (multi ? LBS_MULTIPLESEL : 0) , 4297 WS_VSCROLL | (multi ? LBS_MULTIPLESEL : 0) ,
4298 0,0,2000,1000, 4298 0,0,2000,1000,
4299 DW_HWND_OBJECT, 4299 DW_HWND_OBJECT,
4300 NULL, 4300 (HMENU)id,
4301 DWInstance, 4301 DWInstance,
4302 NULL); 4302 NULL);
4303 ContainerInfo *cinfo = (ContainerInfo *)calloc(1, sizeof(ContainerInfo)); 4303 ContainerInfo *cinfo = (ContainerInfo *)calloc(1, sizeof(ContainerInfo));
4304 4304
4305 if(!cinfo) 4305 if(!cinfo)
6209 HWND tmp = CreateWindow(ObjectClassName, 6209 HWND tmp = CreateWindow(ObjectClassName,
6210 "", 6210 "",
6211 WS_VISIBLE | WS_CHILD | WS_CLIPCHILDREN, 6211 WS_VISIBLE | WS_CHILD | WS_CLIPCHILDREN,
6212 0,0,2000,1000, 6212 0,0,2000,1000,
6213 DW_HWND_OBJECT, 6213 DW_HWND_OBJECT,
6214 NULL, 6214 (HMENU)id,
6215 DWInstance, 6215 DWInstance,
6216 NULL); 6216 NULL);
6217 newbox->pad = 0; 6217 newbox->pad = 0;
6218 newbox->type = 0; 6218 newbox->type = 0;
6219 newbox->count = 0; 6219 newbox->count = 0;
6769 * topleft: Handle to the window to be top or left. 6769 * topleft: Handle to the window to be top or left.
6770 * bottomright: Handle to the window to be bottom or right. 6770 * bottomright: Handle to the window to be bottom or right.
6771 * Returns: 6771 * Returns:
6772 * A handle to a splitbar window or NULL on failure. 6772 * A handle to a splitbar window or NULL on failure.
6773 */ 6773 */
6774 HWND dw_splitbar_new(int type, HWND topleft, HWND bottomright) 6774 HWND dw_splitbar_new(int type, HWND topleft, HWND bottomright, unsigned long id)
6775 { 6775 {
6776 HWND tmp = CreateWindow(SplitbarClassName, 6776 HWND tmp = CreateWindow(SplitbarClassName,
6777 "", 6777 "",
6778 WS_VISIBLE | WS_CHILD | WS_CLIPCHILDREN, 6778 WS_VISIBLE | WS_CHILD | WS_CLIPCHILDREN,
6779 0,0,2000,1000, 6779 0,0,2000,1000,
6780 DW_HWND_OBJECT, 6780 DW_HWND_OBJECT,
6781 NULL, 6781 (HMENU)id,
6782 DWInstance, 6782 DWInstance,
6783 NULL); 6783 NULL);
6784 6784
6785 if(tmp) 6785 if(tmp)
6786 { 6786 {