2 // Open Service Platform
3 // Copyright (c) 2012 Samsung Electronics Co., Ltd.
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
9 // http://www.apache.org/licenses/LICENSE-2.0
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.
19 * @file FWebCtrl_WebPopup.h
20 * @brief The file contains the declaration of _WebPopup class.
22 * The file contains the declaration of _WebPopup class.
24 #ifndef _FWEB_CTRL_INTERNAL_WEB_POPUP_H_
25 #define _FWEB_CTRL_INTERNAL_WEB_POPUP_H_
27 #include <unique_ptr.h>
28 #include <FUiCtrlPopup.h>
31 namespace Tizen { namespace Base { namespace Collection
34 }}} // Tizen::Base::Collection
36 namespace Tizen { namespace Graphics
41 namespace Tizen { namespace Ui
43 class IActionEventListener;
46 namespace Tizen { namespace Ui { namespace Controls
51 }}} // Tizen::Ui::Controls
53 namespace Tizen { namespace Web { namespace Controls
56 enum _WebPopupButtonId
58 ID_BUTTON_COMMON_CLOSE
63 Tizen::Graphics::Dimension btnDim;
64 Tizen::Graphics::Dimension editDim;
65 Tizen::Graphics::Dimension popupDim;
66 Tizen::Graphics::Dimension dateDim;
67 Tizen::Graphics::Dimension colorDim;
68 Tizen::Graphics::Dimension checkDim;
69 Tizen::Graphics::Dimension labelDim;
77 : public Tizen::Ui::Controls::Popup
78 , virtual public Tizen::Ui::IActionEventListener
89 virtual ~_WebPopup(void);
91 result Construct(bool hasTitle, const Tizen::Graphics::Dimension& popupDim);
93 virtual void OnActionPerformed(const Tizen::Ui::Control& source, int actionId);
96 * This function launches non modal (asynchronous) popup
98 result ShowPopup(void);
100 result HidePopup(int modalResult = 0);
103 * This function launches modal (synchronous) popup
105 result ShowAndWait(int& modalResult);
107 Tizen::Ui::Controls::Panel* CreateAndAddPanel(void);
109 result CreateAndAddButtons(const Tizen::Base::Collection::IList& buttonIds,
110 const Tizen::Base::Collection::IList& buttonTitles,
111 Tizen::Ui::Controls::Panel* pPanel);
113 bool IsModalPopup(void);
116 static _WebPopupData* GetPopupData(bool refresh = false);
119 _WebPopup(const _WebPopup& source);
121 _WebPopup& operator =(const _WebPopup& source);
124 static std::unique_ptr<_WebPopupData> __pWebPopupData;
130 }}} //Tizen::Web::Controls
131 #endif // _FWEB_CTRL_INTERNAL_WEB_POPUP_H_