fyiReporting.RdlDesign.RdlDesigner.mainTC_MouseClick C# (CSharp) Метод

mainTC_MouseClick() приватный Метод

Handles right mouse button processing on current tab
private mainTC_MouseClick ( object sender, MouseEventArgs e ) : void
sender object
e MouseEventArgs
Результат void
        void mainTC_MouseClick(object sender, MouseEventArgs e)
        {
            TabControl tc = sender as TabControl;
            if (tc == null)
                return;

            if (e.Button != MouseButtons.Right)
                return;
            Point p = e.Location;
            int current = -1;
            for (int i = 0; i < tc.TabCount; i++)
            {
                Rectangle r = tc.GetTabRect(i);
                if (r.Contains(p))
                {
                    current = i;
                    break;
                }
            }
            if (current != tc.SelectedIndex)
                return;             // didn't find the tab

            ContextMenuTB.Show(tc, p);
        }
RdlDesigner