2 * Copyright (c) 2012 - 2014 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.
20 #include "sclcontext.h"
21 #include "scleventcallback.h"
23 #ifndef __SCL_EVENT_HANDLER_H__
24 #define __SCL_EVENT_HANDLER_H__
31 * @brief The default event handler class
34 class CSCLEventHandler : public ISCLUIEventCallback
39 virtual ~CSCLEventHandler();
41 static CSCLEventHandler* get_instance();
43 sclboolean set_input_mode(const sclchar *input_mode);
44 void set_event_callback(ISCLUIEventCallback *callback, const sclchar *input_mode);
46 SCLEventReturnType on_event_key_clicked(SclUIEventDesc ui_event_desc);
47 SCLEventReturnType on_event_drag_state_changed(SclUIEventDesc ui_event_desc);
48 SCLEventReturnType on_event_notification(SCLUINotiType noti_type, SclNotiDesc *etc_info);
50 void pre_process_ui_event(SclUIEventDesc &ui_event_desc);
53 ISCLUIEventCallback* m_default_event_callback;
54 ISCLUIEventCallback* m_cur_input_mode_event_callback;
56 std::map<std::string, ISCLUIEventCallback*> m_input_mode_event_callbacks;
63 #endif //__SCL_EVENT_HANDLER_H__