From: wenfeng.ge Date: Fri, 1 Feb 2019 05:31:42 +0000 (+0800) Subject: [NUI][Non-ACR][Update TCTs for Tizen.NUI] X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=refs%2Fchanges%2F52%2F199052%2F5;p=test%2Ftct%2Fcsharp%2Fapi.git [NUI][Non-ACR][Update TCTs for Tizen.NUI] Change-Id: I9b2e0330bca7e0df053b29772fedbe2ffc82aa53 --- diff --git a/tct-suite-vs/Tizen.NUI.Tests/testcase/TSCustomView.cs b/tct-suite-vs/Tizen.NUI.Tests/testcase/TSCustomView.cs index 9bfa875e7..aafbfb2e4 100755 --- a/tct-suite-vs/Tizen.NUI.Tests/testcase/TSCustomView.cs +++ b/tct-suite-vs/Tizen.NUI.Tests/testcase/TSCustomView.cs @@ -5,6 +5,7 @@ using Tizen.NUI; using Tizen.NUI.BaseComponents; using System.Runtime.InteropServices; using Tizen.NUI.Test; +using System.Threading.Tasks; namespace Tizen.NUI.Tests { @@ -563,11 +564,586 @@ namespace Tizen.NUI.Tests Assert.Fail("Caught Exception" + e.ToString()); } } + + [Test] + [Category("P1")] + [Description("Test whether GetNextFocusableView return the right value or not")] + [Property("SPEC", "Tizen.NUI.BaseComponents.CustomView.GetNextFocusableView M")] + [Property("SPEC_URL", "-")] + [Property("CRITERIA", "MR")] + [Property("AUTHOR", "Wenfeng Ge, wenfeng.ge@samsung.com")] + public void GetNextFocusableView_CHECK_RETURN_VALUE() + { + CustomView customView = new CustomView("CustomView", CustomViewBehaviour.DisableSizeNegotiation); + FocusManager.Instance.SetCurrentFocusView(customView); + View view = customView.GetNextFocusableView(customView, View.FocusDirection.Up, false); + Assert.IsNotNull(view, "Should be not null"); + } + + [Test] + [Category("P1")] + [Description("Test OnCalculateRelayoutSize. Check it has been triggered")] + [Property("SPEC", "Tizen.NUI.BaseComponents.CustomView.OnCalculateRelayoutSize M")] + [Property("SPEC_URL", "-")] + [Property("CRITERIA", "MR")] + [Property("AUTHOR", "Wenfeng Ge, wenfeng.ge@samsung.com")] + public void OnCalculateRelayoutSize_CHECK_VALUE() + { + MyCustomView view = new MyCustomView("CustomView", CustomViewBehaviour.ViewBehaviourDefault); + view.OnCalculateRelayoutSize(DimensionType.AllDimensions); + Assert.AreEqual(true, view.calculateRelayoutSizeFlag, "OnCalculateRelayoutSize return Check Fail."); + } + + [Test] + [Category("P1")] + [Description("Test OnChildAdd. Check it has been triggered")] + [Property("SPEC", "Tizen.NUI.BaseComponents.CustomView.OnChildAdd M")] + [Property("SPEC_URL", "-")] + [Property("CRITERIA", "MR")] + [Property("AUTHOR", "Wenfeng Ge, wenfeng.ge@samsung.com")] + public void OnChildAdd_CHECK() + { + MyCustomView myCustomView = new MyCustomView("CustomView", CustomViewBehaviour.ViewBehaviourDefault); + View view = new View(); + myCustomView.Children.Add(view); + Assert.AreEqual(true, myCustomView.childAddFlag, "OnChildAdd return Check Fail."); + myCustomView.Children.Remove(view); + } + + [Test] + [Category("P1")] + [Description("Test OnChildRemove. Check it has been triggered")] + [Property("SPEC", "Tizen.NUI.BaseComponents.CustomView.OnChildRemove M")] + [Property("SPEC_URL", "-")] + [Property("CRITERIA", "MR")] + [Property("AUTHOR", "Wenfeng Ge, wenfeng.ge@samsung.com")] + public void OnChildRemove_CHECK() + { + MyCustomView myCustomView = new MyCustomView("CustomView", CustomViewBehaviour.ViewBehaviourDefault); + View view = new View(); + myCustomView.Children.Add(view); + myCustomView.Remove(view); + Assert.AreEqual(true, myCustomView.childRemoveFlag, "OnChildRemove Check Fail."); + } + + [Test] + [Category("P1")] + [Description("Test OnFocusChangeCommitted. Check it has been triggered")] + [Property("SPEC", "Tizen.NUI.BaseComponents.CustomView.OnFocusChangeCommitted M")] + [Property("SPEC_URL", "-")] + [Property("CRITERIA", "MR")] + [Property("AUTHOR", "Wenfeng Ge, wenfeng.ge@samsung.com")] + public void OnFocusChangeCommitted_CHECK_VALUE() + { + MyCustomView myCustomView = new MyCustomView("CustomView", CustomViewBehaviour.DisableSizeNegotiation); + View view = new View(); + view.Focusable = true; + myCustomView.OnFocusChangeCommitted(view); + Assert.AreEqual(true, myCustomView.focusChangeCommittedFlag, "OnFocusChangeCommitted Check Fail."); + } + + [Test] + [Category("P1")] + [Description("Test OnFocusGained. Check it has been triggered")] + [Property("SPEC", "Tizen.NUI.BaseComponents.CustomView.OnFocusGained M")] + [Property("SPEC_URL", "-")] + [Property("CRITERIA", "MR")] + [Property("AUTHOR", "Wenfeng Ge, wenfeng.ge@samsung.com")] + public void OnFocusGained_CHECK_VALUE() + { + /* TEST CODE */ + Window window = Window.Instance; + MyCustomView view = new MyCustomView("CustomView", CustomViewBehaviour.ViewBehaviourDefault); + view.Focusable = true; + window.Add(view); + FocusManager.Instance.SetCurrentFocusView(view); + Assert.AreEqual(true, view.focusGainedFlag, "OnFocusGained Check Fail."); + window.Remove(view); + } + + [Test] + [Category("P1")] + [Description("Test OnFocusLost. Check it has been triggered")] + [Property("SPEC", "Tizen.NUI.BaseComponents.CustomView.OnFocusLost M")] + [Property("SPEC_URL", "-")] + [Property("CRITERIA", "MR")] + [Property("AUTHOR", "Wenfeng Ge, wenfeng.ge@samsung.com")] + public void OnFocusLost_CHECK_VALUE() + { + /* TEST CODE */ + Window window = Window.Instance; + MyCustomView view = new MyCustomView("CustomView", CustomViewBehaviour.ViewBehaviourDefault); + MyCustomView view2 = new MyCustomView("CustomView", CustomViewBehaviour.ViewBehaviourDefault); + view.Focusable = true; + view2.Focusable = true; + window.Add(view); + window.Add(view2); + FocusManager.Instance.SetCurrentFocusView(view); + FocusManager.Instance.SetCurrentFocusView(view2); + Assert.AreEqual(true, view.focusLostFlag, "OnFocusLost Check Fail."); + window.Remove(view); + window.Remove(view2); + } + + [Test] + [Category("P1")] + [Description("Test OnHover. Check return the right value or not")] + [Property("SPEC", "Tizen.NUI.BaseComponents.CustomView.OnHover M")] + [Property("SPEC_URL", "-")] + [Property("CRITERIA", "MR")] + [Property("AUTHOR", "Wenfeng Ge, wenfeng.ge@samsung.com")] + public void OnHover_CHECK_RETURN_VALUE() + { + /* TEST CODE */ + try + { + CustomView View = new CustomView("CustomView", CustomViewBehaviour.DisableSizeNegotiation); + bool flag = true; + flag = View.OnHover(new Hover()); + Assert.AreEqual(false, flag, "OnHover return check fail."); + } + catch (Exception e) + { + Tizen.Log.Error(TAG, "Caught Exception" + e.ToString()); + LogUtils.Write(LogUtils.DEBUG, LogUtils.TAG, "Caught Exception" + e.ToString()); + Assert.Fail("Caught Exception" + e.ToString()); + } + + } + + [Test] + [Category("P1")] + [Description("Test OnInitialize. Check it has been triggered")] + [Property("SPEC", "Tizen.NUI.BaseComponents.CustomView.OnInitialize M")] + [Property("SPEC_URL", "-")] + [Property("CRITERIA", "MR")] + [Property("AUTHOR", "Wenfeng Ge, wenfeng.ge@samsung.com")] + public void OnInitialize_CHECK_VALUE() + { + /* TEST CODE */ + try + { + CustomView view = new CustomView("CustomView", CustomViewBehaviour.DisableSizeNegotiation); + view.OnInitialize(); + } + catch (Exception e) + { + Tizen.Log.Error(TAG, "Caught Exception" + e.ToString()); + LogUtils.Write(LogUtils.DEBUG, LogUtils.TAG, "Caught Exception" + e.ToString()); + Assert.Fail("Caught Exception" + e.ToString()); + } + } + + [Test] + [Category("P1")] + [Description("Test OnKey. Check return the right value or not")] + [Property("SPEC", "Tizen.NUI.BaseComponents.CustomView.OnKey M")] + [Property("SPEC_URL", "-")] + [Property("CRITERIA", "MR")] + [Property("AUTHOR", "Wenfeng Ge, wenfeng.ge@samsung.com")] + public void OnKey_CHECK_RETURN_VALUE() + { + /* TEST CODE */ + try + { + CustomView View = new CustomView("CustomView", CustomViewBehaviour.DisableSizeNegotiation); + bool flag = true; + flag = View.OnKey(new Key()); + Assert.AreEqual(false, flag, "OnKey return check fail."); + } + catch (Exception e) + { + Tizen.Log.Error(TAG, "Caught Exception" + e.ToString()); + LogUtils.Write(LogUtils.DEBUG, LogUtils.TAG, "Caught Exception" + e.ToString()); + Assert.Fail("Caught Exception" + e.ToString()); + } + } + + [Test] + [Category("P1")] + [Description("Test OnKeyboardEnter. Check return the right value or not")] + [Property("SPEC", "Tizen.NUI.BaseComponents.CustomView.OnKeyboardEnter M")] + [Property("SPEC_URL", "-")] + [Property("CRITERIA", "MR")] + [Property("AUTHOR", "Wenfeng Ge, wenfeng.ge@samsung.com")] + public void OnKeyboardEnter_CHECK_RETURN_VALUE() + { + /* TEST CODE */ + try + { + CustomView View = new CustomView("CustomView", CustomViewBehaviour.ViewBehaviourDefault); + bool flag = true; + flag = View.OnKeyboardEnter(); + Assert.AreEqual(false, flag, "OnKeyboardEnter return Check Fail."); + } + catch (Exception e) + { + Tizen.Log.Error(TAG, "Caught Exception" + e.ToString()); + LogUtils.Write(LogUtils.DEBUG, LogUtils.TAG, "Caught Exception" + e.ToString()); + Assert.Fail("Caught Exception" + e.ToString()); + } + } + + [Test] + [Category("P1")] + [Description("Test OnLayoutNegotiated. Check it has been triggered")] + [Property("SPEC", "Tizen.NUI.BaseComponents.CustomView.OnLayoutNegotiated M")] + [Property("SPEC_URL", "-")] + [Property("CRITERIA", "MR")] + [Property("AUTHOR", "Wenfeng Ge, wenfeng.ge@samsung.com")] + public void OnLayoutNegotiated_CHECK_VALUE() + { + /* TEST CODE */ + try + { + MyCustomView view = new MyCustomView("CustomView", CustomViewBehaviour.ViewBehaviourDefault); + view.OnLayoutNegotiated(0.5f, DimensionType.Height); + Assert.AreEqual(true, view.layoutNegotiatedFlag, "OnLayoutNegotiated trigger Check Fail."); + } + catch (Exception e) + { + Tizen.Log.Error(TAG, "Caught Exception" + e.ToString()); + LogUtils.Write(LogUtils.DEBUG, LogUtils.TAG, "Caught Exception" + e.ToString()); + Assert.Fail("Caught Exception" + e.ToString()); + } + + } + + [Test] + [Category("P1")] + [Description("Test OnPan. Check it has been triggered")] + [Property("SPEC", "Tizen.NUI.BaseComponents.CustomView.OnPan M")] + [Property("SPEC_URL", "-")] + [Property("CRITERIA", "MR")] + [Property("AUTHOR", "Wenfeng Ge, wenfeng.ge@samsung.com")] + public void OnPan_CHECK_VALUE() + { + /* TEST CODE */ + try + { + MyCustomView View = new MyCustomView("CustomView", CustomViewBehaviour.ViewBehaviourDefault); + PanGesture pan = new PanGesture(); + View.OnPan(pan); + Assert.AreEqual(true, View.panFlag, "OnPan trigger Check Fail."); + } + catch (Exception e) + { + Tizen.Log.Error(TAG, "Caught Exception" + e.ToString()); + LogUtils.Write(LogUtils.DEBUG, LogUtils.TAG, "Caught Exception" + e.ToString()); + Assert.Fail("Caught Exception" + e.ToString()); + } + } + + [Test] + [Category("P1")] + [Description("Test OnPropertySet. Check it has been triggered")] + [Property("SPEC", "Tizen.NUI.BaseComponents.CustomView.OnPropertySet M")] + [Property("SPEC_URL", "-")] + [Property("CRITERIA", "MR")] + [Property("AUTHOR", "Wenfeng Ge, wenfeng.ge@samsung.com")] + public void OnPropertySet_CHECK_VALUE() + { + /* TEST CODE */ + try + { + MyCustomView view = new MyCustomView("CustomView", CustomViewBehaviour.ViewBehaviourDefault); + view.Size2D = new Size2D(100, 100); + view.Position = new Position(100, 100, 0); + view.BackgroundColor = Color.Red; + Window.Instance.GetDefaultLayer().Add(view); + view.StyleName = "fake"; + Window.Instance.GetDefaultLayer().Remove(view); + Assert.AreEqual(true, view.propertySetFlag, "OnPropertySet trigger Check Fail."); + } + catch (Exception e) + { + Tizen.Log.Error(TAG, "Caught Exception" + e.ToString()); + LogUtils.Write(LogUtils.DEBUG, LogUtils.TAG, "Caught Exception" + e.ToString()); + Assert.Fail("Caught Exception" + e.ToString()); + } + } + + [Test] + [Category("P1")] + [Description("Test OnRelayout. Check it has been triggered")] + [Property("SPEC", "Tizen.NUI.BaseComponents.CustomView.OnRelayout M")] + [Property("SPEC_URL", "-")] + [Property("CRITERIA", "MR")] + [Property("AUTHOR", "Wenfeng Ge, wenfeng.ge@samsung.com")] + public async Task OnRelayout_CHECK_VALUE() + { + /* TEST CODE */ + try + { + MyCustomView view = new MyCustomView("CustomView", CustomViewBehaviour.ViewBehaviourDefault); + Window window = Window.Instance; + window.Add(view); + await Task.Delay(500); + Assert.AreEqual(true, view.relayoutFlag, "OnRelayout trigger Check Fail."); + window.Remove(view); + } + catch (Exception e) + { + Tizen.Log.Error(TAG, "Caught Exception" + e.ToString()); + LogUtils.Write(LogUtils.DEBUG, LogUtils.TAG, "Caught Exception" + e.ToString()); + Assert.Fail("Caught Exception" + e.ToString()); + } + } + + [Test] + [Category("P1")] + [Description("Test OnSetResizePolicy. Check it has been triggered")] + [Property("SPEC", "Tizen.NUI.BaseComponents.CustomView.OnSetResizePolicy M")] + [Property("SPEC_URL", "-")] + [Property("CRITERIA", "MR")] + [Property("AUTHOR", "Wenfeng Ge, wenfeng.ge@samsung.com")] + public void OnSetResizePolicy_CHECK_VALUE() + { + /* TEST CODE */ + try + { + MyCustomView view = new MyCustomView("CustomView", CustomViewBehaviour.ViewBehaviourDefault); + view.OnSetResizePolicy(ResizePolicyType.Fixed, DimensionType.Height); + Assert.AreEqual(true, view.setResizePolicyFlag, "OnSetResizePolicy trigger Check Fail."); + } + catch (Exception e) + { + Tizen.Log.Error(TAG, "Caught Exception" + e.ToString()); + LogUtils.Write(LogUtils.DEBUG, LogUtils.TAG, "Caught Exception" + e.ToString()); + Assert.Fail("Caught Exception" + e.ToString()); + } + } + + [Test] + [Category("P1")] + [Description("Test OnSizeAnimation. Check it has been triggered")] + [Property("SPEC", "Tizen.NUI.BaseComponents.CustomView.OnSizeAnimation M")] + [Property("SPEC_URL", "-")] + [Property("CRITERIA", "MR")] + [Property("AUTHOR", "Wenfeng Ge, wenfeng.ge@samsung.com")] + public void OnSizeAnimation_CHECK_VALUE() + { + /* TEST CODE */ + try + { + MyCustomView view = new MyCustomView("CustomView", CustomViewBehaviour.ViewBehaviourDefault); + Vector3 v3 = new Vector3(20, 30, 40); + Animation animation = new Animation(); + view.OnSizeAnimation(animation, v3); + Assert.AreEqual(true, view.sizeAnimationFlag, "OnSizeAnimation trigger Check Fail."); + } + catch (Exception e) + { + Tizen.Log.Error(TAG, "Caught Exception" + e.ToString()); + LogUtils.Write(LogUtils.DEBUG, LogUtils.TAG, "Caught Exception" + e.ToString()); + Assert.Fail("Caught Exception" + e.ToString()); + } + } + + [Test] + [Category("P1")] + [Description("Test OnSizeSet. Check it has been triggered")] + [Property("SPEC", "Tizen.NUI.BaseComponents.CustomView.OnSizeSet M")] + [Property("SPEC_URL", "-")] + [Property("CRITERIA", "MR")] + [Property("AUTHOR", "Wenfeng Ge, wenfeng.ge@samsung.com")] + public void OnSizeSet_CHECK_VALUE() + { + /* TEST CODE */ + try + { + MyCustomView view = new MyCustomView("CustomView", CustomViewBehaviour.ViewBehaviourDefault); + Vector3 v3 = new Vector3(20, 30, 40); + view.OnSizeSet(v3); + Assert.AreEqual(true, view.sizeSetFlag, "OnSizeSet trigger Check Fail."); + } + catch (Exception e) + { + Tizen.Log.Error(TAG, "Caught Exception" + e.ToString()); + LogUtils.Write(LogUtils.DEBUG, LogUtils.TAG, "Caught Exception" + e.ToString()); + Assert.Fail("Caught Exception" + e.ToString()); + } + } + + [Test] + [Category("P1")] + [Description("Test OnStageConnection. Check it has been triggered")] + [Property("SPEC", "Tizen.NUI.BaseComponents.CustomView.OnStageConnection M")] + [Property("SPEC_URL", "-")] + [Property("CRITERIA", "MR")] + [Property("AUTHOR", "Wenfeng Ge, wenfeng.ge@samsung.com")] + public void OnStageConnection_CHECK_VALUE() + { + /* TEST CODE */ + try + { + MyCustomView view = new MyCustomView("CustomView", CustomViewBehaviour.ViewBehaviourDefault); + view.OnStageConnection(1); + Assert.AreEqual(true, view.stageConnectionFlag, "OnStageConnection trigger Check Fail."); + } + catch (Exception e) + { + Tizen.Log.Error(TAG, "Caught Exception" + e.ToString()); + LogUtils.Write(LogUtils.DEBUG, LogUtils.TAG, "Caught Exception" + e.ToString()); + Assert.Fail("Caught Exception" + e.ToString()); + } + } + + [Test] + [Category("P1")] + [Description("Test OnStageDisconnection. Check it has been triggered")] + [Property("SPEC", "Tizen.NUI.BaseComponents.CustomView.OnStageDisconnection M")] + [Property("SPEC_URL", "-")] + [Property("CRITERIA", "MR")] + [Property("AUTHOR", "Wenfeng Ge, wenfeng.ge@samsung.com")] + public void OnStageDisconnection_CHECK_VALUE() + { + /* TEST CODE */ + try + { + MyCustomView view = new MyCustomView("CustomView", CustomViewBehaviour.ViewBehaviourDefault); + view.OnStageDisconnection(); + Assert.AreEqual(true, view.stageDisconnectionFlag, "OnStageDisconnection trigger Check Fail."); + } + catch (Exception e) + { + Tizen.Log.Error(TAG, "Caught Exception" + e.ToString()); + LogUtils.Write(LogUtils.DEBUG, LogUtils.TAG, "Caught Exception" + e.ToString()); + Assert.Fail("Caught Exception" + e.ToString()); + } + } + + [Test] + [Category("P1")] + [Description("Test OnStyleChange. Check it has been triggered")] + [Property("SPEC", "Tizen.NUI.BaseComponents.CustomView.OnStyleChange M")] + [Property("SPEC_URL", "-")] + [Property("CRITERIA", "MR")] + [Property("AUTHOR", "Wenfeng Ge, wenfeng.ge@samsung.com")] + public void OnStyleChange_CHECK_VALUE() + { + /* TEST CODE */ + try + { + MyCustomView view = new MyCustomView("CustomView", CustomViewBehaviour.ViewBehaviourDefault); + StyleManager manager = new StyleManager(); + view.OnStyleChange(manager, StyleChangeType.DefaultFontChange); + Assert.AreEqual(true, view.styleChangeFlag, "OnStyleChange trigger Check Fail."); + } + catch (Exception e) + { + Tizen.Log.Error(TAG, "Caught Exception" + e.ToString()); + LogUtils.Write(LogUtils.DEBUG, LogUtils.TAG, "Caught Exception" + e.ToString()); + Assert.Fail("Caught Exception" + e.ToString()); + } + } + + [Test] + [Category("P1")] + [Description("Test OnTap. Check it has been triggered")] + [Property("SPEC", "Tizen.NUI.BaseComponents.CustomView.OnTap M")] + [Property("SPEC_URL", "-")] + [Property("CRITERIA", "MR")] + [Property("AUTHOR", "Wenfeng Ge, wenfeng.ge@samsung.com")] + public void OnTap_CHECK_VALUE() + { + /* TEST CODE */ + try + { + MyCustomView view = new MyCustomView("CustomView", CustomViewBehaviour.ViewBehaviourDefault); + TapGesture tap = new TapGesture(); + view.OnTap(tap); + Assert.AreEqual(true, view.tapFlag, "OnTap trigger Check Fail."); + } + catch (Exception e) + { + Tizen.Log.Error(TAG, "Caught Exception" + e.ToString()); + LogUtils.Write(LogUtils.DEBUG, LogUtils.TAG, "Caught Exception" + e.ToString()); + Assert.Fail("Caught Exception" + e.ToString()); + } + } + + [Test] + [Category("P1")] + [Description("Test OnTouch. Check it has been triggered")] + [Property("SPEC", "Tizen.NUI.BaseComponents.CustomView.OnTouch M")] + [Property("SPEC_URL", "-")] + [Property("CRITERIA", "MR")] + [Property("AUTHOR", "Wenfeng Ge, wenfeng.ge@samsung.com")] + public void OnTouch_CHECK_VALUE() + { + /* TEST CODE */ + try + { + CustomView view = new CustomView("CustomView", CustomViewBehaviour.ViewBehaviourDefault); + Touch touch = new Touch(); + bool flag = true; + flag = view.OnTouch(touch); + Assert.AreEqual(false, flag, "OnTouch trigger Check Fail."); + } + catch (Exception e) + { + Tizen.Log.Error(TAG, "Caught Exception" + e.ToString()); + LogUtils.Write(LogUtils.DEBUG, LogUtils.TAG, "Caught Exception" + e.ToString()); + Assert.Fail("Caught Exception" + e.ToString()); + } + } + + [Test] + [Category("P1")] + [Description("Test OnWheel. Check it has been triggered")] + [Property("SPEC", "Tizen.NUI.BaseComponents.CustomView.OnWheel M")] + [Property("SPEC_URL", "-")] + [Property("CRITERIA", "MR")] + [Property("AUTHOR", "Wenfeng Ge, wenfeng.ge@samsung.com")] + public void OnWheel_CHECK_VALUE() + { + /* TEST CODE */ + try + { + CustomView view = new CustomView("CustomView", CustomViewBehaviour.ViewBehaviourDefault); + Wheel wheel = new Wheel(); + bool flag = true; + flag = view.OnWheel(wheel); + Assert.AreEqual(false, flag, "OnWheel trigger Check Fail."); + } + catch (Exception e) + { + Tizen.Log.Error(TAG, "Caught Exception" + e.ToString()); + LogUtils.Write(LogUtils.DEBUG, LogUtils.TAG, "Caught Exception" + e.ToString()); + Assert.Fail("Caught Exception" + e.ToString()); + } + } + } public class MyCustomView : CustomView { View view; + public bool calculateRelayoutSizeFlag = false; + public bool childAddFlag = false; + public bool childRemoveFlag = false; + public bool focusChangeCommittedFlag = false; + public bool focusGainedFlag = false; + public bool focusLostFlag = false; + public bool hoverFlag = false; + public bool initializeFlag = false; + public bool keyFlag = false; + public bool keyboardEnterFlag = false; + public bool layoutNegotiatedFlag = false; + public bool panFlag = false; + public bool propertySetFlag = false; + public bool relayoutFlag = false; + public bool setResizePolicyFlag = false; + public bool sizeAnimationFlag = false; + public bool sizeSetFlag = false; + public bool stageConnectionFlag = false; + public bool stageDisconnectionFlag = false; + public bool styleChangeFlag = false; + public bool tapFlag = false; + public bool touchFlag = false; + public bool wheelFlag = false; + static CustomView CreateInstance() { return new MyCustomView(); @@ -585,6 +1161,36 @@ namespace Tizen.NUI.Tests { } + public override void OnCalculateRelayoutSize(DimensionType dimension) + { + calculateRelayoutSizeFlag = true; + } + + public override void OnChildAdd(View view) + { + childAddFlag = true; + } + + public override void OnChildRemove(View view) + { + childRemoveFlag = true; + } + + public override void OnFocusChangeCommitted(View commitedFocusableView) + { + focusChangeCommittedFlag = true; + } + + public override void OnFocusGained() + { + focusGainedFlag = true; + } + + public override void OnFocusLost() + { + focusLostFlag = true; + } + public override void OnInitialize() { view = new BaseComponents.View(); @@ -593,6 +1199,61 @@ namespace Tizen.NUI.Tests this.Add(view); } + public override void OnLayoutNegotiated(float size, DimensionType dimension) + { + layoutNegotiatedFlag = true; + } + + public override void OnPan(PanGesture pan) + { + panFlag = true; + } + + public override void OnPropertySet(int index, Tizen.NUI.PropertyValue propertyValue) + { + propertySetFlag = true; + } + + public override void OnRelayout(Vector2 size, RelayoutContainer container) + { + relayoutFlag = true; + } + + public override void OnSetResizePolicy(ResizePolicyType policy, DimensionType dimension) + { + setResizePolicyFlag = true; + } + + public override void OnSizeAnimation(Animation animation, Vector3 targetSize) + { + sizeAnimationFlag = true; + } + + public override void OnSizeSet(Vector3 targetSize) + { + sizeSetFlag = true; + } + + public override void OnStageConnection(int depth) + { + stageConnectionFlag = true; + } + + public override void OnStageDisconnection() + { + stageDisconnectionFlag = true; + } + + public override void OnStyleChange(StyleManager styleManager, StyleChangeType change) + { + styleChangeFlag = true; + } + + public override void OnTap(TapGesture tap) + { + tapFlag = true; + } + public override Size2D GetNaturalSize() { return new Size2D(200, 200);