aboutsummaryrefslogtreecommitdiff
path: root/backends/platform/tizen/application.cpp
diff options
context:
space:
mode:
authorChris Warren-Smith2013-08-17 08:52:14 +1000
committerChris Warren-Smith2013-08-17 08:52:14 +1000
commit1f4feaffb0c6dc49e8a5f4d2ca1ef10650185ca2 (patch)
treeee2756f1ea091f17b0e72d907d8af22f89213847 /backends/platform/tizen/application.cpp
parente2856ed85b08b4ab96e5a05cef793052e3232838 (diff)
downloadscummvm-rg350-1f4feaffb0c6dc49e8a5f4d2ca1ef10650185ca2.tar.gz
scummvm-rg350-1f4feaffb0c6dc49e8a5f4d2ca1ef10650185ca2.tar.bz2
scummvm-rg350-1f4feaffb0c6dc49e8a5f4d2ca1ef10650185ca2.zip
TIZEN: updates for tizen 2.2 SDK
Diffstat (limited to 'backends/platform/tizen/application.cpp')
-rw-r--r--backends/platform/tizen/application.cpp22
1 files changed, 13 insertions, 9 deletions
diff --git a/backends/platform/tizen/application.cpp b/backends/platform/tizen/application.cpp
index 8236ebef67..a73efacf58 100644
--- a/backends/platform/tizen/application.cpp
+++ b/backends/platform/tizen/application.cpp
@@ -31,7 +31,7 @@ Application *TizenScummVM::createInstance() {
return new TizenScummVM();
}
-TizenScummVM::TizenScummVM() : _appForm(0) {
+TizenScummVM::TizenScummVM() : _appForm(NULL) {
logEntered();
}
@@ -41,7 +41,7 @@ TizenScummVM::~TizenScummVM() {
TizenSystem *system = (TizenSystem *)g_system;
system->destroyBackend();
delete system;
- g_system = 0;
+ g_system = NULL;
}
}
@@ -68,17 +68,19 @@ bool TizenScummVM::OnAppTerminating(AppRegistry &appRegistry, bool forcedTermina
}
void TizenScummVM::OnUserEventReceivedN(RequestId requestId, IList *args) {
+ logEntered();
MessageBox messageBox;
int modalResult;
+ String *message;
- logEntered();
-
- if (requestId == USER_MESSAGE_EXIT) {
+ switch (requestId) {
+ case USER_MESSAGE_EXIT:
// normal program termination
Terminate();
- } else if (requestId == USER_MESSAGE_EXIT_ERR) {
+ break;
+
+ case USER_MESSAGE_EXIT_ERR:
// assertion failure termination
- String *message = NULL;
if (args) {
message = (String *)args->GetAt(0);
}
@@ -88,12 +90,15 @@ void TizenScummVM::OnUserEventReceivedN(RequestId requestId, IList *args) {
messageBox.Construct(L"Oops...", *message, MSGBOX_STYLE_OK);
messageBox.ShowAndWait(modalResult);
Terminate();
- } else if (requestId == USER_MESSAGE_EXIT_ERR_CONFIG) {
+ break;
+
+ case USER_MESSAGE_EXIT_ERR_CONFIG:
// the config file was corrupted
messageBox.Construct(L"Config file corrupted",
L"Settings have been reverted, please restart.", MSGBOX_STYLE_OK);
messageBox.ShowAndWait(modalResult);
Terminate();
+ break;
}
}
@@ -132,7 +137,6 @@ void TizenScummVM::pauseGame(bool pause) {
if (pause && g_engine && !g_engine->isPaused()) {
_appForm->pushKey(Common::KEYCODE_SPACE);
}
-
if (g_system) {
((TizenSystem *)g_system)->setMute(pause);
}