stop displaying spurious help messages & pop open help when we launch a network
This commit is contained in:
parent
e5512b06b0
commit
3a7a3f4299
@ -96,6 +96,7 @@ namespace EduNetworkBuilder
|
||||
|
||||
public static void Clone(Network source, Network dest)
|
||||
{
|
||||
dest.AlreadyDisplayedMessage = false;
|
||||
dest.DefaultTimeout = source.DefaultTimeout;
|
||||
dest.HintsToDisplay = source.HintsToDisplay;
|
||||
dest.itemsize = source.itemsize;
|
||||
@ -161,7 +162,7 @@ namespace EduNetworkBuilder
|
||||
}
|
||||
}
|
||||
|
||||
public void Load(XmlNode TheNode, string Name, bool FromResource=false)
|
||||
public void Load(XmlNode TheNode, string Name, bool FromResource=false, bool skipOpeningWindows = false)
|
||||
{
|
||||
_isDirty = true;
|
||||
NetworkDevice newND;
|
||||
@ -277,7 +278,17 @@ namespace EduNetworkBuilder
|
||||
}
|
||||
DoAllVerifyLinks();
|
||||
DoAllAutoJoin();
|
||||
if (NetMessage.GetText() != "" && !AlreadyDisplayedMessage)
|
||||
OpenHelpIfNeeded(skipOpeningWindows);
|
||||
if (NetTests.Count > 0)
|
||||
PuzzleIsSolved = false; //When we load the puzzle.
|
||||
|
||||
if (newUnique != -1)
|
||||
UniqueIdentifier = newUnique;
|
||||
}
|
||||
|
||||
public void OpenHelpIfNeeded(bool skipOpeningWindows)
|
||||
{
|
||||
if (NetMessage.GetText() != "" && !AlreadyDisplayedMessage & !skipOpeningWindows)
|
||||
{
|
||||
//We have a message loaded on this network. Display it
|
||||
BuilderWindow myWin = (BuilderWindow)Application.OpenForms["BuilderWindow"];
|
||||
@ -291,14 +302,8 @@ namespace EduNetworkBuilder
|
||||
}
|
||||
AlreadyDisplayedMessage = true;
|
||||
}
|
||||
if(NetTests.Count > 0)
|
||||
PuzzleIsSolved = false; //When we load the puzzle.
|
||||
|
||||
if (newUnique != -1)
|
||||
UniqueIdentifier = newUnique;
|
||||
}
|
||||
|
||||
|
||||
public void Save()
|
||||
{
|
||||
Save(Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.Desktop), "Test.enbx"));
|
||||
|
@ -1585,6 +1585,7 @@ namespace EduNetworkBuilder
|
||||
{
|
||||
PrepForLoad();
|
||||
Network.Clone(NewNet, myNetwork); //Push the settings
|
||||
myNetwork.OpenHelpIfNeeded(false);
|
||||
UpdateMenu();
|
||||
UpdateForm();
|
||||
}
|
||||
|
@ -103,7 +103,7 @@ namespace EduNetworkBuilder
|
||||
break;
|
||||
case "network":
|
||||
theProject = new Network();
|
||||
theProject.Load(Individual, "");
|
||||
theProject.Load(Individual, "",false,true);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user