Beispiel #1
0
        public void Register(FigureManager manager)
        {
            m_Manager = manager;

            Shape = createShape();

            Shape.MouseEnter += (s, e) => { if (Focus != null) Focus(); };
            Shape.MouseLeave += (s, e) => { if (Blur != null) Blur(); };
            Shape.MouseLeftButtonDown += (s, e) => { if (Click != null) Click(); };

            m_Manager.Canvas.Children.Add(Shape);
        }
Beispiel #2
0
        public void Register(FigureManager manager)
        {
            m_Manager = manager;

            Shape = createShape();

            Shape.MouseEnter += (s, e) => { if (Focus != null)
                                            {
                                                Focus();
                                            }
            };
            Shape.MouseLeave += (s, e) => { if (Blur != null)
                                            {
                                                Blur();
                                            }
            };
            Shape.MouseLeftButtonDown += (s, e) => { if (Click != null)
                                                     {
                                                         Click();
                                                     }
            };

            m_Manager.Canvas.Children.Add(Shape);
        }