예제 #1
0
파일: GoalPanel.cs 프로젝트: nandub/DeOps
        private void PlanList_MouseDoubleClick(object sender, MouseEventArgs e)
        {
            PlanListItem item = PlanList.GetItemAt(e.Location) as PlanListItem;

            if (item == null)
            {
                return;
            }

            if (Selected == null)
            {
                return;
            }

            bool local = (Selected.Person == Core.UserID);

            EditItemMode mode = local ? EditItemMode.Edit : EditItemMode.View;
            EditPlanItem form = new EditPlanItem(mode, Selected, item.Item);

            if (form.ShowDialog(this) == DialogResult.OK)
            {
                if (local)
                {
                    View.ChangesMade();
                }
            }
        }
예제 #2
0
파일: GoalPanel.cs 프로젝트: nandub/DeOps
        void Plan_View(object sender, EventArgs e)
        {
            PlanMenuItem menu = sender as PlanMenuItem;

            if (menu == null)
            {
                return;
            }

            EditPlanItem form = new EditPlanItem(EditItemMode.View, Selected, menu.Item);

            form.ShowDialog(this);
        }
예제 #3
0
파일: GoalPanel.cs 프로젝트: nandub/DeOps
        private void AddItemLink_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
        {
            PlanItem item = new PlanItem();

            item.Ident    = Head.Ident;
            item.Project  = Head.Project;
            item.BranchUp = Selected.BranchDown;
            //item.Start = Core.TimeNow.ToUniversalTime();
            //item.End = Selected.End;

            EditPlanItem form = new EditPlanItem(EditItemMode.New, Selected, item);

            if (form.ShowDialog(this) == DialogResult.OK)
            {
                Plans.LocalPlan.AddItem(form.Editing);
                View.ChangesMade();
            }
        }
예제 #4
0
파일: GoalPanel.cs 프로젝트: nandub/DeOps
        void Plan_Edit(object sender, EventArgs e)
        {
            PlanMenuItem menu = sender as PlanMenuItem;

            if (menu == null)
            {
                return;
            }

            if (Selected == null)
            {
                return;
            }

            EditPlanItem form = new EditPlanItem(EditItemMode.Edit, Selected, menu.Item);

            if (form.ShowDialog(this) == DialogResult.OK)
            {
                View.ChangesMade();
            }
        }
예제 #5
0
        void Plan_View(object sender, EventArgs e)
        {
            PlanMenuItem menu = sender as PlanMenuItem;

            if (menu == null)
                return;

            EditPlanItem form = new EditPlanItem(EditItemMode.View, Selected, menu.Item);
            form.ShowDialog(this);
        }
예제 #6
0
        void Plan_Edit(object sender, EventArgs e)
        {
            PlanMenuItem menu = sender as PlanMenuItem;

            if (menu == null)
                return;

            if (Selected == null)
                return;

            EditPlanItem form = new EditPlanItem(EditItemMode.Edit, Selected, menu.Item);

            if (form.ShowDialog(this) == DialogResult.OK)
                View.ChangesMade();
        }
예제 #7
0
        private void PlanList_MouseDoubleClick(object sender, MouseEventArgs e)
        {
            PlanListItem item = PlanList.GetItemAt(e.Location) as PlanListItem;

            if (item == null)
                return;

            if (Selected == null)
                return;

            bool local = (Selected.Person == Core.UserID);

            EditItemMode mode = local ? EditItemMode.Edit : EditItemMode.View;
            EditPlanItem form = new EditPlanItem(mode, Selected, item.Item);

            if (form.ShowDialog(this) == DialogResult.OK)
                if(local)
                    View.ChangesMade();
        }
예제 #8
0
        private void AddItemLink_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
        {
            PlanItem item = new PlanItem();
            item.Ident = Head.Ident;
            item.Project = Head.Project;
            item.BranchUp = Selected.BranchDown;
            //item.Start = Core.TimeNow.ToUniversalTime();
            //item.End = Selected.End;

            EditPlanItem form = new EditPlanItem(EditItemMode.New, Selected, item);

            if (form.ShowDialog(this) == DialogResult.OK)
            {
                Plans.LocalPlan.AddItem(form.Editing);
                View.ChangesMade();
            }
        }