Example #1
0
        public void FlexLayoutSetFlexAlignmentSelf()
        {
            tlog.Debug(tag, $"FlexLayoutSetFlexAlignmentSelf START");

            View view = new View()
            {
                Size            = new Size(400, 400),
                BackgroundColor = Color.White,
                Layout          = new FlexLayout()
                {
                    Direction = FlexLayout.FlexDirection.Column,
                }
            };

            try
            {
                FlexLayout.SetFlexAlignmentSelf(view, FlexLayout.AlignmentType.FlexStart);
            }
            catch (Exception e)
            {
                tlog.Error(tag, "Caught Exception" + e.ToString());
                LogUtils.Write(LogUtils.DEBUG, LogUtils.TAG, "Caught Exception" + e.ToString());
                Assert.Fail("Caught Exception" + e.ToString());
            }

            view.Dispose();
            tlog.Debug(tag, $"FlexLayoutSetFlexAlignmentSelf END (OK)");
        }
Example #2
0
        public void FlexLayoutGetFlexAlignmentSelf()
        {
            tlog.Debug(tag, $"FlexLayoutGetFlexAlignmentSelf START");

            View view = new View()
            {
                Size            = new Size(400, 400),
                BackgroundColor = Color.White,
                Layout          = new FlexLayout()
                {
                    Direction = FlexLayout.FlexDirection.Column,
                }
            };

            FlexLayout.SetFlexAlignmentSelf(view, FlexLayout.AlignmentType.FlexStart);
            var result = FlexLayout.GetFlexAlignmentSelf(view);

            Assert.AreEqual(FlexLayout.AlignmentType.FlexStart, result, "should be equal!");

            view.Dispose();
            tlog.Debug(tag, $"FlexLayoutGetFlexAlignmentSelf END (OK)");
        }