2 * Copyright(c) 2018 Samsung Electronics Co., Ltd.
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
8 * http://www.apache.org/licenses/LICENSE-2.0
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.
20 using Tizen.NUI.BaseComponents;
22 internal class CustomActorImpl : RefObject
24 private global::System.Runtime.InteropServices.HandleRef swigCPtr;
26 internal CustomActorImpl(global::System.IntPtr cPtr, bool cMemoryOwn) : base(Interop.CustomActorImpl.CustomActorImpl_SWIGUpcast(cPtr), cMemoryOwn)
28 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
31 internal static global::System.Runtime.InteropServices.HandleRef getCPtr(CustomActorImpl obj)
33 return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
36 protected override void Dispose(DisposeTypes type)
43 if (type == DisposeTypes.Explicit)
46 //Release your own managed resources here.
47 //You should release all of your own disposable objects here.
51 //Release your own unmanaged resources here.
52 //You should not access any managed member here except static instance.
53 //because the execution order of Finalizes is non-deterministic.
55 if (swigCPtr.Handle != global::System.IntPtr.Zero)
60 throw new global::System.MethodAccessException("C++ destructor does not have public access");
62 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
68 internal CustomActor Self()
70 CustomActor ret = new CustomActor(Interop.CustomActorImpl.CustomActorImpl_Self(swigCPtr), true);
71 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
75 public virtual void OnStageConnection(int depth)
77 Interop.CustomActorImpl.CustomActorImpl_OnStageConnection(swigCPtr, depth);
78 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
81 public virtual void OnStageDisconnection()
83 Interop.CustomActorImpl.CustomActorImpl_OnStageDisconnection(swigCPtr);
84 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
87 public virtual void OnChildAdd(View child)
89 Interop.CustomActorImpl.CustomActorImpl_OnChildAdd(swigCPtr, View.getCPtr(child));
90 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
93 public virtual void OnChildRemove(View child)
95 Interop.CustomActorImpl.CustomActorImpl_OnChildRemove(swigCPtr, View.getCPtr(child));
96 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
99 public virtual void OnPropertySet(int index, PropertyValue propertyValue)
101 Interop.CustomActorImpl.CustomActorImpl_OnPropertySet(swigCPtr, index, PropertyValue.getCPtr(propertyValue));
102 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
105 public virtual void OnSizeSet(Vector3 targetSize)
107 Interop.CustomActorImpl.CustomActorImpl_OnSizeSet(swigCPtr, Vector3.getCPtr(targetSize));
108 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
111 public virtual void OnSizeAnimation(Animation animation, Vector3 targetSize)
113 Interop.CustomActorImpl.CustomActorImpl_OnSizeAnimation(swigCPtr, Animation.getCPtr(animation), Vector3.getCPtr(targetSize));
114 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
117 internal virtual bool OnTouchEvent(SWIGTYPE_p_Dali__TouchEvent arg0)
119 bool ret = Interop.CustomActorImpl.CustomActorImpl_OnTouchEvent(swigCPtr, SWIGTYPE_p_Dali__TouchEvent.getCPtr(arg0));
120 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
124 public virtual bool OnHoverEvent(Hover arg0)
126 bool ret = Interop.CustomActorImpl.CustomActorImpl_OnHoverEvent(swigCPtr, Hover.getCPtr(arg0));
127 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
131 public virtual bool OnKeyEvent(Key arg0)
133 bool ret = Interop.CustomActorImpl.CustomActorImpl_OnKeyEvent(swigCPtr, Key.getCPtr(arg0));
134 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
138 public virtual bool OnWheelEvent(Wheel arg0)
140 bool ret = Interop.CustomActorImpl.CustomActorImpl_OnWheelEvent(swigCPtr, Wheel.getCPtr(arg0));
141 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
145 public virtual void OnRelayout(Vector2 size, RelayoutContainer container)
147 Interop.CustomActorImpl.CustomActorImpl_OnRelayout(swigCPtr, Vector2.getCPtr(size), RelayoutContainer.getCPtr(container));
148 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
151 public virtual void OnSetResizePolicy(ResizePolicyType policy, DimensionType dimension)
153 Interop.CustomActorImpl.CustomActorImpl_OnSetResizePolicy(swigCPtr, (int)policy, (int)dimension);
154 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
157 public virtual Vector3 GetNaturalSize()
159 Vector3 ret = new Vector3(Interop.CustomActorImpl.CustomActorImpl_GetNaturalSize(swigCPtr), true);
160 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
164 public virtual float CalculateChildSize(View child, DimensionType dimension)
166 float ret = Interop.CustomActorImpl.CustomActorImpl_CalculateChildSize(swigCPtr, View.getCPtr(child), (int)dimension);
167 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
171 public virtual float GetHeightForWidth(float width)
173 float ret = Interop.CustomActorImpl.CustomActorImpl_GetHeightForWidth(swigCPtr, width);
174 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
178 public virtual float GetWidthForHeight(float height)
180 float ret = Interop.CustomActorImpl.CustomActorImpl_GetWidthForHeight(swigCPtr, height);
181 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
185 public virtual bool RelayoutDependentOnChildren(DimensionType dimension)
187 bool ret = Interop.CustomActorImpl.CustomActorImpl_RelayoutDependentOnChildren__SWIG_0(swigCPtr, (int)dimension);
188 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
192 public virtual bool RelayoutDependentOnChildren()
194 bool ret = Interop.CustomActorImpl.CustomActorImpl_RelayoutDependentOnChildren__SWIG_1(swigCPtr);
195 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
199 public virtual void OnCalculateRelayoutSize(DimensionType dimension)
201 Interop.CustomActorImpl.CustomActorImpl_OnCalculateRelayoutSize(swigCPtr, (int)dimension);
202 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
205 public virtual void OnLayoutNegotiated(float size, DimensionType dimension)
207 Interop.CustomActorImpl.CustomActorImpl_OnLayoutNegotiated(swigCPtr, size, (int)dimension);
208 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
211 public bool RequiresTouchEvents()
213 bool ret = Interop.CustomActorImpl.CustomActorImpl_RequiresTouchEvents(swigCPtr);
214 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
218 public bool RequiresHoverEvents()
220 bool ret = Interop.CustomActorImpl.CustomActorImpl_RequiresHoverEvents(swigCPtr);
221 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
225 public bool RequiresWheelEvents()
227 bool ret = Interop.CustomActorImpl.CustomActorImpl_RequiresWheelEvents(swigCPtr);
228 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
232 public bool IsRelayoutEnabled()
234 bool ret = Interop.CustomActorImpl.CustomActorImpl_IsRelayoutEnabled(swigCPtr);
235 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();