public void PopUpPostIt(PostIt p) { if (listPostit.Remove(p)) { listPostit.Insert(0, p); } }
public PostIt CreateNewPostit(int x, int y) { var p = new PostIt(x, y); listPostit.Insert(0, p); return(p); }
public DesignPostIt(PostIt p) { idModel = p.GetID(); InitializeComponent(); Controls.Add(tb); Display(p); Enabled = true; }
public DesignPostIt CreateNewPostItDesigner(PostIt p, AbstractControler controler) { var design = new DesignPostIt(p); Controls.Add(design); Controls.SetChildIndex(design, 0); design.SetControler(controler); return(design); }
public object Clone() { var p = new PostIt(); p.id = id; p.text = text; p.x = x; p.y = y; p.selected = false; return(p); }
public void Display(PostIt postIt) { if (postIt.GetText() != tb.Text) { tb.Text = postIt.GetText(); } Location = new Point(postIt.GetX(), postIt.GetY()); if (postIt.IsSelected()) { Selected(); } else { Deseleted(); } }
public DesignPostItControler(Model model, PostitEditor view, int idModel) : base(model, view) { mousePosition = new Point(0, 0); postIt = model.GetPostItByID(idModel); isMoved = false; }
public int GetIndex(PostIt p) { return(listPostit.IndexOf(p)); }
public bool Correspond(PostIt p) { return(p.GetID() == idModel); }