Пример #1
0
        private void toolSplitObject_Click(object sender, EventArgs e)
        {
            PrintModel act = SingleSelectedModel;

            if (act == null)
            {
                return;
            }
            List <TopoModel> models = act.ActiveModel.SplitIntoSurfaces();

            if (models.Count == 1)
            {
                return;
            }
            int idx = 1;

            foreach (TopoModel m in models)
            {
                PrintModel pm = act.cloneWithModel(m, idx++);
                cont.models.AddLast(pm);
                AddObject(pm);
            }
            cont.models.Remove(act);
            RemoveObject(act);
        }