mirror of
https://github.com/cemu-project/DS4Windows.git
synced 2024-11-29 20:44:20 +01:00
Disable control service button while a routine is active
This commit is contained in:
parent
0630719ffc
commit
af9557e53b
@ -1163,6 +1163,7 @@ Properties.Resources.DS4Update, MessageBoxButtons.YesNo, MessageBoxIcon.Question
|
|||||||
{
|
{
|
||||||
var uiContext = SynchronizationContext.Current;
|
var uiContext = SynchronizationContext.Current;
|
||||||
changingService = true;
|
changingService = true;
|
||||||
|
btnStartStop.Enabled = false;
|
||||||
TaskRunner.Run(() =>
|
TaskRunner.Run(() =>
|
||||||
{
|
{
|
||||||
//Thread.CurrentThread.Priority = ThreadPriority.AboveNormal;
|
//Thread.CurrentThread.Priority = ThreadPriority.AboveNormal;
|
||||||
@ -1187,11 +1188,13 @@ Properties.Resources.DS4Update, MessageBoxButtons.YesNo, MessageBoxIcon.Question
|
|||||||
}
|
}
|
||||||
|
|
||||||
startToolStripMenuItem.Text = btnStartStop.Text = Properties.Resources.StopText;
|
startToolStripMenuItem.Text = btnStartStop.Text = Properties.Resources.StopText;
|
||||||
|
btnStartStop.Enabled = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
private void ServiceShutdown(bool log)
|
private void ServiceShutdown(bool log)
|
||||||
{
|
{
|
||||||
changingService = true;
|
changingService = true;
|
||||||
|
btnStartStop.Enabled = false;
|
||||||
TaskRunner.Run(() =>
|
TaskRunner.Run(() =>
|
||||||
{
|
{
|
||||||
Program.rootHub.Stop(log);
|
Program.rootHub.Stop(log);
|
||||||
@ -1207,6 +1210,7 @@ Properties.Resources.DS4Update, MessageBoxButtons.YesNo, MessageBoxIcon.Question
|
|||||||
//hotkeysTimer.Stop();
|
//hotkeysTimer.Stop();
|
||||||
//autoProfilesTimer.Stop();
|
//autoProfilesTimer.Stop();
|
||||||
startToolStripMenuItem.Text = btnStartStop.Text = Properties.Resources.StartText;
|
startToolStripMenuItem.Text = btnStartStop.Text = Properties.Resources.StartText;
|
||||||
|
btnStartStop.Enabled = true;
|
||||||
blankControllerTab();
|
blankControllerTab();
|
||||||
populateFullNotifyText();
|
populateFullNotifyText();
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user