From: Andy Date: Wed, 13 Nov 2013 00:19:39 +0000 Subject: Merge branch 'laptop_dev' X-Git-Tag: 0.9.11 X-Git-Url: http://git.toad.homelinux.net/projects/VOID.git/commitdiff/4c4d0b6 --- Merge branch 'laptop_dev' --- --- a/VOID.csproj +++ b/VOID.csproj @@ -22,7 +22,7 @@ false - + @@ -35,7 +35,7 @@ TRACE - + @@ -61,13 +61,16 @@ - ..\..\..\Games\KSP_win\KSP_Data\Managed\Assembly-CSharp.dll + ..\..\..\..\..\mnt\games-ssd\KSP_linux\KSP_Data\Managed\Assembly-CSharp.dll + False - ..\..\..\Games\KSP_win\KSP_Data\Managed\UnityEngine.dll + ..\..\..\..\..\mnt\games-ssd\KSP_linux\KSP_Data\Managed\UnityEngine.dll + False - ..\..\..\Games\KSP_win\KSP_Data\Managed\System.dll + ..\..\..\..\..\mnt\games-ssd\KSP_linux\KSP_Data\Managed\System.dll + False --- a/VOIDFlightMaster.cs +++ b/VOIDFlightMaster.cs @@ -48,8 +48,7 @@ { Tools.PostDebugMessage ("VOIDFlightMaster: Waking up."); this.Core = (VOID_Core)VOID_Core.Instance; - this.Core.StopGUI (); - this.Core.StartGUI (); + this.Core.ResetGUI (); Tools.PostDebugMessage ("VOIDFlightMaster: Awake."); } @@ -72,7 +71,8 @@ if (this.Core.vessel != null) { - SimManager.Instance.Gravity = VOID_Core.Instance.vessel.mainBody.gravParameter / Math.Pow(VOID_Core.Instance.vessel.mainBody.Radius, 2); + SimManager.Instance.Gravity = VOID_Core.Instance.vessel.mainBody.gravParameter / + Math.Pow(VOID_Core.Instance.vessel.mainBody.Radius, 2); SimManager.Instance.TryStartSimulation(); } @@ -114,8 +114,7 @@ { Tools.PostDebugMessage ("VOIDEditorMaster: Waking up."); this.Core = VOID_EditorCore.Instance; - this.Core.StopGUI (); - this.Core.StartGUI (); + this.Core.ResetGUI (); Tools.PostDebugMessage ("VOIDEditorMaster: Awake."); } --- a/VOID_Core.cs +++ b/VOID_Core.cs @@ -694,6 +694,19 @@ } } + public void ResetGUI() + { + this.StopGUI (); + + foreach (IVOID_Module module in this.Modules) + { + module.StopGUI (); + module.StartGUI (); + } + + this.StartGUI (); + } + public override void LoadConfig() { base.LoadConfig ();