1 //------------------------------------------------------------------------------
4 // This file was automatically generated by SWIG (http://www.swig.org).
7 // Do not make changes to this file unless you know what you are doing--modify
8 // the SWIG interface file instead.
9 //------------------------------------------------------------------------------
13 public class Hover : global::System.IDisposable {
14 private global::System.Runtime.InteropServices.HandleRef swigCPtr;
15 protected bool swigCMemOwn;
17 internal Hover(global::System.IntPtr cPtr, bool cMemoryOwn) {
18 swigCMemOwn = cMemoryOwn;
19 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
22 internal static global::System.Runtime.InteropServices.HandleRef getCPtr(Hover obj) {
23 return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
27 DisposeQueue.Instance.Add(this);
30 public virtual void Dispose() {
31 if (!Stage.IsInstalled()) {
32 DisposeQueue.Instance.Add(this);
37 if (swigCPtr.Handle != global::System.IntPtr.Zero) {
40 NDalicPINVOKE.delete_Hover(swigCPtr);
42 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
44 global::System.GC.SuppressFinalize(this);
49 public static Hover GetHoverFromPtr(global::System.IntPtr cPtr) {
50 Hover ret = new Hover(cPtr, false);
51 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
63 public int GetDeviceId(uint point) {
64 if( point < points.Count )
66 return points[(int)point].deviceId;
71 public PointStateType GetState(uint point) {
72 if( point < points.Count )
74 return (Dali.PointStateType)(points[(int)point].state);
76 return PointStateType.FINISHED;
79 public Actor GetHitActor(uint point) {
80 if( point < points.Count )
82 return points[(int)point].hitActor;
86 // Return a native empty handle
87 Actor actor = new Actor();
93 public Vector2 GetLocalPosition(uint point) {
94 if( point < points.Count )
96 return points[(int)point].local;
98 return new Vector2(0.0f, 0.0f);
101 public Vector2 GetScreenPosition(uint point) {
102 if( point < points.Count )
104 return points[(int)point].screen;
106 return new Vector2(0.0f, 0.0f);
109 public Hover() : this(NDalicPINVOKE.new_Hover__SWIG_0(), true) {
110 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
113 public Hover(uint time) : this(NDalicPINVOKE.new_Hover__SWIG_1(time), true) {
114 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
117 private TouchPointContainer points {
119 NDalicPINVOKE.Hover_points_set(swigCPtr, TouchPointContainer.getCPtr(value));
120 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
123 global::System.IntPtr cPtr = NDalicPINVOKE.Hover_points_get(swigCPtr);
124 TouchPointContainer ret = (cPtr == global::System.IntPtr.Zero) ? null : new TouchPointContainer(cPtr, false);
125 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
132 NDalicPINVOKE.Hover_time_set(swigCPtr, value);
133 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
136 uint ret = NDalicPINVOKE.Hover_time_get(swigCPtr);
137 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
142 public uint GetPointCount() {
143 uint ret = NDalicPINVOKE.Hover_GetPointCount(swigCPtr);
144 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
148 public TouchPoint GetPoint(uint point) {
149 TouchPoint ret = new TouchPoint(NDalicPINVOKE.Hover_GetPoint(swigCPtr, point), false);
150 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();