示例#1
0
        private void BuildContextMenu()
        {
            _notifyIcon.ContextMenuStrip.Items.Add(
                _startMenuItem = new ToolStripMenuItem(Resources.Tray_Start, null, (a, b) => changer.Start()));
            _notifyIcon.ContextMenuStrip.Items.Add(
                _stopMenuItem = new ToolStripMenuItem(Resources.Tray_Stop, null, (a, b) => changer.Stop()));
            _notifyIcon.ContextMenuStrip.Items.Add(
                _skipMenuItem = new ToolStripMenuItem(Resources.Tray_Skip, null, (a, b) => changer.Start()));

            _notifyIcon.ContextMenuStrip.Items.Add(_startStopSeparator = new ToolStripSeparator());
            _notifyIcon.ContextMenuStrip.Items.Add(
                _setupMenuItem = new ToolStripMenuItem(Resources.Tray_Setup, null, TraySetup_Click));
            _notifyIcon.ContextMenuStrip.Items.Add(new ToolStripSeparator());
            _notifyIcon.ContextMenuStrip.Items.Add(
                new ToolStripMenuItem(Resources.Tray_Close, null, TrayClose_Click));
        }
示例#2
0
 private void btnStop_Click(object sender, EventArgs e)
 {
     _changer.Stop();
     //ShowData();
 }