mirror of
https://github.com/cemu-project/DS4Windows.git
synced 2024-11-29 20:44:20 +01:00
Allow saving and editing loadProfile special action without unload trigger definition (ie. don't crash when editing specAction without unload trigger and allow saving an empty list of unload trigger keys for loadProfile action type).
This commit is contained in:
parent
1e82db0f9e
commit
88e3e0e3a2
@ -92,13 +92,16 @@ namespace DS4Windows
|
|||||||
case "Profile":
|
case "Profile":
|
||||||
cBActions.SelectedIndex = 3;
|
cBActions.SelectedIndex = 3;
|
||||||
cBProfiles.Text = act.details;
|
cBProfiles.Text = act.details;
|
||||||
foreach (string s in act.ucontrols.Split('/'))
|
if (act.ucontrols != null)
|
||||||
foreach (ListViewItem lvi in lVUnloadTrigger.Items)
|
{
|
||||||
if (lvi.Text == s)
|
foreach (string s in act.ucontrols.Split('/'))
|
||||||
{
|
foreach (ListViewItem lvi in lVUnloadTrigger.Items)
|
||||||
lvi.Checked = true;
|
if (lvi.Text == s)
|
||||||
break;
|
{
|
||||||
}
|
lvi.Checked = true;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
case "Key":
|
case "Key":
|
||||||
cBActions.SelectedIndex = 4;
|
cBActions.SelectedIndex = 4;
|
||||||
@ -261,7 +264,7 @@ namespace DS4Windows
|
|||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case 3:
|
case 3:
|
||||||
if (cBProfiles.SelectedIndex > 0 && ucontrols.Count > 0)
|
if (cBProfiles.SelectedIndex > 0 /*&& ucontrols.Count > 0*/)
|
||||||
{
|
{
|
||||||
action = Properties.Resources.LoadProfile.Replace("*profile*", cBProfiles.Text);
|
action = Properties.Resources.LoadProfile.Replace("*profile*", cBProfiles.Text);
|
||||||
actRe = true;
|
actRe = true;
|
||||||
|
Loading…
Reference in New Issue
Block a user