summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJonathan Gordon <rockbox@jdgordon.info>2012-08-14 12:12:15 +1000
committerJonathan Gordon <rockbox@jdgordon.info>2012-08-14 12:12:15 +1000
commit70eb3e6a563758a80ec894c009ca51bd79945043 (patch)
tree88f291ce485f961cb7705dfa597ec62e74884a21
parentbd6e6ed40385c5d5f357a39909ae6a5db60f7ce9 (diff)
downloadrockbox-70eb3e6a563758a80ec894c009ca51bd79945043.tar.gz
rockbox-70eb3e6a563758a80ec894c009ca51bd79945043.zip
Revert "fix erroneous button read in yesno screen and missed buttons in action.c."
This reverts commit 15775c8badac65ad9d7477a1706c019703c15b47.
-rw-r--r--apps/action.c6
-rw-r--r--apps/gui/yesno.c7
2 files changed, 2 insertions, 11 deletions
diff --git a/apps/action.c b/apps/action.c
index 3c130e3e29..5ebcbf771b 100644
--- a/apps/action.c
+++ b/apps/action.c
@@ -232,13 +232,7 @@ static int get_action_worker(int context, int timeout,
232 /* Data from sys events can be pulled with button_get_data 232 /* Data from sys events can be pulled with button_get_data
233 * multimedia button presses don't go through the action system */ 233 * multimedia button presses don't go through the action system */
234 if (button == BUTTON_NONE || button & (SYS_EVENT|BUTTON_MULTIMEDIA)) 234 if (button == BUTTON_NONE || button & (SYS_EVENT|BUTTON_MULTIMEDIA))
235 {
236 /* no button pressed so no point in waiting for release */
237 if (button == BUTTON_NONE)
238 wait_for_release = false;
239 return button; 235 return button;
240 }
241
242 /* the special redraw button should result in a screen refresh */ 236 /* the special redraw button should result in a screen refresh */
243 if (button == BUTTON_REDRAW) 237 if (button == BUTTON_REDRAW)
244 return ACTION_REDRAW; 238 return ACTION_REDRAW;
diff --git a/apps/gui/yesno.c b/apps/gui/yesno.c
index dc0465184d..a2abae33ae 100644
--- a/apps/gui/yesno.c
+++ b/apps/gui/yesno.c
@@ -169,10 +169,9 @@ enum yesno_res gui_syncyesno_run(const struct text_message * main_message,
169 screens[i].stop_scroll(); 169 screens[i].stop_scroll();
170 gui_yesno_draw(&(yn[i])); 170 gui_yesno_draw(&(yn[i]));
171 } 171 }
172
173 /* make sure to eat any extranous keypresses */ 172 /* make sure to eat any extranous keypresses */
174 action_wait_for_release(); 173 while (get_action(CONTEXT_STD+99, TIMEOUT_NOBLOCK))
175 174 action_wait_for_release();
176 while (result==-1) 175 while (result==-1)
177 { 176 {
178 /* Repeat the question every 5secs (more or less) */ 177 /* Repeat the question every 5secs (more or less) */
@@ -206,7 +205,6 @@ enum yesno_res gui_syncyesno_run(const struct text_message * main_message,
206 result=YESNO_YES; 205 result=YESNO_YES;
207 break; 206 break;
208 case ACTION_NONE: 207 case ACTION_NONE:
209 case ACTION_UNKNOWN:
210 case SYS_CHARGER_DISCONNECTED: 208 case SYS_CHARGER_DISCONNECTED:
211 case SYS_BATTERY_UPDATE: 209 case SYS_BATTERY_UPDATE:
212 /* ignore some SYS events that can happen */ 210 /* ignore some SYS events that can happen */
@@ -235,7 +233,6 @@ enum yesno_res gui_syncyesno_run(const struct text_message * main_message,
235 screens[i].scroll_stop(yn[i].vp); 233 screens[i].scroll_stop(yn[i].vp);
236 viewportmanager_theme_undo(i, true); 234 viewportmanager_theme_undo(i, true);
237 } 235 }
238
239 return(result); 236 return(result);
240} 237}
241 238