2014-05-30 22:39:39 +02:00
|
|
|
|
using System;
|
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
using System.ComponentModel;
|
|
|
|
|
using System.Data;
|
|
|
|
|
using System.Drawing;
|
|
|
|
|
using System.Linq;
|
|
|
|
|
using System.Text;
|
|
|
|
|
using System.Threading.Tasks;
|
|
|
|
|
using System.Windows.Forms;
|
2015-02-08 22:51:52 +01:00
|
|
|
|
|
2014-05-30 22:39:39 +02:00
|
|
|
|
|
2019-04-30 21:29:50 +02:00
|
|
|
|
namespace DS4Windows.Forms
|
2014-05-30 22:39:39 +02:00
|
|
|
|
{
|
Version 1.4.222
Added Press/Toggle Key to Special Actions, you can hold a trigger to
hold a key or toggle a key with one set of buttons, and untoggle it by
pressing or releasing another set of buttons
Added Disconnect BT to Special Actions, PS+Options to d/c is now added
to Special actions and can be enabled for each profile. You can now set
Disconnect BT to any control(s) and how long you need to hold the
control(s) to take affect
Added Partial German Translation (Thanks Michél)
Added 95% Finished Russian Translation (Thanks overclockers.ru members:
KoNoRIMCI & Sr_psycho)
Added Partial Italian Translation (Thanks Giulio)
Updates to the translations sheets, they should now have every bit of
text in DS4Windows, minus the controls of the controller
English Spelling fixes
Main/Starting tab only shows info for connected controllers, and context
menu only shows options for connected controllers.
Mouse wheel scrolling with analog sticks/triggers/gyro, the mouse now
scrolls smoothly
Slightly reworked analog mouse movement + mouse acceleration (not as
janky anymore)
When starting DS4Windows, if no controllers are connected, DS4Windows
defaults to the profile tab
Certain log warnings (Like unable to get controller exclusively) shows
up in red
Easter egg: try pressing a few buttons in sequence while in the log tab
Fixed Start Profile with TP off being unchecked next time a profile is
opened
Other minor Bug Fixes, such as clearing the log then moving to a new tab
crashing DS4W
2015-01-17 21:16:48 +01:00
|
|
|
|
public partial class DupBox : Form
|
2014-05-30 22:39:39 +02:00
|
|
|
|
{
|
|
|
|
|
public string oldfilename;
|
2014-11-14 20:44:50 +01:00
|
|
|
|
DS4Form yes;
|
Version 1.4.222
Added Press/Toggle Key to Special Actions, you can hold a trigger to
hold a key or toggle a key with one set of buttons, and untoggle it by
pressing or releasing another set of buttons
Added Disconnect BT to Special Actions, PS+Options to d/c is now added
to Special actions and can be enabled for each profile. You can now set
Disconnect BT to any control(s) and how long you need to hold the
control(s) to take affect
Added Partial German Translation (Thanks Michél)
Added 95% Finished Russian Translation (Thanks overclockers.ru members:
KoNoRIMCI & Sr_psycho)
Added Partial Italian Translation (Thanks Giulio)
Updates to the translations sheets, they should now have every bit of
text in DS4Windows, minus the controls of the controller
English Spelling fixes
Main/Starting tab only shows info for connected controllers, and context
menu only shows options for connected controllers.
Mouse wheel scrolling with analog sticks/triggers/gyro, the mouse now
scrolls smoothly
Slightly reworked analog mouse movement + mouse acceleration (not as
janky anymore)
When starting DS4Windows, if no controllers are connected, DS4Windows
defaults to the profile tab
Certain log warnings (Like unable to get controller exclusively) shows
up in red
Easter egg: try pressing a few buttons in sequence while in the log tab
Fixed Start Profile with TP off being unchecked next time a profile is
opened
Other minor Bug Fixes, such as clearing the log then moving to a new tab
crashing DS4W
2015-01-17 21:16:48 +01:00
|
|
|
|
public DupBox(string name, DS4Form mainwindow)
|
2014-05-30 22:39:39 +02:00
|
|
|
|
{
|
|
|
|
|
InitializeComponent();
|
|
|
|
|
oldfilename = name;
|
|
|
|
|
yes = mainwindow;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private void button1_Click(object sender, EventArgs e)
|
|
|
|
|
{
|
|
|
|
|
if (tBProfile.Text != null && tBProfile.Text != "" && !tBProfile.Text.Contains("\\") && !tBProfile.Text.Contains("/") && !tBProfile.Text.Contains(":") && !tBProfile.Text.Contains("*") && !tBProfile.Text.Contains("?") && !tBProfile.Text.Contains("\"") && !tBProfile.Text.Contains("<") && !tBProfile.Text.Contains(">") && !tBProfile.Text.Contains("|"))
|
|
|
|
|
{
|
|
|
|
|
System.IO.File.Copy(Global.appdatapath + "\\Profiles\\" + oldfilename + ".xml", Global.appdatapath + "\\Profiles\\" + tBProfile.Text + ".xml", true);
|
|
|
|
|
yes.RefreshProfiles();
|
|
|
|
|
this.Close();
|
|
|
|
|
}
|
|
|
|
|
else
|
2014-08-17 00:09:15 +02:00
|
|
|
|
MessageBox.Show(Properties.Resources.ValidName, Properties.Resources.NotValid, MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
|
2014-05-30 22:39:39 +02:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private void tBProfile_TextChanged(object sender, EventArgs e)
|
|
|
|
|
{
|
|
|
|
|
if (tBProfile.Text != null && tBProfile.Text != "" && !tBProfile.Text.Contains("\\") && !tBProfile.Text.Contains("/") && !tBProfile.Text.Contains(":") && !tBProfile.Text.Contains("*") && !tBProfile.Text.Contains("?") && !tBProfile.Text.Contains("\"") && !tBProfile.Text.Contains("<") && !tBProfile.Text.Contains(">") && !tBProfile.Text.Contains("|"))
|
|
|
|
|
tBProfile.ForeColor = System.Drawing.SystemColors.WindowText;
|
|
|
|
|
else
|
|
|
|
|
tBProfile.ForeColor = System.Drawing.SystemColors.GrayText;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private void tBProfile_Enter(object sender, EventArgs e)
|
|
|
|
|
{
|
2014-08-17 00:09:15 +02:00
|
|
|
|
if (tBProfile.Text == "<" + Properties.Resources.TypeNewName + ">")
|
2014-05-30 22:39:39 +02:00
|
|
|
|
tBProfile.Text = "";
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private void tBProfile_Leave(object sender, EventArgs e)
|
|
|
|
|
{
|
|
|
|
|
if (tBProfile.Text == "")
|
2014-08-17 00:09:15 +02:00
|
|
|
|
tBProfile.Text = "<" + Properties.Resources.TypeNewName + ">";
|
2014-05-30 22:39:39 +02:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private void button2_Click(object sender, EventArgs e)
|
|
|
|
|
{
|
|
|
|
|
this.Close();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|