From ae5b297475f75328b23e8951e7c38973e26217b4 Mon Sep 17 00:00:00 2001 From: Jonathan Westhues Date: Thu, 7 Jan 2010 00:02:13 -0800 Subject: [PATCH] Add warning when user tries to toggle construction with nothing selected. [git-p4: depot-paths = "//depot/solvespace/": change = 2097] --- graphicswin.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/graphicswin.cpp b/graphicswin.cpp index a733ac3..579d15b 100644 --- a/graphicswin.cpp +++ b/graphicswin.cpp @@ -847,6 +847,10 @@ c: case MNU_CONSTRUCTION: { SS.UndoRemember(); SS.GW.GroupSelection(); + if(SS.GW.gs.entities == 0) { + Error("No entities are selected. Select entities before " + "trying to toggle their construction state."); + } int i; for(i = 0; i < SS.GW.gs.entities; i++) { hEntity he = SS.GW.gs.entity[i];