3 * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
5 * Licensed under the Apache License, Version 2.0 (the "License");
6 * you may not use this file except in compliance with the License.
7 * You may obtain a copy of the License at
9 * http://www.apache.org/licenses/LICENSE-2.0
11 * Unless required by applicable law or agreed to in writing, software
12 * distributed under the License is distributed on an "AS IS" BASIS,
13 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 * See the License for the specific language governing permissions and
15 * limitations under the License.
21 Evas_Object* dpm_encryption_create_layout(Evas_Object* parent, const char* file, const char* group)
23 Evas_Object* layout = NULL;
26 dlog_print(DLOG_ERROR, LOG_TAG, "parent is null");
30 layout = elm_layout_add(parent);
32 dlog_print(DLOG_ERROR, LOG_TAG, "Cannot add layout");
36 if ((file != NULL) && (group != NULL))
37 elm_layout_file_set(layout, file, group);
39 elm_layout_theme_set(layout, "layout", "application", "default");
41 evas_object_size_hint_weight_set(layout, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
42 evas_object_show(layout);
47 Evas_Object* dpm_encryption_create_navigation(Evas_Object* parent)
49 Evas_Object* navi_bar = NULL;
52 dlog_print(DLOG_ERROR, LOG_TAG, "parent is null");
56 navi_bar = elm_naviframe_add(parent);
57 eext_object_event_callback_add(navi_bar, EEXT_CALLBACK_BACK, eext_naviframe_back_cb, NULL);
58 elm_object_part_content_set(parent, "elm.swallow.content", navi_bar);
59 evas_object_show(navi_bar);
64 Evas_Object* dpm_encryption_create_button(Evas_Object* parent, const char* text, const char* style)
66 Evas_Object* btn = elm_button_add(parent);
68 evas_object_size_hint_weight_set(btn, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
69 elm_object_text_set(btn, text);
72 elm_object_style_set(btn, style);
74 evas_object_show(btn);
79 Evas_Object* dpm_encryption_create_textblock(Evas_Object* parent, const char* text, Evas_Textblock_Style* style)
81 Evas_Object* txt = evas_object_textblock_add(parent);
84 evas_object_textblock_style_set(txt, style);
85 evas_object_textblock_text_markup_set(txt, text);
86 evas_object_show(txt);