Exemplo n.º 1
0
    private void hover_EditPropertiesClicked(object sender, EventArgs e)
    {
        Strokes selected = inkoverlay.Selection;

        if (selected == null || selected.Count != 1)
        {
            return;
        }

        // Get objects for the targeted stroke(s).  Ensure that only one is selected.
        RigidBodyBase[] bodies = doc.GetBodiesFor(selected);
        if (bodies.Length != 1)
        {
            return;
        }

        RigidBodyBase body = bodies[0];

        using (BodyPropertiesForm bpf = new BodyPropertiesForm(body))
        {
            bpf.ShowDialog(this);
            Invalidate();
        }
    }
Exemplo n.º 2
0
    private void hover_EditPropertiesClicked(object sender, EventArgs e)
    {
        Strokes selected = inkoverlay.Selection;
        if (selected == null || selected.Count != 1) return;

        // Get objects for the targeted stroke(s).  Ensure that only one is selected.
        RigidBodyBase[] bodies = doc.GetBodiesFor(selected);
        if (bodies.Length != 1) return;

        RigidBodyBase body = bodies[0];

        using (BodyPropertiesForm bpf = new BodyPropertiesForm(body))
        {
            bpf.ShowDialog(this);
            Invalidate();
        }
    }