diff --git a/Source/Data/DataManager.cs b/Source/Data/DataManager.cs index 29dc2ea3..e061ce64 100644 --- a/Source/Data/DataManager.cs +++ b/Source/Data/DataManager.cs @@ -231,6 +231,9 @@ namespace CodeImp.DoomBuilder.Data // Sort names texturenames.Sort(); flatnames.Sort(); + + // Update the used textures + General.Map.Data.UpdateUsedTextures(); // Add texture names to texture sets foreach(KeyValuePair img in textures) diff --git a/Source/General/MapManager.cs b/Source/General/MapManager.cs index 7d4ff1a7..40132290 100644 --- a/Source/General/MapManager.cs +++ b/Source/General/MapManager.cs @@ -332,9 +332,6 @@ namespace CodeImp.DoomBuilder maplocation = new DataLocation(DataLocation.RESOURCE_WAD, filepathname, false, false); data.Load(configinfo.Resources, options.Resources, maplocation); - // Update the used textures - General.Map.Data.UpdateUsedTextures(); - // Bind any methods General.Actions.BindMethods(this); @@ -1022,9 +1019,6 @@ namespace CodeImp.DoomBuilder data = new DataManager(); maplocation = new DataLocation(DataLocation.RESOURCE_WAD, filepathname, false, false); data.Load(configinfo.Resources, options.Resources, maplocation); - - // Update the used textures - General.Map.Data.UpdateUsedTextures(); // Apply new settings to map elements map.UpdateConfiguration(); diff --git a/Source/Windows/MainForm.cs b/Source/Windows/MainForm.cs index 5e087ed9..677e89b1 100644 --- a/Source/Windows/MainForm.cs +++ b/Source/Windows/MainForm.cs @@ -411,7 +411,10 @@ namespace CodeImp.DoomBuilder.Windows // This returns the current status text internal string GetCurrentSatus() { - return statuslabel.Text; + if(statustype == StatusType.Busy) + return statuslabel.Text; + else + return null; } // This shows a warning @@ -482,21 +485,29 @@ namespace CodeImp.DoomBuilder.Windows // This changes status text public void DisplayStatus(string status) { - // Stop warning timers - warningtimer.Stop(); - warningflasher.Stop(); - - // Update status description - statustype = StatusType.Busy; - if(statuslabel.Text != status) - statuslabel.Text = status; - - // Update icon as well - UpdateStatusIcon(); - - // Refresh if needed - statusbar.Invalidate(); - this.Update(); + // Null is no busy status + if(status == null) + { + DisplayReady(); + } + else + { + // Stop warning timers + warningtimer.Stop(); + warningflasher.Stop(); + + // Update status description + statustype = StatusType.Busy; + if(statuslabel.Text != status) + statuslabel.Text = status; + + // Update icon as well + UpdateStatusIcon(); + + // Refresh if needed + statusbar.Invalidate(); + this.Update(); + } } // This changes status text to Ready