mirror of
https://git.do.srb2.org/STJr/UltimateZoneBuilder.git
synced 2024-11-26 22:01:45 +00:00
fixed incorrect red "busy" status light
This commit is contained in:
parent
6d6b594c24
commit
0b0f3777ac
3 changed files with 30 additions and 22 deletions
|
@ -231,6 +231,9 @@ namespace CodeImp.DoomBuilder.Data
|
||||||
// Sort names
|
// Sort names
|
||||||
texturenames.Sort();
|
texturenames.Sort();
|
||||||
flatnames.Sort();
|
flatnames.Sort();
|
||||||
|
|
||||||
|
// Update the used textures
|
||||||
|
General.Map.Data.UpdateUsedTextures();
|
||||||
|
|
||||||
// Add texture names to texture sets
|
// Add texture names to texture sets
|
||||||
foreach(KeyValuePair<long, ImageData> img in textures)
|
foreach(KeyValuePair<long, ImageData> img in textures)
|
||||||
|
|
|
@ -332,9 +332,6 @@ namespace CodeImp.DoomBuilder
|
||||||
maplocation = new DataLocation(DataLocation.RESOURCE_WAD, filepathname, false, false);
|
maplocation = new DataLocation(DataLocation.RESOURCE_WAD, filepathname, false, false);
|
||||||
data.Load(configinfo.Resources, options.Resources, maplocation);
|
data.Load(configinfo.Resources, options.Resources, maplocation);
|
||||||
|
|
||||||
// Update the used textures
|
|
||||||
General.Map.Data.UpdateUsedTextures();
|
|
||||||
|
|
||||||
// Bind any methods
|
// Bind any methods
|
||||||
General.Actions.BindMethods(this);
|
General.Actions.BindMethods(this);
|
||||||
|
|
||||||
|
@ -1022,9 +1019,6 @@ namespace CodeImp.DoomBuilder
|
||||||
data = new DataManager();
|
data = new DataManager();
|
||||||
maplocation = new DataLocation(DataLocation.RESOURCE_WAD, filepathname, false, false);
|
maplocation = new DataLocation(DataLocation.RESOURCE_WAD, filepathname, false, false);
|
||||||
data.Load(configinfo.Resources, options.Resources, maplocation);
|
data.Load(configinfo.Resources, options.Resources, maplocation);
|
||||||
|
|
||||||
// Update the used textures
|
|
||||||
General.Map.Data.UpdateUsedTextures();
|
|
||||||
|
|
||||||
// Apply new settings to map elements
|
// Apply new settings to map elements
|
||||||
map.UpdateConfiguration();
|
map.UpdateConfiguration();
|
||||||
|
|
|
@ -411,7 +411,10 @@ namespace CodeImp.DoomBuilder.Windows
|
||||||
// This returns the current status text
|
// This returns the current status text
|
||||||
internal string GetCurrentSatus()
|
internal string GetCurrentSatus()
|
||||||
{
|
{
|
||||||
return statuslabel.Text;
|
if(statustype == StatusType.Busy)
|
||||||
|
return statuslabel.Text;
|
||||||
|
else
|
||||||
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
// This shows a warning
|
// This shows a warning
|
||||||
|
@ -482,21 +485,29 @@ namespace CodeImp.DoomBuilder.Windows
|
||||||
// This changes status text
|
// This changes status text
|
||||||
public void DisplayStatus(string status)
|
public void DisplayStatus(string status)
|
||||||
{
|
{
|
||||||
// Stop warning timers
|
// Null is no busy status
|
||||||
warningtimer.Stop();
|
if(status == null)
|
||||||
warningflasher.Stop();
|
{
|
||||||
|
DisplayReady();
|
||||||
// Update status description
|
}
|
||||||
statustype = StatusType.Busy;
|
else
|
||||||
if(statuslabel.Text != status)
|
{
|
||||||
statuslabel.Text = status;
|
// Stop warning timers
|
||||||
|
warningtimer.Stop();
|
||||||
// Update icon as well
|
warningflasher.Stop();
|
||||||
UpdateStatusIcon();
|
|
||||||
|
// Update status description
|
||||||
// Refresh if needed
|
statustype = StatusType.Busy;
|
||||||
statusbar.Invalidate();
|
if(statuslabel.Text != status)
|
||||||
this.Update();
|
statuslabel.Text = status;
|
||||||
|
|
||||||
|
// Update icon as well
|
||||||
|
UpdateStatusIcon();
|
||||||
|
|
||||||
|
// Refresh if needed
|
||||||
|
statusbar.Invalidate();
|
||||||
|
this.Update();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// This changes status text to Ready
|
// This changes status text to Ready
|
||||||
|
|
Loading…
Reference in a new issue