mirror of
https://github.com/cemu-project/DS4Windows.git
synced 2024-12-23 23:21:49 +01:00
Fix errors when using multiple special actions
This commit is contained in:
parent
6ae80efad4
commit
91f36e4297
@ -2596,6 +2596,8 @@ namespace DS4Windows
|
||||
else if (type == "BatteryCheck")
|
||||
{
|
||||
typeID = ActionTypeId.BatteryCheck;
|
||||
string[] dets = details.Split('|');
|
||||
this.details = string.Join(",", dets);
|
||||
}
|
||||
else if (type == "MultiAction")
|
||||
{
|
||||
|
106
DS4Windows/DS4Forms/Options.Designer.cs
generated
106
DS4Windows/DS4Forms/Options.Designer.cs
generated
@ -257,6 +257,10 @@
|
||||
this.lbLSCurvePercent = new System.Windows.Forms.Label();
|
||||
this.lbLSCurve = new System.Windows.Forms.Label();
|
||||
this.antiDeadzoneTabPage = new System.Windows.Forms.TabPage();
|
||||
this.nUDR2AntiDead = new System.Windows.Forms.NumericUpDown();
|
||||
this.label3 = new System.Windows.Forms.Label();
|
||||
this.nUDL2AntiDead = new System.Windows.Forms.NumericUpDown();
|
||||
this.label4 = new System.Windows.Forms.Label();
|
||||
this.nUDRSAntiDead = new System.Windows.Forms.NumericUpDown();
|
||||
this.label2 = new System.Windows.Forms.Label();
|
||||
this.nUDLSAntiDead = new System.Windows.Forms.NumericUpDown();
|
||||
@ -307,10 +311,6 @@
|
||||
this.shareToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.pSToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.alwaysOnToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.nUDR2AntiDead = new System.Windows.Forms.NumericUpDown();
|
||||
this.label3 = new System.Windows.Forms.Label();
|
||||
this.nUDL2AntiDead = new System.Windows.Forms.NumericUpDown();
|
||||
this.label4 = new System.Windows.Forms.Label();
|
||||
this.advColorDialog = new DS4Windows.AdvancedColorDialog();
|
||||
((System.ComponentModel.ISupportInitialize)(this.nUDRainbow)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.tBBlueBar)).BeginInit();
|
||||
@ -372,6 +372,8 @@
|
||||
((System.ComponentModel.ISupportInitialize)(this.nUDLSCurve)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.nUDRSCurve)).BeginInit();
|
||||
this.antiDeadzoneTabPage.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.nUDR2AntiDead)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.nUDL2AntiDead)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.nUDRSAntiDead)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.nUDLSAntiDead)).BeginInit();
|
||||
this.fLPSettings.SuspendLayout();
|
||||
@ -386,8 +388,6 @@
|
||||
((System.ComponentModel.ISupportInitialize)(this.nUDSXS)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.nUDSZS)).BeginInit();
|
||||
this.cMGyroTriggers.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.nUDR2AntiDead)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.nUDL2AntiDead)).BeginInit();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// lowColorChooserButton
|
||||
@ -2507,7 +2507,7 @@
|
||||
this.lVActions.ShowItemToolTips = true;
|
||||
this.lVActions.UseCompatibleStateImageBehavior = false;
|
||||
this.lVActions.View = System.Windows.Forms.View.Details;
|
||||
this.lVActions.ItemChecked += new System.Windows.Forms.ItemCheckedEventHandler(this.lVActions_ItemChecked);
|
||||
this.lVActions.ItemCheck += new System.Windows.Forms.ItemCheckEventHandler(this.lVActions_ItemCheck);
|
||||
//
|
||||
// cHName
|
||||
//
|
||||
@ -2657,6 +2657,50 @@
|
||||
this.antiDeadzoneTabPage.Name = "antiDeadzoneTabPage";
|
||||
this.antiDeadzoneTabPage.UseVisualStyleBackColor = true;
|
||||
//
|
||||
// nUDR2AntiDead
|
||||
//
|
||||
this.nUDR2AntiDead.DecimalPlaces = 2;
|
||||
this.nUDR2AntiDead.Increment = new decimal(new int[] {
|
||||
1,
|
||||
0,
|
||||
0,
|
||||
65536});
|
||||
resources.ApplyResources(this.nUDR2AntiDead, "nUDR2AntiDead");
|
||||
this.nUDR2AntiDead.Maximum = new decimal(new int[] {
|
||||
1,
|
||||
0,
|
||||
0,
|
||||
0});
|
||||
this.nUDR2AntiDead.Name = "nUDR2AntiDead";
|
||||
this.nUDR2AntiDead.ValueChanged += new System.EventHandler(this.nUDR2AntiDead_ValueChanged);
|
||||
//
|
||||
// label3
|
||||
//
|
||||
resources.ApplyResources(this.label3, "label3");
|
||||
this.label3.Name = "label3";
|
||||
//
|
||||
// nUDL2AntiDead
|
||||
//
|
||||
this.nUDL2AntiDead.DecimalPlaces = 2;
|
||||
this.nUDL2AntiDead.Increment = new decimal(new int[] {
|
||||
1,
|
||||
0,
|
||||
0,
|
||||
65536});
|
||||
resources.ApplyResources(this.nUDL2AntiDead, "nUDL2AntiDead");
|
||||
this.nUDL2AntiDead.Maximum = new decimal(new int[] {
|
||||
1,
|
||||
0,
|
||||
0,
|
||||
0});
|
||||
this.nUDL2AntiDead.Name = "nUDL2AntiDead";
|
||||
this.nUDL2AntiDead.ValueChanged += new System.EventHandler(this.nUDL2AntiDead_ValueChanged);
|
||||
//
|
||||
// label4
|
||||
//
|
||||
resources.ApplyResources(this.label4, "label4");
|
||||
this.label4.Name = "label4";
|
||||
//
|
||||
// nUDRSAntiDead
|
||||
//
|
||||
this.nUDRSAntiDead.DecimalPlaces = 2;
|
||||
@ -3204,50 +3248,6 @@
|
||||
resources.ApplyResources(this.alwaysOnToolStripMenuItem, "alwaysOnToolStripMenuItem");
|
||||
this.alwaysOnToolStripMenuItem.CheckedChanged += new System.EventHandler(this.SATrigger_CheckedChanged);
|
||||
//
|
||||
// nUDR2AntiDead
|
||||
//
|
||||
this.nUDR2AntiDead.DecimalPlaces = 2;
|
||||
this.nUDR2AntiDead.Increment = new decimal(new int[] {
|
||||
1,
|
||||
0,
|
||||
0,
|
||||
65536});
|
||||
resources.ApplyResources(this.nUDR2AntiDead, "nUDR2AntiDead");
|
||||
this.nUDR2AntiDead.Maximum = new decimal(new int[] {
|
||||
1,
|
||||
0,
|
||||
0,
|
||||
0});
|
||||
this.nUDR2AntiDead.Name = "nUDR2AntiDead";
|
||||
this.nUDR2AntiDead.ValueChanged += new System.EventHandler(this.nUDR2AntiDead_ValueChanged);
|
||||
//
|
||||
// label3
|
||||
//
|
||||
resources.ApplyResources(this.label3, "label3");
|
||||
this.label3.Name = "label3";
|
||||
//
|
||||
// nUDL2AntiDead
|
||||
//
|
||||
this.nUDL2AntiDead.DecimalPlaces = 2;
|
||||
this.nUDL2AntiDead.Increment = new decimal(new int[] {
|
||||
1,
|
||||
0,
|
||||
0,
|
||||
65536});
|
||||
resources.ApplyResources(this.nUDL2AntiDead, "nUDL2AntiDead");
|
||||
this.nUDL2AntiDead.Maximum = new decimal(new int[] {
|
||||
1,
|
||||
0,
|
||||
0,
|
||||
0});
|
||||
this.nUDL2AntiDead.Name = "nUDL2AntiDead";
|
||||
this.nUDL2AntiDead.ValueChanged += new System.EventHandler(this.nUDL2AntiDead_ValueChanged);
|
||||
//
|
||||
// label4
|
||||
//
|
||||
resources.ApplyResources(this.label4, "label4");
|
||||
this.label4.Name = "label4";
|
||||
//
|
||||
// Options
|
||||
//
|
||||
resources.ApplyResources(this, "$this");
|
||||
@ -3333,6 +3333,8 @@
|
||||
((System.ComponentModel.ISupportInitialize)(this.nUDRSCurve)).EndInit();
|
||||
this.antiDeadzoneTabPage.ResumeLayout(false);
|
||||
this.antiDeadzoneTabPage.PerformLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.nUDR2AntiDead)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.nUDL2AntiDead)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.nUDRSAntiDead)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.nUDLSAntiDead)).EndInit();
|
||||
this.fLPSettings.ResumeLayout(false);
|
||||
@ -3350,8 +3352,6 @@
|
||||
((System.ComponentModel.ISupportInitialize)(this.nUDSXS)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.nUDSZS)).EndInit();
|
||||
this.cMGyroTriggers.ResumeLayout(false);
|
||||
((System.ComponentModel.ISupportInitialize)(this.nUDR2AntiDead)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.nUDL2AntiDead)).EndInit();
|
||||
this.ResumeLayout(false);
|
||||
|
||||
}
|
||||
|
@ -27,6 +27,7 @@ namespace DS4Windows
|
||||
private float dpiy;
|
||||
public Dictionary<string, string> defaults = new Dictionary<string, string>();
|
||||
public bool saving, loading;
|
||||
public bool actionTabSeen = false;
|
||||
public static Size mSize { get; private set; }
|
||||
private Size settingsSize;
|
||||
public Options(DS4Form rt)
|
||||
@ -99,7 +100,7 @@ namespace DS4Windows
|
||||
bnSwipeDown.Text = Properties.Resources.SwipeDown;
|
||||
bnSwipeLeft.Text = Properties.Resources.SwipeLeft;
|
||||
bnSwipeRight.Text = Properties.Resources.SwipeRight;
|
||||
}
|
||||
}
|
||||
|
||||
public void Reload(int deviceNum, string name)
|
||||
{
|
||||
@ -1811,10 +1812,16 @@ namespace DS4Windows
|
||||
|
||||
private void tabControls_SelectedIndexChanged(object sender, EventArgs e)
|
||||
{
|
||||
if (tCControls.SelectedIndex == 2)
|
||||
int index = tCControls.SelectedIndex;
|
||||
if (index == 2)
|
||||
sixaxisTimer.Start();
|
||||
else
|
||||
sixaxisTimer.Stop();
|
||||
|
||||
if (index == 1)
|
||||
{
|
||||
actionTabSeen = true;
|
||||
}
|
||||
}
|
||||
|
||||
private void DrawCircle(object sender, PaintEventArgs e)
|
||||
@ -2005,21 +2012,6 @@ namespace DS4Windows
|
||||
}
|
||||
}
|
||||
|
||||
private void lVActions_ItemChecked(object sender, ItemCheckedEventArgs e)
|
||||
{
|
||||
List<string> pactions = new List<string>();
|
||||
foreach (ListViewItem lvi in lVActions.Items)
|
||||
if (lvi != null && lvi.Checked)
|
||||
pactions.Add(lvi.Text);
|
||||
ProfileActions[device] = pactions;
|
||||
calculateProfileActionCount(device);
|
||||
calculateProfileActionDicts(device);
|
||||
/*if (lVActions.Items.Count >= 50)
|
||||
{
|
||||
btnNewAction.Enabled = false;
|
||||
}*/
|
||||
}
|
||||
|
||||
private void nUDLSCurve_ValueChanged(object sender, EventArgs e)
|
||||
{
|
||||
LSCurve[device] = (int)Math.Round(nUDLSCurve.Value, 0);
|
||||
@ -2401,6 +2393,21 @@ namespace DS4Windows
|
||||
R2AntiDeadzone[device] = (int)(nUDR2AntiDead.Value * 100);
|
||||
}
|
||||
|
||||
private void lVActions_ItemCheck(object sender, ItemCheckEventArgs e)
|
||||
{
|
||||
if (actionTabSeen)
|
||||
{
|
||||
List<string> pactions = new List<string>();
|
||||
foreach (ListViewItem lvi in lVActions.Items)
|
||||
if (lvi != null && lvi.Checked)
|
||||
pactions.Add(lvi.Text);
|
||||
|
||||
ProfileActions[device] = pactions;
|
||||
calculateProfileActionCount(device);
|
||||
calculateProfileActionDicts(device);
|
||||
}
|
||||
}
|
||||
|
||||
private void Options_Resize(object sender, EventArgs e)
|
||||
{
|
||||
fLPSettings.AutoScroll = false;
|
||||
|
@ -7514,7 +7514,7 @@ with profile</value>
|
||||
<value>advColorDialog</value>
|
||||
</data>
|
||||
<data name=">>advColorDialog.Type" xml:space="preserve">
|
||||
<value>DS4Windows.AdvancedColorDialog, DS4Windows, Version=1.4.55.0, Culture=neutral, PublicKeyToken=null</value>
|
||||
<value>DS4Windows.AdvancedColorDialog, DS4Windows, Version=1.4.57.0, Culture=neutral, PublicKeyToken=null</value>
|
||||
</data>
|
||||
<data name=">>$this.Name" xml:space="preserve">
|
||||
<value>Options</value>
|
||||
|
Loading…
Reference in New Issue
Block a user