c05cb7c11e0bbc9fd8096b723ba87f0aad0a2197
[platform/framework/native/uifw.git] / src / ui / controls / FUiCtrl_FrameImpl.cpp
1 //
2 // Open Service Platform
3 // Copyright (c) 2012-2013 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 #include <new>
19 #include <FUiCtrlForm.h>
20 #include <FUiAnimFrameAnimator.h>
21 #include <FUiCtrlIFrameEventListener.h>
22 #include <FBaseSysLog.h>
23 #include <FApp_AppInfo.h>
24 #include "FUi_ControlManager.h"
25 #include "FUi_OrientationAgent.h"
26 #include "FUi_ImeOrientationAgent.h"
27 #include "FUi_CoordinateSystemUtils.h"
28 #include "FUiCtrlForm.h"
29 #include "FUiCtrl_FrameImpl.h"
30 #include "FUiCtrl_FormImpl.h"
31 #include "FUiCtrl_Frame.h"
32 #include "FUiCtrl_PublicFrameEvent.h"
33
34 using namespace Tizen::App;
35 using namespace Tizen::Base;
36 using namespace Tizen::Base::Collection;
37 using namespace Tizen::Base::Runtime;
38 using namespace Tizen::Graphics;
39 using namespace Tizen::Ui;
40 using namespace Tizen::Ui::Animations;
41
42 namespace Tizen { namespace Ui { namespace Controls {
43
44 const String _REQUEST_ORIENTATION_EVENT = L"RequestOrientationEvent";
45
46 const _FrameImpl*
47 _FrameImpl::GetInstance(const Frame& frame)
48 {
49         return static_cast<const _FrameImpl*> (frame._pControlImpl);
50 }
51
52 _FrameImpl*
53 _FrameImpl::GetInstance(Frame& frame)
54 {
55         return static_cast<_FrameImpl*> (frame._pControlImpl);
56 }
57
58 void
59 _FrameImpl::Dispose(void)
60 {
61         GetCore().RemoveFrameEventListener(*this);
62
63         if (__pFrameEvent)
64         {
65                 delete __pFrameEvent;
66                 __pFrameEvent = null;
67         }
68
69         if (__pOrientationAgent)
70         {
71                 delete __pOrientationAgent;
72                 __pOrientationAgent = null;
73         }
74
75         if (__pImeOrientationAgent)
76         {
77                 delete __pImeOrientationAgent;
78                 __pImeOrientationAgent = null;
79         }
80
81         delete __pFrameAnimator;
82         __pFrameAnimator = null;
83 }
84
85 _FrameImpl::_FrameImpl(Frame* pPublic, _Frame* pCore)
86         : _WindowImpl(pPublic, pCore)
87         , __pFrameEvent(null)
88         , __pFrameAnimator(null)
89         , __pOrientationAgent(null)
90         , __pImeOrientationAgent(null)
91 {
92         __pFrameEvent = _PublicFrameEvent::CreateInstanceN(*pPublic);
93         SysTryReturnVoidResult(NID_UI_CTRL, __pFrameEvent, GetLastResult(), "[%s] Propagating.", GetErrorMessage(GetLastResult()));
94
95         int appType = _AppInfo::GetAppType();
96         if (appType & _APP_TYPE_IME_APP)
97         {
98                 __pImeOrientationAgent = _ImeOrientationAgent::CreateInstanceN(*pPublic);
99                 SysTryCatch(NID_UI_CTRL, __pImeOrientationAgent != null, , GetLastResult(), "[%s] Propagating.", GetErrorMessage(GetLastResult()));
100         }
101         else
102         {
103                 __pOrientationAgent = _OrientationAgent::CreateInstanceN(*pPublic);
104                 SysTryCatch(NID_UI_CTRL, __pOrientationAgent != null, , GetLastResult(), "[%s] Propagating.", GetErrorMessage(GetLastResult()));
105         }
106
107         return;
108
109 CATCH:
110         Dispose();
111 }
112
113 _FrameImpl::~_FrameImpl(void)
114 {
115         // [ToDo] Wrong point to call OnFrameTerminating().
116         if (__pFrameEvent)
117         {
118                 IEventArg* pEventArg = _PublicFrameEvent::CreateFrameEventArgN(_FrameImpl::GetPublic(), FRAME_STATE_TERMINATING);
119                 if (pEventArg)
120                 {
121                         __pFrameEvent->Fire(*pEventArg);
122                 }
123         }
124
125         Dispose();
126         ClearLastResult();
127 }
128
129 const char*
130 _FrameImpl::GetPublicClassName(void) const
131 {
132         return "Tizen::Ui::Controls::Frame";
133 }
134
135 const Frame&
136 _FrameImpl::GetPublic(void) const
137 {
138         return static_cast<const Frame&>(_ControlImpl::GetPublic());
139 }
140
141 Frame&
142 _FrameImpl::GetPublic(void)
143 {
144         return static_cast<Frame&>(_ControlImpl::GetPublic());
145 }
146
147 const _Frame&
148 _FrameImpl::GetCore(void) const
149 {
150         return static_cast<const _Frame&>(_ControlImpl::GetCore());
151 }
152
153 _Frame&
154 _FrameImpl::GetCore(void)
155 {
156         return static_cast<_Frame&>(_ControlImpl::GetCore());
157 }
158
159 result
160 _FrameImpl::SetCurrentForm(const _FormImpl& formImpl)
161 {
162         result r = E_SUCCESS;
163
164         _FormImpl* pNewCurForm = const_cast<_FormImpl*>(&formImpl);
165
166         SysTryReturn(NID_UI_CTRL,
167                 pNewCurForm != null, E_INVALID_ARG,
168                 E_INVALID_ARG, "[E_INVALID_ARG] The Form is not initialized.");
169
170         SysTryReturn(NID_UI_CTRL,
171                 IsAncestorOf(pNewCurForm), E_INVALID_ARG,
172                 E_INVALID_ARG, "[E_INVALID_ARG] The Form is not the child of this Frame.");
173
174         FrameShowMode showMode = GetCore().GetShowMode();
175         if (showMode != FRAME_SHOW_MODE_FULL_SCREEN)
176         {
177                 if (showMode == FRAME_SHOW_MODE_MINIMIZED)
178                 {
179                         if (GetCore().GetShowMode(false) != FRAME_SHOW_MODE_FULL_SCREEN)
180                         {
181                                 SysTryReturn(NID_UI_CTRL, !(pNewCurForm->GetFormStyle() & FORM_STYLE_INDICATOR), E_INVALID_ARG, E_INVALID_ARG, "Only Frame whose show mode is @c FRAME_SHOW_MODE_FULL_SCREEN can set a Form which has the style of @c FORM_STYLE_INDICATOR as the current form.");
182                         }
183                 }
184                 else
185                 {
186                         SysTryReturn(NID_UI_CTRL, !(pNewCurForm->GetFormStyle() & FORM_STYLE_INDICATOR), E_INVALID_ARG, E_INVALID_ARG, "Only Frame whose show mode is @c FRAME_SHOW_MODE_FULL_SCREEN can set a Form which has the style of @c FORM_STYLE_INDICATOR as the current form.");
187                 }
188         }
189
190
191         r = MoveChildToTop(*pNewCurForm);
192         SysTryReturn(NID_UI_CTRL, r == E_SUCCESS, r, r, "[%s] Propagating.", GetErrorMessage(r));
193
194         // [ToDo] Change the method to return result. And the arg should be reference.
195         GetCore().SetCurrentForm(&pNewCurForm->GetCore());
196         r = GetLastResult();
197         SysAssert(r == E_SUCCESS); // [ToDo] Exception check.
198
199         pNewCurForm->UpdateOrientationStatus();
200
201         // [ToDo] Check last result
202         SysAssert(GetLastResult() == E_SUCCESS);
203         return E_SUCCESS;
204 }
205
206 result
207 _FrameImpl::SetCurrentForm(_FormImpl* pFormImpl)
208 {
209         result r = E_SUCCESS;
210
211         _FormImpl* pNewCurForm = pFormImpl;
212
213         SysTryReturn(NID_UI_CTRL,
214                 pNewCurForm != null, E_INVALID_ARG,
215                 E_INVALID_ARG, "[E_INVALID_ARG] The Form is not initialized.");
216
217         SysTryReturn(NID_UI_CTRL,
218                 IsAncestorOf(pNewCurForm), E_INVALID_ARG,
219                 E_INVALID_ARG, "[E_INVALID_ARG] The Form is not the child of this Frame.");
220
221         if (GetCore().GetShowMode() != FRAME_SHOW_MODE_FULL_SCREEN)
222         {
223                 SysTryReturn(NID_UI_CTRL, !(pNewCurForm->GetFormStyle() & FORM_STYLE_INDICATOR), E_INVALID_ARG, E_INVALID_ARG, "Only Frame whose show mode is @c FRAME_SHOW_MODE_FULL_SCREEN can set a Form which has the style of @c FORM_STYLE_INDICATOR as the current form.");
224         }
225
226
227         r = MoveChildToTop(*pNewCurForm);
228         SysTryReturn(NID_UI_CTRL, r == E_SUCCESS, r, r, "[%s] Propagating.", GetErrorMessage(r));
229
230         // [ToDo] Change the method to return result. And the arg should be reference.
231         GetCore().SetCurrentForm(&pNewCurForm->GetCore());
232         r = GetLastResult();
233         SysAssert(r == E_SUCCESS); // [ToDo] Exception check.
234
235         pNewCurForm->UpdateOrientationStatus();
236
237         // [ToDo] Check last result
238         SysAssert(GetLastResult() == E_SUCCESS);
239         return E_SUCCESS;
240 }
241
242 // [ToDo] This function should return _FormImpl*.
243 _FormImpl*
244 _FrameImpl::GetCurrentForm(void) const
245 {
246         _Control* pFormCore = GetCore().GetCurrentForm();
247         SysTryReturn(NID_UI_CTRL, pFormCore, null, GetLastResult(), "[%s] Propagating.", GetErrorMessage(GetLastResult()));
248
249         _FormImpl* pFormImpl = static_cast<_FormImpl*>(pFormCore->GetUserData());
250
251         return pFormImpl;
252 }
253
254 _FrameImpl*
255 _FrameImpl::CreateFrameImplN(Frame* pPublic)
256 {
257         ClearLastResult();
258         result r = E_SUCCESS;
259
260         _Frame* pCore = _Frame::CreateFrameN();
261         SysTryReturn(NID_UI_CTRL, pCore, null, GetLastResult(), "[%s] Propagating.", GetErrorMessage(GetLastResult()));
262
263         _FrameImpl* pImpl = new (std::nothrow) _FrameImpl(pPublic, pCore);
264         r = _ControlImpl::CheckConstruction(pCore, pImpl);
265         SysTryReturn(NID_UI_CTRL, r == E_SUCCESS, null, r, "[%s] Propagating.", GetErrorMessage(r));
266
267         pCore->SetSize(_ControlManager::GetInstance()->GetScreenSizeF());
268
269         pCore->AddFrameEventListener(*pImpl);
270
271         SetLastResult(E_SUCCESS);
272
273         return pImpl;
274 }
275
276 void
277 _FrameImpl::AddFrameEventListener(IFrameEventListener& listener)
278 {
279         result r = __pFrameEvent->AddListener(listener);
280         SysTryReturnVoidResult(NID_UI_CTRL, r == E_SUCCESS, r, "[%s] Propagating.", GetErrorMessage(r));
281 }
282
283 void
284 _FrameImpl::RemoveFrameEventListener(IFrameEventListener& listener)
285 {
286         result r = __pFrameEvent->RemoveListener(listener);
287         SysTryReturnVoidResult(NID_UI_CTRL, r == E_SUCCESS, r, "[%s] Propagating.", GetErrorMessage(r));
288 }
289
290 Animations::FrameAnimator*
291 _FrameImpl::GetFrameAnimator(void) const
292 {
293         if (__pFrameAnimator == null)
294         {
295                 FrameAnimator* pFrameAnimator = new (std::nothrow) FrameAnimator();
296                 SysTryReturn(NID_UI_CTRL,
297                         pFrameAnimator != null, null,
298                         E_OUT_OF_MEMORY, "[E_OUT_OF_MEMORY] Insufficient memory.");
299
300                 result r = pFrameAnimator->Construct(GetPublic());
301                 if (IsFailed(r))
302                 {
303                         SysLogException(NID_UI_CTRL, E_SYSTEM, "[E_SYSTEM] FrameAnimator::Construct failed");
304                         delete pFrameAnimator;
305                         return null;
306                 }
307
308                 const_cast<_FrameImpl*>(this)->__pFrameAnimator = pFrameAnimator;
309         }
310
311         SetLastResult(E_SUCCESS);
312
313         return __pFrameAnimator;
314 }
315
316 void
317 _FrameImpl::OnDraw(void)
318 {
319         if (__pOrientationAgent)
320         {
321                 __pOrientationAgent->FireOrientationEvent();
322         }
323
324         _WindowImpl::OnDraw();
325 }
326
327 void
328 _FrameImpl::OnChangeLayout(_ControlOrientation orientation)
329 {
330         // Change layout.
331         _ContainerImpl::OnChangeLayout(orientation);
332         SysTryReturnVoidResult(NID_UI_CTRL, GetLastResult() == E_SUCCESS, GetLastResult(), "[%s] Propagating.", GetErrorMessage(GetLastResult()));
333
334         bool resizable = IsResizable();
335         SetResizable(true);
336
337         _ControlManager* pCoreManager = _ControlManager::GetInstance();
338         SysAssert(pCoreManager);
339         const FloatDimension& screenSize = pCoreManager->GetScreenSizeF();
340
341         FrameShowMode frameShowMode = GetCore().GetShowMode();
342
343         if (frameShowMode == FRAME_SHOW_MODE_FULL_SCREEN)
344         {
345                 GetCore().SetRotation(true);
346
347                 if (orientation == _CONTROL_ORIENTATION_PORTRAIT)
348                 {
349                         SetSize(screenSize);
350                 }
351                 else
352                 {
353                         SetSize(FloatDimension(screenSize.height, screenSize.width));
354                 }
355
356                 GetCore().SetRotation(false);
357         }
358         else if ((frameShowMode == FRAME_SHOW_MODE_PARTIAL_SCREEN) || (frameShowMode == FRAME_SHOW_MODE_PARTIAL_SCREEN_FLOATING))
359         {
360                 bool movable = IsMovable();
361                 SetMovable(true);
362
363                 FloatPoint prevPoint = GetPositionF();
364                 FloatPoint curPoint(prevPoint.x, prevPoint.y);
365                 float ratio = screenSize.width / screenSize.height;
366                 if (orientation == _CONTROL_ORIENTATION_PORTRAIT)
367                 {
368                         if (prevPoint.x > 0.0f)
369                         {
370                                 curPoint.x = prevPoint.x * ratio;
371                         }
372
373                         if (prevPoint.y > 0.0f)
374                         {
375                                 curPoint.y = prevPoint.y / ratio;
376                         }
377                 }
378                 else
379                 {
380                         if (prevPoint.x > 0.0f)
381                         {
382                                 curPoint.x = prevPoint.x / ratio;
383                         }
384
385                         if (prevPoint.y > 0.0f)
386                         {
387                                 curPoint.y = prevPoint.y * ratio;
388                         }
389                 }
390
391                 SetPosition(curPoint);
392                 SetMovable(movable);
393         }
394
395         SetResizable(resizable);
396 }
397
398 void
399 _FrameImpl::OnChildDetaching(const _Control& child)
400 {
401         result r = E_SUCCESS;
402
403         _FormImpl* pFormImpl = static_cast<_FormImpl*>(child.GetUserData());
404
405         _FormImpl* pCurrentForm = GetCurrentForm();
406
407         if (pCurrentForm != null)
408         {
409                 if (pCurrentForm == pFormImpl)
410                 {
411                         // if the given control will be the current form, hide the current form
412                         int count = GetChildCount();
413                         if (count > 1)
414                         {
415                                 _ControlImpl* pControlImpl = GetChild(count - 2);
416                                 if (!pControlImpl)
417                                 {
418                                         return ;
419                                 }
420
421                                 Form* pPrevForm = static_cast<Form*>(&pControlImpl->GetPublic());
422
423                                 if (pPrevForm != null)
424                                 {
425                                         r = pPrevForm->SetShowState(true);
426                                         if (IsFailed(r))
427                                         {
428                                                 SysLogException(NID_UI_CTRL, r, "[%s] Propagating.", GetErrorMessage(r));
429                                                 return ;
430                                         }
431                                 }
432                         }
433                 }
434         }
435 }
436
437 void
438 _FrameImpl::OnChildDetached(const _Control& child)
439 {
440         _ControlImpl::OnChildDetached(child);
441
442         int childCount = GetCore().GetChildCount();
443         if (childCount == 0)
444         {
445                 UpdateOrientationStatus();
446         }
447         else if (childCount > 0)
448         {
449                 _Control* pControl = GetCore().GetChild(childCount - 1);
450                 _ControlImpl* pControlImpl = static_cast<_ControlImpl*>(pControl->GetUserData());
451                 _FormImpl* pCurrentFormImpl = dynamic_cast<_FormImpl*>(pControlImpl);
452                 SysTryReturnVoidResult(NID_UI_CTRL, pCurrentFormImpl, GetLastResult(), "[%s] Propagating.", GetErrorMessage(GetLastResult()));
453                 pCurrentFormImpl->UpdateOrientationStatus(true);
454         }
455 }
456
457 void
458 _FrameImpl::OnFrameActivated(const _Frame& source)
459 {
460         if (__pFrameEvent)
461         {
462                 IEventArg* pEventArg = _PublicFrameEvent::CreateFrameEventArgN(_FrameImpl::GetPublic(), FRAME_STATE_ACTIVATED);
463                 if (pEventArg)
464                 {
465                         __pFrameEvent->Fire(*pEventArg);
466                 }
467         }
468 }
469
470 void
471 _FrameImpl::OnFrameDeactivated(const _Frame& source)
472 {
473         if (__pFrameEvent)
474         {
475                 IEventArg* pEventArg = _PublicFrameEvent::CreateFrameEventArgN(_FrameImpl::GetPublic(), FRAME_STATE_DEACTIVATED);
476                 if (pEventArg)
477                 {
478                         __pFrameEvent->Fire(*pEventArg);
479                 }
480         }
481 }
482
483 void
484 _FrameImpl::OnFrameMinimized(const _Frame& source)
485 {
486         if (__pFrameEvent)
487         {
488                 IEventArg* pEventArg = _PublicFrameEvent::CreateFrameEventArgN(_FrameImpl::GetPublic(), FRAME_STATE_MINIMIZED);
489                 if (pEventArg)
490                 {
491                         __pFrameEvent->Fire(*pEventArg);
492                 }
493         }
494 }
495
496 void
497 _FrameImpl::OnFrameRestored(const _Frame& source)
498 {
499         if (__pFrameEvent)
500         {
501                 IEventArg* pEventArg = _PublicFrameEvent::CreateFrameEventArgN(_FrameImpl::GetPublic(), FRAME_STATE_RESTORED);
502                 if (pEventArg)
503                 {
504                         __pFrameEvent->Fire(*pEventArg);
505                 }
506         }
507 }
508
509 void
510 _FrameImpl::OnBoundsChanged(void)
511 {
512         int childcount = GetChildCount();
513         FloatRectangle bounds = GetBoundsF();
514
515         for (int i = 0 ; i < childcount ; i++)
516         {
517                 _ControlImpl* pChild = GetChild(i);
518                 _FormImpl* pForm = dynamic_cast<_FormImpl*>(pChild);
519                 if (pForm)
520                 {
521                         if (GetShowMode() == FRAME_SHOW_MODE_FULL_SCREEN)
522                         {
523                                 if (pForm->GetOrientationStatus() == ORIENTATION_STATUS_PORTRAIT || pForm->GetOrientationStatus() == ORIENTATION_STATUS_PORTRAIT_REVERSE)
524                                 {
525                                         pForm->SetBounds(FloatRectangle(0.0f, 0.0f, bounds.width, bounds.height));
526                                 }
527                                 else
528                                 {
529                                         pForm->SetBounds(FloatRectangle(0.0f, 0.0f, bounds.height, bounds.width));
530                                 }
531                         }
532                         else
533                         {
534                                 pForm->SetBounds(FloatRectangle(0.0f, 0.0f, bounds.width, bounds.height));
535                         }
536
537                 }
538         }
539
540         _ContainerImpl::OnBoundsChanged();
541
542 }
543
544 result
545 _FrameImpl::OnAttachedToMainTree(void)
546 {
547         result r = _WindowImpl::OnAttachedToMainTree();
548         SysTryReturn(NID_UI_CTRL, r == E_SUCCESS, r, r, "[%s] Propagating.", GetErrorMessage(r));
549
550         if (__pOrientationAgent)
551         {
552                 __pOrientationAgent->RequestOrientationEvent();
553         }
554
555         return r;
556 }
557
558 result
559 _FrameImpl::OnDetachingFromMainTree(void)
560 {
561         result r = _WindowImpl::OnDetachingFromMainTree();
562         SysTryReturn(NID_UI_CTRL, r == E_SUCCESS, r, r, "[%s] Propagating.", GetErrorMessage(r));
563
564         delete __pFrameAnimator;
565         __pFrameAnimator = null;
566
567         return r;
568 }
569
570 bool
571 _FrameImpl::OnNotifiedN(const _ControlImpl& source, IList* pArgs)
572 {
573         String* pString = dynamic_cast <Tizen::Base::String*>(pArgs->GetAt(0));
574         if (pString)
575         {
576                 if (*pString == _REQUEST_ORIENTATION_EVENT)
577                 {
578                         if (__pOrientationAgent)
579                         {
580                                 __pOrientationAgent->FireOrientationEvent();
581                         }
582
583                         pArgs->RemoveAll(true);
584                         delete pArgs;
585
586                         return true;
587                 }
588         }
589
590         return false;
591 }
592
593 void
594 _FrameImpl::AddOrientationEventListener(Tizen::Ui::IOrientationEventListener& listener)
595 {
596         if (__pOrientationAgent)
597         {
598                 __pOrientationAgent->AddListener(listener);
599         }
600         else if (__pImeOrientationAgent)
601         {
602                 __pImeOrientationAgent->AddListener(listener);
603         }
604 }
605
606 void
607 _FrameImpl::RemoveOrientationEventListener(Tizen::Ui::IOrientationEventListener& listener)
608 {
609         if (__pOrientationAgent)
610         {
611                 __pOrientationAgent->RemoveListener(listener);
612         }
613         else if (__pImeOrientationAgent)
614         {
615                 __pImeOrientationAgent->RemoveListener(listener);
616         }
617 }
618
619 void
620 _FrameImpl::SetOrientation(Orientation orientation)
621 {
622         if (__pOrientationAgent)
623         {
624                 __pOrientationAgent->SetMode(orientation);
625         }
626 }
627
628 Orientation
629 _FrameImpl::GetOrientation(void) const
630 {
631         if (__pOrientationAgent)
632         {
633                 return __pOrientationAgent->GetMode();
634         }
635
636         return ORIENTATION_NONE;
637 }
638
639 OrientationStatus
640 _FrameImpl::GetOrientationStatus(void) const
641 {
642         if (__pOrientationAgent)
643         {
644                 return __pOrientationAgent->GetStatus();
645         }
646         else if (__pImeOrientationAgent)
647         {
648                 return __pImeOrientationAgent->GetStatus();
649         }
650
651         return ORIENTATION_STATUS_NONE;
652 }
653
654 bool
655 _FrameImpl::IsChildAttachable(_ControlImpl& child) const
656 {
657         return (dynamic_cast<_FormImpl*>(&child) != null);
658 }
659
660 void
661 _FrameImpl::UpdateOrientationStatus(void)
662 {
663         if (__pOrientationAgent)
664         {
665                 __pOrientationAgent->Update();
666         }
667 }
668
669 void
670 _FrameImpl::UpdateOrientation(void)
671 {
672         if (__pOrientationAgent)
673         {
674                 __pOrientationAgent->UpdateOrientation();
675         }
676 }
677
678 void
679 _FrameImpl::UpdateOrientation(int angle)
680 {
681         SysLog(NID_UI_CTRL, "[Ime Rotation]");
682
683         if (__pImeOrientationAgent)
684         {
685                 __pImeOrientationAgent->UpdateOrientation(angle);
686         }
687 }
688
689 bool
690 _FrameImpl::IsOpaque(void) const
691 {
692         //return true;
693         return false;
694 }
695
696 void
697 _FrameImpl::SetFloatingBounds(const FloatRectangle& rect)
698 {
699         GetCore().SetFloatingBounds(rect);
700 }
701
702 void
703 _FrameImpl::SetFloatingBounds(const Rectangle& rect)
704 {
705         GetCore().SetFloatingBounds(rect);
706 }
707
708 result
709 _FrameImpl::SetShowMode(FrameShowMode showMode)
710 {
711         return GetCore().SetShowMode(showMode);
712 }
713
714 FrameShowMode
715 _FrameImpl::GetShowMode(void) const
716 {
717         return GetCore().GetShowMode();
718 }
719
720 }}} // Tizen::Ui::Controls