Tizen 2.1 base
[sdk/ide/native-sample.git] / samples / native / partner / cpp / Sample / Tizen C++ / MultipointTouch / MultipointTouch / project / inc / MainForm.h
1 //
2 // Open Service Platform
3 // Copyright (c) 2012 Samsung Electronics Co., Ltd.
4 //
5 // Licensed under the Flora License, Version 1.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
8 //
9 //     http://www.tizenopensource.org/license
10 //
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.
16 //
17 #ifndef MAINFORM_H_\r
18 #define MAINFORM_H_\r
19 \r
20 #include <FBase.h>\r
21 #include <FUi.h>\r
22 #include <FGraphics.h>\r
23 #include <FApp.h>\r
24 class MainForm :\r
25         public Osp::Ui::Controls::Form,\r
26         public Osp::Ui::IActionEventListener,\r
27         public Osp::Ui::ITouchEventListener\r
28 {\r
29 public:\r
30         MainForm();\r
31         virtual ~MainForm();\r
32 \r
33         bool Initialize();\r
34         void DrawCircle(const Osp::Ui::Control &source);\r
35 \r
36 protected:\r
37         static const int ID_HEADER_RIGHTBUTTON = 101 ;\r
38         static const int IDC_BTN_CLEAR = 501;\r
39         Osp::Graphics::Canvas*  __pCanvas;\r
40 \r
41 public:\r
42         virtual result OnInitializing(void);\r
43         virtual result OnTerminating(void);\r
44         virtual result OnDraw();\r
45         virtual void  OnActionPerformed (const Osp::Ui::Control &source, int actionId);\r
46         virtual void  OnTouchDoublePressed (const Osp::Ui::Control &source,     const Osp::Graphics::Point &currentPosition, const Osp::Ui::TouchEventInfo &touchInfo);\r
47         virtual void  OnTouchFocusIn (const Osp::Ui::Control &source, const Osp::Graphics::Point &currentPosition, const Osp::Ui::TouchEventInfo &touchInfo);\r
48         virtual void  OnTouchFocusOut (const Osp::Ui::Control &source, const Osp::Graphics::Point &currentPosition, const Osp::Ui::TouchEventInfo &touchInfo);\r
49         virtual void  OnTouchLongPressed (const Osp::Ui::Control &source, const Osp::Graphics::Point &currentPosition, const Osp::Ui::TouchEventInfo &touchInfo);\r
50         virtual void  OnTouchMoved (const Osp::Ui::Control &source, const Osp::Graphics::Point &currentPosition, const Osp::Ui::TouchEventInfo &touchInfo);\r
51         virtual void  OnTouchPressed (const Osp::Ui::Control &source, const Osp::Graphics::Point &currentPosition, const Osp::Ui::TouchEventInfo &touchInfo);\r
52         virtual void  OnTouchReleased (const Osp::Ui::Control &source, const Osp::Graphics::Point &currentPosition, const Osp::Ui::TouchEventInfo &touchInfo);\r
53 };\r
54 \r
55 #endif\r