2 * Copyright (c) 2009-2014 Samsung Electronics Co., Ltd All Rights Reserved
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
8 * http://www.apache.org/licenses/LICENSE-2.0
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
21 #include <Elementary.h>
26 #include "lockscreen.h"
28 #include "main_ctrl.h"
30 static Eina_Bool _lock_idler_cb(void *data)
32 lockscreen_main_ctrl_init();
34 return ECORE_CALLBACK_CANCEL;
37 bool _create_app(void *data)
39 DBG("Lockscreen launch request.");
40 elm_config_accel_preference_set("opengl");
41 DBG("base scale : %f", elm_app_base_scale_get());
42 DBG("edje scale : %f", edje_scale_get());
44 /* Quickfix: run real creation in idler since running device/display API here
46 ecore_idler_add(_lock_idler_cb, NULL);
51 void _terminate_app(void *data)
53 DBG("Lockscreen terminated request.");
56 int main(int argc, char *argv[])
60 ui_app_lifecycle_callback_s lifecycle_callback = {0,};
62 lifecycle_callback.create = _create_app;
63 lifecycle_callback.terminate = _terminate_app;
65 ret = ui_app_main(argc, argv, &lifecycle_callback, NULL);
66 if (ret != APP_ERROR_NONE) {
67 ERR("ui_app_main failed: %s", get_error_message(ret));