2 * Copyright(c) 2017 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.
18 using Tizen.NUI.BaseComponents;
19 using System.ComponentModel;
24 /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API.
25 [EditorBrowsable(EditorBrowsableState.Never)]
26 public class ItemLayout : RefObject
28 private global::System.Runtime.InteropServices.HandleRef swigCPtr;
30 internal ItemLayout(global::System.IntPtr cPtr, bool cMemoryOwn) : base(Interop.ItemLayout.ItemLayout_SWIGUpcast(cPtr), cMemoryOwn)
32 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
35 internal static global::System.Runtime.InteropServices.HandleRef getCPtr(ItemLayout obj)
37 return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
40 /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API.
41 [EditorBrowsable(EditorBrowsableState.Never)]
42 protected override void Dispose(DisposeTypes type)
49 if (type == DisposeTypes.Explicit)
52 //Release your own managed resources here.
53 //You should release all of your own disposable objects here.
57 //Release your own unmanaged resources here.
58 //You should not access any managed member here except static instance.
59 //because the execution order of Finalizes is non-deterministic.
61 if (swigCPtr.Handle != global::System.IntPtr.Zero)
66 Interop.ItemLayout.delete_ItemLayout(swigCPtr);
68 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
75 /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API.
76 [EditorBrowsable(EditorBrowsableState.Never)]
77 public void SetLayoutProperties(PropertyMap properties)
79 Interop.ItemLayout.ItemLayout_SetLayoutProperties(swigCPtr, PropertyMap.getCPtr(properties));
80 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
83 /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API.
84 [EditorBrowsable(EditorBrowsableState.Never)]
85 public PropertyMap GetLayoutProperties()
87 PropertyMap ret = new PropertyMap(Interop.ItemLayout.ItemLayout_GetLayoutProperties(swigCPtr), true);
88 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
92 /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API.
93 [EditorBrowsable(EditorBrowsableState.Never)]
94 public void GetItemSize(uint itemId, Vector3 layoutSize, Vector3 itemSize)
96 Interop.ItemLayout.ItemLayout_GetItemSize(swigCPtr, itemId, Vector3.getCPtr(layoutSize), Vector3.getCPtr(itemSize));
97 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
100 /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API.
101 [EditorBrowsable(EditorBrowsableState.Never)]
102 public void SetItemSize(Vector3 itemSize)
104 Interop.ItemLayout.ItemLayout_SetItemSize(swigCPtr, Vector3.getCPtr(itemSize));
105 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
108 /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API.
109 [EditorBrowsable(EditorBrowsableState.Never)]
110 public virtual float GetMinimumLayoutPosition(uint numberOfItems, Vector3 layoutSize)
112 float ret = Interop.ItemLayout.ItemLayout_GetMinimumLayoutPosition(swigCPtr, numberOfItems, Vector3.getCPtr(layoutSize));
113 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
117 /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API.
118 [EditorBrowsable(EditorBrowsableState.Never)]
119 public virtual float GetClosestAnchorPosition(float layoutPosition)
121 float ret = Interop.ItemLayout.ItemLayout_GetClosestAnchorPosition(swigCPtr, layoutPosition);
122 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
126 /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API.
127 [EditorBrowsable(EditorBrowsableState.Never)]
128 public virtual float GetItemScrollToPosition(uint itemId)
130 float ret = Interop.ItemLayout.ItemLayout_GetItemScrollToPosition(swigCPtr, itemId);
131 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
135 /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API.
136 [EditorBrowsable(EditorBrowsableState.Never)]
137 public virtual ItemRange GetItemsWithinArea(float firstItemPosition, Vector3 layoutSize)
139 ItemRange ret = new ItemRange(Interop.ItemLayout.ItemLayout_GetItemsWithinArea(swigCPtr, firstItemPosition, Vector3.getCPtr(layoutSize)), true);
140 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
144 /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API.
145 [EditorBrowsable(EditorBrowsableState.Never)]
146 public virtual float GetClosestOnScreenLayoutPosition(int itemID, float currentLayoutPosition, Vector3 layoutSize)
148 float ret = Interop.ItemLayout.ItemLayout_GetClosestOnScreenLayoutPosition(swigCPtr, itemID, currentLayoutPosition, Vector3.getCPtr(layoutSize));
149 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
153 /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API.
154 [EditorBrowsable(EditorBrowsableState.Never)]
155 public virtual uint GetReserveItemCount(Vector3 layoutSize)
157 uint ret = Interop.ItemLayout.ItemLayout_GetReserveItemCount(swigCPtr, Vector3.getCPtr(layoutSize));
158 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
162 /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API.
163 [EditorBrowsable(EditorBrowsableState.Never)]
164 public virtual void GetDefaultItemSize(uint itemId, Vector3 layoutSize, Vector3 itemSize)
166 Interop.ItemLayout.ItemLayout_GetDefaultItemSize(swigCPtr, itemId, Vector3.getCPtr(layoutSize), Vector3.getCPtr(itemSize));
167 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
170 /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API.
171 [EditorBrowsable(EditorBrowsableState.Never)]
172 public virtual Degree GetScrollDirection()
174 Degree ret = new Degree(Interop.ItemLayout.ItemLayout_GetScrollDirection(swigCPtr), true);
175 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
179 /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API.
180 [EditorBrowsable(EditorBrowsableState.Never)]
181 public virtual float GetScrollSpeedFactor()
183 float ret = Interop.ItemLayout.ItemLayout_GetScrollSpeedFactor(swigCPtr);
184 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
188 /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API.
189 [EditorBrowsable(EditorBrowsableState.Never)]
190 public virtual float GetMaximumSwipeSpeed()
192 float ret = Interop.ItemLayout.ItemLayout_GetMaximumSwipeSpeed(swigCPtr);
193 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
197 /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API.
198 [EditorBrowsable(EditorBrowsableState.Never)]
199 public virtual float GetItemFlickAnimationDuration()
201 float ret = Interop.ItemLayout.ItemLayout_GetItemFlickAnimationDuration(swigCPtr);
202 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
206 /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API.
207 [EditorBrowsable(EditorBrowsableState.Never)]
208 public virtual int GetNextFocusItemID(int itemID, int maxItems, View.FocusDirection direction, bool loopEnabled)
210 int ret = Interop.ItemLayout.ItemLayout_GetNextFocusItemID(swigCPtr, itemID, maxItems, (int)direction, loopEnabled);
211 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
215 /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API.
216 [EditorBrowsable(EditorBrowsableState.Never)]
217 public virtual float GetFlickSpeedFactor()
219 float ret = Interop.ItemLayout.ItemLayout_GetFlickSpeedFactor(swigCPtr);
220 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
224 /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API.
225 [EditorBrowsable(EditorBrowsableState.Never)]
226 public virtual void ApplyConstraints(View view, int itemId, Vector3 layoutSize, View itemView)
228 Interop.ItemLayout.ItemLayout_ApplyConstraints(swigCPtr, View.getCPtr(view), itemId, Vector3.getCPtr(layoutSize), View.getCPtr(itemView));
229 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
232 /// This will be public opened in next tizen after ACR done. Before ACR, need to be hidden as inhouse API.
233 [EditorBrowsable(EditorBrowsableState.Never)]
234 public virtual Vector3 GetItemPosition(int itemID, float currentLayoutPosition, Vector3 layoutSize)
236 Vector3 ret = new Vector3(Interop.ItemLayout.ItemLayout_GetItemPosition(swigCPtr, itemID, currentLayoutPosition, Vector3.getCPtr(layoutSize)), true);
237 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();