Exemple #1
0
        /// <summary>
        /// Creates a new instance of TabBar.
        /// </summary>
        /// <since_tizen> 9 </since_tizen>
        public TabBar()
        {
            Layout = new LinearLayout()
            {
                LinearOrientation = LinearLayout.Orientation.Horizontal
            };

            WidthSpecification = LayoutParamPolicies.MatchParent;

            tabButtons     = new List <TabButton>();
            tabButtonGroup = new TabButtonGroup();
            SelectedIndex  = -1;
        }
Exemple #2
0
        protected override void Dispose(DisposeTypes type)
        {
            if (disposed)
            {
                return;
            }

            if (type == DisposeTypes.Explicit)
            {
                if (tabButtons != null)
                {
                    foreach (TabButton tabButton in tabButtons)
                    {
                        Utility.Dispose(tabButton);
                    }

                    tabButtons = null;
                }

                tabButtonGroup = null;
            }

            base.Dispose(type);
        }