1 /** Copyright (c) 2016 Samsung Electronics Co., Ltd.
3 * Licensed under the Apache License, Version 2.0 (the "License");
4 * you may not use this file except in compliance with the License.
5 * You may obtain a copy of the License at
7 * http://www.apache.org/licenses/LICENSE-2.0
9 * Unless required by applicable law or agreed to in writing, software
10 * distributed under the License is distributed on an "AS IS" BASIS,
11 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 * See the License for the specific language governing permissions and
13 * limitations under the License.
16 // This File has been auto-generated by SWIG and then modified using DALi Ruby Scripts
17 //------------------------------------------------------------------------------
20 // This file was automatically generated by SWIG (http://www.swig.org).
23 // Do not make changes to this file unless you know what you are doing--modify
24 // the SWIG interface file instead.
25 //------------------------------------------------------------------------------
30 using System.Runtime.InteropServices;
33 public class Popup : View {
34 private global::System.Runtime.InteropServices.HandleRef swigCPtr;
36 internal Popup(global::System.IntPtr cPtr, bool cMemoryOwn) : base(NDalicPINVOKE.Popup_SWIGUpcast(cPtr), cMemoryOwn) {
37 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
40 internal static global::System.Runtime.InteropServices.HandleRef getCPtr(Popup obj) {
41 return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
48 public override void Dispose() {
50 if (swigCPtr.Handle != global::System.IntPtr.Zero) {
53 NDalicPINVOKE.delete_Popup(swigCPtr);
55 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
57 global::System.GC.SuppressFinalize(this);
63 public class OutsideTouchedEventArgs : EventArgs
67 public class ShowingEventArgs : EventArgs
71 public class ShownEventArgs : EventArgs
75 public class HidingEventArgs : EventArgs
79 public class HiddenEventArgs : EventArgs
83 [UnmanagedFunctionPointer(CallingConvention.StdCall)]
84 private delegate void OutsideTouchedEventCallbackDelegate();
85 private DaliEventHandler<object,OutsideTouchedEventArgs> _popUpOutsideTouchedEventHandler;
86 private OutsideTouchedEventCallbackDelegate _popUpOutsideTouchedEventCallbackDelegate;
88 [UnmanagedFunctionPointer(CallingConvention.StdCall)]
89 private delegate void ShowingEventCallbackDelegate();
90 private DaliEventHandler<object,ShowingEventArgs> _popUpShowingEventHandler;
91 private ShowingEventCallbackDelegate _popUpShowingEventCallbackDelegate;
93 [UnmanagedFunctionPointer(CallingConvention.StdCall)]
94 private delegate void ShownEventCallbackDelegate();
95 private DaliEventHandler<object,ShownEventArgs> _popUpShownEventHandler;
96 private ShownEventCallbackDelegate _popUpShownEventCallbackDelegate;
98 [UnmanagedFunctionPointer(CallingConvention.StdCall)]
99 private delegate void HidingEventCallbackDelegate();
100 private DaliEventHandler<object,HidingEventArgs> _popUpHidingEventHandler;
101 private HidingEventCallbackDelegate _popUpHidingEventCallbackDelegate;
103 [UnmanagedFunctionPointer(CallingConvention.StdCall)]
104 private delegate void HiddenEventCallbackDelegate();
105 private DaliEventHandler<object,HiddenEventArgs> _popUpHiddenEventHandler;
106 private HiddenEventCallbackDelegate _popUpHiddenEventCallbackDelegate;
108 public event DaliEventHandler<object,OutsideTouchedEventArgs> OutsideTouched
114 // Restricted to only one listener
115 if (_popUpOutsideTouchedEventHandler == null)
117 _popUpOutsideTouchedEventHandler += value;
119 _popUpOutsideTouchedEventCallbackDelegate = new OutsideTouchedEventCallbackDelegate(OnOutsideTouched);
120 this.OutsideTouchedSignal().Connect(_popUpOutsideTouchedEventCallbackDelegate);
129 if (_popUpOutsideTouchedEventHandler != null)
131 this.OutsideTouchedSignal().Disconnect(_popUpOutsideTouchedEventCallbackDelegate);
134 _popUpOutsideTouchedEventHandler -= value;
139 // Callback for Popup OutsideTouchedSignal
140 private void OnOutsideTouched()
142 OutsideTouchedEventArgs e = new OutsideTouchedEventArgs();
144 if (_popUpOutsideTouchedEventHandler != null)
146 //here we send all data to user event handlers
147 _popUpOutsideTouchedEventHandler(this, e);
151 public event DaliEventHandler<object,ShowingEventArgs> Showing
157 // Restricted to only one listener
158 if (_popUpShowingEventHandler == null)
160 _popUpShowingEventHandler += value;
162 _popUpShowingEventCallbackDelegate = new ShowingEventCallbackDelegate(OnShowing);
163 this.ShowingSignal().Connect(_popUpShowingEventCallbackDelegate);
172 if (_popUpShowingEventHandler != null)
174 this.ShowingSignal().Disconnect(_popUpShowingEventCallbackDelegate);
177 _popUpShowingEventHandler -= value;
182 // Callback for ShowingSignal
183 private void OnShowing()
185 ShowingEventArgs e = new ShowingEventArgs();
187 if (_popUpShowingEventHandler != null)
189 //here we send all data to user event handlers
190 _popUpShowingEventHandler(this, e);
195 public event DaliEventHandler<object,ShownEventArgs> Shown
201 // Restricted to only one listener
202 if (_popUpShownEventHandler == null)
204 _popUpShownEventHandler += value;
206 _popUpShownEventCallbackDelegate = new ShownEventCallbackDelegate(OnShown);
207 this.ShownSignal().Connect(_popUpShownEventCallbackDelegate);
216 if (_popUpShownEventHandler != null)
218 this.ShownSignal().Disconnect(_popUpShownEventCallbackDelegate);
221 _popUpShownEventHandler -= value;
226 // Callback for ShownSignal
227 private void OnShown()
229 ShownEventArgs e = new ShownEventArgs();
231 if (_popUpShownEventHandler != null)
233 //here we send all data to user event handlers
234 _popUpShownEventHandler(this, e);
238 public event DaliEventHandler<object,HidingEventArgs> Hiding
244 // Restricted to only one listener
245 if (_popUpHidingEventHandler == null)
247 _popUpHidingEventHandler += value;
249 _popUpHidingEventCallbackDelegate = new HidingEventCallbackDelegate(OnHiding);
250 this.HidingSignal().Connect(_popUpHidingEventCallbackDelegate);
259 if (_popUpHidingEventHandler != null)
261 this.HidingSignal().Disconnect(_popUpHidingEventCallbackDelegate);
264 _popUpHidingEventHandler -= value;
269 // Callback for HidingSignal
270 private void OnHiding()
272 HidingEventArgs e = new HidingEventArgs();
274 if (_popUpHidingEventHandler != null)
276 //here we send all data to user event handlers
277 _popUpHidingEventHandler(this, e);
281 public event DaliEventHandler<object,HiddenEventArgs> Hidden
287 // Restricted to only one listener
288 if (_popUpHiddenEventHandler == null)
290 _popUpHiddenEventHandler += value;
292 _popUpHiddenEventCallbackDelegate = new HiddenEventCallbackDelegate(OnHidden);
293 this.HiddenSignal().Connect(_popUpHiddenEventCallbackDelegate);
302 if (_popUpHiddenEventHandler != null)
304 this.HiddenSignal().Disconnect(_popUpHiddenEventCallbackDelegate);
307 _popUpHiddenEventHandler -= value;
312 // Callback for HiddenSignal
313 private void OnHidden()
315 HiddenEventArgs e = new HiddenEventArgs();
317 if (_popUpHiddenEventHandler != null)
319 //here we send all data to user event handlers
320 _popUpHiddenEventHandler(this, e);
324 public class Property : global::System.IDisposable {
325 private global::System.Runtime.InteropServices.HandleRef swigCPtr;
326 protected bool swigCMemOwn;
328 internal Property(global::System.IntPtr cPtr, bool cMemoryOwn) {
329 swigCMemOwn = cMemoryOwn;
330 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
333 internal static global::System.Runtime.InteropServices.HandleRef getCPtr(Property obj) {
334 return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
341 public virtual void Dispose() {
343 if (swigCPtr.Handle != global::System.IntPtr.Zero) {
346 NDalicPINVOKE.delete_Popup_Property(swigCPtr);
348 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
350 global::System.GC.SuppressFinalize(this);
354 public Property() : this(NDalicPINVOKE.new_Popup_Property(), true) {
355 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
358 public static readonly int TITLE = NDalicPINVOKE.Popup_Property_TITLE_get();
359 public static readonly int CONTENT = NDalicPINVOKE.Popup_Property_CONTENT_get();
360 public static readonly int FOOTER = NDalicPINVOKE.Popup_Property_FOOTER_get();
361 public static readonly int DISPLAY_STATE = NDalicPINVOKE.Popup_Property_DISPLAY_STATE_get();
362 public static readonly int TOUCH_TRANSPARENT = NDalicPINVOKE.Popup_Property_TOUCH_TRANSPARENT_get();
363 public static readonly int TAIL_VISIBILITY = NDalicPINVOKE.Popup_Property_TAIL_VISIBILITY_get();
364 public static readonly int TAIL_POSITION = NDalicPINVOKE.Popup_Property_TAIL_POSITION_get();
365 public static readonly int CONTEXTUAL_MODE = NDalicPINVOKE.Popup_Property_CONTEXTUAL_MODE_get();
366 public static readonly int ANIMATION_DURATION = NDalicPINVOKE.Popup_Property_ANIMATION_DURATION_get();
367 public static readonly int ANIMATION_MODE = NDalicPINVOKE.Popup_Property_ANIMATION_MODE_get();
368 public static readonly int ENTRY_ANIMATION = NDalicPINVOKE.Popup_Property_ENTRY_ANIMATION_get();
369 public static readonly int EXIT_ANIMATION = NDalicPINVOKE.Popup_Property_EXIT_ANIMATION_get();
370 public static readonly int AUTO_HIDE_DELAY = NDalicPINVOKE.Popup_Property_AUTO_HIDE_DELAY_get();
371 public static readonly int BACKING_ENABLED = NDalicPINVOKE.Popup_Property_BACKING_ENABLED_get();
372 public static readonly int BACKING_COLOR = NDalicPINVOKE.Popup_Property_BACKING_COLOR_get();
373 public static readonly int POPUP_BACKGROUND_IMAGE = NDalicPINVOKE.Popup_Property_POPUP_BACKGROUND_IMAGE_get();
374 public static readonly int TAIL_UP_IMAGE = NDalicPINVOKE.Popup_Property_TAIL_UP_IMAGE_get();
375 public static readonly int TAIL_DOWN_IMAGE = NDalicPINVOKE.Popup_Property_TAIL_DOWN_IMAGE_get();
376 public static readonly int TAIL_LEFT_IMAGE = NDalicPINVOKE.Popup_Property_TAIL_LEFT_IMAGE_get();
377 public static readonly int TAIL_RIGHT_IMAGE = NDalicPINVOKE.Popup_Property_TAIL_RIGHT_IMAGE_get();
381 public Popup () : this (NDalicPINVOKE.Popup_New(), true) {
382 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
385 public Popup(Popup handle) : this(NDalicPINVOKE.new_Popup__SWIG_1(Popup.getCPtr(handle)), true) {
386 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
389 public Popup Assign(Popup handle) {
390 Popup ret = new Popup(NDalicPINVOKE.Popup_Assign(swigCPtr, Popup.getCPtr(handle)), false);
391 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
395 public new static Popup DownCast(BaseHandle handle) {
396 Popup ret = new Popup(NDalicPINVOKE.Popup_DownCast(BaseHandle.getCPtr(handle)), true);
397 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
401 public void SetTitle(Actor titleActor) {
402 NDalicPINVOKE.Popup_SetTitle(swigCPtr, Actor.getCPtr(titleActor));
403 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
406 public Actor GetTitle() {
407 Actor ret = new Actor(NDalicPINVOKE.Popup_GetTitle(swigCPtr), true);
408 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
412 public void SetContent(Actor content) {
413 NDalicPINVOKE.Popup_SetContent(swigCPtr, Actor.getCPtr(content));
414 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
417 public Actor GetContent() {
418 Actor ret = new Actor(NDalicPINVOKE.Popup_GetContent(swigCPtr), true);
419 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
423 public void SetFooter(Actor footer) {
424 NDalicPINVOKE.Popup_SetFooter(swigCPtr, Actor.getCPtr(footer));
425 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
428 public Actor GetFooter() {
429 Actor ret = new Actor(NDalicPINVOKE.Popup_GetFooter(swigCPtr), true);
430 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
434 public void SetDisplayState(Popup.DisplayStateType displayState) {
435 NDalicPINVOKE.Popup_SetDisplayState(swigCPtr, (int)displayState);
436 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
439 public Popup.DisplayStateType GetDisplayState() {
440 Popup.DisplayStateType ret = (Popup.DisplayStateType)NDalicPINVOKE.Popup_GetDisplayState(swigCPtr);
441 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
445 public VoidSignal OutsideTouchedSignal() {
446 VoidSignal ret = new VoidSignal(NDalicPINVOKE.Popup_OutsideTouchedSignal(swigCPtr), false);
447 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
451 public VoidSignal ShowingSignal() {
452 VoidSignal ret = new VoidSignal(NDalicPINVOKE.Popup_ShowingSignal(swigCPtr), false);
453 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
457 public VoidSignal ShownSignal() {
458 VoidSignal ret = new VoidSignal(NDalicPINVOKE.Popup_ShownSignal(swigCPtr), false);
459 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
463 public VoidSignal HidingSignal() {
464 VoidSignal ret = new VoidSignal(NDalicPINVOKE.Popup_HidingSignal(swigCPtr), false);
465 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
469 public VoidSignal HiddenSignal() {
470 VoidSignal ret = new VoidSignal(NDalicPINVOKE.Popup_HiddenSignal(swigCPtr), false);
471 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
475 public enum PropertyRange {
476 PROPERTY_START_INDEX = PropertyRanges.PROPERTY_REGISTRATION_START_INDEX,
477 PROPERTY_END_INDEX = View.PropertyRange.PROPERTY_START_INDEX+1000
480 public enum DisplayStateType {
487 public enum AnimationModeType {
494 public enum ContextualModeType {
502 public Dali.Property.Map Title
506 Dali.Property.Map temp = new Dali.Property.Map();
507 GetProperty( Popup.Property.TITLE).Get( temp );
512 SetProperty( Popup.Property.TITLE, new Dali.Property.Value( value ) );
515 public Dali.Property.Map Content
519 Dali.Property.Map temp = new Dali.Property.Map();
520 GetProperty( Popup.Property.CONTENT).Get( temp );
525 SetProperty( Popup.Property.CONTENT, new Dali.Property.Value( value ) );
528 public Dali.Property.Map Footer
532 Dali.Property.Map temp = new Dali.Property.Map();
533 GetProperty( Popup.Property.FOOTER).Get( temp );
538 SetProperty( Popup.Property.FOOTER, new Dali.Property.Value( value ) );
541 public string DisplayState
546 GetProperty( Popup.Property.DISPLAY_STATE).Get( out temp );
551 SetProperty( Popup.Property.DISPLAY_STATE, new Dali.Property.Value( value ) );
554 public bool TouchTransparent
559 GetProperty( Popup.Property.TOUCH_TRANSPARENT).Get( ref temp );
564 SetProperty( Popup.Property.TOUCH_TRANSPARENT, new Dali.Property.Value( value ) );
567 public bool TailVisibility
572 GetProperty( Popup.Property.TAIL_VISIBILITY).Get( ref temp );
577 SetProperty( Popup.Property.TAIL_VISIBILITY, new Dali.Property.Value( value ) );
580 public Vector3 TailPosition
584 Vector3 temp = new Vector3(0.0f,0.0f,0.0f);
585 GetProperty( Popup.Property.TAIL_POSITION).Get( temp );
590 SetProperty( Popup.Property.TAIL_POSITION, new Dali.Property.Value( value ) );
593 public string ContextualMode
598 GetProperty( Popup.Property.CONTEXTUAL_MODE).Get( out temp );
603 SetProperty( Popup.Property.CONTEXTUAL_MODE, new Dali.Property.Value( value ) );
606 public float AnimationDuration
611 GetProperty( Popup.Property.ANIMATION_DURATION).Get( ref temp );
616 SetProperty( Popup.Property.ANIMATION_DURATION, new Dali.Property.Value( value ) );
619 public string AnimationMode
624 GetProperty( Popup.Property.ANIMATION_MODE).Get( out temp );
629 SetProperty( Popup.Property.ANIMATION_MODE, new Dali.Property.Value( value ) );
632 public Dali.Property.Map EntryAnimation
636 Dali.Property.Map temp = new Dali.Property.Map();
637 GetProperty( Popup.Property.ENTRY_ANIMATION).Get( temp );
642 SetProperty( Popup.Property.ENTRY_ANIMATION, new Dali.Property.Value( value ) );
645 public Dali.Property.Map ExitAnimation
649 Dali.Property.Map temp = new Dali.Property.Map();
650 GetProperty( Popup.Property.EXIT_ANIMATION).Get( temp );
655 SetProperty( Popup.Property.EXIT_ANIMATION, new Dali.Property.Value( value ) );
658 public int AutoHideDelay
663 GetProperty( Popup.Property.AUTO_HIDE_DELAY).Get( ref temp );
668 SetProperty( Popup.Property.AUTO_HIDE_DELAY, new Dali.Property.Value( value ) );
671 public bool BackingEnabled
676 GetProperty( Popup.Property.BACKING_ENABLED).Get( ref temp );
681 SetProperty( Popup.Property.BACKING_ENABLED, new Dali.Property.Value( value ) );
684 public Vector4 BackingColor
688 Vector4 temp = new Vector4(0.0f,0.0f,0.0f,0.0f);
689 GetProperty( Popup.Property.BACKING_COLOR).Get( temp );
694 SetProperty( Popup.Property.BACKING_COLOR, new Dali.Property.Value( value ) );
697 public string PopupBackgroundImage
702 GetProperty( Popup.Property.POPUP_BACKGROUND_IMAGE).Get( out temp );
707 SetProperty( Popup.Property.POPUP_BACKGROUND_IMAGE, new Dali.Property.Value( value ) );
710 public string TailUpImage
715 GetProperty( Popup.Property.TAIL_UP_IMAGE).Get( out temp );
720 SetProperty( Popup.Property.TAIL_UP_IMAGE, new Dali.Property.Value( value ) );
723 public string TailDownImage
728 GetProperty( Popup.Property.TAIL_DOWN_IMAGE).Get( out temp );
733 SetProperty( Popup.Property.TAIL_DOWN_IMAGE, new Dali.Property.Value( value ) );
736 public string TailLeftImage
741 GetProperty( Popup.Property.TAIL_LEFT_IMAGE).Get( out temp );
746 SetProperty( Popup.Property.TAIL_LEFT_IMAGE, new Dali.Property.Value( value ) );
749 public string TailRightImage
754 GetProperty( Popup.Property.TAIL_RIGHT_IMAGE).Get( out temp );
759 SetProperty( Popup.Property.TAIL_RIGHT_IMAGE, new Dali.Property.Value( value ) );