Changeset 19210 for gsdl/trunk/runtime-src/src/w32server/settings.cpp
- Timestamp:
- 2009-04-22T22:32:44+12:00 (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
gsdl/trunk/runtime-src/src/w32server/settings.cpp
r19015 r19210 61 61 // general settings 62 62 int gsdl_port_num = 80; 63 int gsdl_external_access = 0; 63 64 int gsdl_auto_enter = 0; 64 65 int gsdl_browser = GS_DEFAULT; … … 310 311 311 312 write_ini_line(fout, "portnumber", text_t(gsdl_port_num)); 313 write_ini_line(fout, "externalaccess", text_t(gsdl_external_access)); 312 314 write_ini_line(fout, "autoenter", text_t(gsdl_auto_enter)); 313 315 write_ini_line(fout, "browser", text_t(gsdl_browser)); … … 402 404 // general settings 403 405 gsdl_port_num = 80; 406 gsdl_external_access = 0; 404 407 gsdl_auto_enter = 0; 405 408 gsdl_start_browser = 1; … … 464 467 } else if (key == "portnumber") { 465 468 gsdl_port_num = value.getint(); 469 470 } else if (key == "externalaccess") { 471 gsdl_external_access = value.getint(); 466 472 467 473 } else if (key == "autoenter") { … … 636 642 gsdl_port_num = GetDlgItemInt(hwndDlg, SERVER_PORT_EDIT_BOX, &bres, 0); 637 643 if (!bres) gsdl_port_num = 80; 638 644 645 // whether to allow external access or not 646 res = SendDlgItemMessage(hwndDlg, ID_EXTERNAL_ACCESS, BM_GETCHECK, 0, 0); 647 gsdl_external_access = (res == 1); 648 639 649 // whether to enter the library automatically on startup 640 650 res = SendDlgItemMessage(hwndDlg, ID_AUTO_ENTER_LIBRARY, BM_GETCHECK, 0, 0); 641 651 gsdl_auto_enter = (res == 1); 642 652 643 653 // which browser to use 644 654 gsdl_browser = read_dialog_browser_field (hwndDlg); … … 666 676 // set current values 667 677 SetDlgItemInt(hwndDlg, SERVER_PORT_EDIT_BOX, gsdl_port_num, FALSE); 678 SendDlgItemMessage(hwndDlg, ID_EXTERNAL_ACCESS, BM_SETCHECK, 679 gsdl_external_access ? 1 : 0, 0); 668 680 SendDlgItemMessage(hwndDlg, ID_AUTO_ENTER_LIBRARY, BM_SETCHECK, 669 681 gsdl_auto_enter ? 1 : 0, 0); … … 877 889 int old_gsdl_show_console = gsdl_show_console; 878 890 int old_gsdl_port_num = gsdl_port_num; 891 int old_gsdl_external_access = gsdl_external_access; 879 892 880 893 int res = 0; … … 912 925 if (res == 1) { 913 926 // only update if exited via the OK button 914 if (gsdl_port_num != old_gsdl_port_num) { 927 if ((gsdl_port_num != old_gsdl_port_num) 928 || (gsdl_external_access != old_gsdl_external_access)) { 915 929 EndHTTPServer(); 916 930 StartHTTPServer(window);
Note:
See TracChangeset
for help on using the changeset viewer.