some more topmosts and sound mutes

This commit is contained in:
feos 2017-03-14 22:13:51 +03:00
parent 19cf3b8551
commit 868c02175c
4 changed files with 11 additions and 1 deletions

View File

@ -165,7 +165,7 @@ namespace BizHawk.Client.EmuHawk.WinFormExtensions
form.StartPosition = FormStartPosition.Manual;
form.Location = position;
}
var result = (owner == null ? form.ShowDialog() : form.ShowDialog(owner));
var result = (owner == null ? form.ShowDialog(new Form() { TopMost = true }) : form.ShowDialog(owner));
GlobalWin.Sound.StartSound();
return result;
}

View File

@ -95,6 +95,7 @@
this.ShowIcon = false;
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent;
this.Text = "Input Prompt";
this.TopMost = true;
this.Load += new System.EventHandler(this.InputPrompt_Load);
this.ResumeLayout(false);
this.PerformLayout();

View File

@ -15,6 +15,7 @@ namespace BizHawk.Client.EmuHawk
{
public InputPrompt()
{
GlobalWin.Sound.StopSound();
InitializeComponent();
StartLocation = new Point(-1, -1);
}
@ -60,12 +61,14 @@ namespace BizHawk.Client.EmuHawk
{
DialogResult = DialogResult.OK;
Close();
GlobalWin.Sound.StartSound();
}
private void Cancel_Click(object sender, EventArgs e)
{
DialogResult = DialogResult.Cancel;
Close();
GlobalWin.Sound.StartSound();
}
private void PromptBox_KeyPress(object sender, KeyPressEventArgs e)

View File

@ -108,6 +108,7 @@ namespace BizHawk.Client.EmuHawk
else
{
_autosaveTimer.Stop();
GlobalWin.Sound.StopSound();
MessageStatusLabel.Text = "Saving...";
this.Cursor = Cursors.WaitCursor;
Update();
@ -117,6 +118,7 @@ namespace BizHawk.Client.EmuHawk
MessageStatusLabel.Text = CurrentTasMovie.Name + " saved.";
Settings.RecentTas.Add(CurrentTasMovie.Filename);
this.Cursor = Cursors.Default;
GlobalWin.Sound.StartSound();
}
}
@ -131,6 +133,7 @@ namespace BizHawk.Client.EmuHawk
private void SaveAsTas(object sender, EventArgs e)
{
_autosaveTimer.Stop();
GlobalWin.Sound.StopSound();
ClearLeftMouseStates();
var filename = CurrentTasMovie.Filename;
if (string.IsNullOrWhiteSpace(filename) || filename == DefaultTasProjName())
@ -159,6 +162,7 @@ namespace BizHawk.Client.EmuHawk
// keep insisting
if (Settings.AutosaveInterval > 0)
_autosaveTimer.Start();
GlobalWin.Sound.StartSound();
}
// call this one from the menu only
@ -179,6 +183,7 @@ namespace BizHawk.Client.EmuHawk
else
{
_autosaveTimer.Stop();
GlobalWin.Sound.StopSound();
MessageStatusLabel.Text = "Saving...";
this.Cursor = Cursors.WaitCursor;
Update();
@ -188,6 +193,7 @@ namespace BizHawk.Client.EmuHawk
MessageStatusLabel.Text = "Backup .tasproj saved to \"Movie backups\" path.";
Settings.RecentTas.Add(CurrentTasMovie.Filename);
this.Cursor = Cursors.Default;
GlobalWin.Sound.StartSound();
}
}