コード例 #1
0
ファイル: MainForm.cs プロジェクト: jova/JoScrum
        private void addATaskToolStripMenuItem_Click(object sender, EventArgs e)
        {
            ToolStripItem    menuItem = sender as ToolStripItem;
            ContextMenuStrip owner    = menuItem.Owner as ContextMenuStrip;
            TextBox          textBox  = owner.SourceControl as TextBox;

            AddTaskForm addTaskForm = new AddTaskForm(textBox.Name);

            addTaskForm.ShowDialog();
        }
コード例 #2
0
ファイル: MainForm.cs プロジェクト: jova/JoScrum
        private void viewToolStripMenuItem_Click(object sender, EventArgs e)
        {
            ToolStripItem    menuItem = sender as ToolStripItem;
            ContextMenuStrip owner    = menuItem.Owner as ContextMenuStrip;
            TextBox          textBox  = owner.SourceControl as TextBox;
            Panel            panel    = textBox.Parent as Panel;

            StoryTask   task        = JoScrum.GetTask(panel.Name, textBox.Name);
            AddTaskForm addTaskForm = new AddTaskForm(task);

            addTaskForm.ShowDialog();
        }