2 * Copyright(c) 2021 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 System.ComponentModel;
19 using Tizen.NUI.Binding;
23 public partial class ItemView
28 [EditorBrowsable(EditorBrowsableState.Never)]
29 public static new readonly BindableProperty LayoutProperty = BindableProperty.Create(nameof(Layout), typeof(Tizen.NUI.PropertyArray), typeof(ItemView), null, propertyChanged: (bindable, oldValue, newValue) =>
31 var instance = (Tizen.NUI.ItemView)bindable;
34 instance.InternalLayout = (Tizen.NUI.PropertyArray)newValue;
37 defaultValueCreator: (bindable) =>
39 var instance = (Tizen.NUI.ItemView)bindable;
40 return instance.InternalLayout;
44 /// MinimumSwipeSpeedProperty
46 [EditorBrowsable(EditorBrowsableState.Never)]
47 public static readonly BindableProperty MinimumSwipeSpeedProperty = BindableProperty.Create(nameof(MinimumSwipeSpeed), typeof(float), typeof(ItemView), default(float), propertyChanged: (bindable, oldValue, newValue) =>
49 var instance = (Tizen.NUI.ItemView)bindable;
52 instance.InternalMinimumSwipeSpeed = (float)newValue;
55 defaultValueCreator: (bindable) =>
57 var instance = (Tizen.NUI.ItemView)bindable;
58 return instance.InternalMinimumSwipeSpeed;
62 /// MinimumSwipeDistanceProperty
64 [EditorBrowsable(EditorBrowsableState.Never)]
65 public static readonly BindableProperty MinimumSwipeDistanceProperty = BindableProperty.Create(nameof(MinimumSwipeDistance), typeof(float), typeof(ItemView), default(float), propertyChanged: (bindable, oldValue, newValue) =>
67 var instance = (Tizen.NUI.ItemView)bindable;
70 instance.InternalMinimumSwipeDistance = (float)newValue;
73 defaultValueCreator: (bindable) =>
75 var instance = (Tizen.NUI.ItemView)bindable;
76 return instance.InternalMinimumSwipeDistance;
80 /// WheelScrollDistanceStepProperty
82 [EditorBrowsable(EditorBrowsableState.Never)]
83 public static readonly BindableProperty WheelScrollDistanceStepProperty = BindableProperty.Create(nameof(WheelScrollDistanceStep), typeof(float), typeof(ItemView), default(float), propertyChanged: (bindable, oldValue, newValue) =>
85 var instance = (Tizen.NUI.ItemView)bindable;
88 instance.InternalWheelScrollDistanceStep = (float)newValue;
91 defaultValueCreator: (bindable) =>
93 var instance = (Tizen.NUI.ItemView)bindable;
94 return instance.InternalWheelScrollDistanceStep;
98 /// SnapToItemEnabledProperty
100 [EditorBrowsable(EditorBrowsableState.Never)]
101 public static readonly BindableProperty SnapToItemEnabledProperty = BindableProperty.Create(nameof(SnapToItemEnabled), typeof(bool), typeof(ItemView), true, propertyChanged: (bindable, oldValue, newValue) =>
103 var instance = (Tizen.NUI.ItemView)bindable;
104 if (newValue != null)
106 instance.InternalSnapToItemEnabled = (bool)newValue;
109 defaultValueCreator: (bindable) =>
111 var instance = (Tizen.NUI.ItemView)bindable;
112 return instance.InternalSnapToItemEnabled;
116 /// RefreshIntervalProperty
118 [EditorBrowsable(EditorBrowsableState.Never)]
119 public static readonly BindableProperty RefreshIntervalProperty = BindableProperty.Create(nameof(RefreshInterval), typeof(float), typeof(ItemView), default(float), propertyChanged: (bindable, oldValue, newValue) =>
121 var instance = (Tizen.NUI.ItemView)bindable;
122 if (newValue != null)
124 instance.InternalRefreshInterval = (float)newValue;
127 defaultValueCreator: (bindable) =>
129 var instance = (Tizen.NUI.ItemView)bindable;
130 return instance.InternalRefreshInterval;
134 /// LayoutPositionProperty
136 [EditorBrowsable(EditorBrowsableState.Never)]
137 public static readonly BindableProperty LayoutPositionProperty = BindableProperty.Create(nameof(LayoutPosition), typeof(float), typeof(ItemView), default(float), propertyChanged: (bindable, oldValue, newValue) =>
139 var instance = (Tizen.NUI.ItemView)bindable;
140 if (newValue != null)
142 instance.InternalLayoutPosition = (float)newValue;
145 defaultValueCreator: (bindable) =>
147 var instance = (Tizen.NUI.ItemView)bindable;
148 return instance.InternalLayoutPosition;
152 /// ScrollSpeedProperty
154 [EditorBrowsable(EditorBrowsableState.Never)]
155 public static readonly BindableProperty ScrollSpeedProperty = BindableProperty.Create(nameof(ScrollSpeed), typeof(float), typeof(ItemView), default(float), propertyChanged: (bindable, oldValue, newValue) =>
157 var instance = (Tizen.NUI.ItemView)bindable;
158 if (newValue != null)
160 instance.InternalScrollSpeed = (float)newValue;
163 defaultValueCreator: (bindable) =>
165 var instance = (Tizen.NUI.ItemView)bindable;
166 return instance.InternalScrollSpeed;
170 /// OvershootProperty
172 [EditorBrowsable(EditorBrowsableState.Never)]
173 public static readonly BindableProperty OvershootProperty = BindableProperty.Create(nameof(Overshoot), typeof(float), typeof(ItemView), default(float), propertyChanged: (bindable, oldValue, newValue) =>
175 var instance = (Tizen.NUI.ItemView)bindable;
176 if (newValue != null)
178 instance.InternalOvershoot = (float)newValue;
181 defaultValueCreator: (bindable) =>
183 var instance = (Tizen.NUI.ItemView)bindable;
184 return instance.InternalOvershoot;
188 /// ScrollDirectionProperty
190 [EditorBrowsable(EditorBrowsableState.Never)]
191 public static readonly BindableProperty ScrollDirectionProperty = BindableProperty.Create(nameof(ScrollDirection), typeof(Tizen.NUI.Vector2), typeof(ItemView), null, propertyChanged: (bindable, oldValue, newValue) =>
193 var instance = (Tizen.NUI.ItemView)bindable;
194 if (newValue != null)
196 instance.InternalScrollDirection = (Tizen.NUI.Vector2)newValue;
199 defaultValueCreator: (bindable) =>
201 var instance = (Tizen.NUI.ItemView)bindable;
202 return instance.InternalScrollDirection;
206 /// LayoutOrientationProperty
208 [EditorBrowsable(EditorBrowsableState.Never)]
209 public static readonly BindableProperty LayoutOrientationProperty = BindableProperty.Create(nameof(LayoutOrientation), typeof(int), typeof(ItemView), 0, propertyChanged: (bindable, oldValue, newValue) =>
211 var instance = (Tizen.NUI.ItemView)bindable;
212 if (newValue != null)
214 instance.InternalLayoutOrientation = (int)newValue;
217 defaultValueCreator: (bindable) =>
219 var instance = (Tizen.NUI.ItemView)bindable;
220 return instance.InternalLayoutOrientation;
224 /// ScrollContentSizeProperty
226 [EditorBrowsable(EditorBrowsableState.Never)]
227 public static readonly BindableProperty ScrollContentSizeProperty = BindableProperty.Create(nameof(ScrollContentSize), typeof(float), typeof(ItemView), default(float), propertyChanged: (bindable, oldValue, newValue) =>
229 var instance = (Tizen.NUI.ItemView)bindable;
230 if (newValue != null)
232 instance.InternalScrollContentSize = (float)newValue;
235 defaultValueCreator: (bindable) =>
237 var instance = (Tizen.NUI.ItemView)bindable;
238 return instance.InternalScrollContentSize;