PCem
view src/win-hdconf.c @ 117:a6ce8addfffa
Fixed crash when selecting no sound card.
Fixed number of heads when creating a new hard disc for drive C.
| author | TomW |
|---|---|
| date | Tue Jul 08 21:03:34 2014 +0100 |
| parents | c5989dbbc2ce |
| children |
line source
1 #define BITMAP WINDOWS_BITMAP
2 #include <windows.h>
3 #include <windowsx.h>
4 #undef BITMAP
6 #include "ibm.h"
7 #include "ide.h"
8 #include "resources.h"
9 #include "win.h"
11 static int hd_changed = 0;
13 static char hd_new_name[512];
14 static int hd_new_spt, hd_new_hpc, hd_new_cyl;
16 static BOOL CALLBACK hdnew_dlgproc(HWND hdlg, UINT message, WPARAM wParam, LPARAM lParam)
17 {
18 char s[260];
19 HWND h;
20 int c;
21 PcemHDC hd[2];
22 FILE *f;
23 uint8_t buf[512];
24 switch (message)
25 {
26 case WM_INITDIALOG:
27 h = GetDlgItem(hdlg, IDC_EDIT1);
28 sprintf(s, "%i", 63);
29 SendMessage(h, WM_SETTEXT, 0, (LPARAM)s);
30 h = GetDlgItem(hdlg, IDC_EDIT2);
31 sprintf(s, "%i", 16);
32 SendMessage(h, WM_SETTEXT, 0, (LPARAM)s);
33 h = GetDlgItem(hdlg, IDC_EDIT3);
34 sprintf(s, "%i", 511);
35 SendMessage(h, WM_SETTEXT, 0, (LPARAM)s);
37 h = GetDlgItem(hdlg, IDC_EDITC);
38 SendMessage(h, WM_SETTEXT, 0, (LPARAM)"");
40 h = GetDlgItem(hdlg, IDC_TEXT1);
41 sprintf(s, "Size : %imb", (((511*16*63)*512)/1024)/1024);
42 SendMessage(h, WM_SETTEXT, 0, (LPARAM)s);
44 return TRUE;
45 case WM_COMMAND:
46 switch (LOWORD(wParam))
47 {
48 case IDOK:
49 h = GetDlgItem(hdlg, IDC_EDITC);
50 SendMessage(h, WM_GETTEXT, 511, (LPARAM)hd_new_name);
51 if (!hd_new_name[0])
52 {
53 MessageBox(ghwnd,"Please enter a valid filename","PCem error",MB_OK);
54 return TRUE;
55 }
56 h = GetDlgItem(hdlg, IDC_EDIT1);
57 SendMessage(h, WM_GETTEXT, 255, (LPARAM)s);
58 sscanf(s, "%i", &hd_new_spt);
59 h = GetDlgItem(hdlg, IDC_EDIT2);
60 SendMessage(h, WM_GETTEXT, 255, (LPARAM)s);
61 sscanf(s, "%i", &hd_new_hpc);
62 h = GetDlgItem(hdlg, IDC_EDIT3);
63 SendMessage(h, WM_GETTEXT, 255, (LPARAM)s);
64 sscanf(s, "%i", &hd_new_cyl);
66 if (hd_new_spt > 63)
67 {
68 MessageBox(ghwnd, "Drive has too many sectors (maximum is 63)", "PCem error", MB_OK);
69 return TRUE;
70 }
71 if (hd_new_hpc > 128)
72 {
73 MessageBox(ghwnd, "Drive has too many heads (maximum is 128)", "PCem error", MB_OK);
74 return TRUE;
75 }
76 if (hd_new_cyl > 16383)
77 {
78 MessageBox(ghwnd, "Drive has too many cylinders (maximum is 16383)", "PCem error", MB_OK);
79 return TRUE;
80 }
82 f = fopen64(hd_new_name, "wb");
83 if (!f)
84 {
85 MessageBox(ghwnd, "Can't open file for write", "PCem error", MB_OK);
86 return TRUE;
87 }
88 memset(buf, 0, 512);
89 for (c = 0; c < (hd_new_cyl * hd_new_hpc * hd_new_spt); c++)
90 fwrite(buf, 512, 1, f);
91 fclose(f);
93 MessageBox(ghwnd, "Remember to partition and format the new drive", "PCem", MB_OK);
95 EndDialog(hdlg, 1);
96 return TRUE;
97 case IDCANCEL:
98 EndDialog(hdlg, 0);
99 return TRUE;
101 case IDC_CFILE:
102 if (!getsfile(hdlg, "Hard disc image (*.IMG)\0*.IMG\0All files (*.*)\0*.*\0", ""))
103 {
104 h = GetDlgItem(hdlg, IDC_EDITC);
105 SendMessage(h, WM_SETTEXT, 0, (LPARAM)openfilestring);
106 }
107 return TRUE;
109 case IDC_EDIT1: case IDC_EDIT2: case IDC_EDIT3:
110 h = GetDlgItem(hdlg, IDC_EDIT1);
111 SendMessage(h, WM_GETTEXT, 255, (LPARAM)s);
112 sscanf(s, "%i", &hd[0].spt);
113 h = GetDlgItem(hdlg, IDC_EDIT2);
114 SendMessage(h, WM_GETTEXT, 255, (LPARAM)s);
115 sscanf(s, "%i", &hd[0].hpc);
116 h = GetDlgItem(hdlg, IDC_EDIT3);
117 SendMessage(h, WM_GETTEXT, 255, (LPARAM)s);
118 sscanf(s, "%i", &hd[0].tracks);
120 h = GetDlgItem(hdlg, IDC_TEXT1);
121 sprintf(s, "Size : %imb", (((((uint64_t)hd[0].tracks*(uint64_t)hd[0].hpc)*(uint64_t)hd[0].spt)*512)/1024)/1024);
122 SendMessage(h, WM_SETTEXT, 0, (LPARAM)s);
123 return TRUE;
124 }
125 break;
127 }
128 return FALSE;
129 }
131 BOOL CALLBACK hdsize_dlgproc(HWND hdlg, UINT message, WPARAM wParam, LPARAM lParam)
132 {
133 char s[260];
134 HWND h;
135 PcemHDC hd[2];
136 switch (message)
137 {
138 case WM_INITDIALOG:
139 h = GetDlgItem(hdlg, IDC_EDIT1);
140 sprintf(s, "%i", hd_new_spt);
141 SendMessage(h, WM_SETTEXT, 0, (LPARAM)s);
142 h = GetDlgItem(hdlg, IDC_EDIT2);
143 sprintf(s, "%i", hd_new_hpc);
144 SendMessage(h, WM_SETTEXT, 0, (LPARAM)s);
145 h = GetDlgItem(hdlg, IDC_EDIT3);
146 sprintf(s, "%i", hd_new_cyl);
147 SendMessage(h, WM_SETTEXT, 0, (LPARAM)s);
149 h = GetDlgItem(hdlg, IDC_TEXT1);
150 sprintf(s, "Size : %imb", ((((uint64_t)hd_new_spt*(uint64_t)hd_new_hpc*(uint64_t)hd_new_cyl)*512)/1024)/1024);
151 SendMessage(h, WM_SETTEXT, 0, (LPARAM)s);
153 return TRUE;
154 case WM_COMMAND:
155 switch (LOWORD(wParam))
156 {
157 case IDOK:
158 h = GetDlgItem(hdlg, IDC_EDIT1);
159 SendMessage(h, WM_GETTEXT, 255, (LPARAM)s);
160 sscanf(s, "%i", &hd_new_spt);
161 h = GetDlgItem(hdlg, IDC_EDIT2);
162 SendMessage(h, WM_GETTEXT, 255, (LPARAM)s);
163 sscanf(s, "%i", &hd_new_hpc);
164 h = GetDlgItem(hdlg, IDC_EDIT3);
165 SendMessage(h, WM_GETTEXT, 255, (LPARAM)s);
166 sscanf(s, "%i", &hd_new_cyl);
168 if (hd_new_spt > 63)
169 {
170 MessageBox(ghwnd,"Drive has too many sectors (maximum is 63)","PCem error",MB_OK);
171 return TRUE;
172 }
173 if (hd_new_hpc > 128)
174 {
175 MessageBox(ghwnd,"Drive has too many heads (maximum is 128)","PCem error",MB_OK);
176 return TRUE;
177 }
178 if (hd_new_cyl > 16383)
179 {
180 MessageBox(ghwnd,"Drive has too many cylinders (maximum is 16383)","PCem error",MB_OK);
181 return TRUE;
182 }
184 EndDialog(hdlg,1);
185 return TRUE;
186 case IDCANCEL:
187 EndDialog(hdlg,0);
188 return TRUE;
190 case IDC_EDIT1: case IDC_EDIT2: case IDC_EDIT3:
191 h = GetDlgItem(hdlg, IDC_EDIT1);
192 SendMessage(h, WM_GETTEXT, 255, (LPARAM)s);
193 sscanf(s, "%i", &hd[0].spt);
194 h = GetDlgItem(hdlg, IDC_EDIT2);
195 SendMessage(h, WM_GETTEXT, 255, (LPARAM)s);
196 sscanf(s, "%i", &hd[0].hpc);
197 h = GetDlgItem(hdlg, IDC_EDIT3);
198 SendMessage(h, WM_GETTEXT, 255, (LPARAM)s);
199 sscanf(s, "%i", &hd[0].tracks);
201 h = GetDlgItem(hdlg, IDC_TEXT1);
202 sprintf(s, "Size : %imb", (((((uint64_t)hd[0].tracks*(uint64_t)hd[0].hpc)*(uint64_t)hd[0].spt)*512)/1024)/1024);
203 SendMessage(h, WM_SETTEXT, 0, (LPARAM)s);
204 return TRUE;
205 }
206 break;
208 }
209 return FALSE;
210 }
212 static BOOL CALLBACK hdconf_dlgproc(HWND hdlg, UINT message, WPARAM wParam, LPARAM lParam)
213 {
214 char s[260];
215 HWND h;
216 PcemHDC hd[2];
217 FILE *f;
218 off64_t sz;
219 switch (message)
220 {
221 case WM_INITDIALOG:
222 pause = 1;
223 hd[0] = hdc[0];
224 hd[1] = hdc[1];
225 hd_changed = 0;
227 h = GetDlgItem(hdlg, IDC_EDIT_C_SPT);
228 sprintf(s, "%i", hdc[0].spt);
229 SendMessage(h, WM_SETTEXT, 0, (LPARAM)s);
230 h = GetDlgItem(hdlg, IDC_EDIT_C_HPC);
231 sprintf(s, "%i", hdc[0].hpc);
232 SendMessage(h, WM_SETTEXT, 0, (LPARAM)s);
233 h = GetDlgItem(hdlg, IDC_EDIT_C_CYL);
234 sprintf(s, "%i", hdc[0].tracks);
235 SendMessage(h, WM_SETTEXT, 0, (LPARAM)s);
236 h = GetDlgItem(hdlg, IDC_EDIT_C_FN);
237 SendMessage(h, WM_SETTEXT, 0, (LPARAM)ide_fn[0]);
239 h = GetDlgItem(hdlg, IDC_EDIT_D_SPT);
240 sprintf(s, "%i", hdc[1].spt);
241 SendMessage(h, WM_SETTEXT, 0, (LPARAM)s);
242 h = GetDlgItem(hdlg, IDC_EDIT_D_HPC);
243 sprintf(s, "%i", hdc[1].hpc);
244 SendMessage(h, WM_SETTEXT, 0, (LPARAM)s);
245 h = GetDlgItem(hdlg, IDC_EDIT_D_CYL);
246 sprintf(s, "%i", hdc[1].tracks);
247 SendMessage(h, WM_SETTEXT, 0, (LPARAM)s);
248 h= GetDlgItem(hdlg, IDC_EDIT_D_FN);
249 SendMessage(h, WM_SETTEXT, 0, (LPARAM)ide_fn[1]);
251 h = GetDlgItem(hdlg, IDC_TEXT_C_SIZE);
252 sprintf(s, "Size : %imb", (((((uint64_t)hd[0].tracks*(uint64_t)hd[0].hpc)*(uint64_t)hd[0].spt)*512)/1024)/1024);
253 SendMessage(h, WM_SETTEXT, 0, (LPARAM)s);
255 h = GetDlgItem(hdlg, IDC_TEXT_D_SIZE);
256 sprintf(s, "Size : %imb", (((((uint64_t)hd[1].tracks*(uint64_t)hd[1].hpc)*(uint64_t)hd[1].spt)*512)/1024)/1024);
257 SendMessage(h, WM_SETTEXT, 0, (LPARAM)s);
258 return TRUE;
260 case WM_COMMAND:
261 switch (LOWORD(wParam))
262 {
263 case IDOK:
264 if (hd_changed)
265 {
266 if (MessageBox(NULL, "This will reset PCem!\nOkay to continue?", "PCem", MB_OKCANCEL) == IDOK)
267 {
268 h = GetDlgItem(hdlg, IDC_EDIT_C_SPT);
269 SendMessage(h, WM_GETTEXT, 255, (LPARAM)s);
270 sscanf(s, "%i", &hd[0].spt);
271 h = GetDlgItem(hdlg, IDC_EDIT_C_HPC);
272 SendMessage(h, WM_GETTEXT, 255, (LPARAM)s);
273 sscanf(s, "%i", &hd[0].hpc);
274 h = GetDlgItem(hdlg, IDC_EDIT_C_CYL);
275 SendMessage(h, WM_GETTEXT, 255, (LPARAM)s);
276 sscanf(s, "%i", &hd[0].tracks);
277 h = GetDlgItem(hdlg, IDC_EDIT_C_FN);
278 SendMessage(h, WM_GETTEXT, 511, (LPARAM)ide_fn[0]);
280 h = GetDlgItem(hdlg, IDC_EDIT_D_SPT);
281 SendMessage(h, WM_GETTEXT, 255, (LPARAM)s);
282 sscanf(s, "%i", &hd[1].spt);
283 h = GetDlgItem(hdlg, IDC_EDIT_D_HPC);
284 SendMessage(h, WM_GETTEXT, 255, (LPARAM)s);
285 sscanf(s, "%i", &hd[1].hpc);
286 h = GetDlgItem(hdlg, IDC_EDIT_D_CYL);
287 SendMessage(h, WM_GETTEXT, 255, (LPARAM)s);
288 sscanf(s, "%i", &hd[1].tracks);
289 h = GetDlgItem(hdlg, IDC_EDIT_D_FN);
290 SendMessage(h, WM_GETTEXT, 511, (LPARAM)ide_fn[1]);
292 hdc[0] = hd[0];
293 hdc[1] = hd[1];
295 saveconfig();
297 resetpchard();
298 }
299 }
300 case IDCANCEL:
301 EndDialog(hdlg, 0);
302 pause = 0;
303 return TRUE;
305 case IDC_EJECTC:
306 hd[0].spt = 0;
307 hd[0].hpc = 0;
308 hd[0].tracks = 0;
309 ide_fn[0][0] = 0;
310 SetDlgItemText(hdlg, IDC_EDIT_C_SPT, "0");
311 SetDlgItemText(hdlg, IDC_EDIT_C_HPC, "0");
312 SetDlgItemText(hdlg, IDC_EDIT_C_CYL, "0");
313 SetDlgItemText(hdlg, IDC_EDIT_C_FN, "");
314 hd_changed = 1;
315 return TRUE;
316 case IDC_EJECTD:
317 hd[1].spt = 0;
318 hd[1].hpc = 0;
319 hd[1].tracks = 0;
320 ide_fn[1][0] = 0;
321 SetDlgItemText(hdlg, IDC_EDIT_D_SPT, "0");
322 SetDlgItemText(hdlg, IDC_EDIT_D_HPC, "0");
323 SetDlgItemText(hdlg, IDC_EDIT_D_CYL, "0");
324 SetDlgItemText(hdlg, IDC_EDIT_D_FN, "");
325 hd_changed = 1;
326 return TRUE;
328 case IDC_CNEW:
329 if (DialogBox(hinstance, TEXT("HdNewDlg"), hdlg, hdnew_dlgproc) == 1)
330 {
331 h = GetDlgItem(hdlg, IDC_EDIT_C_SPT);
332 sprintf(s, "%i", hd_new_spt);
333 SendMessage(h, WM_SETTEXT, 0, (LPARAM)s);
334 h = GetDlgItem(hdlg, IDC_EDIT_C_HPC);
335 sprintf(s, "%i", hd_new_hpc);
336 SendMessage(h, WM_SETTEXT, 0, (LPARAM)s);
337 h = GetDlgItem(hdlg, IDC_EDIT_C_CYL);
338 sprintf(s, "%i", hd_new_cyl);
339 SendMessage(h, WM_SETTEXT, 0, (LPARAM)s);
340 h = GetDlgItem(hdlg, IDC_EDIT_C_FN);
341 SendMessage(h, WM_SETTEXT, 0, (LPARAM)hd_new_name);
343 h = GetDlgItem(hdlg, IDC_TEXT_C_SIZE);
344 sprintf(s, "Size : %imb", (((((uint64_t)hd_new_cyl*(uint64_t)hd_new_hpc)*(uint64_t)hd_new_spt)*512)/1024)/1024);
345 SendMessage(h, WM_SETTEXT, 0, (LPARAM)s);
347 hd_changed = 1;
348 }
349 return TRUE;
351 case IDC_CFILE:
352 if (!getfile(hdlg, "Hard disc image (*.IMG)\0*.IMG\0All files (*.*)\0*.*\0", ""))
353 {
354 f = fopen64(openfilestring, "rb");
355 if (!f)
356 {
357 MessageBox(ghwnd,"Can't open file for read","PCem error",MB_OK);
358 return TRUE;
359 }
360 fseeko64(f, -1, SEEK_END);
361 sz = ftello64(f) + 1;
362 fclose(f);
363 hd_new_spt = 63;
364 hd_new_hpc = 16;
365 hd_new_cyl = ((sz / 512) / 16) / 63;
367 if (DialogBox(hinstance, TEXT("HdSizeDlg"), hdlg, hdsize_dlgproc) == 1)
368 {
369 h = GetDlgItem(hdlg, IDC_EDIT_C_SPT);
370 sprintf(s, "%i", hd_new_spt);
371 SendMessage(h, WM_SETTEXT, 0, (LPARAM)s);
372 h = GetDlgItem(hdlg, IDC_EDIT_C_HPC);
373 sprintf(s, "%i", hd_new_hpc);
374 SendMessage(h, WM_SETTEXT, 0, (LPARAM)s);
375 h = GetDlgItem(hdlg, IDC_EDIT_C_CYL);
376 sprintf(s, "%i", hd_new_cyl);
377 SendMessage(h, WM_SETTEXT, 0, (LPARAM)s);
378 h = GetDlgItem(hdlg, IDC_EDIT_C_FN);
379 SendMessage(h, WM_SETTEXT, 0, (LPARAM)openfilestring);
381 h= GetDlgItem(hdlg, IDC_TEXT_C_SIZE);
382 sprintf(s, "Size : %imb", (((((uint64_t)hd_new_cyl*(uint64_t)hd_new_hpc)*(uint64_t)hd_new_spt)*512)/1024)/1024);
383 SendMessage(h, WM_SETTEXT, 0, (LPARAM)s);
385 hd_changed = 1;
386 }
387 }
388 return TRUE;
390 case IDC_DNEW:
391 if (DialogBox(hinstance, TEXT("HdNewDlg"), hdlg, hdnew_dlgproc) == 1)
392 {
393 h = GetDlgItem(hdlg, IDC_EDIT_D_SPT);
394 sprintf(s, "%i", hd_new_spt);
395 SendMessage(h, WM_SETTEXT, 0, (LPARAM)s);
396 h = GetDlgItem(hdlg, IDC_EDIT_D_HPC);
397 sprintf(s, "%i", hd_new_hpc);
398 SendMessage(h, WM_SETTEXT, 0, (LPARAM)s);
399 h = GetDlgItem(hdlg, IDC_EDIT_D_CYL);
400 sprintf(s, "%i", hd_new_cyl);
401 SendMessage(h, WM_SETTEXT, 0, (LPARAM)s);
402 h = GetDlgItem(hdlg, IDC_EDIT_D_FN);
403 SendMessage(h, WM_SETTEXT, 0, (LPARAM)hd_new_name);
405 h= GetDlgItem(hdlg, IDC_TEXT_D_SIZE);
406 sprintf(s, "Size : %imb", (((((uint64_t)hd_new_cyl*(uint64_t)hd_new_hpc)*(uint64_t)hd_new_spt)*512)/1024)/1024);
407 SendMessage(h, WM_SETTEXT, 0, (LPARAM)s);
409 hd_changed = 1;
410 }
411 return TRUE;
413 case IDC_DFILE:
414 if (!getfile(hdlg, "Hard disc image (*.IMG)\0*.IMG\0All files (*.*)\0*.*\0", ""))
415 {
416 f = fopen64(openfilestring, "rb");
417 if (!f)
418 {
419 MessageBox(ghwnd,"Can't open file for read","PCem error",MB_OK);
420 return TRUE;
421 }
422 fseeko64(f, -1, SEEK_END);
423 sz = ftello64(f) + 1;
424 fclose(f);
425 hd_new_spt = 63;
426 hd_new_hpc = 16;
427 hd_new_cyl = ((sz / 512) / 16) / 63;
429 if (DialogBox(hinstance, TEXT("HdSizeDlg"), hdlg, hdsize_dlgproc) == 1)
430 {
431 h = GetDlgItem(hdlg, IDC_EDIT_D_SPT);
432 sprintf(s, "%i", hd_new_spt);
433 SendMessage(h, WM_SETTEXT, 0, (LPARAM)s);
434 h = GetDlgItem(hdlg, IDC_EDIT_D_HPC);
435 sprintf(s, "%i", hd_new_hpc);
436 SendMessage(h, WM_SETTEXT, 0, (LPARAM)s);
437 h = GetDlgItem(hdlg, IDC_EDIT_D_CYL);
438 sprintf(s, "%i", hd_new_cyl);
439 SendMessage(h, WM_SETTEXT, 0, (LPARAM)s);
440 h = GetDlgItem(hdlg, IDC_EDIT_D_FN);
441 SendMessage(h, WM_SETTEXT, 0, (LPARAM)openfilestring);
443 h = GetDlgItem(hdlg, IDC_TEXT_D_SIZE);
444 sprintf(s, "Size : %imb", (((((uint64_t)hd_new_cyl*(uint64_t)hd_new_hpc)*(uint64_t)hd_new_spt)*512)/1024)/1024);
445 SendMessage(h, WM_SETTEXT, 0, (LPARAM)s);
447 hd_changed = 1;
448 }
449 }
450 return TRUE;
452 case IDC_EDIT_C_SPT: case IDC_EDIT_C_HPC: case IDC_EDIT_C_CYL:
453 h = GetDlgItem(hdlg, IDC_EDIT_C_SPT);
454 SendMessage(h, WM_GETTEXT, 255, (LPARAM)s);
455 sscanf(s, "%i", &hd[0].spt);
456 h = GetDlgItem(hdlg, IDC_EDIT_C_HPC);
457 SendMessage(h, WM_GETTEXT, 255, (LPARAM)s);
458 sscanf(s, "%i", &hd[0].hpc);
459 h = GetDlgItem(hdlg, IDC_EDIT_C_CYL);
460 SendMessage(h, WM_GETTEXT, 255, (LPARAM)s);
461 sscanf(s, "%i", &hd[0].tracks);
463 h = GetDlgItem(hdlg, IDC_TEXT_C_SIZE);
464 sprintf(s, "Size : %imb", ((((hd[0].tracks*hd[0].hpc)*hd[0].spt)*512)/1024)/1024);
465 SendMessage(h, WM_SETTEXT, 0, (LPARAM)s);
466 return TRUE;
468 case IDC_EDIT_D_SPT: case IDC_EDIT_D_HPC: case IDC_EDIT_D_CYL:
469 h = GetDlgItem(hdlg, IDC_EDIT_D_SPT);
470 SendMessage(h, WM_GETTEXT, 255, (LPARAM)s);
471 sscanf(s, "%i", &hd[1].spt);
472 h = GetDlgItem(hdlg, IDC_EDIT_D_HPC);
473 SendMessage(h, WM_GETTEXT, 255, (LPARAM)s);
474 sscanf(s, "%i", &hd[1].hpc);
475 h = GetDlgItem(hdlg, IDC_EDIT_D_CYL);
476 SendMessage(h, WM_GETTEXT, 255, (LPARAM)s);
477 sscanf(s, "%i", &hd[1].tracks);
479 h = GetDlgItem(hdlg, IDC_TEXT_D_SIZE);
480 sprintf(s, "Size : %imb", ((((hd[1].tracks*hd[1].hpc)*hd[1].spt)*512)/1024)/1024);
481 SendMessage(h, WM_SETTEXT, 0, (LPARAM)s);
482 return TRUE;
483 }
484 break;
486 }
487 return FALSE;
488 }
490 void hdconf_open(HWND hwnd)
491 {
492 DialogBox(hinstance, TEXT("HdConfDlg"), hwnd, hdconf_dlgproc);
493 }
