⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 tabseparator.cs

📁 浏览器端看到树型目录结构,用户可以完整地看到像windows资源管理器一样的效果
💻 CS
字号:
//------------------------------------------------------------------------------
// Copyright (c) 2000-2003 Microsoft Corporation. All Rights Reserved.
//------------------------------------------------------------------------------

namespace Microsoft.Web.UI.WebControls
{
    using System;
    using System.ComponentModel;
    using System.Web.UI;
    using System.Web.UI.WebControls;

    /// <summary>
    /// Represents a separator within a TabStrip.
    /// </summary>
    public class TabSeparator : TabItem
    {
        /// <summary>
        /// Separators are active when they are next to a selected tab.
        /// </summary>
        internal override bool Active
        {
            get
            {
                TabStrip parent = ParentTabStrip;
                if (parent == null)
                {
                    return false;
                }

                int nIndex = parent.Items.IndexOf(this);
                if (nIndex > 0)
                {
                    // Look at the item to the left
                    TabItem item = parent.Items[nIndex - 1];
                    if ((item != null) && (item is Tab) && ((Tab)item).Active)
                    {
                        // If the item is a tab and is active, then the separator is active
                        return true;
                    }
                }

                if (nIndex < (parent.Items.Count - 1))
                {
                    // Look at the item to the right
                    TabItem item = parent.Items[nIndex + 1];
                    if ((item != null) && (item is Tab) && ((Tab)item).Active)
                    {
                        // If the item is a tab and is active, then the separator is active
                        return true;
                    }
                }

                return false;
            }
        }

        /// <summary>
        /// The uplevel tag name for the tab item.
        /// </summary>
        protected override string UpLevelTag
        {
            get { return TabStrip.TabSeparatorTagName; }
        }
    }
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -