From d3dd1ab866cb613802e24eda4cbd3a0a8fb82a77 Mon Sep 17 00:00:00 2001 From: Clarik <54880771+Clarik@users.noreply.github.com> Date: Tue, 23 Apr 2024 14:30:05 +0700 Subject: [PATCH] [NUI] ScrollViewBindableProperty changes (#6095) --- src/Tizen.NUI/src/public/Utility/ScrollView.cs | 371 +++++++++++++++++++-- .../public/Utility/ScrollViewBindableProperty.cs | 215 ++++++++---- 2 files changed, 478 insertions(+), 108 deletions(-) diff --git a/src/Tizen.NUI/src/public/Utility/ScrollView.cs b/src/Tizen.NUI/src/public/Utility/ScrollView.cs index 69b6b8c..05a6395 100755 --- a/src/Tizen.NUI/src/public/Utility/ScrollView.cs +++ b/src/Tizen.NUI/src/public/Utility/ScrollView.cs @@ -17,6 +17,8 @@ using System.ComponentModel; using Tizen.NUI.BaseComponents; +using Tizen.NUI; +using Tizen.NUI.Binding; namespace Tizen.NUI { @@ -27,6 +29,49 @@ namespace Tizen.NUI public partial class ScrollView : Scrollable { + static ScrollView() + { + if(NUIApplication.IsUsingXaml) + { + WrapEnabledProperty = BindableProperty.Create(nameof(WrapEnabled), typeof(bool), typeof(ScrollView), false, propertyChanged: SetInternalWrapEnabledProperty, defaultValueCreator: GetInternalWrapEnabledProperty); + + PanningEnabledProperty = BindableProperty.Create(nameof(PanningEnabled), typeof(bool), typeof(ScrollView), false, propertyChanged: SetInternalPanningEnabledProperty, defaultValueCreator: GetInternalPanningEnabledProperty); + + AxisAutoLockEnabledProperty = BindableProperty.Create(nameof(AxisAutoLockEnabled), typeof(bool), typeof(ScrollView), false, propertyChanged: SetInternalAxisAutoLockEnabledProperty, defaultValueCreator: GetInternalAxisAutoLockEnabledProperty); + + WheelScrollDistanceStepProperty = BindableProperty.Create(nameof(WheelScrollDistanceStep), typeof(Vector2), typeof(ScrollView), Vector2.Zero, propertyChanged: SetInternalWheelScrollDistanceStepProperty, defaultValueCreator: GetInternalWheelScrollDistanceStepProperty); + + ScrollPositionProperty = BindableProperty.Create(nameof(ScrollPosition), typeof(Vector2), typeof(ScrollView), Vector2.Zero, propertyChanged: SetInternalScrollPositionProperty, defaultValueCreator: GetInternalScrollPositionProperty); + + ScrollPrePositionProperty = BindableProperty.Create(nameof(ScrollPrePosition), typeof(Vector2), typeof(ScrollView), Vector2.Zero, propertyChanged: SetInternalScrollPrePositionProperty, defaultValueCreator: GetInternalScrollPrePositionProperty); + + ScrollPrePositionMaxProperty = BindableProperty.Create(nameof(ScrollPrePositionMax), typeof(Vector2), typeof(ScrollView), Vector2.Zero, propertyChanged: SetInternalScrollPrePositionMaxProperty, defaultValueCreator: GetInternalScrollPrePositionMaxProperty); + + OvershootXProperty = BindableProperty.Create(nameof(OvershootX), typeof(float), typeof(ScrollView), default(float), propertyChanged: SetInternalOvershootXProperty, defaultValueCreator: GetInternalOvershootXProperty); + + OvershootYProperty = BindableProperty.Create(nameof(OvershootY), typeof(float), typeof(ScrollView), default(float), propertyChanged: SetInternalOvershootYProperty, defaultValueCreator: GetInternalOvershootYProperty); + + ScrollFinalProperty = BindableProperty.Create(nameof(ScrollFinal), typeof(Vector2), typeof(ScrollView), Vector2.Zero, propertyChanged: SetInternalScrollFinalProperty, defaultValueCreator: GetInternalScrollFinalProperty); + + WrapProperty = BindableProperty.Create(nameof(Wrap), typeof(bool), typeof(ScrollView), false, propertyChanged: SetInternalWrapProperty, defaultValueCreator: GetInternalWrapProperty); + + PanningProperty = BindableProperty.Create(nameof(Panning), typeof(bool), typeof(ScrollView), false, propertyChanged: SetInternalPanningProperty, defaultValueCreator: GetInternalPanningProperty); + + ScrollingProperty = BindableProperty.Create(nameof(Scrolling), typeof(bool), typeof(ScrollView), false, propertyChanged: SetInternalScrollingProperty, defaultValueCreator: GetInternalScrollingProperty); + + ScrollDomainSizeProperty = BindableProperty.Create(nameof(ScrollDomainSize), typeof(Vector2), typeof(ScrollView), Vector2.Zero, propertyChanged: SetInternalScrollDomainSizeProperty, defaultValueCreator: GetInternalScrollDomainSizeProperty); + + ScrollDomainOffsetProperty = BindableProperty.Create(nameof(ScrollDomainOffset), typeof(Vector2), typeof(ScrollView), Vector2.Zero, propertyChanged: SetInternalScrollDomainOffsetProperty, defaultValueCreator: GetInternalScrollDomainOffsetProperty); + + ScrollPositionDeltaProperty = BindableProperty.Create(nameof(ScrollPositionDelta), typeof(Vector2), typeof(ScrollView), Vector2.Zero, propertyChanged: SetInternalScrollPositionDeltaProperty, defaultValueCreator: GetInternalScrollPositionDeltaProperty); + + StartPagePositionProperty = BindableProperty.Create(nameof(StartPagePosition), typeof(Vector3), typeof(ScrollView), Vector3.Zero, propertyChanged: SetInternalStartPagePositionProperty, defaultValueCreator: GetInternalStartPagePositionProperty); + + ScrollModeProperty = BindableProperty.Create(nameof(ScrollMode), typeof(PropertyMap), typeof(ScrollView), new PropertyMap(), propertyChanged: SetInternalScrollModeProperty, defaultValueCreator: GetInternalScrollModeProperty); + + } + } + /// /// Create an instance of ScrollView. /// @@ -48,11 +93,25 @@ namespace Tizen.NUI { get { - return (bool)GetValue(WrapEnabledProperty); + if (NUIApplication.IsUsingXaml) + { + return (bool)GetValue(WrapEnabledProperty); + } + else + { + return (bool)GetInternalWrapEnabledProperty(this); + } } set { - SetValue(WrapEnabledProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(WrapEnabledProperty, value); + } + else + { + SetInternalWrapEnabledProperty(this, null, value); + } } } @@ -64,11 +123,25 @@ namespace Tizen.NUI { get { - return (bool)GetValue(PanningEnabledProperty); + if (NUIApplication.IsUsingXaml) + { + return (bool)GetValue(PanningEnabledProperty); + } + else + { + return (bool)GetInternalPanningEnabledProperty(this); + } } set { - SetValue(PanningEnabledProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(PanningEnabledProperty, value); + } + else + { + SetInternalPanningEnabledProperty(this, null, value); + } } } @@ -80,11 +153,25 @@ namespace Tizen.NUI { get { - return (bool)GetValue(AxisAutoLockEnabledProperty); + if (NUIApplication.IsUsingXaml) + { + return (bool)GetValue(AxisAutoLockEnabledProperty); + } + else + { + return (bool)GetInternalAxisAutoLockEnabledProperty(this); + } } set { - SetValue(AxisAutoLockEnabledProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(AxisAutoLockEnabledProperty, value); + } + else + { + SetInternalAxisAutoLockEnabledProperty(this, null, value); + } } } @@ -96,11 +183,25 @@ namespace Tizen.NUI { get { - return (Vector2)GetValue(WheelScrollDistanceStepProperty); + if (NUIApplication.IsUsingXaml) + { + return (Vector2)GetValue(WheelScrollDistanceStepProperty); + } + else + { + return (Vector2)GetInternalWheelScrollDistanceStepProperty(this); + } } set { - SetValue(WheelScrollDistanceStepProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(WheelScrollDistanceStepProperty, value); + } + else + { + SetInternalWheelScrollDistanceStepProperty(this, null, value); + } } } @@ -112,11 +213,25 @@ namespace Tizen.NUI { get { - return (Vector2)GetValue(ScrollPositionProperty); + if (NUIApplication.IsUsingXaml) + { + return (Vector2)GetValue(ScrollPositionProperty); + } + else + { + return (Vector2)GetInternalScrollPositionProperty(this); + } } set { - SetValue(ScrollPositionProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(ScrollPositionProperty, value); + } + else + { + SetInternalScrollPositionProperty(this, null, value); + } } } @@ -128,11 +243,25 @@ namespace Tizen.NUI { get { - return (Vector2)GetValue(ScrollPrePositionProperty); + if (NUIApplication.IsUsingXaml) + { + return (Vector2)GetValue(ScrollPrePositionProperty); + } + else + { + return (Vector2)GetInternalScrollPrePositionProperty(this); + } } set { - SetValue(ScrollPrePositionProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(ScrollPrePositionProperty, value); + } + else + { + SetInternalScrollPrePositionProperty(this, null, value); + } } } @@ -144,11 +273,26 @@ namespace Tizen.NUI { get { - return (Vector2)GetValue(ScrollPrePositionMaxProperty); + if (NUIApplication.IsUsingXaml) + { + return (Vector2)GetValue(ScrollPrePositionMaxProperty); + } + else + { + return (Vector2)GetInternalScrollPrePositionMaxProperty(this); + } } set { - SetValue(ScrollPrePositionMaxProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(ScrollPrePositionMaxProperty, value); + + } + else + { + SetInternalScrollPrePositionMaxProperty(this, null, value); + } } } @@ -160,11 +304,25 @@ namespace Tizen.NUI { get { - return (float)GetValue(OvershootXProperty); + if (NUIApplication.IsUsingXaml) + { + return (float)GetValue(OvershootXProperty); + } + else + { + return (float)GetInternalOvershootXProperty(this); + } } set { - SetValue(OvershootXProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(OvershootXProperty, value); + } + else + { + SetInternalOvershootXProperty(this, null, value); + } } } @@ -176,11 +334,25 @@ namespace Tizen.NUI { get { - return (float)GetValue(OvershootYProperty); + if (NUIApplication.IsUsingXaml) + { + return (float)GetValue(OvershootYProperty); + } + else + { + return (float)GetInternalOvershootYProperty(this); + } } set { - SetValue(OvershootYProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(OvershootYProperty, value); + } + else + { + SetInternalOvershootYProperty(this, null, value); + } } } @@ -192,11 +364,25 @@ namespace Tizen.NUI { get { - return (Vector2)GetValue(ScrollFinalProperty); + if (NUIApplication.IsUsingXaml) + { + return (Vector2)GetValue(ScrollFinalProperty); + } + else + { + return (Vector2)GetInternalScrollFinalProperty(this); + } } set { - SetValue(ScrollFinalProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(ScrollFinalProperty, value); + } + else + { + SetInternalScrollFinalProperty(this, null, value); + } } } @@ -208,11 +394,26 @@ namespace Tizen.NUI { get { - return (bool)GetValue(WrapProperty); + if (NUIApplication.IsUsingXaml) + { + return (bool)GetValue(WrapProperty); + } + else + { + return (bool)GetInternalWrapProperty(this); + } } set { - SetValue(WrapProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(WrapProperty, value); + + } + else + { + SetInternalWrapProperty(this, null, value); + } } } @@ -224,11 +425,25 @@ namespace Tizen.NUI { get { - return (bool)GetValue(PanningProperty); + if (NUIApplication.IsUsingXaml) + { + return (bool)GetValue(PanningProperty); + } + else + { + return (bool)GetInternalPanningProperty(this); + } } set { - SetValue(PanningProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(PanningProperty, value); + } + else + { + SetInternalPanningProperty(this, null, value); + } } } @@ -240,11 +455,25 @@ namespace Tizen.NUI { get { - return (bool)GetValue(ScrollingProperty); + if (NUIApplication.IsUsingXaml) + { + return (bool)GetValue(ScrollingProperty); + } + else + { + return (bool)GetInternalScrollingProperty(this); + } } set { - SetValue(ScrollingProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(ScrollingProperty, value); + } + else + { + SetInternalScrollingProperty(this, null, value); + } } } @@ -256,11 +485,25 @@ namespace Tizen.NUI { get { - return (Vector2)GetValue(ScrollDomainSizeProperty); + if (NUIApplication.IsUsingXaml) + { + return (Vector2)GetValue(ScrollDomainSizeProperty); + } + else + { + return (Vector2)GetInternalScrollDomainSizeProperty(this); + } } set { - SetValue(ScrollDomainSizeProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(ScrollDomainSizeProperty, value); + } + else + { + SetInternalScrollDomainSizeProperty(this, null, value); + } } } @@ -272,11 +515,25 @@ namespace Tizen.NUI { get { - return (Vector2)GetValue(ScrollDomainOffsetProperty); + if (NUIApplication.IsUsingXaml) + { + return (Vector2)GetValue(ScrollDomainOffsetProperty); + } + else + { + return (Vector2)GetInternalScrollDomainOffsetProperty(this); + } } set { - SetValue(ScrollDomainOffsetProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(ScrollDomainOffsetProperty, value); + } + else + { + SetInternalScrollDomainOffsetProperty(this, null, value); + } } } @@ -288,11 +545,25 @@ namespace Tizen.NUI { get { - return (Vector2)GetValue(ScrollPositionDeltaProperty); + if (NUIApplication.IsUsingXaml) + { + return (Vector2)GetValue(ScrollPositionDeltaProperty); + } + else + { + return (Vector2)GetInternalScrollPositionDeltaProperty(this); + } } set { - SetValue(ScrollPositionDeltaProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(ScrollPositionDeltaProperty, value); + } + else + { + SetInternalScrollPositionDeltaProperty(this, null, value); + } } } @@ -304,11 +575,25 @@ namespace Tizen.NUI { get { - return (Vector3)GetValue(StartPagePositionProperty); + if (NUIApplication.IsUsingXaml) + { + return (Vector3)GetValue(StartPagePositionProperty); + } + else + { + return (Vector3)GetInternalStartPagePositionProperty(this); + } } set { - SetValue(StartPagePositionProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(StartPagePositionProperty, value); + } + else + { + SetInternalStartPagePositionProperty(this, null, value); + } } } @@ -321,11 +606,25 @@ namespace Tizen.NUI { get { - return (PropertyMap)GetValue(ScrollModeProperty); + if (NUIApplication.IsUsingXaml) + { + return (PropertyMap)GetValue(ScrollModeProperty); + } + else + { + return (PropertyMap)GetInternalScrollModeProperty(this); + } } set { - SetValue(ScrollModeProperty, value); + if (NUIApplication.IsUsingXaml) + { + SetValue(ScrollModeProperty, value); + } + else + { + SetInternalScrollModeProperty(this, null, value); + } } } diff --git a/src/Tizen.NUI/src/public/Utility/ScrollViewBindableProperty.cs b/src/Tizen.NUI/src/public/Utility/ScrollViewBindableProperty.cs index f7521ba..4bd11bd 100755 --- a/src/Tizen.NUI/src/public/Utility/ScrollViewBindableProperty.cs +++ b/src/Tizen.NUI/src/public/Utility/ScrollViewBindableProperty.cs @@ -27,293 +27,364 @@ namespace Tizen.NUI public partial class ScrollView { [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty WrapEnabledProperty = BindableProperty.Create(nameof(WrapEnabled), typeof(bool), typeof(ScrollView), false, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty WrapEnabledProperty = null; + + internal static void SetInternalWrapEnabledProperty(BindableObject bindable, object oldValue, object newValue) { var scrollView = (ScrollView)bindable; if (newValue != null) { Tizen.NUI.Object.SetProperty((System.Runtime.InteropServices.HandleRef)scrollView.SwigCPtr, ScrollView.Property.WrapEnabled, new Tizen.NUI.PropertyValue((bool)newValue)); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + + internal static object GetInternalWrapEnabledProperty(BindableObject bindable) { var scrollView = (ScrollView)bindable; bool temp = false; Tizen.NUI.Object.GetProperty((System.Runtime.InteropServices.HandleRef)scrollView.SwigCPtr, ScrollView.Property.WrapEnabled).Get(out temp); return temp; - })); + } + [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty PanningEnabledProperty = BindableProperty.Create(nameof(PanningEnabled), typeof(bool), typeof(ScrollView), false, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty PanningEnabledProperty = null; + + internal static void SetInternalPanningEnabledProperty(BindableObject bindable, object oldValue, object newValue) { var scrollView = (ScrollView)bindable; if (newValue != null) { Tizen.NUI.Object.SetProperty((System.Runtime.InteropServices.HandleRef)scrollView.SwigCPtr, ScrollView.Property.PanningEnabled, new Tizen.NUI.PropertyValue((bool)newValue)); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + + internal static object GetInternalPanningEnabledProperty(BindableObject bindable) { var scrollView = (ScrollView)bindable; bool temp = false; Tizen.NUI.Object.GetProperty((System.Runtime.InteropServices.HandleRef)scrollView.SwigCPtr, ScrollView.Property.PanningEnabled).Get(out temp); return temp; - })); + } + [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty AxisAutoLockEnabledProperty = BindableProperty.Create(nameof(AxisAutoLockEnabled), typeof(bool), typeof(ScrollView), false, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty AxisAutoLockEnabledProperty = null; + + internal static void SetInternalAxisAutoLockEnabledProperty(BindableObject bindable, object oldValue, object newValue) { var scrollView = (ScrollView)bindable; if (newValue != null) { Tizen.NUI.Object.SetProperty((System.Runtime.InteropServices.HandleRef)scrollView.SwigCPtr, ScrollView.Property.AxisAutoLockEnabled, new Tizen.NUI.PropertyValue((bool)newValue)); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + + internal static object GetInternalAxisAutoLockEnabledProperty(BindableObject bindable) { var scrollView = (ScrollView)bindable; bool temp = false; Tizen.NUI.Object.GetProperty((System.Runtime.InteropServices.HandleRef)scrollView.SwigCPtr, ScrollView.Property.AxisAutoLockEnabled).Get(out temp); return temp; - })); + } + [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty WheelScrollDistanceStepProperty = BindableProperty.Create(nameof(WheelScrollDistanceStep), typeof(Vector2), typeof(ScrollView), Vector2.Zero, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty WheelScrollDistanceStepProperty = null; + + internal static void SetInternalWheelScrollDistanceStepProperty(BindableObject bindable, object oldValue, object newValue) { var scrollView = (ScrollView)bindable; if (newValue != null) { Tizen.NUI.Object.SetProperty((System.Runtime.InteropServices.HandleRef)scrollView.SwigCPtr, ScrollView.Property.WheelScrollDistanceStep, new Tizen.NUI.PropertyValue((Vector2)newValue)); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + + internal static object GetInternalWheelScrollDistanceStepProperty(BindableObject bindable) { var scrollView = (ScrollView)bindable; Vector2 temp = new Vector2(0.0f, 0.0f); Tizen.NUI.Object.GetProperty((System.Runtime.InteropServices.HandleRef)scrollView.SwigCPtr, ScrollView.Property.WheelScrollDistanceStep).Get(temp); return temp; - })); + } + [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty ScrollPositionProperty = BindableProperty.Create(nameof(ScrollPosition), typeof(Vector2), typeof(ScrollView), Vector2.Zero, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty ScrollPositionProperty = null; + + internal static void SetInternalScrollPositionProperty(BindableObject bindable, object oldValue, object newValue) { var scrollView = (ScrollView)bindable; if (newValue != null) { Tizen.NUI.Object.SetProperty((System.Runtime.InteropServices.HandleRef)scrollView.SwigCPtr, ScrollView.Property.ScrollPosition, new Tizen.NUI.PropertyValue((Vector2)newValue)); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + + internal static object GetInternalScrollPositionProperty(BindableObject bindable) { var scrollView = (ScrollView)bindable; Vector2 temp = new Vector2(0.0f, 0.0f); Tizen.NUI.Object.GetProperty((System.Runtime.InteropServices.HandleRef)scrollView.SwigCPtr, ScrollView.Property.ScrollPosition).Get(temp); return temp; - })); + } + [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty ScrollPrePositionProperty = BindableProperty.Create(nameof(ScrollPrePosition), typeof(Vector2), typeof(ScrollView), Vector2.Zero, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty ScrollPrePositionProperty = null; + + internal static void SetInternalScrollPrePositionProperty(BindableObject bindable, object oldValue, object newValue) { var scrollView = (ScrollView)bindable; if (newValue != null) { Tizen.NUI.Object.SetProperty((System.Runtime.InteropServices.HandleRef)scrollView.SwigCPtr, ScrollView.Property.ScrollPrePosition, new Tizen.NUI.PropertyValue((Vector2)newValue)); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + + internal static object GetInternalScrollPrePositionProperty(BindableObject bindable) { var scrollView = (ScrollView)bindable; Vector2 temp = new Vector2(0.0f, 0.0f); Tizen.NUI.Object.GetProperty((System.Runtime.InteropServices.HandleRef)scrollView.SwigCPtr, ScrollView.Property.ScrollPrePosition).Get(temp); return temp; - })); + } + [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty ScrollPrePositionMaxProperty = BindableProperty.Create(nameof(ScrollPrePositionMax), typeof(Vector2), typeof(ScrollView), Vector2.Zero, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty ScrollPrePositionMaxProperty = null; + + internal static void SetInternalScrollPrePositionMaxProperty(BindableObject bindable, object oldValue, object newValue) { var scrollView = (ScrollView)bindable; if (newValue != null) { Tizen.NUI.Object.SetProperty((System.Runtime.InteropServices.HandleRef)scrollView.SwigCPtr, ScrollView.Property.ScrollPrePositionMax, new Tizen.NUI.PropertyValue((Vector2)newValue)); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + + internal static object GetInternalScrollPrePositionMaxProperty(BindableObject bindable) { var scrollView = (ScrollView)bindable; Vector2 temp = new Vector2(0.0f, 0.0f); Tizen.NUI.Object.GetProperty((System.Runtime.InteropServices.HandleRef)scrollView.SwigCPtr, ScrollView.Property.ScrollPrePositionMax).Get(temp); return temp; - })); + } + [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty OvershootXProperty = BindableProperty.Create(nameof(OvershootX), typeof(float), typeof(ScrollView), default(float), propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty OvershootXProperty = null; + + internal static void SetInternalOvershootXProperty(BindableObject bindable, object oldValue, object newValue) { var scrollView = (ScrollView)bindable; if (newValue != null) { Tizen.NUI.Object.SetProperty((System.Runtime.InteropServices.HandleRef)scrollView.SwigCPtr, ScrollView.Property.OvershootX, new Tizen.NUI.PropertyValue((float)newValue)); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + + internal static object GetInternalOvershootXProperty(BindableObject bindable) { var scrollView = (ScrollView)bindable; float temp = 0.0f; Tizen.NUI.Object.GetProperty((System.Runtime.InteropServices.HandleRef)scrollView.SwigCPtr, ScrollView.Property.OvershootX).Get(out temp); return temp; - })); + } + [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty OvershootYProperty = BindableProperty.Create(nameof(OvershootY), typeof(float), typeof(ScrollView), default(float), propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty OvershootYProperty = null; + + internal static void SetInternalOvershootYProperty(BindableObject bindable, object oldValue, object newValue) { var scrollView = (ScrollView)bindable; if (newValue != null) { Tizen.NUI.Object.SetProperty((System.Runtime.InteropServices.HandleRef)scrollView.SwigCPtr, ScrollView.Property.OvershootY, new Tizen.NUI.PropertyValue((float)newValue)); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + + internal static object GetInternalOvershootYProperty(BindableObject bindable) { var scrollView = (ScrollView)bindable; float temp = 0.0f; Tizen.NUI.Object.GetProperty((System.Runtime.InteropServices.HandleRef)scrollView.SwigCPtr, ScrollView.Property.OvershootY).Get(out temp); return temp; - })); + } + [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty ScrollFinalProperty = BindableProperty.Create(nameof(ScrollFinal), typeof(Vector2), typeof(ScrollView), Vector2.Zero, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty ScrollFinalProperty = null; + + internal static void SetInternalScrollFinalProperty(BindableObject bindable, object oldValue, object newValue) { var scrollView = (ScrollView)bindable; if (newValue != null) { Tizen.NUI.Object.SetProperty((System.Runtime.InteropServices.HandleRef)scrollView.SwigCPtr, ScrollView.Property.ScrollFinal, new Tizen.NUI.PropertyValue((Vector2)newValue)); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + + internal static object GetInternalScrollFinalProperty(BindableObject bindable) { var scrollView = (ScrollView)bindable; Vector2 temp = new Vector2(0.0f, 0.0f); Tizen.NUI.Object.GetProperty((System.Runtime.InteropServices.HandleRef)scrollView.SwigCPtr, ScrollView.Property.ScrollFinal).Get(temp); return temp; - })); + } + [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty WrapProperty = BindableProperty.Create(nameof(Wrap), typeof(bool), typeof(ScrollView), false, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty WrapProperty = null; + + internal static void SetInternalWrapProperty(BindableObject bindable, object oldValue, object newValue) { var scrollView = (ScrollView)bindable; if (newValue != null) { Tizen.NUI.Object.SetProperty((System.Runtime.InteropServices.HandleRef)scrollView.SwigCPtr, ScrollView.Property.WRAP, new Tizen.NUI.PropertyValue((bool)newValue)); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + + internal static object GetInternalWrapProperty(BindableObject bindable) { var scrollView = (ScrollView)bindable; bool temp = false; Tizen.NUI.Object.GetProperty((System.Runtime.InteropServices.HandleRef)scrollView.SwigCPtr, ScrollView.Property.WRAP).Get(out temp); return temp; - })); + } + [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty PanningProperty = BindableProperty.Create(nameof(Panning), typeof(bool), typeof(ScrollView), false, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty PanningProperty = null; + + internal static void SetInternalPanningProperty(BindableObject bindable, object oldValue, object newValue) { var scrollView = (ScrollView)bindable; if (newValue != null) { Tizen.NUI.Object.SetProperty((System.Runtime.InteropServices.HandleRef)scrollView.SwigCPtr, ScrollView.Property.PANNING, new Tizen.NUI.PropertyValue((bool)newValue)); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + + internal static object GetInternalPanningProperty(BindableObject bindable) { var scrollView = (ScrollView)bindable; bool temp = false; Tizen.NUI.Object.GetProperty((System.Runtime.InteropServices.HandleRef)scrollView.SwigCPtr, ScrollView.Property.PANNING).Get(out temp); return temp; - })); + } + [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty ScrollingProperty = BindableProperty.Create(nameof(Scrolling), typeof(bool), typeof(ScrollView), false, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty ScrollingProperty = null; + + internal static void SetInternalScrollingProperty(BindableObject bindable, object oldValue, object newValue) { var scrollView = (ScrollView)bindable; if (newValue != null) { Tizen.NUI.Object.SetProperty((System.Runtime.InteropServices.HandleRef)scrollView.SwigCPtr, ScrollView.Property.SCROLLING, new Tizen.NUI.PropertyValue((bool)newValue)); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + + internal static object GetInternalScrollingProperty(BindableObject bindable) { var scrollView = (ScrollView)bindable; bool temp = false; Tizen.NUI.Object.GetProperty((System.Runtime.InteropServices.HandleRef)scrollView.SwigCPtr, ScrollView.Property.SCROLLING).Get(out temp); return temp; - })); + } + [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty ScrollDomainSizeProperty = BindableProperty.Create(nameof(ScrollDomainSize), typeof(Vector2), typeof(ScrollView), Vector2.Zero, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty ScrollDomainSizeProperty = null; + + internal static void SetInternalScrollDomainSizeProperty(BindableObject bindable, object oldValue, object newValue) { var scrollView = (ScrollView)bindable; if (newValue != null) { Tizen.NUI.Object.SetProperty((System.Runtime.InteropServices.HandleRef)scrollView.SwigCPtr, ScrollView.Property.ScrollDomainSize, new Tizen.NUI.PropertyValue((Vector2)newValue)); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + + internal static object GetInternalScrollDomainSizeProperty(BindableObject bindable) { var scrollView = (ScrollView)bindable; Vector2 temp = new Vector2(0.0f, 0.0f); Tizen.NUI.Object.GetProperty((System.Runtime.InteropServices.HandleRef)scrollView.SwigCPtr, ScrollView.Property.ScrollDomainSize).Get(temp); return temp; - })); + } + [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty ScrollDomainOffsetProperty = BindableProperty.Create(nameof(ScrollDomainOffset), typeof(Vector2), typeof(ScrollView), Vector2.Zero, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty ScrollDomainOffsetProperty = null; + + internal static void SetInternalScrollDomainOffsetProperty(BindableObject bindable, object oldValue, object newValue) { var scrollView = (ScrollView)bindable; if (newValue != null) { Tizen.NUI.Object.SetProperty((System.Runtime.InteropServices.HandleRef)scrollView.SwigCPtr, ScrollView.Property.ScrollDomainOffset, new Tizen.NUI.PropertyValue((Vector2)newValue)); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + + internal static object GetInternalScrollDomainOffsetProperty(BindableObject bindable) { var scrollView = (ScrollView)bindable; Vector2 temp = new Vector2(0.0f, 0.0f); Tizen.NUI.Object.GetProperty((System.Runtime.InteropServices.HandleRef)scrollView.SwigCPtr, ScrollView.Property.ScrollDomainOffset).Get(temp); return temp; - })); + } + [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty ScrollPositionDeltaProperty = BindableProperty.Create(nameof(ScrollPositionDelta), typeof(Vector2), typeof(ScrollView), Vector2.Zero, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty ScrollPositionDeltaProperty = null; + + internal static void SetInternalScrollPositionDeltaProperty(BindableObject bindable, object oldValue, object newValue) { var scrollView = (ScrollView)bindable; if (newValue != null) { Tizen.NUI.Object.SetProperty((System.Runtime.InteropServices.HandleRef)scrollView.SwigCPtr, ScrollView.Property.ScrollPositionDelta, new Tizen.NUI.PropertyValue((Vector2)newValue)); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + + internal static object GetInternalScrollPositionDeltaProperty(BindableObject bindable) { var scrollView = (ScrollView)bindable; Vector2 temp = new Vector2(0.0f, 0.0f); Tizen.NUI.Object.GetProperty((System.Runtime.InteropServices.HandleRef)scrollView.SwigCPtr, ScrollView.Property.ScrollPositionDelta).Get(temp); return temp; - })); + } + [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty StartPagePositionProperty = BindableProperty.Create(nameof(StartPagePosition), typeof(Vector3), typeof(ScrollView), Vector3.Zero, propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty StartPagePositionProperty = null; + + internal static void SetInternalStartPagePositionProperty(BindableObject bindable, object oldValue, object newValue) { var scrollView = (ScrollView)bindable; if (newValue != null) { Tizen.NUI.Object.SetProperty((System.Runtime.InteropServices.HandleRef)scrollView.SwigCPtr, ScrollView.Property.StartPagePosition, new Tizen.NUI.PropertyValue((Vector3)newValue)); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + + internal static object GetInternalStartPagePositionProperty(BindableObject bindable) { var scrollView = (ScrollView)bindable; Vector3 temp = new Vector3(0.0f, 0.0f, 0.0f); Tizen.NUI.Object.GetProperty((System.Runtime.InteropServices.HandleRef)scrollView.SwigCPtr, ScrollView.Property.StartPagePosition).Get(temp); return temp; - })); + } + [EditorBrowsable(EditorBrowsableState.Never)] - public static readonly BindableProperty ScrollModeProperty = BindableProperty.Create(nameof(ScrollMode), typeof(PropertyMap), typeof(ScrollView), new PropertyMap(), propertyChanged: (BindableProperty.BindingPropertyChangedDelegate)((bindable, oldValue, newValue) => + public static readonly BindableProperty ScrollModeProperty = null; + + internal static void SetInternalScrollModeProperty(BindableObject bindable, object oldValue, object newValue) { var scrollView = (ScrollView)bindable; if (newValue != null) { Tizen.NUI.Object.SetProperty((System.Runtime.InteropServices.HandleRef)scrollView.SwigCPtr, ScrollView.Property.ScrollMode, new Tizen.NUI.PropertyValue((PropertyMap)newValue)); } - }), - defaultValueCreator: (BindableProperty.CreateDefaultValueDelegate)((bindable) => + } + + internal static object GetInternalScrollModeProperty(BindableObject bindable) { var scrollView = (ScrollView)bindable; PropertyValue value = Tizen.NUI.Object.GetProperty((System.Runtime.InteropServices.HandleRef)scrollView.SwigCPtr, ScrollView.Property.ScrollMode); PropertyMap map = new PropertyMap(); value.Get(map); return map; - })); + } } } -- 2.7.4