2 * Copyright (c) 2014 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://floralicense.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.
20 * Created on: Oct 9, 2013
24 #ifndef SETTING_DISPLAY_H_
25 #define SETTING_DISPLAY_H_
27 #include <Elementary.h>
32 #define FONT_SIZE_COUNT 3
33 #define SCREEN_TIME_COUNT 5
34 #define ROTATE_SCREEN_COUNT 4
35 #define AMBIENT_MODE_ENABLE 1
36 #define SETTING_FONT_PRELOAD_FONT_PATH "/usr/share/fonts"
37 #define SETTING_FONT_DOWNLOADED_FONT_PATH "/opt/share/fonts"
39 struct _display_menu_item {
42 void (*func)(void *data, Evas_Object *obj, void *event_info);
43 int is_enable_ambient_mode;
46 struct _font_menu_item {
48 void (*func)(void *data, Evas_Object *obj, void *event_info);
51 typedef struct _Display_Item_Data {
53 Elm_Object_Item *item;
57 typedef struct _Font_Style_Item_Data {
60 Elm_Object_Item *item;
61 } Font_Style_Item_Data;
64 SETTING_DISPLAY_BRIGTHNESS,
65 SETTING_DISPLAY_SCREEN_TIME,
68 SETTING_DISPLAY_GESTURE,
69 SETTING_DISPLAY_ICON_SIZE,
70 SETTING_DISPLAY_EDIT_HOME,
71 SETTING_DISPLAY_EDIT_APPS,
72 SETTING_DISPLAY_AMBIENT_MODE
76 SETTING_DISPLAY_FONT_STYLE,
77 SETTING_DISPLAY_FONT_SIZE
81 char *_gl_display_title_get(void *data, Evas_Object *obj, const char *part);
82 Evas_Object *_gl_display_check_get(void *data, Evas_Object *obj, const char *part);
83 Evas_Object *_create_display_list(void *data);
84 void _display_gl_Battery_percent_cb(void *data, Evas_Object *obj, void *event_info);
85 void _display_gl_screen_timeout_cb(void *data, Evas_Object *obj, void *event_info);
86 void _show_screen_timeout_list(void *data);
87 void _display_gl_language_cb(void *data, Evas_Object *obj, void *event_info);
88 void _display_gl_font_cb(void *data, Evas_Object *obj, void *event_info);
89 void _display_gl_font_style_cb(void *data, Evas_Object *obj, void *event_info);
90 void _display_gl_font_size_cb(void *data, Evas_Object *obj, void *event_info);
91 void _show_font_list(void *data);
92 int _show_font_style_list(void *data);
93 void _show_font_size_list(void *data);
94 void _display_gl_rotate_screen_cb(void *data, Evas_Object *obj, void *event_info);
95 void _show_rotate_screen_list(void *data);
96 static void _display_brightness_cb(void *data, Evas_Object *obj, void *event_info);
97 Evas_Object *_show_brightness_popup(void *data, Evas_Object *obj, void *event_info);
98 void _back_brightness_naviframe_cb(void *data, Elm_Object_Item *it);
100 void _init_display();
101 void _init_screen_rotate();
102 Eina_Bool _clear_display_cb(void *data, Elm_Object_Item *it);
103 static void _set_rotate_screen(const int rotation);
104 static int _get_rotate_screen();
106 void _display_ambient_mode_cb(void *data, Evas_Object *obj, void *event_info);
108 #endif /* SETTING_DISPLAY_H_ */