diff --git a/EduNetworkBuilder/NetShape.cs b/EduNetworkBuilder/NetShape.cs index f580a34..cf2a158 100644 --- a/EduNetworkBuilder/NetShape.cs +++ b/EduNetworkBuilder/NetShape.cs @@ -55,7 +55,7 @@ namespace EduNetworkBuilder } if(InShapeEditMode) { - int sz = 5; + int sz = 15; Color edgeColor = Color.Black; if (FillColor == Color.Black) edgeColor = Color.White; coloredBrush = new SolidBrush(edgeColor); diff --git a/EduNetworkBuilder/Network.cs b/EduNetworkBuilder/Network.cs index f684f36..ef8b8b0 100644 --- a/EduNetworkBuilder/Network.cs +++ b/EduNetworkBuilder/Network.cs @@ -70,6 +70,7 @@ namespace EduNetworkBuilder private List BrokenItems = new List(); private List Shapes = new List(); //For storing simple shapes which are drawn on the network public bool IsRandomNetwork = false; + public bool InShapeEditMode = false; private List Animations = new List(); @@ -800,7 +801,7 @@ namespace EduNetworkBuilder Graphics.FromImage(TheNetImage).FillRectangle(theBrush, new Rectangle(0,0, TheNetImage.Width, TheNetImage.Height)); //re-generate the image foreach (NetShape shape in Shapes) - shape.Draw(TheNetImage); //Draw any shapes + shape.Draw(TheNetImage, InShapeEditMode); //Draw any shapes //Do all the links first foreach (NetworkComponent NC in NetComponents) { diff --git a/EduNetworkBuilder/NetworkBuilder.cs b/EduNetworkBuilder/NetworkBuilder.cs index 7289a1d..c64b89b 100644 --- a/EduNetworkBuilder/NetworkBuilder.cs +++ b/EduNetworkBuilder/NetworkBuilder.cs @@ -741,14 +741,22 @@ namespace EduNetworkBuilder btn.BackColor = Color.LightGreen; selectedButton = btn.Name; lblStatus.Text = myTooltip.GetToolTip(btn); - if (selectedButton == "btnShapes") doupdate = true; + myNetwork.InShapeEditMode = true; + if (selectedButton == "btnShapes") { + myNetwork.InShapeEditMode = true; + doupdate = true; + } + else + { + myNetwork.InShapeEditMode = false; + } } else { btn.BackColor = Button.DefaultBackColor; } } - if (doupdate) UpdateForm(); + if (doupdate) { UpdateForm(); } } private void btnReset() {