예제 #1
0
        private void SettingsRibbonButton_Click(object sender, RibbonControlEventArgs e)
        {
            var settingsDialog = new TaskSettingsDialog(this._addinRibbonTab, Task);

            if (settingsDialog.ShowDialog() == DialogResult.OK)
            {
                UpdateGUI();
                _addinRibbonTab.UpdateGUI();
            }
        }
예제 #2
0
        private void AddTaskRibbonButton_Click(object sender, RibbonControlEventArgs e)
        {
            var addNewTask = new TaskSettingsDialog(this)
            {
                Text = "Add New Task"
            };

            if (addNewTask.ShowDialog() == System.Windows.Forms.DialogResult.OK)
            {
                addNewTask.Task.Id = tasks.NextId();
                tasks.AddOrUpdate(addNewTask.Task);
                UpdateGUI();
            }
        }