Revert "Implement -reset option feature in WinBoard"
authorArun Persaud <apersaud@lbl.gov>
Thu, 3 Feb 2011 16:28:15 +0000 (08:28 -0800)
committerArun Persaud <apersaud@lbl.gov>
Thu, 3 Feb 2011 16:28:15 +0000 (08:28 -0800)
This reverts commit efecf86cd9b54072c6a2f38d62f1d775e69c545b.

picked the wrong commit from HGM's git tree.

backend.c
winboard/wsettings.c

index e0f6ec9..17e77ae 100644 (file)
--- a/backend.c
+++ b/backend.c
@@ -13908,8 +13908,6 @@ ParseOption(Option *opt, ChessProgramState *cps)
            opt->type = Button;
        } else if(p = strstr(opt->name, " -save")) {
            opt->type = SaveButton;
            opt->type = Button;
        } else if(p = strstr(opt->name, " -save")) {
            opt->type = SaveButton;
-       } else if(p = strstr(opt->name, " -reset")) {
-           opt->type = ResetButton;
        } else return FALSE;
        *p = 0; // terminate option name
        // now look if the command-line options define a setting for this engine option.
        } else return FALSE;
        *p = 0; // terminate option name
        // now look if the command-line options define a setting for this engine option.
index df992aa..ccfae75 100644 (file)
@@ -419,10 +419,7 @@ LRESULT CALLBACK SettingsProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lPa
                if(j < 0) break;\r
                if( activeCps->option[j].type  == SaveButton)\r
                     GetOptionValues(hDlg, activeCps);\r
                if(j < 0) break;\r
                if( activeCps->option[j].type  == SaveButton)\r
                     GetOptionValues(hDlg, activeCps);\r
-               else if( activeCps->option[j].type  == ResetButton) {\r
-                    ClearOptions(activeCps);\r
-                    EndDialog( hDlg, 0 );\r
-               } else if( activeCps->option[j].type  != Button) break;\r
+               else if( activeCps->option[j].type  != Button) break;\r
                snprintf(buf, MSG_SIZ, "option %s\n", activeCps->option[j].name);\r
                SendToProgram(buf, activeCps);\r
            }\r
                snprintf(buf, MSG_SIZ, "option %s\n", activeCps->option[j].name);\r
                SendToProgram(buf, activeCps);\r
            }\r