diff --git a/xwords4/common/board.c b/xwords4/common/board.c index 464d3abae..b0806cb3b 100644 --- a/xwords4/common/board.c +++ b/xwords4/common/board.c @@ -394,6 +394,7 @@ board_prefsChanged( BoardCtxt* board, CommonPrefs* cp ) board->disableArrow = !cp->showBoardArrow; board->hideValsInTray = cp->hideTileValues; + board->skipCommitConfirm = cp->skipCommitConfirm; if ( showArrowChanged ) { showArrowChanged = setArrowVisible( board, XP_FALSE ); @@ -619,8 +620,9 @@ board_commitTurn( BoardCtxt* board ) result = board_hideTray( board ); } - if ( util_userQuery( board->util, QUERY_COMMIT_TURN, - stream ) ) { + if ( board->skipCommitConfirm + || util_userQuery( board->util, QUERY_COMMIT_TURN, + stream ) ) { result = server_commitMove( board->server ) || result; /* invalidate any selected tiles in case we'll be drawing this tray again rather than some other -- as is the diff --git a/xwords4/common/boardp.h b/xwords4/common/boardp.h index 08ee48f8b..58c697586 100644 --- a/xwords4/common/boardp.h +++ b/xwords4/common/boardp.h @@ -155,6 +155,7 @@ struct BoardCtxt { XP_Bool timerPending; XP_Bool disableArrow; XP_Bool hideValsInTray; + XP_Bool skipCommitConfirm; XP_Bool eraseTray; XP_Bool boardObscuresTray; diff --git a/xwords4/common/comtypes.h b/xwords4/common/comtypes.h index b69fbc2bd..76bbf1b74 100644 --- a/xwords4/common/comtypes.h +++ b/xwords4/common/comtypes.h @@ -129,7 +129,7 @@ typedef struct CommonPrefs { XP_Bool showBoardArrow; /* applies to all games */ XP_Bool showRobotScores; /* applies to all games */ XP_Bool hideTileValues; - XP_Bool reserved2; /* get to 32-bit for ARM... */ + XP_Bool skipCommitConfirm; /* applies to all games */ #ifdef XWFEATURE_SLOW_ROBOT XP_U16 robotThinkMin, robotThinkMax; #endif diff --git a/xwords4/wince/ceprefs.c b/xwords4/wince/ceprefs.c index e95716f38..c298c69ee 100755 --- a/xwords4/wince/ceprefs.c +++ b/xwords4/wince/ceprefs.c @@ -86,8 +86,8 @@ adjustForChoice( CePrefsDlgState* state ) HWND hDlg = state->dlgHdr.hDlg; XP_U16 goesWithGlobal[] = {IDC_CHECKCOLORPLAYED, IDC_LEFTYCHECK, IDC_CHECKSHOWCURSOR, IDC_CHECKROBOTSCORES, - IDC_HIDETILEVALUES, IDC_PREFCOLORS, - IDC_PREFLOCALE + IDC_SKIPCONFIRM, IDC_HIDETILEVALUES, + IDC_PREFCOLORS, IDC_PREFLOCALE #ifdef ALLOW_CHOOSE_FONTS ,IDC_PREFFONTS #endif @@ -210,6 +210,7 @@ loadControlsFromState( CePrefsDlgState* pState ) ceSetChecked( hDlg, IDC_CHECKSHOWCURSOR, prefsPrefs->cp.showBoardArrow ); ceSetChecked( hDlg, IDC_CHECKROBOTSCORES, prefsPrefs->cp.showRobotScores ); + ceSetChecked( hDlg, IDC_SKIPCONFIRM, prefsPrefs->cp.skipCommitConfirm ); ceSetChecked( hDlg, IDC_HIDETILEVALUES, prefsPrefs->cp.hideTileValues ); #ifdef FEATURE_TRAY_EDIT @@ -264,6 +265,7 @@ ceControlsToPrefs( CePrefsDlgState* state ) prefsPrefs->cp.showBoardArrow = ceGetChecked( hDlg, IDC_CHECKSHOWCURSOR ); prefsPrefs->cp.showRobotScores = ceGetChecked( hDlg, IDC_CHECKROBOTSCORES ); + prefsPrefs->cp.skipCommitConfirm = ceGetChecked( hDlg, IDC_SKIPCONFIRM ); prefsPrefs->cp.hideTileValues = ceGetChecked( hDlg, IDC_HIDETILEVALUES ); prefsPrefs->gp.timerEnabled = ceGetChecked( hDlg, TIMER_CHECK ); diff --git a/xwords4/wince/l10n/xwords4_catalan.rc b/xwords4/wince/l10n/xwords4_catalan.rc index 0c63cc0cb..c0734ecad 100644 --- a/xwords4/wince/l10n/xwords4_catalan.rc +++ b/xwords4/wince/l10n/xwords4_catalan.rc @@ -531,7 +531,8 @@ END #define PR_ROW5 (PR_ROW4+PR_SPACING) #define PR_ROW6 (PR_ROW5+PR_SPACING) #define PR_ROW7 (PR_ROW6+PR_SPACING) -#define PR_BUTTONROW (PR_ROW7+PR_SPACING+3) +#define PR_ROW8 (PR_ROW7+PR_SPACING) +#define PR_BUTTONROW (PR_ROW8+PR_SPACING+3) #define PR_LEFT 6 #ifdef _WIN32_WCE @@ -558,12 +559,14 @@ BEGIN BS_AUTOCHECKBOX | WS_TABSTOP,PR_LEFT,PR_ROW3,80,PREFS_ROW_HT CONTROL "Explica la puntuació dels robots",IDC_CHECKROBOTSCORES,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,PR_LEFT,PR_ROW4,95,PREFS_ROW_HT + CONTROL "Skip turn confirm",IDC_SKIPCONFIRM,"Button", /* translate */ + BS_AUTOCHECKBOX | WS_TABSTOP,PR_LEFT,PR_ROW5,80,PREFS_ROW_HT CONTROL "Amaga els valors de les lletres",IDC_HIDETILEVALUES,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,PR_LEFT,PR_ROW5,95,PREFS_ROW_HT - PUSHBUTTON "Edita els colors...",IDC_PREFCOLORS,PR_LEFT,PR_ROW6,70,12 - PUSHBUTTON "Canvia la llengua...",IDC_PREFLOCALE,PR_LEFT,PR_ROW7,70,12 + BS_AUTOCHECKBOX | WS_TABSTOP,PR_LEFT,PR_ROW6,95,PREFS_ROW_HT + PUSHBUTTON "Edita els colors...",IDC_PREFCOLORS,PR_LEFT,PR_ROW7,70,12 + PUSHBUTTON "Canvia la llengua...",IDC_PREFLOCALE,PR_LEFT,PR_ROW8,70,12 #ifdef ALLOW_CHOOSE_FONTS - PUSHBUTTON "Trieu el tipus de lletra...",IDC_PREFFONTS,PR_LEFT,PR_ROW8,60,12 + PUSHBUTTON "Trieu el tipus de lletra...",IDC_PREFFONTS,PR_LEFT,PR_ROW9,60,12 #endif /* Per game */ diff --git a/xwords4/wince/l10n/xwords4_english.rc b/xwords4/wince/l10n/xwords4_english.rc index 92b13b4f7..d14d50e1d 100755 --- a/xwords4/wince/l10n/xwords4_english.rc +++ b/xwords4/wince/l10n/xwords4_english.rc @@ -521,7 +521,8 @@ END #define PR_ROW5 (PR_ROW4+PR_SPACING) #define PR_ROW6 (PR_ROW5+PR_SPACING) #define PR_ROW7 (PR_ROW6+PR_SPACING) -#define PR_BUTTONROW (PR_ROW7+PR_SPACING+3) +#define PR_ROW8 (PR_ROW7+PR_SPACING) +#define PR_BUTTONROW (PR_ROW8+PR_SPACING+3) #ifdef _WIN32_WCE # define PREFS_DLG_HT PR_BUTTONROW @@ -547,12 +548,14 @@ BEGIN BS_AUTOCHECKBOX | WS_TABSTOP,8,PR_ROW3,80,PREFS_ROW_HT CONTROL "Explain robot scores",IDC_CHECKROBOTSCORES,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,8,PR_ROW4,80,PREFS_ROW_HT - CONTROL "Hide tile values",IDC_HIDETILEVALUES,"Button", + CONTROL "Skip turn confirmation",IDC_SKIPCONFIRM,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,8,PR_ROW5,80,PREFS_ROW_HT - PUSHBUTTON "Edit colors...",IDC_PREFCOLORS,8,PR_ROW6,80,12 - PUSHBUTTON "Change language...",IDC_PREFLOCALE,8,PR_ROW7,80,12 + CONTROL "Hide tile values",IDC_HIDETILEVALUES,"Button", + BS_AUTOCHECKBOX | WS_TABSTOP,8,PR_ROW6,80,PREFS_ROW_HT + PUSHBUTTON "Edit colors...",IDC_PREFCOLORS,8,PR_ROW7,80,12 + PUSHBUTTON "Change language...",IDC_PREFLOCALE,8,PR_ROW8,80,12 #ifdef ALLOW_CHOOSE_FONTS - PUSHBUTTON "Choose font...",IDC_PREFFONTS,8,PR_ROW8,60,12 + PUSHBUTTON "Choose font...",IDC_PREFFONTS,8,PR_ROW9,60,12 #endif /* Per game */ diff --git a/xwords4/wince/l10n/xwords4_french.rc b/xwords4/wince/l10n/xwords4_french.rc index 6863c6be4..829f24ad6 100644 --- a/xwords4/wince/l10n/xwords4_french.rc +++ b/xwords4/wince/l10n/xwords4_french.rc @@ -514,7 +514,8 @@ END #define PR_ROW5 (PR_ROW4+PR_SPACING) #define PR_ROW6 (PR_ROW5+PR_SPACING) #define PR_ROW7 (PR_ROW6+PR_SPACING) -#define PR_BUTTONROW (PR_ROW7+PR_SPACING) +#define PR_ROW8 (PR_ROW7+PR_SPACING) +#define PR_BUTTONROW (PR_ROW8+PR_SPACING) #define PR_LEFT 6 #ifdef _WIN32_WCE @@ -541,12 +542,14 @@ BEGIN BS_AUTOCHECKBOX | WS_TABSTOP,PR_LEFT,PR_ROW3,60,PREFS_ROW_HT CONTROL "Détails des points du robot",IDC_CHECKROBOTSCORES,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,PR_LEFT,PR_ROW4,87,PREFS_ROW_HT + CONTROL "Skip turn confirm",IDC_SKIPCONFIRM,"Button", /* <- translate */ + BS_AUTOCHECKBOX | WS_TABSTOP,PR_LEFT,PR_ROW5,80,PREFS_ROW_HT CONTROL "Cacher valeur des lettres",IDC_HIDETILEVALUES,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,PR_LEFT,PR_ROW5,87,PREFS_ROW_HT - PUSHBUTTON "Editer les couleurs...",IDC_PREFCOLORS,PR_LEFT,PR_ROW6,70,12 - PUSHBUTTON "Changer la langue...",IDC_PREFLOCALE,PR_LEFT,PR_ROW7,70,12 // <-translate + BS_AUTOCHECKBOX | WS_TABSTOP,PR_LEFT,PR_ROW6,87,PREFS_ROW_HT + PUSHBUTTON "Editer les couleurs...",IDC_PREFCOLORS,PR_LEFT,PR_ROW7,70,12 + PUSHBUTTON "Changer la langue...",IDC_PREFLOCALE,PR_LEFT,PR_ROW8,70,12 // <-translate #ifdef ALLOW_CHOOSE_FONTS - PUSHBUTTON "Choisir une police...",IDC_PREFFONTS,PR_LEFT,PR_ROW8,60,12 + PUSHBUTTON "Choisir une police...",IDC_PREFFONTS,PR_LEFT,PR_ROW9,60,12 #endif /* Per game */ diff --git a/xwords4/wince/l10n/xwords4_polish.rc b/xwords4/wince/l10n/xwords4_polish.rc index 4c88723ac..722a9f4be 100644 --- a/xwords4/wince/l10n/xwords4_polish.rc +++ b/xwords4/wince/l10n/xwords4_polish.rc @@ -523,7 +523,8 @@ END #define PR_ROW5 (PR_ROW4+PR_SPACING) #define PR_ROW6 (PR_ROW5+PR_SPACING) #define PR_ROW7 (PR_ROW6+PR_SPACING) -#define PR_BUTTONROW (PR_ROW7+PR_SPACING) +#define PR_ROW8 (PR_ROW7+PR_SPACING) +#define PR_BUTTONROW (PR_ROW8+PR_SPACING) #ifdef _WIN32_WCE # define PREFS_DLG_HT PR_BUTTONROW @@ -549,12 +550,14 @@ BEGIN BS_AUTOCHECKBOX | WS_TABSTOP,4,PR_ROW3,80,PREFS_ROW_HT CONTROL "Pokazuj pkty robotów",IDC_CHECKROBOTSCORES,"Button", BS_AUTOCHECKBOX | WS_TABSTOP,4,PR_ROW4,90,PREFS_ROW_HT + CONTROL "Skip turn confirm",IDC_SKIPCONFIRM,"Button", /* translate */ + BS_AUTOCHECKBOX | WS_TABSTOP,4,PR_ROW5,80,PREFS_ROW_HT CONTROL "Ukryj wartość klocków",IDC_HIDETILEVALUES,"Button", - BS_AUTOCHECKBOX | WS_TABSTOP,4,PR_ROW5,82,PREFS_ROW_HT - PUSHBUTTON "Ustaw kolory...",IDC_PREFCOLORS,4,PR_ROW6,60,12 - PUSHBUTTON "Zmień język...",IDC_PREFLOCALE,4,PR_ROW7,60,12 + BS_AUTOCHECKBOX | WS_TABSTOP,4,PR_ROW6,82,PREFS_ROW_HT + PUSHBUTTON "Ustaw kolory...",IDC_PREFCOLORS,4,PR_ROW7,60,12 + PUSHBUTTON "Zmień język...",IDC_PREFLOCALE,4,PR_ROW8,60,12 #ifdef ALLOW_CHOOSE_FONTS - PUSHBUTTON "Wybierz font...",IDC_PREFFONTS,4,PR_ROW7,60,12 + PUSHBUTTON "Wybierz font...",IDC_PREFFONTS,4,PR_ROW9,60,12 #endif /* Per game */ diff --git a/xwords4/wince/resource.h b/xwords4/wince/resource.h index e886a0752..0f95eb422 100755 --- a/xwords4/wince/resource.h +++ b/xwords4/wince/resource.h @@ -83,79 +83,80 @@ #define IDC_CHECKHINTSOK 1041 #define IDC_CHECKSHOWCURSOR 1042 #define IDC_CHECKROBOTSCORES 1043 -#define IDC_HIDETILEVALUES 1044 -#define IDC_PREFCOLORS 1045 -#define IDC_PREFLOCALE 1046 -#define IDC_PREFFONTS 1047 -#define PHONIES_LABEL 1048 -#define GIROLECONF_BUTTON 1049 -#define GIJUGGLE_BUTTON 1050 -#define IDC_TOTAL_LABEL 1051 -#define IDC_REMOTE_LABEL 1052 -#define IDC_PICKTILES 1053 -#define IDC_BPICK 1054 -#define IDC_PICKMSG 1055 +#define IDC_SKIPCONFIRM 1044 +#define IDC_HIDETILEVALUES 1045 +#define IDC_PREFCOLORS 1046 +#define IDC_PREFLOCALE 1047 +#define IDC_PREFFONTS 1048 +#define PHONIES_LABEL 1049 +#define GIROLECONF_BUTTON 1050 +#define GIJUGGLE_BUTTON 1051 +#define IDC_TOTAL_LABEL 1052 +#define IDC_REMOTE_LABEL 1053 +#define IDC_PICKTILES 1054 +#define IDC_BPICK 1055 +#define IDC_PICKMSG 1056 #ifdef FEATURE_TRAY_EDIT -# define IDC_CPICK 1100 -# define IDC_BACKUP 1056 +# define IDC_CPICK 1057 +# define IDC_BACKUP 1058 #endif #ifdef XWFEATURE_SEARCHLIMIT -# define IDC_CHECKHINTSLIMITS 1057 +# define IDC_CHECKHINTSLIMITS 1059 #endif /* buttons and lables must be parallel arrays so CLRSEL_LABEL_OFFSET works. */ -#define DLBLTR_BUTTON 1058 -#define DBLWRD_BUTTON 1059 -#define TPLLTR_BUTTON 1060 -#define TPLWRD_BUTTON 1061 -#define EMPCELL_BUTTON 1062 -#define TBACK_BUTTON 1063 -#define FOCUSCLR_BUTTON 1064 -#define PLAYER1_BUTTON 1065 -#define PLAYER2_BUTTON 1066 -#define PLAYER3_BUTTON 1067 -#define PLAYER4_BUTTON 1068 +#define DLBLTR_BUTTON 1060 +#define DBLWRD_BUTTON 1061 +#define TPLLTR_BUTTON 1062 +#define TPLWRD_BUTTON 1063 +#define EMPCELL_BUTTON 1064 +#define TBACK_BUTTON 1065 +#define FOCUSCLR_BUTTON 1066 +#define PLAYER1_BUTTON 1067 +#define PLAYER2_BUTTON 1068 +#define PLAYER3_BUTTON 1069 +#define PLAYER4_BUTTON 1070 -#define DLBLTR_LABEL 1069 -#define DBLWRD_LABEL 1070 -#define TPLLTR_LABEL 1071 -#define TPLWRD_LABEL 1072 -#define EMPCELL_LABEL 1073 -#define TBACK_LABEL 1074 -#define FOCUSCLR_LABEL 1075 -#define PLAYER1_LABEL 1076 -#define PLAYER2_LABEL 1077 -#define PLAYER3_LABEL 1078 -#define PLAYER4_LABEL 1079 +#define DLBLTR_LABEL 1071 +#define DBLWRD_LABEL 1072 +#define TPLLTR_LABEL 1073 +#define TPLWRD_LABEL 1074 +#define EMPCELL_LABEL 1075 +#define TBACK_LABEL 1076 +#define FOCUSCLR_LABEL 1077 +#define PLAYER1_LABEL 1078 +#define PLAYER2_LABEL 1079 +#define PLAYER3_LABEL 1080 +#define PLAYER4_LABEL 1081 -#define DLBLTR_SAMPLE 1080 -#define DBLWRD_SAMPLE 1081 -#define TPLLTR_SAMPLE 1082 -#define TPLWRD_SAMPLE 1083 -#define EMPCELL_SAMPLE 1084 -#define TBACK_SAMPLE 1085 -#define FOCUSCLR_SAMPLE 1086 -#define PLAYER1_SAMPLE 1087 -#define PLAYER2_SAMPLE 1088 -#define PLAYER3_SAMPLE 1089 -#define PLAYER4_SAMPLE 1090 +#define DLBLTR_SAMPLE 1082 +#define DBLWRD_SAMPLE 1083 +#define TPLLTR_SAMPLE 1084 +#define TPLWRD_SAMPLE 1085 +#define EMPCELL_SAMPLE 1086 +#define TBACK_SAMPLE 1087 +#define FOCUSCLR_SAMPLE 1088 +#define PLAYER1_SAMPLE 1089 +#define PLAYER2_SAMPLE 1090 +#define PLAYER3_SAMPLE 1091 +#define PLAYER4_SAMPLE 1092 #define CLRSEL_LABEL_OFFSET (DLBLTR_LABEL-DLBLTR_BUTTON) /* editor dlg: assumption is that the edit field's ID is one more than the corresponding slider's */ #ifdef MY_COLOR_SEL -# define CLREDT_SLIDER1 1091 -# define RED_EDIT 1092 -# define CLREDT_SLIDER2 1093 -# define GREEN_EDIT 1094 -# define CLREDT_SLIDER3 1095 -# define BLUE_EDIT 1096 +# define CLREDT_SLIDER1 1093 +# define RED_EDIT 1094 +# define CLREDT_SLIDER2 1095 +# define GREEN_EDIT 1096 +# define CLREDT_SLIDER3 1097 +# define BLUE_EDIT 1098 -# define RED_LABEL 1097 -# define GREEN_LABEL 1098 -# define BLUE_LABEL 1099 +# define RED_LABEL 1099 +# define GREEN_LABEL 1100 +# define BLUE_LABEL 1101 # define CLSAMPLE_BUTTON_ID 1123 #endif // MY_COLOR_SEL