Init Tizen 2.2.1
[framework/osp/web.git] / inc / FWebCtrlIWebKeypadEventListener.h
1 //
2 // Open Service Platform
3 // Copyright (c) 2012 Samsung Electronics Co., Ltd.
4 //
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
8 //
9 //     http://www.apache.org/licenses/LICENSE-2.0
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
18 /**
19  * @file                FWebCtrlIWebKeypadEventListener.h
20  * @brief               This is the header file for the %IWebKeypadEventListener interface.
21  *
22  * This header file contains the declarations of the %IWebKeypadEventListener interface.
23  */
24 #ifndef _FWEB_CTRL_IWEB_KEYPAD_EVENT_LISTENER_H_
25 #define _FWEB_CTRL_IWEB_KEYPAD_EVENT_LISTENER_H_
26
27 #include <FBaseRtIEventListener.h>
28
29 namespace Tizen { namespace Web { namespace Controls
30 {
31 class Web;
32 }}} // Tizen::Web::Controls
33
34 namespace Tizen { namespace Web { namespace Controls
35 {
36
37 /**
38  * @interface   IWebKeypadEventListener
39  * @brief               This interface provides a listener for keypad events invoked by the <textarea> or <input> tag, which has "text" or "password" value as its attribute.
40  *
41  * @since               2.0
42  *
43  * The %IWebKeypadEventListener interface provides a listener for keypad events invoked by the <textarea> or <input> tag, which has "text" or "password" value as its attribute.
44  * It also enables the implementer class to receive the overlay keypad related events.
45  */
46 class _OSP_EXPORT_ IWebKeypadEventListener
47         : public virtual Tizen::Base::Runtime::IEventListener
48 {
49 public:
50         /**
51          * This polymorphic destructor should be overridden if required. @n
52          * This way, the destructors of the derived classes are called when the destructor of this interface is called.
53          *
54          * @since               2.0
55          */
56         virtual ~IWebKeypadEventListener(void) {}
57
58         /**
59          * Called when the keypad is about to be shown on the screen.
60          *
61          * @since               2.0
62          *
63          * @param[in]   source                  The source of the event
64          */
65         virtual void OnWebKeypadWillOpen(Tizen::Web::Controls::Web& source) = 0;
66
67         /**
68          * Called when the keypad is shown on the screen.
69          *
70          * @since               2.0
71          *
72          * @param[in]   source                  The source of the event
73          * @remarks             When the overlay keypad appears on the screen, the current Form's
74          *                          area is adjusted to account for the space that is taken up by the overlay keypad.
75          * @see Tizen::Ui::Controls::Form::GetClientAreaBounds()
76          */
77         virtual void OnWebKeypadOpened(Tizen::Web::Controls::Web& source) = 0;
78
79         /**
80          * Called when the keypad is hidden from the screen.
81          *
82          * @since               2.0
83          *
84          * @param[in]   source                  The source of the event
85          * @see Tizen::Ui::Controls::Form::GetClientAreaBounds()
86          */
87         virtual void OnWebKeypadClosed(Tizen::Web::Controls::Web& source) = 0;
88
89         /**
90          * Called when the keypad bounds are changed, for instance when the predictive text window which is located in the upper part of the keypad is shown.
91          *
92          * @since               2.0
93          *
94          * @param[in]   source                  The source of the event
95          * @see Tizen::Ui::Controls::Form::GetClientAreaBounds()
96          */
97         virtual void OnWebKeypadBoundsChanged(Tizen::Web::Controls::Web& source) {};
98
99 protected:
100         //
101         // This method is for internal use only. Using this method can cause behavioral, security-related, and consistency-related issues in the application.
102         //
103         // Gets the Impl instance.
104         //
105         // @since               2.0
106         //
107         virtual void IWebKeypadEventListener_Reserved1(void) {}
108
109         //
110         // This method is for internal use only. Using this method can cause behavioral, security-related, and consistency-related issues in the application.
111         //
112         // Gets the Impl instance.
113         //
114         // @since               2.0
115         //
116         virtual void IWebKeypadEventListener_Reserved2(void) {}
117
118         //
119         // This method is for internal use only.
120         // Using this method can cause behavioral, security-related, and consistency-related issues in the application.
121         //
122         // @since               2.0
123         //
124         virtual void IWebKeypadEventListener_Reserved3(void) {}
125
126         //
127         // This method is for internal use only. Using this method can cause behavioral, security-related, and consistency-related issues in the application.
128         //
129         // Gets the Impl instance.
130         //
131         // @since               2.0
132         //
133         virtual void IWebKeypadEventListener_Reserved4(void) {}
134
135         //
136         // This method is for internal use only. Using this method can cause behavioral, security-related, and consistency-related issues in the application.
137         //
138         // Gets the Impl instance.
139         //
140         // @since               2.0
141         //
142         virtual void IWebKeypadEventListener_Reserved5(void) {}
143 }; // IWebKeypadEventListener
144
145 }}} // Tizen::Web::Controls
146 #endif // _FWEB_CTRL_IWEB_KEYPAD_EVENT_LISTENER_H_