devices can be locked to a region. They can be moved around somewhat, but only within a named shape. You can still lock a device so it cannot be moved around at all.
This commit is contained in:
		@@ -1193,6 +1193,29 @@ namespace EduNetworkBuilder
 | 
			
		||||
            return Descriptions;
 | 
			
		||||
        }
 | 
			
		||||
 | 
			
		||||
        public Rectangle RectangleByNamedShape(string Name)
 | 
			
		||||
        {
 | 
			
		||||
            foreach (NetShape NS in Shapes)
 | 
			
		||||
            {
 | 
			
		||||
                if (NS.Name == Name)
 | 
			
		||||
                    return NS.InArea;
 | 
			
		||||
            }
 | 
			
		||||
            return new Rectangle(0, 0, myWidth, myHeight); //return the biggest one we can do
 | 
			
		||||
        }
 | 
			
		||||
 | 
			
		||||
        public List<string> DeviceLockedToShapes(string Host)
 | 
			
		||||
        {
 | 
			
		||||
            List<string> ShapeNames = new List<string>();
 | 
			
		||||
            foreach(NetTest NS in NetTests)
 | 
			
		||||
            {
 | 
			
		||||
                if(NS.sHost == Host && NS.TheTest == NetTestType.LockLocation)
 | 
			
		||||
                {
 | 
			
		||||
                    ShapeNames.Add(NS.dHost);
 | 
			
		||||
                }
 | 
			
		||||
            }
 | 
			
		||||
            return ShapeNames;
 | 
			
		||||
        }
 | 
			
		||||
 | 
			
		||||
        void KillAllExtraWindows(bool EvenRTF=false)
 | 
			
		||||
        {
 | 
			
		||||
            for(int i = Application.OpenForms.Count -1; i >=0; i--)
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user