• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

C# Forms.ToolStripItemEventArgs类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C#中System.Windows.Forms.ToolStripItemEventArgs的典型用法代码示例。如果您正苦于以下问题:C# ToolStripItemEventArgs类的具体用法?C# ToolStripItemEventArgs怎么用?C# ToolStripItemEventArgs使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



ToolStripItemEventArgs类属于System.Windows.Forms命名空间,在下文中一共展示了ToolStripItemEventArgs类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。

示例1: msMain_ItemAdded

 private void msMain_ItemAdded(object sender, ToolStripItemEventArgs e)
 {
     if (e.Item.Text == "" || e.Item.Text == "还原(&R)" || e.Item.Text == "最小化(&N)" || e.Item.Text == "关闭(&C)")
     {
         msMain.Items.RemoveAt(e.Item.MergeIndex);
     }
 }
开发者ID:hdkn235,项目名称:PasswordTool,代码行数:7,代码来源:FrmMain.cs


示例2: OnItemAdded

        /// <summary>
        /// OnItemAdded-Event we adjust the font and forecolor of this item
        /// </summary>
        /// <param name="e"></param>
        protected override void OnItemAdded(ToolStripItemEventArgs e)
        {
            e.Item.Font = MetroUI.Style.BaseFont;
            e.Item.ForeColor = MetroUI.Style.ForeColor;

            base.OnItemAdded(e);
        }
开发者ID:ajmd17,项目名称:apexengine-sharp,代码行数:11,代码来源:MetroToolbar.cs


示例3: menuTop_ItemAdded

 /// <summary>顶部菜单-项添加事件</summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 private void menuTop_ItemAdded(object sender, ToolStripItemEventArgs e)
 {
     if (e.Item.Text.Length == 0)
     {
         e.Item.Visible = false;
     }
 }
开发者ID:qpyun,项目名称:DomainModelPlatform,代码行数:10,代码来源:Main.cs


示例4: OnItemAdded

 protected override void OnItemAdded(ToolStripItemEventArgs e)
 {
     if (SecurityExclude(e.Item))
         Items.Remove(e.Item);
     else
         base.OnItemAdded(e);
 }
开发者ID:NeuroRoboticTech,项目名称:AnimatLabPublicSource,代码行数:7,代码来源:AnimatMenuStrip.cs


示例5: OnItemRemoved

        private void OnItemRemoved(object sender, ToolStripItemEventArgs e)
        {
            if (e.Item != _item)
                return;

            RegisterEvents(register: false);
            _lifetime.Dispose();
        }
开发者ID:Giftednewt,项目名称:audio-switcher,代码行数:8,代码来源:ToolStripItemCommandBinding.cs


示例6: OnItemAdded

 /// <summary>
 /// When button is added, listen for it's hover events
 /// </summary>
 private void OnItemAdded(Object sender, ToolStripItemEventArgs e)
 {
     if (e.Item is ToolStripButton)
     {
         e.Item.MouseEnter += new EventHandler(this.OnOverChange);
         e.Item.MouseLeave += new EventHandler(this.OnOverChange);
     }
 }
开发者ID:Gr33z00,项目名称:flashdevelop,代码行数:11,代码来源:ToolStripEx.cs


示例7: menuStrip1_ItemAdded

        private void menuStrip1_ItemAdded(object sender, ToolStripItemEventArgs e)
        {
            if (e.Item.Text.Length == 0 || e.Item.Text == "还原(&R)" || e.Item.Text == "最小化(&N)"||e.Item.Text == "关闭(&C)")

            {
                e.Item.Visible = false;
            }
        }
开发者ID:fyyc1204,项目名称:MTSICS,代码行数:8,代码来源:MDIFORM.cs


示例8: m_obRight_ItemAdded

 //�ΡΡΡΡΡΡΡΡΡΡΡΡΡΡΡΡΡΡΡΡΡΡΡΡΡΡΡΡΡΡΡΡΡΡο����Ӧ����
 void m_obRight_ItemAdded(object sender, ToolStripItemEventArgs e)
 {
     m_obContRight.Width = 900;
     int width = Button_item_slot;
     for (int i = 0; i < m_obRight.Items.Count; i++)
     {
         width += m_obRight.Items[i].Width;
     }
     m_obContRight.Width = width;
 }
开发者ID:r1ng0to3tour,项目名称:swsplayer,代码行数:11,代码来源:ShoulderToolBar.cs


示例9: OnItemAdded

        protected override void OnItemAdded(ToolStripItemEventArgs e)
        {
            var button = e.Item as ToolStripButton;

            if (button != null)
                button.CheckedChanged += button_CheckedChanged;

            var dropDownButton = e.Item as ToolStripDropDownButton;

            if (dropDownButton != null)
                dropDownButton.DropDownItemClicked += dropDownButton_DropDownItemClicked;

            base.OnItemAdded(e);
        }
开发者ID:shanwei,项目名称:xenadmin,代码行数:14,代码来源:NavigationToolStrip.cs


示例10: ItemAdded

        internal void ItemAdded(object sender, ToolStripItemEventArgs e)
        {
            if (e.Item is IActionNameContainer)
            {
                var anc = e.Item as IActionNameContainer;
                if (anc.ActionName != ActionNames.None)
                {
                    actionitems.Add(anc.ActionName.ToString(), e.Item as ToolStripItem);
                    var actionManager = Services.ServiceProvider.GetInstance().GetService<IActionManager>();
                    actionManager.Actions[anc.ActionName].EnabledChanged +=
                        new EventHandler(ActionEnabledChanged);
                }
            }

            if (e.Item is ToolStripMenuItem)
            {
                var menuItem = (e.Item as ToolStripMenuItem);
                menuItem.Click += new EventHandler(ItemClick);
                foreach (System.Windows.Forms.ToolStripItem subitem in menuItem.DropDownItems)
                {
                    ItemAdded(e.Item, new ToolStripItemEventArgs(subitem));
                }
            }
        }
开发者ID:dbremner,项目名称:cecilstudio,代码行数:24,代码来源:BarControl.cs


示例11: OnItemAdded

 protected internal virtual void OnItemAdded(ToolStripItemEventArgs e)
 {
     this.DoLayoutIfHandleCreated(e);
     if ((!this.HasVisibleItems && (e.Item != null)) && ((IArrangedElement) e.Item).ParticipatesInLayout)
     {
         this.HasVisibleItems = true;
     }
     ToolStripItemEventHandler handler = (ToolStripItemEventHandler) base.Events[EventItemAdded];
     if (handler != null)
     {
         handler(this, e);
     }
 }
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:13,代码来源:ToolStrip.cs


示例12: menuStrip_ItemAdded

		private void menuStrip_ItemAdded(object sender, ToolStripItemEventArgs e)
		{
			// Translate the items in the menu by finding their Tags in the translation file.
			foreach (ToolStripMenuItem objItem in menuStrip.Items.OfType<ToolStripMenuItem>())
			{
				if (objItem.Tag != null)
				{
					objItem.Text = LanguageManager.Instance.GetString(objItem.Tag.ToString());
				}
			}
		}
开发者ID:AMDX9,项目名称:chummer5a,代码行数:11,代码来源:frmMain.cs


示例13: toolStrip_ItemRemoved

		private void toolStrip_ItemRemoved(object sender, ToolStripItemEventArgs e)
		{
			// ToolStrip Items.
			foreach (ToolStrip objToolStrip in this.Controls.OfType<ToolStrip>())
			{
				foreach (ToolStripButton objButton in objToolStrip.Items.OfType<ToolStripButton>())
				{
					if (objButton.Tag != null)
						objButton.Text = LanguageManager.Instance.GetString(objButton.Tag.ToString());
				}
			}
		}
开发者ID:AMDX9,项目名称:chummer5a,代码行数:12,代码来源:frmMain.cs


示例14: menuMain_ItemAdded

 private void menuMain_ItemAdded(object sender, ToolStripItemEventArgs e)
 {
     if (e.Item.Text == "")
     {
         e.Item.Image = null;
     }
 }
开发者ID:itcthienkhiem,项目名称:DienLucHocMonCT,代码行数:7,代码来源:MDIMain.cs


示例15: OnItemAdded

        /// <summary>
        /// Raises the <see cref="E:System.Windows.Forms.ToolStrip.ItemAdded"/> event.
        /// </summary>
        /// <param name="e">A <see cref="T:System.Windows.Forms.ToolStripItemEventArgs"/> that contains the event data.</param>
        protected override void OnItemAdded(ToolStripItemEventArgs e)
        {
            base.OnItemAdded(e);

            if (ProgressBar == null)
            {
                ToolStripProgressBar pb = e.Item as ToolStripProgressBar;
                if (pb != null)
                {
                    ProgressBar = pb;
                }
            }

            if (ProgressLabel == null)
            {
                ToolStripStatusLabel sl = e.Item as ToolStripStatusLabel;
                if (sl != null)
                {
                    ProgressLabel = sl;
                }
            }
        }
开发者ID:DIVEROVIEDO,项目名称:DotSpatial,代码行数:26,代码来源:SpatialStatusStrip.cs


示例16: OnItemRemoved

		protected internal virtual void OnItemRemoved (ToolStripItemEventArgs e)
		{
			ToolStripItemEventHandler eh = (ToolStripItemEventHandler)(Events [ItemRemovedEvent]);
			if (eh != null)
				eh (this, e);
		}
开发者ID:nekresh,项目名称:mono,代码行数:6,代码来源:ToolStrip.cs


示例17: tsTop_ItemAdded

 private void tsTop_ItemAdded(object sender, ToolStripItemEventArgs e)
 {
     if (this.tlpContent.Padding.Left != 0x17)
     {
         this.tlpContent.Padding = new Padding(0x17, 0, 0, 0);
     }
 }
开发者ID:shankithegreat,项目名称:commanderdotnet,代码行数:7,代码来源:ContentFilterControl.cs


示例18: OnItemRemoved

 protected override void OnItemRemoved(ToolStripItemEventArgs e)
 {
     QMenuItem qmi = e.Item as QMenuItem;
     if(IsQmiResponds(qmi)) {
         lstQMIResponds.Remove(qmi);
     }
     base.OnItemRemoved(e);
 }
开发者ID:Nicologies,项目名称:QTTabBar,代码行数:8,代码来源:DropDownMenuBase.cs


示例19: OnItemAdded

		protected internal virtual void OnItemAdded (ToolStripItemEventArgs e)
		{
			if (e.Item.InternalVisible)
				e.Item.Available = true;
				
			e.Item.SetPlacement (ToolStripItemPlacement.Main);
			
			if (this.Created)
				this.PerformLayout ();
			
			ToolStripItemEventHandler eh = (ToolStripItemEventHandler)(Events [ItemAddedEvent]);
			if (eh != null)
				eh (this, e);
		}
开发者ID:nekresh,项目名称:mono,代码行数:14,代码来源:ToolStrip.cs


示例20: HandleItemAddedToOwner

		/// ------------------------------------------------------------------------------------
		/// <summary>
		/// Handles adding an item's separator (if it has one) to its owning ToolStrip.
		/// </summary>
		/// ------------------------------------------------------------------------------------
		private static void HandleItemAddedToOwner(object sender, ToolStripItemEventArgs e)
		{
			ToolStripItemExtender extender;
			if (s_extenders.TryGetValue(e.Item, out extender))
				extender.AddSeparator(sender as ToolStrip);
		}
开发者ID:sillsdev,项目名称:FieldWorks,代码行数:11,代码来源:ToolStripAdapter.cs



注:本文中的System.Windows.Forms.ToolStripItemEventArgs类示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C# Forms.ToolStripItemImageRenderEventArgs类代码示例发布时间:2022-05-26
下一篇:
C# Forms.ToolStripItemCollection类代码示例发布时间:2022-05-26
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap