diff --git a/.vs/SCJMapper-V2/DesignTimeBuild/.dtbcache b/.vs/SCJMapper-V2/DesignTimeBuild/.dtbcache
new file mode 100644
index 0000000..c881912
Binary files /dev/null and b/.vs/SCJMapper-V2/DesignTimeBuild/.dtbcache differ
diff --git a/AppSettings.cs b/AppSettings.cs
index a1cecab..7334312 100644
--- a/AppSettings.cs
+++ b/AppSettings.cs
@@ -149,7 +149,7 @@ namespace SCJMapper_V2
}
- // Seetings Window
+ // Settings Window
[UserScopedSetting( )]
[DefaultSettingValue( "" )]
@@ -243,10 +243,28 @@ namespace SCJMapper_V2
[DefaultSettingValue( "" )]
public string IgnoreJS12
{
- get { return ( string )this["IgnoreJS12"]; }
+ get { return (string)this["IgnoreJS12"]; }
set { this["IgnoreJS12"] = value; }
}
+ [UserScopedSetting( )]
+ [DefaultSettingValue( "" )]
+ public string JSnHide
+ {
+ get { return (string)this["JSnHide"]; }
+ set { this["JSnHide"] = value; }
+ }
+
+ [UserScopedSetting( )]
+ [DefaultSettingValue( "" )]
+ public string JSnColor
+ {
+ get { return (string)this["JSnColor"]; }
+ set { this["JSnColor"] = value; }
+ }
+
+
+
[UserScopedSetting( )]
[DefaultSettingValue( "" )]
public string UserSCPath
diff --git a/Common/MyColors.cs b/Common/MyColors.cs
index c518215..2d150be 100644
--- a/Common/MyColors.cs
+++ b/Common/MyColors.cs
@@ -49,11 +49,5 @@ namespace SCJMapper_V2.Common
static public Color ProfileColor = Color.DarkKhaki;
static public Color MappingColor = Color.DarkSeaGreen;
- static public void Reset( )
- {
- JsMapColor = ( Color[] )InitColor.Clone( );
- GamepadColor = GamepadColorDefault;
- }
-
}
}
diff --git a/Devices/DeviceCls.cs b/Devices/DeviceCls.cs
index 5aded3f..18497a8 100644
--- a/Devices/DeviceCls.cs
+++ b/Devices/DeviceCls.cs
@@ -2,6 +2,7 @@
using System.Collections.Generic;
using System.Linq;
using System.Text;
+using System.Windows.Forms;
namespace SCJMapper_V2.Devices
{
@@ -51,6 +52,12 @@ namespace SCJMapper_V2.Devices
///
public abstract string DevInstanceGUID { get; }
+ ///
+ /// The TabPage associated with the device (GP and JS only)
+ ///
+ public TabPage TabPage { get; set; } // added to handle hiding..
+ public bool Hidden { get; set; } // added to handle hiding..
+
public abstract System.Drawing.Color MapColor { get; }
public virtual List AnalogCommands { get { return new List( ); } } // just return an empty one if not implemented
diff --git a/Devices/Joystick/FormReassign.Designer.cs b/Devices/Joystick/FormReassign.Designer.cs
index 8fcaac1..c411568 100644
--- a/Devices/Joystick/FormReassign.Designer.cs
+++ b/Devices/Joystick/FormReassign.Designer.cs
@@ -73,7 +73,7 @@
// btCancel
//
this.btCancel.DialogResult = System.Windows.Forms.DialogResult.Cancel;
- this.btCancel.Location = new System.Drawing.Point(562, 379);
+ this.btCancel.Location = new System.Drawing.Point(565, 379);
this.btCancel.Name = "btCancel";
this.btCancel.Size = new System.Drawing.Size(108, 31);
this.btCancel.TabIndex = 27;
@@ -84,7 +84,7 @@
//
// btAccept
//
- this.btAccept.Location = new System.Drawing.Point(446, 379);
+ this.btAccept.Location = new System.Drawing.Point(449, 379);
this.btAccept.Name = "btAccept";
this.btAccept.Size = new System.Drawing.Size(108, 31);
this.btAccept.TabIndex = 26;
@@ -134,7 +134,7 @@
this.gbxReassignJS.Font = new System.Drawing.Font("Segoe UI", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.gbxReassignJS.Location = new System.Drawing.Point(14, 12);
this.gbxReassignJS.Name = "gbxReassignJS";
- this.gbxReassignJS.Size = new System.Drawing.Size(654, 361);
+ this.gbxReassignJS.Size = new System.Drawing.Size(659, 361);
this.gbxReassignJS.TabIndex = 28;
this.gbxReassignJS.TabStop = false;
this.gbxReassignJS.Tag = "§";
diff --git a/Devices/Joystick/JoystickList.cs b/Devices/Joystick/JoystickList.cs
index c482a2e..d9315b0 100644
--- a/Devices/Joystick/JoystickList.cs
+++ b/Devices/Joystick/JoystickList.cs
@@ -13,29 +13,6 @@ namespace SCJMapper_V2.Devices.Joystick
{
#region Static Parts
- ///
- /// Reassigns the mapping color based on the jsAssignment list given
- /// i.e. prepare the mapping colors for a given jsN assignment
- ///
- /// List of 0.. tabs where the value is the jsN number
- static public void ReassignJsColor( List newJsList )
- {
- // the default colors are aligned with the tabs - the tabs color is never changed but the jsN may
- // i.e. if the first Tab is assigned as js2 then the second MapColor must get the color of the first Tab
- int idx = 0;
- foreach ( int i in newJsList ) {
- if ( MyColors.TabColor[idx] == MyColors.GamepadColor ) {
- ; // skip the gamepad for joystick coloring
- } else {
- // walk through the tabs
- if ( i > 0 ) {
- // this is the jsN for the tab indexed (make it 0 based)
- MyColors.JsMapColor[i - 1] = MyColors.TabColor[idx];
- }
- }
- idx++;
- }
- }
static private Color DeviceColor( int dxnumber )
{
diff --git a/FormMain.Designer.cs b/FormMain.Designer.cs
index 34a3a3d..dc709fa 100644
--- a/FormMain.Designer.cs
+++ b/FormMain.Designer.cs
@@ -103,6 +103,7 @@
this.tlpanel = new System.Windows.Forms.TableLayoutPanel();
this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
this.tableLayoutPanel2 = new System.Windows.Forms.TableLayoutPanel();
+ this.lblPTU = new System.Windows.Forms.Label();
this.tableLayoutPanel3 = new System.Windows.Forms.TableLayoutPanel();
this.txMappingName = new System.Windows.Forms.TextBox();
this.lblMappingname = new System.Windows.Forms.Label();
@@ -158,7 +159,6 @@
this.msSelectMapping = new System.Windows.Forms.ToolStripDropDownButton();
this.tsLblMappings = new System.Windows.Forms.ToolStripLabel();
this.IL2 = new System.Windows.Forms.ImageList(this.components);
- this.lblPTU = new System.Windows.Forms.Label();
this.cmCopyPaste.SuspendLayout();
this.panel2.SuspendLayout();
this.cmMouseEntry.SuspendLayout();
@@ -777,7 +777,7 @@
// label8
//
this.label8.AutoSize = true;
- this.label8.Location = new System.Drawing.Point(353, 42);
+ this.label8.Location = new System.Drawing.Point(247, 42);
this.label8.Name = "label8";
this.label8.Size = new System.Drawing.Size(58, 13);
this.label8.TabIndex = 2;
@@ -896,6 +896,20 @@
this.tableLayoutPanel2.Size = new System.Drawing.Size(304, 78);
this.tableLayoutPanel2.TabIndex = 24;
//
+ // lblPTU
+ //
+ this.lblPTU.AutoSize = true;
+ this.lblPTU.BackColor = System.Drawing.Color.SandyBrown;
+ this.lblPTU.Dock = System.Windows.Forms.DockStyle.Fill;
+ this.lblPTU.Font = new System.Drawing.Font("Segoe UI", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
+ this.lblPTU.Location = new System.Drawing.Point(155, 0);
+ this.lblPTU.Name = "lblPTU";
+ this.lblPTU.Size = new System.Drawing.Size(146, 48);
+ this.lblPTU.TabIndex = 14;
+ this.lblPTU.Text = "Using PTU";
+ this.lblPTU.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
+ this.lblPTU.Visible = false;
+ //
// tableLayoutPanel3
//
this.tableLayoutPanel3.ColumnCount = 2;
@@ -1505,20 +1519,6 @@
this.IL2.Images.SetKeyName(1, "Locked");
this.IL2.Images.SetKeyName(2, "RSI");
//
- // lblPTU
- //
- this.lblPTU.AutoSize = true;
- this.lblPTU.BackColor = System.Drawing.Color.SandyBrown;
- this.lblPTU.Dock = System.Windows.Forms.DockStyle.Fill;
- this.lblPTU.Font = new System.Drawing.Font("Segoe UI", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
- this.lblPTU.Location = new System.Drawing.Point(155, 0);
- this.lblPTU.Name = "lblPTU";
- this.lblPTU.Size = new System.Drawing.Size(146, 48);
- this.lblPTU.TabIndex = 14;
- this.lblPTU.Text = "Using PTU";
- this.lblPTU.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
- this.lblPTU.Visible = false;
- //
// MainForm
//
this.AutoScaleDimensions = new System.Drawing.SizeF(96F, 96F);
diff --git a/FormMain.cs b/FormMain.cs
index b94c2ac..62cffaf 100644
--- a/FormMain.cs
+++ b/FormMain.cs
@@ -97,24 +97,28 @@ namespace SCJMapper_V2
return Act.ActionDevice.AD_Keyboard;
}
else {
- if ( IsGamepadTab( tc1.SelectedTab ) ) {
- return Act.ActionDevice.AD_Gamepad;
- }
- else {
- return Act.ActionDevice.AD_Joystick;
+ if ( tc1.SelectedTab != null ) {
+ if ( IsGamepadTab( tc1.SelectedTab ) ) {
+ return Act.ActionDevice.AD_Gamepad;
+ }
+ else {
+ return Act.ActionDevice.AD_Joystick;
+ }
}
+ return Act.ActionDevice.AD_Unknown;
}
}
}
+
///
/// Get the current JsN string for the active device tab
///
/// The jsN string - can be jsx, js1..jsN
private string JSStr()
{
- UC_JoyPanel jp = (UC_JoyPanel)( tc1.SelectedTab.Controls["UC_JoyPanel"] );
- return jp.JsName;
+ UC_JoyPanel jp = (UC_JoyPanel)( tc1.SelectedTab?.Controls["UC_JoyPanel"] );
+ return jp?.JsName;
}
// tab index for the tcXML control
@@ -151,6 +155,85 @@ namespace SCJMapper_V2
}
+ ///
+ /// Returns true if the JS with index (0...) is hidden in AppSettings
+ ///
+ /// The JS index (0...)
+ /// True if hidden
+ private bool IsTabPageHidden( int jsIndex )
+ {
+ return ( AppSettings.Instance.JSnHide.Contains( jsIndex.ToString( "D2" ) ) );
+ }
+
+ private int[] m_tabMap = new int[12] { -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1 };
+
+ // manage TabPage visibility
+ private void ShowTabPages()
+ {
+ foreach ( var dev in DeviceInst.JoystickListRef ) {
+ dev.Hidden = IsTabPageHidden( dev.DevInstance );
+ }
+ tc1.SuspendLayout( );
+ tc1.TabPages.Clear( );
+
+ m_tabMap = new int[12] { -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1 };
+ int i = 0;
+ foreach ( var dev in DeviceInst.JoystickListRef ) {
+ if ( !dev.Hidden ) {
+ m_tabMap[i++] = dev.DevInstance;
+ tc1.TabPages.Add( dev.TabPage );
+ }
+ }
+ if ( DeviceInst.GamepadRef != null ) {
+ tc1.TabPages.Add( DeviceInst.GamepadRef.TabPage );
+ }
+ // select the first tab if one is available
+ if ( tc1.TabPages.Count > 0 )
+ tc1.SelectedTab = tc1.TabPages[0];
+
+ tc1.ResumeLayout( );
+ }
+
+
+ ///
+ /// Returns the assigned color of the Joystick from Settings
+ ///
+ /// The JS index (0...)
+ /// An Argb Color
+ private Color JsColorSetting( int jsIndex )
+ {
+ // JS Tab Colors
+ string[] e = AppSettings.Instance.JSnColor.Split( new char[] { ',' } );
+ if ( jsIndex < e.Length ) {
+ if ( int.TryParse( e[jsIndex], out int colInt ) ) {
+ return Color.FromArgb( colInt );
+ }
+ else {
+ //invalid int... , use default
+ return MyColors.TabColor[jsIndex];
+ }
+ }
+ else {
+ // no color found, use default
+ return MyColors.TabColor[jsIndex];
+ }
+ }
+
+ ///
+ /// Update the TabPage Colors from Setting
+ ///
+ private void UpdateTabPageColors()
+ {
+ // load TabPage colors
+ for ( int i = 0; i < MyColors.TabColor.Length; i++ ) {
+ }
+
+ foreach ( var dev in DeviceInst.JoystickListRef ) {
+ MyColors.TabColor[dev.DevInstance] = JsColorSetting( dev.DevInstance );
+ dev.TabPage.BackColor = MyColors.TabColor[dev.DevInstance];
+ }
+ }
+
#endregion
#region Main Form Handling
@@ -232,6 +315,8 @@ namespace SCJMapper_V2
{
log.Debug( "MainForm_Load - Entry" );
+ SCFiles.Instance.UpdatePack( ); // update game files
+
Tx.LocalizeControlTree( this );
Tx.LocalizeControlTree( cmCopyPaste );
Tx.LocalizeControlTree( cmAddDel );
@@ -286,6 +371,11 @@ namespace SCJMapper_V2
SCFileIndication( );
+ // load TabPage colors
+ for ( int i = 0; i < MyColors.TabColor.Length; i++ ) {
+ MyColors.TabColor[i] = JsColorSetting( i );
+ }
+
// load other defaults
log.Debug( "Loading Other" );
txMappingName.Text = AppSettings.Instance.MyMappingName;
@@ -296,6 +386,7 @@ namespace SCJMapper_V2
break;
}
}
+
// Init X things
log.Debug( "Loading DirectX" );
if ( !InitDirectInput( ) ) {
@@ -326,7 +417,6 @@ namespace SCJMapper_V2
}
}
-
// load show checkboxes
cbxShowJoystick.Checked = AppSettings.Instance.ShowJoystick;
cbxShowGamepad.Checked = AppSettings.Instance.ShowGamepad;
@@ -335,7 +425,9 @@ namespace SCJMapper_V2
cbxShowMappedOnly.Checked = AppSettings.Instance.ShowMapped;
// init current Joystick
- int jsIndex = (int)tc1.SelectedTab.Tag; // gets the index into the JS list
+ int jsIndex = -1;
+ if ( tc1.SelectedTab!=null)
+ jsIndex = (int)tc1.SelectedTab.Tag; // gets the index into the JS list
if ( jsIndex >= 0 ) DeviceInst.JoystickInst = DeviceInst.JoystickListRef[jsIndex];
// Auto Tab XML
@@ -368,12 +460,17 @@ namespace SCJMapper_V2
private void tc1_Selected( object sender, TabControlEventArgs e )
{
- // init current Joystick
- int jsIndex = (int)tc1.SelectedTab.Tag; // gets the index into the JS list
- if ( jsIndex >= 0 )
- DeviceInst.JoystickInst = DeviceInst.JoystickListRef[jsIndex];
- else
+ if ( tc1.SelectedTab == null ) {
DeviceInst.JoystickInst = null;
+ }
+ else {
+ // init current Joystick
+ int jsIndex = (int)tc1.SelectedTab.Tag; // gets the index into the JS list
+ if ( jsIndex >= 0 )
+ DeviceInst.JoystickInst = DeviceInst.JoystickListRef[jsIndex];
+ else
+ DeviceInst.JoystickInst = null;
+ }
}
///
@@ -382,18 +479,15 @@ namespace SCJMapper_V2
private void tc1_DrawItem( object sender, DrawItemEventArgs e )
{
try {
- //This line of code will help you to change the apperance like size,name,style.
Font f;
- //For background color
- Brush backBrush = new SolidBrush( MyColors.TabColor[e.Index] );
- //For forground color
+ Brush backBrush = new SolidBrush( MyColors.TabColor[m_tabMap[e.Index]] );
Brush foreBrush = new SolidBrush( Color.Black );
//This construct will tell you which tab page has focus to change the style.
if ( e.Index == this.tc1.SelectedIndex ) {
f = new Font( e.Font, FontStyle.Bold );
-
+ /*
Rectangle tabRect = tc1.Bounds;
Region tabRegion = new Region( tabRect );
Rectangle TabItemRect = new Rectangle( 0, 0, 0, 0 );
@@ -401,7 +495,8 @@ namespace SCJMapper_V2
TabItemRect = Rectangle.Union( TabItemRect, tc1.GetTabRect( nTanIndex ) );
}
tabRegion.Exclude( TabItemRect );
- e.Graphics.FillRegion( backBrush, tabRegion );
+ //e.Graphics.FillRegion( backBrush, tabRegion );
+ */
}
else {
f = e.Font;
@@ -410,11 +505,9 @@ namespace SCJMapper_V2
//To set the alignment of the caption.
string tabName = this.tc1.TabPages[e.Index].Text;
- StringFormat sf = new StringFormat( );
- sf.Alignment = StringAlignment.Center;
+ StringFormat sf = new StringFormat { Alignment = StringAlignment.Center };
- //Thsi will help you to fill the interior portion of
- //selected tabpage.
+ //This will help you to fill the interior portion of selected tabpage.
e.Graphics.FillRectangle( backBrush, e.Bounds );
Rectangle r = e.Bounds;
r = new Rectangle( r.X, r.Y + 3, r.Width, r.Height - 3 );
@@ -424,6 +517,7 @@ namespace SCJMapper_V2
if ( e.Index == this.tc1.SelectedIndex ) {
f.Dispose( );
backBrush.Dispose( );
+ foreBrush.Dispose( );
}
else {
backBrush.Dispose( );
@@ -528,9 +622,11 @@ namespace SCJMapper_V2
return false;
}
+ // init devices
List dxJoysticks = new List( );
SharpDX.XInput.Controller dxGamepad = null;
+ // load from DirectX
try {
// scan the Input for attached devices
log.Debug( " - Scan GameControl devices" );
@@ -550,9 +646,7 @@ namespace SCJMapper_V2
}
}
else {
- myDxJoystick myJs = new myDxJoystick( );
- myJs.js = new Joystick( directInput, instance.InstanceGuid );
- myJs.prodName = instance.ProductName;
+ myDxJoystick myJs = new myDxJoystick { js = new Joystick( directInput, instance.InstanceGuid ), prodName = instance.ProductName };
dxJoysticks.Add( myJs );
log.DebugFormat( " - Create the device interface for: {0}", myJs.prodName );
}
@@ -563,28 +657,8 @@ namespace SCJMapper_V2
return false;
}
+ // Create the TabPages
int tabs = 0;
- // make the GP the first device if there is one.
- if ( dxGamepad != null ) {
- log.Debug( " - Add first Gamepad panel" );
- tc1.TabPages[tabs].Text = Tx.Translate( "xGamepad" ) + " ";
- UC_GpadPanel uUC_GpadPanelNew = new UC_GpadPanel( ); tc1.TabPages[tabs].Controls.Add( uUC_GpadPanelNew );
- Tx.LocalizeControlTree( uUC_GpadPanelNew );
-
- uUC_GpadPanelNew.Size = UC_JoyPanel.Size; uUC_GpadPanelNew.Location = UC_JoyPanel.Location;
- UC_JoyPanel.Enabled = false; UC_JoyPanel.Visible = false; // don't use this one
- log.Debug( " - Create Gamepad instance" );
- DeviceInst.GamepadInst = new GamepadCls( dxGamepad, uUC_GpadPanelNew, tabs ); // does all device related activities for that particular item
- DeviceInst.GamepadRef.SetDeviceName( GamepadCls.DevNameCIG ); // this is fixed ...
- tc1.TabPages[tabs].ToolTipText = string.Format( "{0}\n{1}", DeviceInst.GamepadRef.DevName, " " );
- toolTip1.SetToolTip( tc1.TabPages[tabs], tc1.TabPages[tabs].ToolTipText );
-
- SetGamepadTab( tc1.TabPages[tabs] ); // indicates the gamepad tab (murks..)
- MyColors.TabColor[tabs] = MyColors.GamepadColor; // save it for future use of tab coloring (drawing)
- tc1.TabPages[tabs].BackColor = MyColors.TabColor[tabs];
-
- tabs++; // next tab
- }
// do all joysticks
int nJs = 0; // number the Joystick Tabs
@@ -603,24 +677,53 @@ namespace SCJMapper_V2
uUC_JoyPanelNew = new UC_JoyPanel( ); tc1.TabPages[tabs].Controls.Add( uUC_JoyPanelNew );
Tx.LocalizeControlTree( uUC_JoyPanelNew );
uUC_JoyPanelNew.Size = UC_JoyPanel.Size; uUC_JoyPanelNew.Location = UC_JoyPanel.Location;
-
}
// common part
- tc1.TabPages[tabs].Text = string.Format( "{0} {1}", Tx.Translate( "xJoystick" ), nJs + 1 ); // numbering is 1 based for the user
log.Debug( " - Create Joystick instance " + nJs.ToString( ) );
- js = new JoystickCls( myJs.js, this, nJs, uUC_JoyPanelNew, tabs ); // does all device related activities for that particular item
+ // does all device related activities for that particular item
+ js = new JoystickCls( myJs.js, this, nJs, uUC_JoyPanelNew, tabs ) { TabPage = tc1.TabPages[tabs] };
DeviceInst.JoystickListRef.Add( js ); // add to joystick list
- tc1.TabPages[tabs].ToolTipText = string.Format( "{0}\n{1}", js.DevName, js.DevInstanceGUID );
- toolTip1.SetToolTip( tc1.TabPages[tabs], tc1.TabPages[tabs].ToolTipText );
- tc1.TabPages[tabs].BackColor = MyColors.TabColor[tabs];
- tc1.TabPages[tabs].Tag = js.DevInstance; // used to find the tab for polling
+ js.TabPage.Text = string.Format( "{0} {1}", Tx.Translate( "xJoystick" ), nJs + 1 ); // numbering is 1 based for the user
+ js.TabPage.ToolTipText = string.Format( "{0}\n{1}", js.DevName, js.DevInstanceGUID );
+ toolTip1.SetToolTip( js.TabPage, js.TabPage.ToolTipText );
+ js.TabPage.Tag = js.DevInstance; // used to find the tab for polling
+ js.TabPage.BackColor = MyColors.TabColor[tabs];
+ js.Hidden = IsTabPageHidden( js.DevInstance );
nJs++; // next joystick
// next Joystick tab
tabs++;
- if ( tabs >= JoystickCls.JSnum_MAX ) break; // cannot load more JSticks than predefined Tabs
+ if ( tabs >= JoystickCls.JSnum_MAX ) {
+ log.Debug( " - Number of Device tabs reached MAX, cannot add more devices" );
+ break; // cannot load more JSticks than predefined Tabs
+ }
}
+ // make the GP the LAST device if there is one.
+ if ( ( tabs < JoystickCls.JSnum_MAX ) && ( dxGamepad != null ) ) {
+ log.Debug( " - Add Gamepad panel" );
+ tc1.TabPages[tabs].Text = Tx.Translate( "xGamepad" ) + " ";
+ UC_GpadPanel uUC_GpadPanelNew = new UC_GpadPanel( );
+ tc1.TabPages[tabs].Controls.Add( uUC_GpadPanelNew );
+ Tx.LocalizeControlTree( uUC_GpadPanelNew );
+
+ uUC_GpadPanelNew.Size = UC_JoyPanel.Size; uUC_GpadPanelNew.Location = UC_JoyPanel.Location;
+ UC_JoyPanel.Enabled = false; UC_JoyPanel.Visible = false; // don't use this one
+ log.Debug( " - Create Gamepad instance" );
+ DeviceInst.GamepadInst = new GamepadCls( dxGamepad, uUC_GpadPanelNew, tabs ); // does all device related activities for that particular item
+ DeviceInst.GamepadRef.SetDeviceName( GamepadCls.DevNameCIG ); // this is fixed ...
+ DeviceInst.GamepadRef.TabPage = tc1.TabPages[tabs];
+
+ DeviceInst.GamepadRef.TabPage.ToolTipText = string.Format( "{0}\n{1}", DeviceInst.GamepadRef.DevName, " " );
+ toolTip1.SetToolTip( DeviceInst.GamepadRef.TabPage, DeviceInst.GamepadRef.TabPage.ToolTipText );
+
+ SetGamepadTab( DeviceInst.GamepadRef.TabPage ); // indicates the gamepad tab (murks..)
+ MyColors.TabColor[tabs] = MyColors.GamepadColor; // save it for future use of tab coloring (drawing)
+ DeviceInst.GamepadRef.TabPage.BackColor = MyColors.TabColor[tabs];
+ DeviceInst.GamepadRef.Hidden = false; // always visible
+
+ tabs++; // next tab
+ }
log.DebugFormat( " - Added {0} GameControl devices", tabs );
if ( tabs == 0 ) {
@@ -629,6 +732,9 @@ namespace SCJMapper_V2
return false;
}
+ // manage visibility of Tabs
+ ShowTabPages( );
+
// load the profile items from the XML
log.Debug( " - End of, InitActionTree now" );
InitActionTree( true );
@@ -728,7 +834,7 @@ namespace SCJMapper_V2
m_modifierTimeout -= timer1.Interval; // decrement timeout
if ( m_modifierTimeout < 0 ) m_modifierTimeout = 0; // prevent undeflow after long time not using modifiers
- if ( m_keyIn || tc1.SelectedTab.Tag == null ) return; // don't handle those
+ if ( m_keyIn || tc1.SelectedTab?.Tag == null ) return; // don't handle those
string ctrl = "";
if ( DeviceInst.JoystickRef == null ) {
@@ -1026,6 +1132,12 @@ namespace SCJMapper_V2
timer1.Enabled = false;
if ( AppSettings.Instance.ShowSettings( "" ) != DialogResult.Cancel ) {
AppSettings.Instance.Reload( ); // must reload in case of any changes in the form
+
+ // Hide JS Tabs as needed
+ ShowTabPages( );
+ // update JS colors
+ UpdateTabPageColors( );
+
// then reload the profile and mappings
LoadMappingDD( );
// indicates (in)valid folders
@@ -1365,9 +1477,9 @@ namespace SCJMapper_V2
txMappingName.BackColor = MyColors.SuccessColor;
// autosave our XML
- string xmlList = string.Format( " \n{2}", DateTime.Now, txMappingName.Text,
+ string xmlList = string.Format( " \n{2}", DateTime.Now, txMappingName.Text,
m_AT.ReportActionsXML( ) );
- using (StreamWriter sw = File.CreateText(TheUser.MappingXmlFileName( txMappingName.Text)) ) {
+ using ( StreamWriter sw = File.CreateText( TheUser.MappingXmlFileName( txMappingName.Text ) ) ) {
sw.Write( xmlList );
}
diff --git a/FormMain.resx b/FormMain.resx
index 5e79115..55b4ea2 100644
--- a/FormMain.resx
+++ b/FormMain.resx
@@ -128,7 +128,7 @@
AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj00LjAuMC4w
LCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2VuPWI3N2E1YzU2MTkzNGUwODkFAQAAACZTeXN0
ZW0uV2luZG93cy5Gb3Jtcy5JbWFnZUxpc3RTdHJlYW1lcgEAAAAERGF0YQcCAgAAAAkDAAAADwMAAAA8
- EAAAAk1TRnQBSQFMAgEBCQEAAUgBFAFIARQBEAEAARABAAT/AQkBAAj/AUIBTQE2AQQGAAE2AQQCAAEo
+ EAAAAk1TRnQBSQFMAgEBCQEAAVgBFAFYARQBEAEAARABAAT/AQkBAAj/AUIBTQE2AQQGAAE2AQQCAAEo
AwABQAMAATADAAEBAQABCAYAAQwYAAGAAgABgAMAAoABAAGAAwABgAEAAYABAAKAAgADwAEAAcAB3AHA
AQAB8AHKAaYBAAEzBQABMwEAATMBAAEzAQACMwIAAxYBAAMcAQADIgEAAykBAANVAQADTQEAA0IBAAM5
AQABgAF8Af8BAAJQAf8BAAGTAQAB1gEAAf8B7AHMAQABxgHWAe8BAAHWAucBAAGQAakBrQIAAf8BMwMA
@@ -582,7 +582,7 @@
AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj00LjAuMC4w
LCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2VuPWI3N2E1YzU2MTkzNGUwODkFAQAAACZTeXN0
ZW0uV2luZG93cy5Gb3Jtcy5JbWFnZUxpc3RTdHJlYW1lcgEAAAAERGF0YQcCAgAAAAkDAAAADwMAAADc
- GQAAAk1TRnQBSQFMAgEBAwEAAQgBAgEIAQIBMAEAATABAAT/AQkBAAj/AUIBTQE2AQQGAAE2AQQCAAEo
+ GQAAAk1TRnQBSQFMAgEBAwEAARgBAgEYAQIBMAEAATABAAT/AQkBAAj/AUIBTQE2AQQGAAE2AQQCAAEo
AwABwAMAATADAAEBAQABCAYAASQYAAGAAgABgAMAAoABAAGAAwABgAEAAYABAAKAAgADwAEAAcAB3AHA
AQAB8AHKAaYBAAEzBQABMwEAATMBAAEzAQACMwIAAxYBAAMcAQADIgEAAykBAANVAQADTQEAA0IBAAM5
AQABgAF8Af8BAAJQAf8BAAGTAQAB1gEAAf8B7AHMAQABxgHWAe8BAAHWAucBAAGQAakBrQIAAf8BMwMA
diff --git a/FormSettings.Designer.cs b/FormSettings.Designer.cs
index df7ce94..e7264f6 100644
--- a/FormSettings.Designer.cs
+++ b/FormSettings.Designer.cs
@@ -50,6 +50,30 @@
this.txJS8 = new System.Windows.Forms.TextBox();
this.fbDlg = new System.Windows.Forms.FolderBrowserDialog();
this.gbxIgnoreBt = new System.Windows.Forms.GroupBox();
+ this.lblColor12 = new System.Windows.Forms.Label();
+ this.chkHidden12 = new System.Windows.Forms.CheckBox();
+ this.lblColor11 = new System.Windows.Forms.Label();
+ this.chkHidden11 = new System.Windows.Forms.CheckBox();
+ this.lblColor10 = new System.Windows.Forms.Label();
+ this.chkHidden10 = new System.Windows.Forms.CheckBox();
+ this.lblColor09 = new System.Windows.Forms.Label();
+ this.chkHidden09 = new System.Windows.Forms.CheckBox();
+ this.lblColor08 = new System.Windows.Forms.Label();
+ this.chkHidden08 = new System.Windows.Forms.CheckBox();
+ this.lblColor07 = new System.Windows.Forms.Label();
+ this.chkHidden07 = new System.Windows.Forms.CheckBox();
+ this.lblColor06 = new System.Windows.Forms.Label();
+ this.chkHidden06 = new System.Windows.Forms.CheckBox();
+ this.lblColor05 = new System.Windows.Forms.Label();
+ this.chkHidden05 = new System.Windows.Forms.CheckBox();
+ this.lblColor04 = new System.Windows.Forms.Label();
+ this.chkHidden04 = new System.Windows.Forms.CheckBox();
+ this.lblColor03 = new System.Windows.Forms.Label();
+ this.chkHidden03 = new System.Windows.Forms.CheckBox();
+ this.lblColor02 = new System.Windows.Forms.Label();
+ this.chkHidden02 = new System.Windows.Forms.CheckBox();
+ this.lblColor01 = new System.Windows.Forms.Label();
+ this.chkHidden01 = new System.Windows.Forms.CheckBox();
this.txJS11 = new System.Windows.Forms.TextBox();
this.label2 = new System.Windows.Forms.Label();
this.txJS12 = new System.Windows.Forms.TextBox();
@@ -72,6 +96,7 @@
this.cbxCSVListing = new System.Windows.Forms.CheckBox();
this.cbxPTU = new System.Windows.Forms.CheckBox();
this.cbxDetectGamepad = new System.Windows.Forms.CheckBox();
+ this.colDlg = new System.Windows.Forms.ColorDialog();
this.gbxIgnoreBt.SuspendLayout();
this.gbxSCPath.SuspendLayout();
this.gbxIgnoreMaps.SuspendLayout();
@@ -120,7 +145,7 @@
//
this.txJS1.Location = new System.Drawing.Point(66, 46);
this.txJS1.Name = "txJS1";
- this.txJS1.Size = new System.Drawing.Size(199, 22);
+ this.txJS1.Size = new System.Drawing.Size(86, 22);
this.txJS1.TabIndex = 6;
this.txJS1.KeyDown += new System.Windows.Forms.KeyEventHandler(this.txJS1_KeyDown);
this.txJS1.KeyPress += new System.Windows.Forms.KeyPressEventHandler(this.txJS1_KeyPress);
@@ -128,6 +153,7 @@
// label3
//
this.label3.AutoSize = true;
+ this.label3.ForeColor = System.Drawing.Color.Blue;
this.label3.Location = new System.Drawing.Point(6, 49);
this.label3.Name = "label3";
this.label3.Size = new System.Drawing.Size(57, 13);
@@ -137,6 +163,7 @@
// label4
//
this.label4.AutoSize = true;
+ this.label4.ForeColor = System.Drawing.Color.Blue;
this.label4.Location = new System.Drawing.Point(6, 77);
this.label4.Name = "label4";
this.label4.Size = new System.Drawing.Size(57, 13);
@@ -147,7 +174,7 @@
//
this.txJS2.Location = new System.Drawing.Point(66, 74);
this.txJS2.Name = "txJS2";
- this.txJS2.Size = new System.Drawing.Size(199, 22);
+ this.txJS2.Size = new System.Drawing.Size(86, 22);
this.txJS2.TabIndex = 8;
this.txJS2.KeyDown += new System.Windows.Forms.KeyEventHandler(this.txJS1_KeyDown);
this.txJS2.KeyPress += new System.Windows.Forms.KeyPressEventHandler(this.txJS1_KeyPress);
@@ -155,6 +182,7 @@
// label5
//
this.label5.AutoSize = true;
+ this.label5.ForeColor = System.Drawing.Color.Blue;
this.label5.Location = new System.Drawing.Point(6, 105);
this.label5.Name = "label5";
this.label5.Size = new System.Drawing.Size(57, 13);
@@ -165,7 +193,7 @@
//
this.txJS3.Location = new System.Drawing.Point(66, 102);
this.txJS3.Name = "txJS3";
- this.txJS3.Size = new System.Drawing.Size(199, 22);
+ this.txJS3.Size = new System.Drawing.Size(86, 22);
this.txJS3.TabIndex = 10;
this.txJS3.KeyDown += new System.Windows.Forms.KeyEventHandler(this.txJS1_KeyDown);
this.txJS3.KeyPress += new System.Windows.Forms.KeyPressEventHandler(this.txJS1_KeyPress);
@@ -173,6 +201,7 @@
// label6
//
this.label6.AutoSize = true;
+ this.label6.ForeColor = System.Drawing.Color.Blue;
this.label6.Location = new System.Drawing.Point(6, 133);
this.label6.Name = "label6";
this.label6.Size = new System.Drawing.Size(57, 13);
@@ -183,7 +212,7 @@
//
this.txJS4.Location = new System.Drawing.Point(66, 130);
this.txJS4.Name = "txJS4";
- this.txJS4.Size = new System.Drawing.Size(199, 22);
+ this.txJS4.Size = new System.Drawing.Size(86, 22);
this.txJS4.TabIndex = 12;
this.txJS4.KeyDown += new System.Windows.Forms.KeyEventHandler(this.txJS1_KeyDown);
this.txJS4.KeyPress += new System.Windows.Forms.KeyPressEventHandler(this.txJS1_KeyPress);
@@ -191,6 +220,7 @@
// label7
//
this.label7.AutoSize = true;
+ this.label7.ForeColor = System.Drawing.Color.Blue;
this.label7.Location = new System.Drawing.Point(6, 161);
this.label7.Name = "label7";
this.label7.Size = new System.Drawing.Size(57, 13);
@@ -201,7 +231,7 @@
//
this.txJS5.Location = new System.Drawing.Point(66, 158);
this.txJS5.Name = "txJS5";
- this.txJS5.Size = new System.Drawing.Size(199, 22);
+ this.txJS5.Size = new System.Drawing.Size(86, 22);
this.txJS5.TabIndex = 14;
this.txJS5.KeyDown += new System.Windows.Forms.KeyEventHandler(this.txJS1_KeyDown);
this.txJS5.KeyPress += new System.Windows.Forms.KeyPressEventHandler(this.txJS1_KeyPress);
@@ -209,6 +239,7 @@
// label8
//
this.label8.AutoSize = true;
+ this.label8.ForeColor = System.Drawing.Color.Blue;
this.label8.Location = new System.Drawing.Point(6, 189);
this.label8.Name = "label8";
this.label8.Size = new System.Drawing.Size(57, 13);
@@ -219,7 +250,7 @@
//
this.txJS6.Location = new System.Drawing.Point(66, 186);
this.txJS6.Name = "txJS6";
- this.txJS6.Size = new System.Drawing.Size(199, 22);
+ this.txJS6.Size = new System.Drawing.Size(86, 22);
this.txJS6.TabIndex = 16;
this.txJS6.KeyDown += new System.Windows.Forms.KeyEventHandler(this.txJS1_KeyDown);
this.txJS6.KeyPress += new System.Windows.Forms.KeyPressEventHandler(this.txJS1_KeyPress);
@@ -227,6 +258,7 @@
// label9
//
this.label9.AutoSize = true;
+ this.label9.ForeColor = System.Drawing.Color.Blue;
this.label9.Location = new System.Drawing.Point(271, 49);
this.label9.Name = "label9";
this.label9.Size = new System.Drawing.Size(57, 13);
@@ -237,7 +269,7 @@
//
this.txJS7.Location = new System.Drawing.Point(340, 46);
this.txJS7.Name = "txJS7";
- this.txJS7.Size = new System.Drawing.Size(199, 22);
+ this.txJS7.Size = new System.Drawing.Size(86, 22);
this.txJS7.TabIndex = 18;
this.txJS7.KeyDown += new System.Windows.Forms.KeyEventHandler(this.txJS1_KeyDown);
this.txJS7.KeyPress += new System.Windows.Forms.KeyPressEventHandler(this.txJS1_KeyPress);
@@ -245,6 +277,7 @@
// label10
//
this.label10.AutoSize = true;
+ this.label10.ForeColor = System.Drawing.Color.Blue;
this.label10.Location = new System.Drawing.Point(271, 77);
this.label10.Name = "label10";
this.label10.Size = new System.Drawing.Size(57, 13);
@@ -255,7 +288,7 @@
//
this.txJS8.Location = new System.Drawing.Point(340, 74);
this.txJS8.Name = "txJS8";
- this.txJS8.Size = new System.Drawing.Size(199, 22);
+ this.txJS8.Size = new System.Drawing.Size(86, 22);
this.txJS8.TabIndex = 20;
this.txJS8.KeyDown += new System.Windows.Forms.KeyEventHandler(this.txJS1_KeyDown);
this.txJS8.KeyPress += new System.Windows.Forms.KeyPressEventHandler(this.txJS1_KeyPress);
@@ -267,6 +300,30 @@
//
// gbxIgnoreBt
//
+ this.gbxIgnoreBt.Controls.Add(this.lblColor12);
+ this.gbxIgnoreBt.Controls.Add(this.chkHidden12);
+ this.gbxIgnoreBt.Controls.Add(this.lblColor11);
+ this.gbxIgnoreBt.Controls.Add(this.chkHidden11);
+ this.gbxIgnoreBt.Controls.Add(this.lblColor10);
+ this.gbxIgnoreBt.Controls.Add(this.chkHidden10);
+ this.gbxIgnoreBt.Controls.Add(this.lblColor09);
+ this.gbxIgnoreBt.Controls.Add(this.chkHidden09);
+ this.gbxIgnoreBt.Controls.Add(this.lblColor08);
+ this.gbxIgnoreBt.Controls.Add(this.chkHidden08);
+ this.gbxIgnoreBt.Controls.Add(this.lblColor07);
+ this.gbxIgnoreBt.Controls.Add(this.chkHidden07);
+ this.gbxIgnoreBt.Controls.Add(this.lblColor06);
+ this.gbxIgnoreBt.Controls.Add(this.chkHidden06);
+ this.gbxIgnoreBt.Controls.Add(this.lblColor05);
+ this.gbxIgnoreBt.Controls.Add(this.chkHidden05);
+ this.gbxIgnoreBt.Controls.Add(this.lblColor04);
+ this.gbxIgnoreBt.Controls.Add(this.chkHidden04);
+ this.gbxIgnoreBt.Controls.Add(this.lblColor03);
+ this.gbxIgnoreBt.Controls.Add(this.chkHidden03);
+ this.gbxIgnoreBt.Controls.Add(this.lblColor02);
+ this.gbxIgnoreBt.Controls.Add(this.chkHidden02);
+ this.gbxIgnoreBt.Controls.Add(this.lblColor01);
+ this.gbxIgnoreBt.Controls.Add(this.chkHidden01);
this.gbxIgnoreBt.Controls.Add(this.txJS11);
this.gbxIgnoreBt.Controls.Add(this.label2);
this.gbxIgnoreBt.Controls.Add(this.txJS12);
@@ -298,14 +355,278 @@
this.gbxIgnoreBt.TabIndex = 22;
this.gbxIgnoreBt.TabStop = false;
this.gbxIgnoreBt.Tag = "§";
- this.gbxIgnoreBt.Text = "Ignore Buttons - enter button numbers which should be ignored separated by spaces" +
- " (e.g. 24 25)";
+ this.gbxIgnoreBt.Text = "Configuration - enter button numbers which should be ignored separated by spaces " +
+ "(e.g. 24 25)";
+ //
+ // lblColor12
+ //
+ this.lblColor12.BackColor = System.Drawing.Color.Maroon;
+ this.lblColor12.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
+ this.lblColor12.Location = new System.Drawing.Point(432, 186);
+ this.lblColor12.Name = "lblColor12";
+ this.lblColor12.Size = new System.Drawing.Size(21, 22);
+ this.lblColor12.TabIndex = 77;
+ this.lblColor12.Text = " ";
+ this.lblColor12.Click += new System.EventHandler(this.lblColor01_Click);
+ //
+ // chkHidden12
+ //
+ this.chkHidden12.AutoSize = true;
+ this.chkHidden12.Location = new System.Drawing.Point(459, 188);
+ this.chkHidden12.Name = "chkHidden12";
+ this.chkHidden12.Size = new System.Drawing.Size(50, 17);
+ this.chkHidden12.TabIndex = 76;
+ this.chkHidden12.Tag = "§";
+ this.chkHidden12.Text = "Hide";
+ this.chkHidden12.UseVisualStyleBackColor = true;
+ //
+ // lblColor11
+ //
+ this.lblColor11.BackColor = System.Drawing.Color.Maroon;
+ this.lblColor11.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
+ this.lblColor11.Location = new System.Drawing.Point(432, 158);
+ this.lblColor11.Name = "lblColor11";
+ this.lblColor11.Size = new System.Drawing.Size(21, 22);
+ this.lblColor11.TabIndex = 75;
+ this.lblColor11.Text = " ";
+ this.lblColor11.Click += new System.EventHandler(this.lblColor01_Click);
+ //
+ // chkHidden11
+ //
+ this.chkHidden11.AutoSize = true;
+ this.chkHidden11.Location = new System.Drawing.Point(459, 160);
+ this.chkHidden11.Name = "chkHidden11";
+ this.chkHidden11.Size = new System.Drawing.Size(50, 17);
+ this.chkHidden11.TabIndex = 74;
+ this.chkHidden11.Tag = "§";
+ this.chkHidden11.Text = "Hide";
+ this.chkHidden11.UseVisualStyleBackColor = true;
+ //
+ // lblColor10
+ //
+ this.lblColor10.BackColor = System.Drawing.Color.Maroon;
+ this.lblColor10.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
+ this.lblColor10.Location = new System.Drawing.Point(432, 130);
+ this.lblColor10.Name = "lblColor10";
+ this.lblColor10.Size = new System.Drawing.Size(21, 22);
+ this.lblColor10.TabIndex = 73;
+ this.lblColor10.Text = " ";
+ this.lblColor10.Click += new System.EventHandler(this.lblColor01_Click);
+ //
+ // chkHidden10
+ //
+ this.chkHidden10.AutoSize = true;
+ this.chkHidden10.Location = new System.Drawing.Point(459, 132);
+ this.chkHidden10.Name = "chkHidden10";
+ this.chkHidden10.Size = new System.Drawing.Size(50, 17);
+ this.chkHidden10.TabIndex = 72;
+ this.chkHidden10.Tag = "§";
+ this.chkHidden10.Text = "Hide";
+ this.chkHidden10.UseVisualStyleBackColor = true;
+ //
+ // lblColor09
+ //
+ this.lblColor09.BackColor = System.Drawing.Color.Maroon;
+ this.lblColor09.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
+ this.lblColor09.Location = new System.Drawing.Point(432, 102);
+ this.lblColor09.Name = "lblColor09";
+ this.lblColor09.Size = new System.Drawing.Size(21, 22);
+ this.lblColor09.TabIndex = 71;
+ this.lblColor09.Text = " ";
+ this.lblColor09.Click += new System.EventHandler(this.lblColor01_Click);
+ //
+ // chkHidden09
+ //
+ this.chkHidden09.AutoSize = true;
+ this.chkHidden09.Location = new System.Drawing.Point(459, 104);
+ this.chkHidden09.Name = "chkHidden09";
+ this.chkHidden09.Size = new System.Drawing.Size(50, 17);
+ this.chkHidden09.TabIndex = 70;
+ this.chkHidden09.Tag = "§";
+ this.chkHidden09.Text = "Hide";
+ this.chkHidden09.UseVisualStyleBackColor = true;
+ //
+ // lblColor08
+ //
+ this.lblColor08.BackColor = System.Drawing.Color.Maroon;
+ this.lblColor08.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
+ this.lblColor08.Location = new System.Drawing.Point(432, 74);
+ this.lblColor08.Name = "lblColor08";
+ this.lblColor08.Size = new System.Drawing.Size(21, 22);
+ this.lblColor08.TabIndex = 69;
+ this.lblColor08.Text = " ";
+ this.lblColor08.Click += new System.EventHandler(this.lblColor01_Click);
+ //
+ // chkHidden08
+ //
+ this.chkHidden08.AutoSize = true;
+ this.chkHidden08.Location = new System.Drawing.Point(459, 76);
+ this.chkHidden08.Name = "chkHidden08";
+ this.chkHidden08.Size = new System.Drawing.Size(50, 17);
+ this.chkHidden08.TabIndex = 68;
+ this.chkHidden08.Tag = "§";
+ this.chkHidden08.Text = "Hide";
+ this.chkHidden08.UseVisualStyleBackColor = true;
+ //
+ // lblColor07
+ //
+ this.lblColor07.BackColor = System.Drawing.Color.Maroon;
+ this.lblColor07.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
+ this.lblColor07.Location = new System.Drawing.Point(432, 46);
+ this.lblColor07.Name = "lblColor07";
+ this.lblColor07.Size = new System.Drawing.Size(21, 22);
+ this.lblColor07.TabIndex = 67;
+ this.lblColor07.Text = " ";
+ this.lblColor07.Click += new System.EventHandler(this.lblColor01_Click);
+ //
+ // chkHidden07
+ //
+ this.chkHidden07.AutoSize = true;
+ this.chkHidden07.Location = new System.Drawing.Point(459, 48);
+ this.chkHidden07.Name = "chkHidden07";
+ this.chkHidden07.Size = new System.Drawing.Size(50, 17);
+ this.chkHidden07.TabIndex = 66;
+ this.chkHidden07.Tag = "§";
+ this.chkHidden07.Text = "Hide";
+ this.chkHidden07.UseVisualStyleBackColor = true;
+ //
+ // lblColor06
+ //
+ this.lblColor06.BackColor = System.Drawing.Color.Maroon;
+ this.lblColor06.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
+ this.lblColor06.Location = new System.Drawing.Point(158, 186);
+ this.lblColor06.Name = "lblColor06";
+ this.lblColor06.Size = new System.Drawing.Size(21, 22);
+ this.lblColor06.TabIndex = 63;
+ this.lblColor06.Text = " ";
+ this.lblColor06.Click += new System.EventHandler(this.lblColor01_Click);
+ //
+ // chkHidden06
+ //
+ this.chkHidden06.AutoSize = true;
+ this.chkHidden06.Location = new System.Drawing.Point(185, 188);
+ this.chkHidden06.Name = "chkHidden06";
+ this.chkHidden06.Size = new System.Drawing.Size(50, 17);
+ this.chkHidden06.TabIndex = 62;
+ this.chkHidden06.Tag = "§";
+ this.chkHidden06.Text = "Hide";
+ this.chkHidden06.UseVisualStyleBackColor = true;
+ //
+ // lblColor05
+ //
+ this.lblColor05.BackColor = System.Drawing.Color.Maroon;
+ this.lblColor05.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
+ this.lblColor05.Location = new System.Drawing.Point(158, 158);
+ this.lblColor05.Name = "lblColor05";
+ this.lblColor05.Size = new System.Drawing.Size(21, 22);
+ this.lblColor05.TabIndex = 61;
+ this.lblColor05.Text = " ";
+ this.lblColor05.Click += new System.EventHandler(this.lblColor01_Click);
+ //
+ // chkHidden05
+ //
+ this.chkHidden05.AutoSize = true;
+ this.chkHidden05.Location = new System.Drawing.Point(185, 160);
+ this.chkHidden05.Name = "chkHidden05";
+ this.chkHidden05.Size = new System.Drawing.Size(50, 17);
+ this.chkHidden05.TabIndex = 60;
+ this.chkHidden05.Tag = "§";
+ this.chkHidden05.Text = "Hide";
+ this.chkHidden05.UseVisualStyleBackColor = true;
+ //
+ // lblColor04
+ //
+ this.lblColor04.BackColor = System.Drawing.Color.Maroon;
+ this.lblColor04.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
+ this.lblColor04.Location = new System.Drawing.Point(158, 130);
+ this.lblColor04.Name = "lblColor04";
+ this.lblColor04.Size = new System.Drawing.Size(21, 22);
+ this.lblColor04.TabIndex = 59;
+ this.lblColor04.Text = " ";
+ this.lblColor04.Click += new System.EventHandler(this.lblColor01_Click);
+ //
+ // chkHidden04
+ //
+ this.chkHidden04.AutoSize = true;
+ this.chkHidden04.Location = new System.Drawing.Point(185, 132);
+ this.chkHidden04.Name = "chkHidden04";
+ this.chkHidden04.Size = new System.Drawing.Size(50, 17);
+ this.chkHidden04.TabIndex = 58;
+ this.chkHidden04.Tag = "§";
+ this.chkHidden04.Text = "Hide";
+ this.chkHidden04.UseVisualStyleBackColor = true;
+ //
+ // lblColor03
+ //
+ this.lblColor03.BackColor = System.Drawing.Color.Maroon;
+ this.lblColor03.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
+ this.lblColor03.Location = new System.Drawing.Point(158, 102);
+ this.lblColor03.Name = "lblColor03";
+ this.lblColor03.Size = new System.Drawing.Size(21, 22);
+ this.lblColor03.TabIndex = 57;
+ this.lblColor03.Text = " ";
+ this.lblColor03.Click += new System.EventHandler(this.lblColor01_Click);
+ //
+ // chkHidden03
+ //
+ this.chkHidden03.AutoSize = true;
+ this.chkHidden03.Location = new System.Drawing.Point(185, 104);
+ this.chkHidden03.Name = "chkHidden03";
+ this.chkHidden03.Size = new System.Drawing.Size(50, 17);
+ this.chkHidden03.TabIndex = 56;
+ this.chkHidden03.Tag = "§";
+ this.chkHidden03.Text = "Hide";
+ this.chkHidden03.UseVisualStyleBackColor = true;
+ //
+ // lblColor02
+ //
+ this.lblColor02.BackColor = System.Drawing.Color.Maroon;
+ this.lblColor02.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
+ this.lblColor02.Location = new System.Drawing.Point(158, 74);
+ this.lblColor02.Name = "lblColor02";
+ this.lblColor02.Size = new System.Drawing.Size(21, 22);
+ this.lblColor02.TabIndex = 55;
+ this.lblColor02.Text = " ";
+ this.lblColor02.Click += new System.EventHandler(this.lblColor01_Click);
+ //
+ // chkHidden02
+ //
+ this.chkHidden02.AutoSize = true;
+ this.chkHidden02.Location = new System.Drawing.Point(185, 76);
+ this.chkHidden02.Name = "chkHidden02";
+ this.chkHidden02.Size = new System.Drawing.Size(50, 17);
+ this.chkHidden02.TabIndex = 54;
+ this.chkHidden02.Tag = "§";
+ this.chkHidden02.Text = "Hide";
+ this.chkHidden02.UseVisualStyleBackColor = true;
+ //
+ // lblColor01
+ //
+ this.lblColor01.BackColor = System.Drawing.Color.Maroon;
+ this.lblColor01.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
+ this.lblColor01.Location = new System.Drawing.Point(158, 46);
+ this.lblColor01.Name = "lblColor01";
+ this.lblColor01.Size = new System.Drawing.Size(21, 22);
+ this.lblColor01.TabIndex = 45;
+ this.lblColor01.Text = " ";
+ this.lblColor01.Click += new System.EventHandler(this.lblColor01_Click);
+ //
+ // chkHidden01
+ //
+ this.chkHidden01.AutoSize = true;
+ this.chkHidden01.Location = new System.Drawing.Point(185, 48);
+ this.chkHidden01.Name = "chkHidden01";
+ this.chkHidden01.Size = new System.Drawing.Size(50, 17);
+ this.chkHidden01.TabIndex = 44;
+ this.chkHidden01.Tag = "§";
+ this.chkHidden01.Text = "Hide";
+ this.chkHidden01.UseVisualStyleBackColor = true;
//
// txJS11
//
this.txJS11.Location = new System.Drawing.Point(340, 158);
this.txJS11.Name = "txJS11";
- this.txJS11.Size = new System.Drawing.Size(199, 22);
+ this.txJS11.Size = new System.Drawing.Size(86, 22);
this.txJS11.TabIndex = 26;
this.txJS11.KeyDown += new System.Windows.Forms.KeyEventHandler(this.txJS1_KeyDown);
this.txJS11.KeyPress += new System.Windows.Forms.KeyPressEventHandler(this.txJS1_KeyPress);
@@ -313,6 +634,7 @@
// label2
//
this.label2.AutoSize = true;
+ this.label2.ForeColor = System.Drawing.Color.Blue;
this.label2.Location = new System.Drawing.Point(271, 189);
this.label2.Name = "label2";
this.label2.Size = new System.Drawing.Size(63, 13);
@@ -323,7 +645,7 @@
//
this.txJS12.Location = new System.Drawing.Point(340, 186);
this.txJS12.Name = "txJS12";
- this.txJS12.Size = new System.Drawing.Size(199, 22);
+ this.txJS12.Size = new System.Drawing.Size(86, 22);
this.txJS12.TabIndex = 28;
this.txJS12.KeyDown += new System.Windows.Forms.KeyEventHandler(this.txJS1_KeyDown);
this.txJS12.KeyPress += new System.Windows.Forms.KeyPressEventHandler(this.txJS1_KeyPress);
@@ -331,6 +653,7 @@
// label11
//
this.label11.AutoSize = true;
+ this.label11.ForeColor = System.Drawing.Color.Blue;
this.label11.Location = new System.Drawing.Point(271, 161);
this.label11.Name = "label11";
this.label11.Size = new System.Drawing.Size(63, 13);
@@ -340,6 +663,7 @@
// label12
//
this.label12.AutoSize = true;
+ this.label12.ForeColor = System.Drawing.Color.Blue;
this.label12.Location = new System.Drawing.Point(271, 133);
this.label12.Name = "label12";
this.label12.Size = new System.Drawing.Size(63, 13);
@@ -350,7 +674,7 @@
//
this.txJS10.Location = new System.Drawing.Point(340, 130);
this.txJS10.Name = "txJS10";
- this.txJS10.Size = new System.Drawing.Size(199, 22);
+ this.txJS10.Size = new System.Drawing.Size(86, 22);
this.txJS10.TabIndex = 24;
this.txJS10.KeyDown += new System.Windows.Forms.KeyEventHandler(this.txJS1_KeyDown);
this.txJS10.KeyPress += new System.Windows.Forms.KeyPressEventHandler(this.txJS1_KeyPress);
@@ -358,6 +682,7 @@
// label13
//
this.label13.AutoSize = true;
+ this.label13.ForeColor = System.Drawing.Color.Blue;
this.label13.Location = new System.Drawing.Point(271, 105);
this.label13.Name = "label13";
this.label13.Size = new System.Drawing.Size(57, 13);
@@ -368,7 +693,7 @@
//
this.txJS9.Location = new System.Drawing.Point(340, 102);
this.txJS9.Name = "txJS9";
- this.txJS9.Size = new System.Drawing.Size(199, 22);
+ this.txJS9.Size = new System.Drawing.Size(86, 22);
this.txJS9.TabIndex = 22;
this.txJS9.KeyDown += new System.Windows.Forms.KeyEventHandler(this.txJS1_KeyDown);
this.txJS9.KeyPress += new System.Windows.Forms.KeyPressEventHandler(this.txJS1_KeyPress);
@@ -537,6 +862,10 @@
this.cbxDetectGamepad.Text = "Use Gamepad";
this.cbxDetectGamepad.UseVisualStyleBackColor = true;
//
+ // colDlg
+ //
+ this.colDlg.FullOpen = true;
+ //
// FormSettings
//
this.AutoScaleDimensions = new System.Drawing.SizeF(96F, 96F);
@@ -617,5 +946,30 @@
private System.Windows.Forms.Label lblProfileLang;
private System.Windows.Forms.ComboBox comboLanguage;
private System.Windows.Forms.CheckBox cbxTreeTips;
+ private System.Windows.Forms.Label lblColor01;
+ private System.Windows.Forms.CheckBox chkHidden01;
+ private System.Windows.Forms.Label lblColor06;
+ private System.Windows.Forms.CheckBox chkHidden06;
+ private System.Windows.Forms.Label lblColor05;
+ private System.Windows.Forms.CheckBox chkHidden05;
+ private System.Windows.Forms.Label lblColor04;
+ private System.Windows.Forms.CheckBox chkHidden04;
+ private System.Windows.Forms.Label lblColor03;
+ private System.Windows.Forms.CheckBox chkHidden03;
+ private System.Windows.Forms.Label lblColor02;
+ private System.Windows.Forms.CheckBox chkHidden02;
+ private System.Windows.Forms.Label lblColor12;
+ private System.Windows.Forms.CheckBox chkHidden12;
+ private System.Windows.Forms.Label lblColor11;
+ private System.Windows.Forms.CheckBox chkHidden11;
+ private System.Windows.Forms.Label lblColor10;
+ private System.Windows.Forms.CheckBox chkHidden10;
+ private System.Windows.Forms.Label lblColor09;
+ private System.Windows.Forms.CheckBox chkHidden09;
+ private System.Windows.Forms.Label lblColor08;
+ private System.Windows.Forms.CheckBox chkHidden08;
+ private System.Windows.Forms.Label lblColor07;
+ private System.Windows.Forms.CheckBox chkHidden07;
+ private System.Windows.Forms.ColorDialog colDlg;
}
}
\ No newline at end of file
diff --git a/FormSettings.cs b/FormSettings.cs
index fcb875e..ae3e06a 100644
--- a/FormSettings.cs
+++ b/FormSettings.cs
@@ -7,6 +7,7 @@ using System.Linq;
using System.Text;
using System.Windows.Forms;
+using SCJMapper_V2.Common;
using SCJMapper_V2.Actions;
using SCJMapper_V2.Translation;
@@ -14,6 +15,10 @@ namespace SCJMapper_V2
{
partial class FormSettings : Form
{
+
+ List m_checks = new List( );
+ List