[NUI] Add Obsolete attributes for EditorBrowsable apis
[platform/core/csapi/tizenfx.git] / src / Tizen.NUI / src / public / UIComponents / Popup.cs
1 /*
2  * Copyright(c) 2017 Samsung Electronics Co., Ltd.
3  *
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
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
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.
15  *
16  */
17 using System;
18 using System.ComponentModel;
19 using System.Runtime.InteropServices;
20 using Tizen.NUI.BaseComponents;
21
22 namespace Tizen.NUI.UIComponents
23 {
24     /// <summary>
25     /// The Popup widget provides a configurable popup dialog with a built-in layout of three main fields.
26     /// </summary>
27     /// <since_tizen> 3 </since_tizen>
28     public class Popup : View
29     {
30         private global::System.Runtime.InteropServices.HandleRef swigCPtr;
31
32         internal Popup(global::System.IntPtr cPtr, bool cMemoryOwn) : base(NDalicPINVOKE.Popup_SWIGUpcast(cPtr), cMemoryOwn)
33         {
34             swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
35         }
36
37         internal static global::System.Runtime.InteropServices.HandleRef getCPtr(Popup obj)
38         {
39             return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
40         }
41
42         /// <summary>
43         /// Dispose.
44         /// </summary>
45         /// <param name="type">The dispose type</param>
46         /// <since_tizen> 3 </since_tizen>
47         protected override void Dispose(DisposeTypes type)
48         {
49             if (disposed)
50             {
51                 return;
52             }
53
54             if (type == DisposeTypes.Explicit)
55             {
56                 //Called by User
57                 //Release your own managed resources here.
58                 //You should release all of your own disposable objects here.
59
60             }
61
62             //Release your own unmanaged resources here.
63             //You should not access any managed member here except static instance.
64             //because the execution order of Finalizes is non-deterministic.
65
66             if (_popUpHiddenEventCallbackDelegate != null)
67             {
68                 HiddenSignal().Disconnect(_popUpHiddenEventCallbackDelegate);
69             }
70
71             if (_popUpHidingEventCallbackDelegate != null)
72             {
73                 HidingSignal().Disconnect(_popUpHidingEventCallbackDelegate);
74             }
75
76             if (_popUpShownEventCallbackDelegate != null)
77             {
78                 ShownSignal().Disconnect(_popUpShownEventCallbackDelegate);
79             }
80
81             if (_popUpShowingEventCallbackDelegate != null)
82             {
83                 ShowingSignal().Disconnect(_popUpShowingEventCallbackDelegate);
84             }
85
86             if (_popUpOutsideTouchedEventCallbackDelegate != null)
87             {
88                 this.OutsideTouchedSignal().Disconnect(_popUpOutsideTouchedEventCallbackDelegate);
89             }
90
91             if (swigCPtr.Handle != global::System.IntPtr.Zero)
92             {
93                 if (swigCMemOwn)
94                 {
95                     swigCMemOwn = false;
96                     NDalicPINVOKE.delete_Popup(swigCPtr);
97                 }
98                 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
99             }
100
101             base.Dispose(type);
102         }
103
104
105
106
107         /// <summary>
108         /// Event arguments that passed via the OutsideTouchedEvent.
109         /// </summary>
110         /// <since_tizen> 3 </since_tizen>
111         public class TouchedOutsideEventArgs : EventArgs
112         {
113         }
114
115         /// <summary>
116         /// Event arguments that passed via the ShowingEventArgs.
117         /// </summary>
118         /// <since_tizen> 3 </since_tizen>
119         public class ShowingEventArgs : EventArgs
120         {
121         }
122
123         /// <summary>
124         /// Event arguments that passed via the ShownEventArgs.
125         /// </summary>
126         /// <since_tizen> 3 </since_tizen>
127         public class ShownEventArgs : EventArgs
128         {
129         }
130
131         /// <summary>
132         /// Event arguments that passed via the HidingEventArgs.
133         /// </summary>
134         /// <since_tizen> 3 </since_tizen>
135         public class HidingEventArgs : EventArgs
136         {
137         }
138
139         /// <summary>
140         /// Event arguments that passed via the HiddenEventArgs.
141         /// </summary>
142         /// <since_tizen> 3 </since_tizen>
143         public class HiddenEventArgs : EventArgs
144         {
145         }
146
147         [UnmanagedFunctionPointer(CallingConvention.StdCall)]
148         private delegate void OutsideTouchedEventCallbackDelegate();
149         private EventHandler<TouchedOutsideEventArgs> _popUpOutsideTouchedEventHandler;
150         private OutsideTouchedEventCallbackDelegate _popUpOutsideTouchedEventCallbackDelegate;
151
152         [UnmanagedFunctionPointer(CallingConvention.StdCall)]
153         private delegate void ShowingEventCallbackDelegate();
154         private EventHandler<ShowingEventArgs> _popUpShowingEventHandler;
155         private ShowingEventCallbackDelegate _popUpShowingEventCallbackDelegate;
156
157         [UnmanagedFunctionPointer(CallingConvention.StdCall)]
158         private delegate void ShownEventCallbackDelegate();
159         private EventHandler<ShownEventArgs> _popUpShownEventHandler;
160         private ShownEventCallbackDelegate _popUpShownEventCallbackDelegate;
161
162         [UnmanagedFunctionPointer(CallingConvention.StdCall)]
163         private delegate void HidingEventCallbackDelegate();
164         private EventHandler<HidingEventArgs> _popUpHidingEventHandler;
165         private HidingEventCallbackDelegate _popUpHidingEventCallbackDelegate;
166
167         [UnmanagedFunctionPointer(CallingConvention.StdCall)]
168         private delegate void HiddenEventCallbackDelegate();
169         private EventHandler<HiddenEventArgs> _popUpHiddenEventHandler;
170         private HiddenEventCallbackDelegate _popUpHiddenEventCallbackDelegate;
171
172         /// <summary>
173         /// An event is sent when the user has touched outside the dialog.
174         /// </summary>
175         /// <since_tizen> 3 </since_tizen>
176         public event EventHandler<TouchedOutsideEventArgs> TouchedOutside
177         {
178             add
179             {
180                 if (_popUpOutsideTouchedEventHandler == null)
181                 {
182                     _popUpOutsideTouchedEventCallbackDelegate = (OnOutsideTouched);
183                     OutsideTouchedSignal().Connect(_popUpOutsideTouchedEventCallbackDelegate);
184                 }
185                 _popUpOutsideTouchedEventHandler += value;
186             }
187             remove
188             {
189                 _popUpOutsideTouchedEventHandler -= value;
190                 if (_popUpOutsideTouchedEventHandler == null && OutsideTouchedSignal().Empty() == false)
191                 {
192                     this.OutsideTouchedSignal().Disconnect(_popUpOutsideTouchedEventCallbackDelegate);
193                 }
194             }
195         }
196
197         // Callback for Popup OutsideTouchedSignal
198         private void OnOutsideTouched()
199         {
200             TouchedOutsideEventArgs e = new TouchedOutsideEventArgs();
201
202             if (_popUpOutsideTouchedEventHandler != null)
203             {
204                 //here we send all data to user event handlers
205                 _popUpOutsideTouchedEventHandler(this, e);
206             }
207         }
208
209         /// <summary>
210         /// An event is sent when the popup starts showing.
211         /// </summary>
212         /// <since_tizen> 3 </since_tizen>
213         public event EventHandler<ShowingEventArgs> Showing
214         {
215             add
216             {
217                 if (_popUpShowingEventHandler == null)
218                 {
219                     _popUpShowingEventCallbackDelegate = (OnShowing);
220                     ShowingSignal().Connect(_popUpShowingEventCallbackDelegate);
221                 }
222                 _popUpShowingEventHandler += value;
223             }
224             remove
225             {
226                 _popUpShowingEventHandler -= value;
227                 if (_popUpShowingEventHandler == null && ShowingSignal().Empty() == false)
228                 {
229                     ShowingSignal().Disconnect(_popUpShowingEventCallbackDelegate);
230                 }
231             }
232         }
233
234         // Callback for ShowingSignal
235         private void OnShowing()
236         {
237             ShowingEventArgs e = new ShowingEventArgs();
238
239             if (_popUpShowingEventHandler != null)
240             {
241                 //here we send all data to user event handlers
242                 _popUpShowingEventHandler(this, e);
243             }
244         }
245
246
247         /// <summary>
248         /// An event is sent when the popup has been fully displayed.
249         /// </summary>
250         /// <since_tizen> 3 </since_tizen>
251         public event EventHandler<ShownEventArgs> Shown
252         {
253             add
254             {
255                 if (_popUpShownEventHandler == null)
256                 {
257                     _popUpShownEventCallbackDelegate = (OnShown);
258                     ShownSignal().Connect(_popUpShownEventCallbackDelegate);
259                 }
260                 _popUpShownEventHandler += value;
261             }
262             remove
263             {
264                 _popUpShownEventHandler -= value;
265                 if (_popUpShownEventHandler == null && ShownSignal().Empty() == false)
266                 {
267                     ShownSignal().Disconnect(_popUpShownEventCallbackDelegate);
268                 }
269             }
270         }
271
272         // Callback for ShownSignal
273         private void OnShown()
274         {
275             ShownEventArgs e = new ShownEventArgs();
276
277             if (_popUpShownEventHandler != null)
278             {
279                 //here we send all data to user event handlers
280                 _popUpShownEventHandler(this, e);
281             }
282         }
283
284         /// <summary>
285         /// An event is sent when the popup starts to hide.
286         /// </summary>
287         /// <since_tizen> 3 </since_tizen>
288         public event EventHandler<HidingEventArgs> Hiding
289         {
290             add
291             {
292                 if (_popUpHidingEventHandler == null)
293                 {
294                     _popUpHidingEventCallbackDelegate = (OnHiding);
295                     HidingSignal().Connect(_popUpHidingEventCallbackDelegate);
296                 }
297                 _popUpHidingEventHandler += value;
298             }
299             remove
300             {
301                 _popUpHidingEventHandler -= value;
302                 if (_popUpHidingEventHandler == null && HidingSignal().Empty() == false)
303                 {
304                     HidingSignal().Disconnect(_popUpHidingEventCallbackDelegate);
305                 }
306             }
307         }
308
309         // Callback for HidingSignal
310         private void OnHiding()
311         {
312             HidingEventArgs e = new HidingEventArgs();
313
314             if (_popUpHidingEventHandler != null)
315             {
316                 //here we send all data to user event handlers
317                 _popUpHidingEventHandler(this, e);
318             }
319         }
320
321         /// <summary>
322         /// An event is sent when the popup has been completely hidden.
323         /// </summary>
324         /// <since_tizen> 3 </since_tizen>
325         public event EventHandler<HiddenEventArgs> Hidden
326         {
327             add
328             {
329                 if (_popUpHiddenEventHandler == null)
330                 {
331                     _popUpHiddenEventCallbackDelegate = (OnHidden);
332                     HiddenSignal().Connect(_popUpHiddenEventCallbackDelegate);
333                 }
334                 _popUpHiddenEventHandler += value;
335             }
336             remove
337             {
338                 _popUpHiddenEventHandler -= value;
339                 if (_popUpHiddenEventHandler == null && HiddenSignal().Empty() == false)
340                 {
341                     HiddenSignal().Disconnect(_popUpHiddenEventCallbackDelegate);
342                 }
343             }
344         }
345
346         // Callback for HiddenSignal
347         private void OnHidden()
348         {
349             HiddenEventArgs e = new HiddenEventArgs();
350
351             if (_popUpHiddenEventHandler != null)
352             {
353                 //here we send all data to user event handlers
354                 _popUpHiddenEventHandler(this, e);
355             }
356         }
357
358         internal new class Property
359         {
360             internal static readonly int TITLE = NDalicPINVOKE.Popup_Property_TITLE_get();
361             internal static readonly int CONTENT = NDalicPINVOKE.Popup_Property_CONTENT_get();
362             internal static readonly int FOOTER = NDalicPINVOKE.Popup_Property_FOOTER_get();
363             internal static readonly int DISPLAY_STATE = NDalicPINVOKE.Popup_Property_DISPLAY_STATE_get();
364             internal static readonly int TOUCH_TRANSPARENT = NDalicPINVOKE.Popup_Property_TOUCH_TRANSPARENT_get();
365             internal static readonly int TAIL_VISIBILITY = NDalicPINVOKE.Popup_Property_TAIL_VISIBILITY_get();
366             internal static readonly int TAIL_POSITION = NDalicPINVOKE.Popup_Property_TAIL_POSITION_get();
367             internal static readonly int CONTEXTUAL_MODE = NDalicPINVOKE.Popup_Property_CONTEXTUAL_MODE_get();
368             internal static readonly int ANIMATION_DURATION = NDalicPINVOKE.Popup_Property_ANIMATION_DURATION_get();
369             internal static readonly int ANIMATION_MODE = NDalicPINVOKE.Popup_Property_ANIMATION_MODE_get();
370             internal static readonly int ENTRY_ANIMATION = NDalicPINVOKE.Popup_Property_ENTRY_ANIMATION_get();
371             internal static readonly int EXIT_ANIMATION = NDalicPINVOKE.Popup_Property_EXIT_ANIMATION_get();
372             internal static readonly int AUTO_HIDE_DELAY = NDalicPINVOKE.Popup_Property_AUTO_HIDE_DELAY_get();
373             internal static readonly int BACKING_ENABLED = NDalicPINVOKE.Popup_Property_BACKING_ENABLED_get();
374             internal static readonly int BACKING_COLOR = NDalicPINVOKE.Popup_Property_BACKING_COLOR_get();
375             internal static readonly int POPUP_BACKGROUND_IMAGE = NDalicPINVOKE.Popup_Property_POPUP_BACKGROUND_IMAGE_get();
376             internal static readonly int POPUP_BACKGROUND_BORDER = NDalicPINVOKE.Popup_Property_POPUP_BACKGROUND_BORDER_get();
377             internal static readonly int TAIL_UP_IMAGE = NDalicPINVOKE.Popup_Property_TAIL_UP_IMAGE_get();
378             internal static readonly int TAIL_DOWN_IMAGE = NDalicPINVOKE.Popup_Property_TAIL_DOWN_IMAGE_get();
379             internal static readonly int TAIL_LEFT_IMAGE = NDalicPINVOKE.Popup_Property_TAIL_LEFT_IMAGE_get();
380             internal static readonly int TAIL_RIGHT_IMAGE = NDalicPINVOKE.Popup_Property_TAIL_RIGHT_IMAGE_get();
381         }
382
383         /// <summary>
384         /// Creates the popup.
385         /// </summary>
386         /// <since_tizen> 3 </since_tizen>
387         public Popup() : this(NDalicPINVOKE.Popup_New(), true)
388         {
389             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
390
391         }
392
393         /// <summary>
394         /// Downcasts a handle to popup handle.
395         /// </summary>
396         /// <since_tizen> 3 </since_tizen>
397         /// Please do not use! this will be deprecated!
398         /// Instead please use as keyword.
399         [Obsolete("Please do not use! This will be deprecated! Please use as keyword instead!")]
400         [EditorBrowsable(EditorBrowsableState.Never)]
401         public new static Popup DownCast(BaseHandle handle)
402         {
403             Popup ret =  Registry.GetManagedBaseHandleFromNativePtr(handle) as Popup;
404             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
405             return ret;
406         }
407
408         /// <summary>
409         /// Sets the title for this popup.
410         /// </summary>
411         /// <param name="titleView">The actor to set the title.</param>
412         /// <since_tizen> 3 </since_tizen>
413         public void SetTitle(View titleView)
414         {
415             NDalicPINVOKE.Popup_SetTitle(swigCPtr, View.getCPtr(titleView));
416             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
417         }
418
419         internal View GetTitle()
420         {
421             IntPtr cPtr = NDalicPINVOKE.Popup_GetTitle(swigCPtr);
422             View ret = Registry.GetManagedBaseHandleFromNativePtr(cPtr) as View;
423
424             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
425             return ret;
426         }
427
428         /// <summary>
429         /// Sets the content actor.
430         /// </summary>
431         /// <param name="content">The actor to use.</param>
432         /// <since_tizen> 3 </since_tizen>
433         public void SetContent(View content)
434         {
435             NDalicPINVOKE.Popup_SetContent(swigCPtr, View.getCPtr(content));
436             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
437         }
438
439         internal View GetContent()
440         {
441             IntPtr cPtr = NDalicPINVOKE.Popup_GetContent(swigCPtr);
442             View ret = Registry.GetManagedBaseHandleFromNativePtr(cPtr) as View;
443
444             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
445             return ret;
446         }
447
448         /// <summary>
449         /// Sets the actor to use for the footer in this popup.
450         /// </summary>
451         /// <param name="footer">The footer actor to be added to this popup.</param>
452         /// <since_tizen> 3 </since_tizen>
453         public void SetFooter(View footer)
454         {
455             NDalicPINVOKE.Popup_SetFooter(swigCPtr, View.getCPtr(footer));
456             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
457         }
458
459         internal View GetFooter()
460         {
461             IntPtr cPtr = NDalicPINVOKE.Popup_GetFooter(swigCPtr);
462             View ret = Registry.GetManagedBaseHandleFromNativePtr(cPtr) as View;
463
464             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
465             return ret;
466         }
467
468         /// <summary>
469         /// Sets the display state of popup.<br />
470         /// There are 4 total display states.<br />
471         /// Only 2 can be set, but all four can be read for better inspection of the current popup state.<br />
472         /// <br />
473         /// The other two states are getable, but not setable, and are there for consistency.<br />
474         /// <br />
475         /// | Value    | Setting the state              | Getting the state              |<br />
476         /// |----------|--------------------------------|--------------------------------|<br />
477         /// | SHOWN    | Show the popup                 | The popup is fully shown       |<br />
478         /// | HIDDEN   | Hide the popup                 | The popup is fully hidden      |<br />
479         /// | SHOWING  |                                | The popup is transitioning in  |<br />
480         /// | HIDING   |                                | The popup is transitioning out |<br />
481         /// <br />
482         /// All 4 states changes cause notifications via 4 respective signals that can be connected to.<br />
483         /// </summary>
484         /// <param name="displayState">The desired display state to change to.</param>
485         /// <since_tizen> 3 </since_tizen>
486         public void SetDisplayState(Popup.DisplayStateType displayState)
487         {
488             NDalicPINVOKE.Popup_SetDisplayState(swigCPtr, (int)displayState);
489             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
490         }
491
492         internal Popup.DisplayStateType GetDisplayState()
493         {
494             Popup.DisplayStateType ret = (Popup.DisplayStateType)NDalicPINVOKE.Popup_GetDisplayState(swigCPtr);
495             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
496             return ret;
497         }
498
499         internal VoidSignal OutsideTouchedSignal()
500         {
501             VoidSignal ret = new VoidSignal(NDalicPINVOKE.Popup_OutsideTouchedSignal(swigCPtr), false);
502             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
503             return ret;
504         }
505
506         internal VoidSignal ShowingSignal()
507         {
508             VoidSignal ret = new VoidSignal(NDalicPINVOKE.Popup_ShowingSignal(swigCPtr), false);
509             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
510             return ret;
511         }
512
513         internal VoidSignal ShownSignal()
514         {
515             VoidSignal ret = new VoidSignal(NDalicPINVOKE.Popup_ShownSignal(swigCPtr), false);
516             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
517             return ret;
518         }
519
520         internal VoidSignal HidingSignal()
521         {
522             VoidSignal ret = new VoidSignal(NDalicPINVOKE.Popup_HidingSignal(swigCPtr), false);
523             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
524             return ret;
525         }
526
527         internal VoidSignal HiddenSignal()
528         {
529             VoidSignal ret = new VoidSignal(NDalicPINVOKE.Popup_HiddenSignal(swigCPtr), false);
530             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
531             return ret;
532         }
533
534         /// <summary>
535         /// The display states of the popup.
536         /// </summary>
537         /// <since_tizen> 3 </since_tizen>
538         public enum DisplayStateType
539         {
540             /// <summary>
541             /// The popup is transitioning in
542             /// </summary>
543             /// <since_tizen> 3 </since_tizen>
544             Showing,
545             /// <summary>
546             /// The popup is fully shown
547             /// </summary>
548             /// <since_tizen> 3 </since_tizen>
549             Shown,
550             /// <summary>
551             /// The popup is transitioning out
552             /// </summary>
553             /// <since_tizen> 3 </since_tizen>
554             Hiding,
555             /// <summary>
556             /// The popup is fully hidden
557             /// </summary>
558             /// <since_tizen> 3 </since_tizen>
559             Hidden
560         }
561
562         /// <summary>
563         /// The animation modes within the popup.<br />
564         /// Choose from a predefined mode or "CUSTOM" to use the ANIMATION_IN and ANIMATION_OUT properties.<br />
565         /// </summary>
566         /// <since_tizen> 3 </since_tizen>
567         public enum AnimationModeType
568         {
569             /// <summary>
570             /// No animation.
571             /// </summary>
572             /// <since_tizen> 3 </since_tizen>
573             None,
574             /// <summary>
575             /// Popup zooms in and out animating the scale property.
576             /// </summary>
577             /// <since_tizen> 3 </since_tizen>
578             Zoom,
579             /// <summary>
580             /// Popup fades in and out
581             /// </summary>
582             /// <since_tizen> 3 </since_tizen>
583             Fade,
584             /// <summary>
585             /// Use the EntryAnimation and ExitAnimation animation properties.
586             /// </summary>
587             /// <since_tizen> 3 </since_tizen>
588             Custom
589         }
590
591         /// <summary>
592         /// The types of the contextual layout.<br />
593         /// The popup is positioned adjacent to it's parent in the direction specified by this mode.<br />
594         /// NON_CONTEXTUAL disables any contextual positioning.<br />
595         /// </summary>
596         /// <since_tizen> 3 </since_tizen>
597         public enum ContextualModeType
598         {
599             /// <summary>
600             /// any contextual positioning
601             /// </summary>
602             /// <since_tizen> 3 </since_tizen>
603             NonContextual,
604             /// <summary>
605             /// Above
606             /// </summary>
607             /// <since_tizen> 3 </since_tizen>
608             Above,
609             /// <summary>
610             /// Rright
611             /// </summary>
612             /// <since_tizen> 3 </since_tizen>
613             Rright,
614             /// <summary>
615             /// Below
616             /// </summary>
617             /// <since_tizen> 3 </since_tizen>
618             Below,
619             /// <summary>
620             /// Left
621             /// </summary>
622             /// <since_tizen> 3 </since_tizen>
623             Left
624         }
625
626         /// <summary>
627         /// The popup title.
628         /// </summary>
629         /// <since_tizen> 3 </since_tizen>
630         public PropertyMap Title
631         {
632             get
633             {
634                 PropertyMap temp = new PropertyMap();
635                 GetProperty(Popup.Property.TITLE).Get(temp);
636                 return temp;
637             }
638             set
639             {
640                 SetProperty(Popup.Property.TITLE, new Tizen.NUI.PropertyValue(value));
641             }
642         }
643         /// <summary>
644         /// The popup content.
645         /// </summary>
646         /// <since_tizen> 3 </since_tizen>
647         public PropertyMap Content
648         {
649             get
650             {
651                 PropertyMap temp = new PropertyMap();
652                 GetProperty(Popup.Property.CONTENT).Get(temp);
653                 return temp;
654             }
655             set
656             {
657                 SetProperty(Popup.Property.CONTENT, new Tizen.NUI.PropertyValue(value));
658             }
659         }
660         /// <summary>
661         /// The popup footer.
662         /// </summary>
663         /// <since_tizen> 3 </since_tizen>
664         public PropertyMap Footer
665         {
666             get
667             {
668                 PropertyMap temp = new PropertyMap();
669                 GetProperty(Popup.Property.FOOTER).Get(temp);
670                 return temp;
671             }
672             set
673             {
674                 SetProperty(Popup.Property.FOOTER, new Tizen.NUI.PropertyValue(value));
675             }
676         }
677         /// <summary>
678         /// The popup display state.
679         /// </summary>
680         /// <since_tizen> 3 </since_tizen>
681         public DisplayStateType DisplayState
682         {
683             get
684             {
685                 string temp;
686                 if (GetProperty(Popup.Property.DISPLAY_STATE).Get(out temp) == false)
687                 {
688                     NUILog.Error("DisplayState get error!");
689                 }
690                 switch (temp)
691                 {
692                     case "SHOWING":
693                         return DisplayStateType.Showing;
694                     case "SHOWN":
695                         return DisplayStateType.Shown;
696                     case "HIDING":
697                         return DisplayStateType.Hiding;
698                     case "HIDDEN":
699                         return DisplayStateType.Hidden;
700                     default:
701                         return DisplayStateType.Hidden;
702                 }
703             }
704             set
705             {
706                 string valueToString = "";
707                 switch (value)
708                 {
709                     case DisplayStateType.Showing:
710                         {
711                             valueToString = "SHOWING";
712                             break;
713                         }
714                     case DisplayStateType.Shown:
715                         {
716                             valueToString = "SHOWN";
717                             break;
718                         }
719                     case DisplayStateType.Hiding:
720                         {
721                             valueToString = "HIDING";
722                             break;
723                         }
724                     case DisplayStateType.Hidden:
725                         {
726                             valueToString = "HIDDEN";
727                             break;
728                         }
729                     default:
730                         {
731                             valueToString = "HIDDEN";
732                             break;
733                         }
734                 }
735                 SetProperty(Popup.Property.DISPLAY_STATE, new Tizen.NUI.PropertyValue(valueToString));
736             }
737         }
738         /// <summary>
739         /// The touch transparent.
740         /// </summary>
741         /// <since_tizen> 3 </since_tizen>
742         public bool TouchTransparent
743         {
744             get
745             {
746                 bool temp = false;
747                 GetProperty(Popup.Property.TOUCH_TRANSPARENT).Get(out temp);
748                 return temp;
749             }
750             set
751             {
752                 SetProperty(Popup.Property.TOUCH_TRANSPARENT, new Tizen.NUI.PropertyValue(value));
753             }
754         }
755         /// <summary>
756         /// The popup tail visibility.
757         /// </summary>
758         /// <since_tizen> 3 </since_tizen>
759         public bool TailVisibility
760         {
761             get
762             {
763                 bool temp = false;
764                 GetProperty(Popup.Property.TAIL_VISIBILITY).Get(out temp);
765                 return temp;
766             }
767             set
768             {
769                 SetProperty(Popup.Property.TAIL_VISIBILITY, new Tizen.NUI.PropertyValue(value));
770             }
771         }
772         /// <summary>
773         /// The popup tail position.
774         /// </summary>
775         /// <since_tizen> 3 </since_tizen>
776         public Vector3 TailPosition
777         {
778             get
779             {
780                 Vector3 temp = new Vector3(0.0f, 0.0f, 0.0f);
781                 GetProperty(Popup.Property.TAIL_POSITION).Get(temp);
782                 return temp;
783             }
784             set
785             {
786                 SetProperty(Popup.Property.TAIL_POSITION, new Tizen.NUI.PropertyValue(value));
787             }
788         }
789         /// <summary>
790         /// The contextual mode.
791         /// </summary>
792         /// <since_tizen> 3 </since_tizen>
793         public ContextualModeType ContextualMode
794         {
795             get
796             {
797                 string temp;
798                 if (GetProperty(Popup.Property.CONTEXTUAL_MODE).Get(out temp) == false)
799                 {
800                     NUILog.Error("ContextualMode get error!");
801                 }
802                 switch (temp)
803                 {
804                     case "NON_CONTEXTUAL":
805                         return ContextualModeType.NonContextual;
806                     case "ABOVE":
807                         return ContextualModeType.Above;
808                     case "RIGHT":
809                         return ContextualModeType.Rright;
810                     case "BELOW":
811                         return ContextualModeType.Below;
812                     case "LEFT":
813                         return ContextualModeType.Left;
814                     default:
815                         return ContextualModeType.Below;
816                 }
817             }
818             set
819             {
820                 string valueToString = "";
821                 switch (value)
822                 {
823                     case ContextualModeType.NonContextual:
824                         {
825                             valueToString = "NON_CONTEXTUAL";
826                             break;
827                         }
828                     case ContextualModeType.Above:
829                         {
830                             valueToString = "ABOVE";
831                             break;
832                         }
833                     case ContextualModeType.Rright:
834                         {
835                             valueToString = "RIGHT";
836                             break;
837                         }
838                     case ContextualModeType.Below:
839                         {
840                             valueToString = "BELOW";
841                             break;
842                         }
843                     case ContextualModeType.Left:
844                         {
845                             valueToString = "LEFT";
846                             break;
847                         }
848                     default:
849                         {
850                             valueToString = "BELOW";
851                             break;
852                         }
853                 }
854                 SetProperty(Popup.Property.CONTEXTUAL_MODE, new Tizen.NUI.PropertyValue(valueToString));
855             }
856         }
857         /// <summary>
858         /// The animation duration.
859         /// </summary>
860         /// <since_tizen> 3 </since_tizen>
861         public float AnimationDuration
862         {
863             get
864             {
865                 float temp = 0.0f;
866                 GetProperty(Popup.Property.ANIMATION_DURATION).Get(out temp);
867                 return temp;
868             }
869             set
870             {
871                 SetProperty(Popup.Property.ANIMATION_DURATION, new Tizen.NUI.PropertyValue(value));
872             }
873         }
874         /// <summary>
875         /// The animation mode.
876         /// </summary>
877         /// <since_tizen> 3 </since_tizen>
878         public AnimationModeType AnimationMode
879         {
880             get
881             {
882                 string temp;
883                 if (GetProperty(Popup.Property.ANIMATION_MODE).Get(out temp) == false)
884                 {
885                     NUILog.Error("AnimationMode get error!");
886                 }
887                 switch (temp)
888                 {
889                     case "NONE":
890                         return AnimationModeType.None;
891                     case "ZOOM":
892                         return AnimationModeType.Zoom;
893                     case "FADE":
894                         return AnimationModeType.Fade;
895                     case "CUSTOM":
896                         return AnimationModeType.Custom;
897                     default:
898                         return AnimationModeType.Fade;
899                 }
900             }
901             set
902             {
903                 string valueToString = "";
904                 switch (value)
905                 {
906                     case AnimationModeType.None:
907                         {
908                             valueToString = "NONE";
909                             break;
910                         }
911                     case AnimationModeType.Zoom:
912                         {
913                             valueToString = "ZOOM";
914                             break;
915                         }
916                     case AnimationModeType.Fade:
917                         {
918                             valueToString = "FADE";
919                             break;
920                         }
921                     case AnimationModeType.Custom:
922                         {
923                             valueToString = "CUSTOM";
924                             break;
925                         }
926                     default:
927                         {
928                             valueToString = "FADE";
929                             break;
930                         }
931                 }
932                 SetProperty(Popup.Property.ANIMATION_MODE, new Tizen.NUI.PropertyValue(valueToString));
933             }
934         }
935         /// <summary>
936         /// The entry animation.
937         /// </summary>
938         /// <since_tizen> 3 </since_tizen>
939         public PropertyMap EntryAnimation
940         {
941             get
942             {
943                 PropertyMap temp = new PropertyMap();
944                 GetProperty(Popup.Property.ENTRY_ANIMATION).Get(temp);
945                 return temp;
946             }
947             set
948             {
949                 SetProperty(Popup.Property.ENTRY_ANIMATION, new Tizen.NUI.PropertyValue(value));
950             }
951         }
952         /// <summary>
953         /// The exit animation.
954         /// </summary>
955         /// <since_tizen> 3 </since_tizen>
956         public PropertyMap ExitAnimation
957         {
958             get
959             {
960                 PropertyMap temp = new PropertyMap();
961                 GetProperty(Popup.Property.EXIT_ANIMATION).Get(temp);
962                 return temp;
963             }
964             set
965             {
966                 SetProperty(Popup.Property.EXIT_ANIMATION, new Tizen.NUI.PropertyValue(value));
967             }
968         }
969         /// <summary>
970         /// The auto hide delay.
971         /// </summary>
972         /// <since_tizen> 3 </since_tizen>
973         public int AutoHideDelay
974         {
975             get
976             {
977                 int temp = 0;
978                 GetProperty(Popup.Property.AUTO_HIDE_DELAY).Get(out temp);
979                 return temp;
980             }
981             set
982             {
983                 SetProperty(Popup.Property.AUTO_HIDE_DELAY, new Tizen.NUI.PropertyValue(value));
984             }
985         }
986         /// <summary>
987         /// The backing enabled.
988         /// </summary>
989         /// <since_tizen> 3 </since_tizen>
990         public bool BackingEnabled
991         {
992             get
993             {
994                 bool temp = false;
995                 GetProperty(Popup.Property.BACKING_ENABLED).Get(out temp);
996                 return temp;
997             }
998             set
999             {
1000                 SetProperty(Popup.Property.BACKING_ENABLED, new Tizen.NUI.PropertyValue(value));
1001             }
1002         }
1003         /// <summary>
1004         /// The backing color.
1005         /// </summary>
1006         /// <since_tizen> 3 </since_tizen>
1007         public Vector4 BackingColor
1008         {
1009             get
1010             {
1011                 Vector4 temp = new Vector4(0.0f, 0.0f, 0.0f, 0.0f);
1012                 GetProperty(Popup.Property.BACKING_COLOR).Get(temp);
1013                 return temp;
1014             }
1015             set
1016             {
1017                 SetProperty(Popup.Property.BACKING_COLOR, new Tizen.NUI.PropertyValue(value));
1018             }
1019         }
1020         /// <summary>
1021         /// The background image.
1022         /// </summary>
1023         /// <since_tizen> 3 </since_tizen>
1024         public string PopupBackgroundImage
1025         {
1026             get
1027             {
1028                 string temp;
1029                 GetProperty(Popup.Property.POPUP_BACKGROUND_IMAGE).Get(out temp);
1030                 return temp;
1031             }
1032             set
1033             {
1034                 SetProperty(Popup.Property.POPUP_BACKGROUND_IMAGE, new Tizen.NUI.PropertyValue(value));
1035             }
1036         }
1037         /// <summary>
1038         /// The background border.
1039         /// </summary>
1040         /// <since_tizen> 3 </since_tizen>
1041         public Rectangle PopupBackgroundBorder
1042         {
1043             get
1044             {
1045                 Rectangle temp = new Rectangle(0, 0, 0, 0);
1046                 GetProperty(Popup.Property.POPUP_BACKGROUND_BORDER).Get(temp);
1047                 return temp;
1048             }
1049             set
1050             {
1051                 SetProperty(Popup.Property.POPUP_BACKGROUND_BORDER, new Tizen.NUI.PropertyValue(value));
1052             }
1053         }
1054         /// <summary>
1055         /// The tail up image.
1056         /// </summary>
1057         /// <since_tizen> 3 </since_tizen>
1058         public string TailUpImage
1059         {
1060             get
1061             {
1062                 string temp;
1063                 GetProperty(Popup.Property.TAIL_UP_IMAGE).Get(out temp);
1064                 return temp;
1065             }
1066             set
1067             {
1068                 SetProperty(Popup.Property.TAIL_UP_IMAGE, new Tizen.NUI.PropertyValue(value));
1069             }
1070         }
1071         /// <summary>
1072         /// The tail down image.
1073         /// </summary>
1074         /// <since_tizen> 3 </since_tizen>
1075         public string TailDownImage
1076         {
1077             get
1078             {
1079                 string temp;
1080                 GetProperty(Popup.Property.TAIL_DOWN_IMAGE).Get(out temp);
1081                 return temp;
1082             }
1083             set
1084             {
1085                 SetProperty(Popup.Property.TAIL_DOWN_IMAGE, new Tizen.NUI.PropertyValue(value));
1086             }
1087         }
1088         /// <summary>
1089         /// The tail left image.
1090         /// </summary>
1091         /// <since_tizen> 3 </since_tizen>
1092         public string TailLeftImage
1093         {
1094             get
1095             {
1096                 string temp;
1097                 GetProperty(Popup.Property.TAIL_LEFT_IMAGE).Get(out temp);
1098                 return temp;
1099             }
1100             set
1101             {
1102                 SetProperty(Popup.Property.TAIL_LEFT_IMAGE, new Tizen.NUI.PropertyValue(value));
1103             }
1104         }
1105         /// <summary>
1106         /// The tail right image.
1107         /// </summary>
1108         /// <since_tizen> 3 </since_tizen>
1109         public string TailRightImage
1110         {
1111             get
1112             {
1113                 string temp;
1114                 GetProperty(Popup.Property.TAIL_RIGHT_IMAGE).Get(out temp);
1115                 return temp;
1116             }
1117             set
1118             {
1119                 SetProperty(Popup.Property.TAIL_RIGHT_IMAGE, new Tizen.NUI.PropertyValue(value));
1120             }
1121         }
1122
1123     }
1124
1125 }