2 * Copyright (c) 2014 - 2015 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.
18 #ifndef __SCL_CORE_UI_H__
19 #define __SCL_CORE_UI_H__
25 #include "sclcorecallback.h"
30 enum KEYBOARD_UI_STATE
32 KEYBOARD_UI_STATE_DID_HIDE,
33 KEYBOARD_UI_STATE_WILL_HIDE,
34 KEYBOARD_UI_STATE_DID_SHOW,
35 KEYBOARD_UI_STATE_WILL_SHOW,
38 enum KEYBOARD_OPTMIZATION_HINT
40 KEYBOARD_OPTIMIZATION_HINT_NONE = 0,
41 KEYBOARD_OPTIMIZATION_HINT_SHOW_PREPARE,
45 * @brief The base class that provides features for a soft-keyboard
47 * This class implements all functions for working as a soft-based keyboard
53 virtual ~CSCLCoreUI();
55 std::string get_backend_identifier();
57 virtual sclboolean init();
60 virtual sclboolean create_main_window();
62 virtual void run(const sclchar *display);
65 * @brief This API returns the pointer to main keyboard window
67 virtual sclwindow get_main_window();
70 * @brief This API sets the rotation angle of the current screen
72 virtual void set_screen_rotation_degree(int degree);
75 * @brief This API returns the rotation angle of the current screen
77 virtual int get_screen_rotation_degree();
80 * @brief This API updates the keyboard window's geometry information
82 virtual void set_keyboard_size_hints(SclSize portrait, SclSize landscape);
85 * @brief Requests to create an option window
87 virtual sclwindow create_option_window(SCLOptionWindowType type);
90 * @brief Requests to show existing option window
92 virtual bool show_option_window(SCLOptionWindowType type);
95 * @brief Requests to destroy an option window
97 virtual void destroy_option_window(sclwindow window);
100 * @brief This API requests each SCLCoreUI backends to process keyboard UI state change event
102 virtual void process_keyboard_ui_state_change(KEYBOARD_UI_STATE state);
105 * @brief Requests to update the keyboard window's geometry
107 virtual void update_keyboard_geometry(SclSize portrait, SclSize landscape);
110 * @brief Requests to get the keyboard size
112 virtual void get_keyboard_size(SclSize *portrait, SclSize *landscape);
115 std::string m_backend_identifier;
125 #endif //__SCL_CORE_UI_H__