Upload initial version
[platform/core/uifw/libscl-ui-nui.git] / scl / sclevents-nui.h
1 /*
2  * Copyright (c) 2012 - 2014 Samsung Electronics Co., Ltd All Rights Reserved
3  *
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
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
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.
15  *
16  */
17
18 #include "sclevents.h"
19 #include <Ecore_Evas.h>
20 #include <Ecore.h>
21 #include <map>
22
23
24 #ifndef __SCL_EVENTS_NUI_H__
25 #define __SCL_EVENTS_NUI_H__
26
27 namespace scl
28 {
29 class CSCLEventsImplNui : public CSCLEventsImpl
30 {
31 public :
32     CSCLEventsImplNui();
33     ~CSCLEventsImplNui();
34
35     void init();
36     void fini();
37
38     /* Implementation about interface functions */
39     void connect_window_events(const sclwindow wnd, const sclint evt);
40     void create_timer(const scl16 id, const scl32 interval, scl16 value, sclboolean addToMap);
41     void destroy_timer(const scl32 id);
42     void destroy_all_timer();
43
44     void generate_mouse_event(SCLMouseEvent type, scl16 x, scl16 y);
45
46 private:
47     std::map<int, Ecore_Timer*> idMap;
48
49     Ecore_Event_Handler *m_mouse_down_handler;
50     Ecore_Event_Handler *m_mouse_move_handler;
51     Ecore_Event_Handler *m_mouse_up_handler;
52     Ecore_Event_Handler *m_key_pressed_handler;
53 };
54 } /* End of scl namespace */
55 #endif