aboutsummaryrefslogtreecommitdiff
path: root/backends/platform/wince/CEActionsPocket.cpp
diff options
context:
space:
mode:
authorMax Horn2009-09-30 16:16:53 +0000
committerMax Horn2009-09-30 16:16:53 +0000
commit8ba75fc522f16844524dd4d6f88c3851e2402969 (patch)
treedf25c20389e3e706d508f37914dedc73c6479f00 /backends/platform/wince/CEActionsPocket.cpp
parent25dde91c7c6c7da52636e3daa34bd9eee5d9dcb9 (diff)
downloadscummvm-rg350-8ba75fc522f16844524dd4d6f88c3851e2402969.tar.gz
scummvm-rg350-8ba75fc522f16844524dd4d6f88c3851e2402969.tar.bz2
scummvm-rg350-8ba75fc522f16844524dd4d6f88c3851e2402969.zip
Fix code formatting (esp. 'if(' -> 'if (' etc., but also indention and other things)
svn-id: r44495
Diffstat (limited to 'backends/platform/wince/CEActionsPocket.cpp')
-rw-r--r--backends/platform/wince/CEActionsPocket.cpp146
1 files changed, 73 insertions, 73 deletions
diff --git a/backends/platform/wince/CEActionsPocket.cpp b/backends/platform/wince/CEActionsPocket.cpp
index 45dbad12cc..ebe6981290 100644
--- a/backends/platform/wince/CEActionsPocket.cpp
+++ b/backends/platform/wince/CEActionsPocket.cpp
@@ -232,7 +232,7 @@ bool CEActionsPocket::perform(GUI::ActionType action, bool pushed) {
static bool keydialogrunning = false, quitdialog = false;
if (!pushed) {
- switch(action) {
+ switch (action) {
case POCKET_ACTION_RIGHTCLICK:
_CESystem->add_right_click(false);
return true;
@@ -251,78 +251,78 @@ bool CEActionsPocket::perform(GUI::ActionType action, bool pushed) {
}
switch (action) {
- case POCKET_ACTION_PAUSE:
- case POCKET_ACTION_SAVE:
- case POCKET_ACTION_SKIP:
- case POCKET_ACTION_MULTI:
- if (action == POCKET_ACTION_SAVE && ConfMan.get("gameid") == "parallaction") {
- // FIXME: This is a temporary solution. The engine should handle its own menus.
- // Note that the user can accomplish this via the virtual keyboard as well, this is just for convenience
- GUI::MessageDialog alert("Do you want to load or save the game?", "Load", "Save");
- if (alert.runModal() == GUI::kMessageOK)
- _key_action[action].setKey(SDLK_l);
- else
- _key_action[action].setKey(SDLK_s);
- }
- EventsBuffer::simulateKey(&_key_action[action], true);
- return true;
- case POCKET_ACTION_KEYBOARD:
- _CESystem->swap_panel();
- return true;
- case POCKET_ACTION_HIDE:
- _CESystem->swap_panel_visibility();
- return true;
- case POCKET_ACTION_SOUND:
- _CESystem->swap_sound_master();
- return true;
- case POCKET_ACTION_RIGHTCLICK:
- _CESystem->add_right_click(true);
- return true;
- case POCKET_ACTION_CURSOR:
- _CESystem->swap_mouse_visibility();
- return true;
- case POCKET_ACTION_FREELOOK:
- _CESystem->swap_freeLook();
- return true;
- case POCKET_ACTION_ZOOM_UP:
- _CESystem->swap_zoom_up();
- return true;
- case POCKET_ACTION_ZOOM_DOWN:
- _CESystem->swap_zoom_down();
- return true;
- case POCKET_ACTION_LEFTCLICK:
- _CESystem->add_left_click(true);
- return true;
- case POCKET_ACTION_UP:
- _CESystem->move_cursor_up();
- return true;
- case POCKET_ACTION_DOWN:
- _CESystem->move_cursor_down();
- return true;
- case POCKET_ACTION_LEFT:
- _CESystem->move_cursor_left();
- return true;
- case POCKET_ACTION_RIGHT:
- _CESystem->move_cursor_right();
- return true;
- case POCKET_ACTION_QUIT:
- if (!quitdialog) {
- quitdialog = true;
- GUI::MessageDialog alert(" Are you sure you want to quit ? ", "Yes", "No");
- if (alert.runModal() == GUI::kMessageOK)
- _mainSystem->quit();
- quitdialog = false;
- }
- return true;
- case POCKET_ACTION_BINDKEYS:
- if (!keydialogrunning) {
- keydialogrunning = true;
- GUI::KeysDialog *keysDialog = new GUI::KeysDialog();
- keysDialog->runModal();
- delete keysDialog;
- keydialogrunning = false;
- }
- return true;
+ case POCKET_ACTION_PAUSE:
+ case POCKET_ACTION_SAVE:
+ case POCKET_ACTION_SKIP:
+ case POCKET_ACTION_MULTI:
+ if (action == POCKET_ACTION_SAVE && ConfMan.get("gameid") == "parallaction") {
+ // FIXME: This is a temporary solution. The engine should handle its own menus.
+ // Note that the user can accomplish this via the virtual keyboard as well, this is just for convenience
+ GUI::MessageDialog alert("Do you want to load or save the game?", "Load", "Save");
+ if (alert.runModal() == GUI::kMessageOK)
+ _key_action[action].setKey(SDLK_l);
+ else
+ _key_action[action].setKey(SDLK_s);
+ }
+ EventsBuffer::simulateKey(&_key_action[action], true);
+ return true;
+ case POCKET_ACTION_KEYBOARD:
+ _CESystem->swap_panel();
+ return true;
+ case POCKET_ACTION_HIDE:
+ _CESystem->swap_panel_visibility();
+ return true;
+ case POCKET_ACTION_SOUND:
+ _CESystem->swap_sound_master();
+ return true;
+ case POCKET_ACTION_RIGHTCLICK:
+ _CESystem->add_right_click(true);
+ return true;
+ case POCKET_ACTION_CURSOR:
+ _CESystem->swap_mouse_visibility();
+ return true;
+ case POCKET_ACTION_FREELOOK:
+ _CESystem->swap_freeLook();
+ return true;
+ case POCKET_ACTION_ZOOM_UP:
+ _CESystem->swap_zoom_up();
+ return true;
+ case POCKET_ACTION_ZOOM_DOWN:
+ _CESystem->swap_zoom_down();
+ return true;
+ case POCKET_ACTION_LEFTCLICK:
+ _CESystem->add_left_click(true);
+ return true;
+ case POCKET_ACTION_UP:
+ _CESystem->move_cursor_up();
+ return true;
+ case POCKET_ACTION_DOWN:
+ _CESystem->move_cursor_down();
+ return true;
+ case POCKET_ACTION_LEFT:
+ _CESystem->move_cursor_left();
+ return true;
+ case POCKET_ACTION_RIGHT:
+ _CESystem->move_cursor_right();
+ return true;
+ case POCKET_ACTION_QUIT:
+ if (!quitdialog) {
+ quitdialog = true;
+ GUI::MessageDialog alert(" Are you sure you want to quit ? ", "Yes", "No");
+ if (alert.runModal() == GUI::kMessageOK)
+ _mainSystem->quit();
+ quitdialog = false;
+ }
+ return true;
+ case POCKET_ACTION_BINDKEYS:
+ if (!keydialogrunning) {
+ keydialogrunning = true;
+ GUI::KeysDialog *keysDialog = new GUI::KeysDialog();
+ keysDialog->runModal();
+ delete keysDialog;
+ keydialogrunning = false;
+ }
+ return true;
}
return false;
}