using System;
using System.ComponentModel;
using System.Collections.Generic;
using System.Diagnostics;
using System.Text;
using System.Windows.Forms;
namespace IReaper.Browser{
public partial class TabContextMenu : ContextMenu
{
private iReaperBrowserForm context = null;
public iReaperBrowserForm Context
{
get
{
return context;
}
set
{
context = value;
}
}
public TabContextMenu()
{
InitializeComponent();
InitMenuItem();
}
private void InitMenuItem()
{
this.MenuItems.Add(Properties.Resources.BrowserClose);
this.MenuItems[0].Click += new EventHandler(TabContextMenu_Click);
}
void TabContextMenu_Click(object sender, EventArgs e)
{
if (context != null)
{
context.Close();
}
}
public TabContextMenu(IContainer container)
{
container.Add(this);
InitializeComponent();
}
}
}
|