2 * Copyright 2012 Samsung Electronics Co., Ltd
4 * Licensed under the Flora License, Version 1.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.tizenopensource.org/license
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.
18 * timer_lib.h is a head file of timer application.
19 * It declares interfaces which are used by Clock application.
21 * Timer has two means to run. One means is that it is a standalone application. It
22 * calls timer_view_add to create and show its view. The other means is that it is
23 * a library called by Clock application. The interface timer_view_add is also called
24 * to create and show view.
26 * Interfaces, like timer_view_add, timer_view_unload, timer_view_reload,
27 * timer_view_free, are called Clock application. Clock application calls timer_view_add
28 * to create and show view. It also calls timer_view_unload to change variable isTimerView,
29 * which indicates whether current view in Clock is timer. The timer_view_reload to reload
30 * view for timer. The timer_view_free is used to delete objects and free memory.
40 #ifndef __DEF_TIMER_LIB_H__
41 #define __DEF_TIMER_LIB_H__
43 #include <Elementary.h>
45 //******************typedef *************************************
46 typedef int (*timer_controlbar_visible) (Eina_Bool);
49 * @name timer_view_add
50 * @decription To create and show view for timer.
51 * @param parent, [in], a layout in which to create and show view.
52 * @param cb, [in], a variable to indicate whether controlbar should by shown.
53 * @return Evas_object*, a pointer to the created view. If failed to create view, it is NULL.
63 EAPI Evas_Object *timer_view_add(Evas_Object *parent, Evas_Object *win,
64 timer_controlbar_visible cb);
67 * @name timer_view_free
68 * @decription To delete objects and free memory used by timer.
69 * @param obj, [in], the view that will be distroyed.
80 EAPI void timer_view_free(Evas_Object *obj);
83 * @name timer_view_reload
84 * @decription To re-create view according to whether there is an actived alarm in server.
95 EAPI void timer_view_reload(void);
98 * @name timer_view_unload
99 * @decription To set that current view in Clock is not timer.
104 * @author Zhou Jinhua
110 EAPI void timer_view_unload(void);
112 #endif /* __DEF_TIMER_LIB_H__ */