if (ret != UI_VIEWMGR_ERROR_NONE)
{
dlog_print(DLOG_ERROR, LOG_TAG, "ui_app_init() is failed, ret = %d", ret);
- return 0;
+ return ret;
}
//Run ui_app. Now it requests to run an application mainloop.
if (ret != UI_VIEWMGR_ERROR_NONE)
{
dlog_print(DLOG_ERROR, LOG_TAG, "ui_app_run() is failed, ret = %d", ret);
- return 0;
+ return ret;
}
//Terminate ui_app. Remove all ui_app resources.
if (ret != UI_VIEWMGR_ERROR_NONE)
{
dlog_print(DLOG_ERROR, LOG_TAG, "ui_app_term() is failed ret = %d", ret);
- return 0;
+ return ret;
}
return 0;
int main(int argc, char *argv[])
{
+ int ret;
+
try {
SampleApp app;
- app.run(argc, argv);
+ ret = app.run(argc, argv);
} catch (UiException& ex)
{
dlog_print(DLOG_ERROR, LOG_TAG, ex.getMessage());
}
- return 0;
+ return ret;
}