Status bar icons - actually hide conditional status bar icons when not relevant
This commit is contained in:
parent
0b03e6edc8
commit
486d621657
File diff suppressed because it is too large
Load Diff
|
@ -1587,9 +1587,12 @@ namespace BizHawk.MultiClient
|
||||||
}
|
}
|
||||||
|
|
||||||
private void FreezeStatus_Click(object sender, EventArgs e)
|
private void FreezeStatus_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
if (CheatStatus.Visible)
|
||||||
{
|
{
|
||||||
LoadCheatsWindow();
|
LoadCheatsWindow();
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
public void UpdateCheatStatus()
|
public void UpdateCheatStatus()
|
||||||
{
|
{
|
||||||
|
@ -1597,11 +1600,13 @@ namespace BizHawk.MultiClient
|
||||||
{
|
{
|
||||||
CheatStatus.ToolTipText = "Cheats are currently active";
|
CheatStatus.ToolTipText = "Cheats are currently active";
|
||||||
CheatStatus.Image = BizHawk.MultiClient.Properties.Resources.Freeze;
|
CheatStatus.Image = BizHawk.MultiClient.Properties.Resources.Freeze;
|
||||||
|
CheatStatus.Visible = true;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
CheatStatus.ToolTipText = "";
|
CheatStatus.ToolTipText = "";
|
||||||
CheatStatus.Image = BizHawk.MultiClient.Properties.Resources.Blank;
|
CheatStatus.Image = BizHawk.MultiClient.Properties.Resources.Blank;
|
||||||
|
CheatStatus.Visible = false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -56,18 +56,21 @@ namespace BizHawk.MultiClient
|
||||||
Text = DisplayNameForSystem(Global.Game.System) + " - " + Global.Game.Name + " - " + Path.GetFileName(Global.MovieSession.Movie.Filename);
|
Text = DisplayNameForSystem(Global.Game.System) + " - " + Global.Game.Name + " - " + Path.GetFileName(Global.MovieSession.Movie.Filename);
|
||||||
PlayRecordStatus.Image = BizHawk.MultiClient.Properties.Resources.Play;
|
PlayRecordStatus.Image = BizHawk.MultiClient.Properties.Resources.Play;
|
||||||
PlayRecordStatus.ToolTipText = "Movie is in playback mode";
|
PlayRecordStatus.ToolTipText = "Movie is in playback mode";
|
||||||
|
PlayRecordStatus.Visible = true;
|
||||||
}
|
}
|
||||||
else if (Global.MovieSession.Movie.IsRecording)
|
else if (Global.MovieSession.Movie.IsRecording)
|
||||||
{
|
{
|
||||||
Text = DisplayNameForSystem(Global.Game.System) + " - " + Global.Game.Name + " - " + Path.GetFileName(Global.MovieSession.Movie.Filename);
|
Text = DisplayNameForSystem(Global.Game.System) + " - " + Global.Game.Name + " - " + Path.GetFileName(Global.MovieSession.Movie.Filename);
|
||||||
PlayRecordStatus.Image = BizHawk.MultiClient.Properties.Resources.RecordHS;
|
PlayRecordStatus.Image = BizHawk.MultiClient.Properties.Resources.RecordHS;
|
||||||
PlayRecordStatus.ToolTipText = "Movie is in record mode";
|
PlayRecordStatus.ToolTipText = "Movie is in record mode";
|
||||||
|
PlayRecordStatus.Visible = true;
|
||||||
}
|
}
|
||||||
else if (!Global.MovieSession.Movie.IsActive)
|
else if (!Global.MovieSession.Movie.IsActive)
|
||||||
{
|
{
|
||||||
Text = DisplayNameForSystem(Global.Game.System) + " - " + Global.Game.Name;
|
Text = DisplayNameForSystem(Global.Game.System) + " - " + Global.Game.Name;
|
||||||
PlayRecordStatus.Image = BizHawk.MultiClient.Properties.Resources.Blank;
|
PlayRecordStatus.Image = BizHawk.MultiClient.Properties.Resources.Blank;
|
||||||
PlayRecordStatus.ToolTipText = "No movie is active";
|
PlayRecordStatus.ToolTipText = "No movie is active";
|
||||||
|
PlayRecordStatus.Visible = false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -51,7 +51,7 @@ namespace BizHawk.MultiClient
|
||||||
bool exit;
|
bool exit;
|
||||||
bool runloop_frameProgress;
|
bool runloop_frameProgress;
|
||||||
DateTime FrameAdvanceTimestamp = DateTime.MinValue;
|
DateTime FrameAdvanceTimestamp = DateTime.MinValue;
|
||||||
public bool EmulatorPaused;
|
public bool EmulatorPaused { get; private set; }
|
||||||
public EventWaitHandle MainWait;
|
public EventWaitHandle MainWait;
|
||||||
int runloop_fps;
|
int runloop_fps;
|
||||||
int runloop_last_fps;
|
int runloop_last_fps;
|
||||||
|
@ -509,27 +509,35 @@ namespace BizHawk.MultiClient
|
||||||
public void PauseEmulator()
|
public void PauseEmulator()
|
||||||
{
|
{
|
||||||
EmulatorPaused = true;
|
EmulatorPaused = true;
|
||||||
PauseStrip.Image = BizHawk.MultiClient.Properties.Resources.Pause;
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public void UnpauseEmulator()
|
public void UnpauseEmulator()
|
||||||
{
|
{
|
||||||
EmulatorPaused = false;
|
EmulatorPaused = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
private void SetPauseStatusbarIcon()
|
||||||
|
{
|
||||||
|
if (EmulatorPaused)
|
||||||
|
{
|
||||||
|
PauseStrip.Image = BizHawk.MultiClient.Properties.Resources.Pause;
|
||||||
|
PauseStrip.Visible = true;
|
||||||
|
PauseStrip.ToolTipText = "Emulator Paused";
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
PauseStrip.Image = BizHawk.MultiClient.Properties.Resources.Blank;
|
PauseStrip.Image = BizHawk.MultiClient.Properties.Resources.Blank;
|
||||||
|
PauseStrip.Visible = false;
|
||||||
|
PauseStrip.ToolTipText = "";
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public void TogglePause()
|
public void TogglePause()
|
||||||
{
|
{
|
||||||
EmulatorPaused ^= true;
|
EmulatorPaused ^= true;
|
||||||
if (EmulatorPaused)
|
SetPauseStatusbarIcon();
|
||||||
{
|
|
||||||
PauseStrip.Image = BizHawk.MultiClient.Properties.Resources.Pause;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
PauseStrip.Image = BizHawk.MultiClient.Properties.Resources.Blank;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private void LoadRomFromRecent(string rom)
|
private void LoadRomFromRecent(string rom)
|
||||||
|
@ -3184,6 +3192,7 @@ namespace BizHawk.MultiClient
|
||||||
Global.OSD.AddMessage("A/V capture started");
|
Global.OSD.AddMessage("A/V capture started");
|
||||||
AVIStatusLabel.Image = BizHawk.MultiClient.Properties.Resources.AVI;
|
AVIStatusLabel.Image = BizHawk.MultiClient.Properties.Resources.AVI;
|
||||||
AVIStatusLabel.ToolTipText = "A/V capture in progress";
|
AVIStatusLabel.ToolTipText = "A/V capture in progress";
|
||||||
|
AVIStatusLabel.Visible = true;
|
||||||
}
|
}
|
||||||
catch
|
catch
|
||||||
{
|
{
|
||||||
|
@ -3210,6 +3219,7 @@ namespace BizHawk.MultiClient
|
||||||
Global.OSD.AddMessage("AVI capture stopped");
|
Global.OSD.AddMessage("AVI capture stopped");
|
||||||
AVIStatusLabel.Image = BizHawk.MultiClient.Properties.Resources.Blank;
|
AVIStatusLabel.Image = BizHawk.MultiClient.Properties.Resources.Blank;
|
||||||
AVIStatusLabel.ToolTipText = "";
|
AVIStatusLabel.ToolTipText = "";
|
||||||
|
AVIStatusLabel.Visible = false;
|
||||||
DumpProxy = null; // return to normal sound output
|
DumpProxy = null; // return to normal sound output
|
||||||
SoundRemainder = 0;
|
SoundRemainder = 0;
|
||||||
}
|
}
|
||||||
|
@ -3508,6 +3518,12 @@ namespace BizHawk.MultiClient
|
||||||
private void MainForm_Load(object sender, EventArgs e)
|
private void MainForm_Load(object sender, EventArgs e)
|
||||||
{
|
{
|
||||||
Text = "BizHawk" + (INTERIM ? " (interim) " : "");
|
Text = "BizHawk" + (INTERIM ? " (interim) " : "");
|
||||||
|
|
||||||
|
//Hide Status bar icons
|
||||||
|
PlayRecordStatus.Visible = false;
|
||||||
|
AVIStatusLabel.Visible = false;
|
||||||
|
SetPauseStatusbarIcon();
|
||||||
|
UpdateCheatStatus();
|
||||||
}
|
}
|
||||||
|
|
||||||
private void IncreaseWindowSize()
|
private void IncreaseWindowSize()
|
||||||
|
|
|
@ -69,12 +69,15 @@ namespace BizHawk.MultiClient
|
||||||
{
|
{
|
||||||
MemoryPulse.Add(domain, address, value, compare);
|
MemoryPulse.Add(domain, address, value, compare);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Global.MainForm.UpdateCheatStatus();
|
||||||
}
|
}
|
||||||
|
|
||||||
public void Disable()
|
public void Disable()
|
||||||
{
|
{
|
||||||
enabled = false;
|
enabled = false;
|
||||||
DisposeOfCheat();
|
DisposeOfCheat();
|
||||||
|
Global.MainForm.UpdateCheatStatus();
|
||||||
}
|
}
|
||||||
|
|
||||||
public void DisposeOfCheat()
|
public void DisposeOfCheat()
|
||||||
|
|
|
@ -116,6 +116,7 @@ namespace BizHawk.MultiClient
|
||||||
{
|
{
|
||||||
Changes = false;
|
Changes = false;
|
||||||
Global.Config.RecentCheats.Add(file.FullName);
|
Global.Config.RecentCheats.Add(file.FullName);
|
||||||
|
Global.MainForm.UpdateCheatStatus();
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|
|
@ -593,7 +593,7 @@ namespace BizHawk.MultiClient
|
||||||
UpdateNumberOfCheats();
|
UpdateNumberOfCheats();
|
||||||
MessageLabel.Text = Path.GetFileName(Global.CheatList.currentCheatFile);
|
MessageLabel.Text = Path.GetFileName(Global.CheatList.currentCheatFile);
|
||||||
DisplayCheatsList();
|
DisplayCheatsList();
|
||||||
return true; //TODO
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue