From 57a6efa25fb91317bfdc2c2f73cb28315a9b3046 Mon Sep 17 00:00:00 2001 From: Alex Ch Date: Sun, 14 Nov 2021 16:04:19 +0300 Subject: [PATCH] 1.2 released --- Input/InputEmulator.cs | 5 --- MainForm.Designer.cs | 67 +++++++++++++++++++++++--------------- Properties/AssemblyInfo.cs | 2 +- 3 files changed, 41 insertions(+), 33 deletions(-) diff --git a/Input/InputEmulator.cs b/Input/InputEmulator.cs index e6ae7fb..ed1dcb7 100644 --- a/Input/InputEmulator.cs +++ b/Input/InputEmulator.cs @@ -47,11 +47,6 @@ private static void OnFFBEvent(IntPtr data, object userData) if (joyStick.Ffb_h_Eff_Constant(data, ref effectInf) == ERROR_SUCCESS) { ffbListener.OnFfbEffect((uint)Math.Abs(effectInf.Magnitude)); - Console.WriteLine("OK, Magnitude = " + effectInf.Magnitude); - } - else - { - //Console.WriteLine("UNABLE"); } } diff --git a/MainForm.Designer.cs b/MainForm.Designer.cs index 303da77..f250e7f 100644 --- a/MainForm.Designer.cs +++ b/MainForm.Designer.cs @@ -48,9 +48,10 @@ private void InitializeComponent() // this.label1.AutoSize = true; this.label1.Font = new System.Drawing.Font("Microsoft Sans Serif", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(204))); - this.label1.Location = new System.Drawing.Point(16, 144); + this.label1.Location = new System.Drawing.Point(21, 177); + this.label1.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.label1.Name = "label1"; - this.label1.Size = new System.Drawing.Size(35, 16); + this.label1.Size = new System.Drawing.Size(42, 20); this.label1.TabIndex = 1; this.label1.Text = "Port:"; // @@ -58,16 +59,18 @@ private void InitializeComponent() // this.label2.AutoSize = true; this.label2.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(204))); - this.label2.Location = new System.Drawing.Point(15, 71); + this.label2.Location = new System.Drawing.Point(20, 87); + this.label2.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.label2.Name = "label2"; - this.label2.Size = new System.Drawing.Size(107, 20); + this.label2.Size = new System.Drawing.Size(133, 25); this.label2.TabIndex = 2; this.label2.Text = "Server status:"; // // numericUpPort // this.numericUpPort.Font = new System.Drawing.Font("Microsoft Sans Serif", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(204))); - this.numericUpPort.Location = new System.Drawing.Point(57, 142); + this.numericUpPort.Location = new System.Drawing.Point(76, 175); + this.numericUpPort.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); this.numericUpPort.Maximum = new decimal(new int[] { 65535, 0, @@ -79,7 +82,7 @@ private void InitializeComponent() 0, 0}); this.numericUpPort.Name = "numericUpPort"; - this.numericUpPort.Size = new System.Drawing.Size(83, 22); + this.numericUpPort.Size = new System.Drawing.Size(111, 25); this.numericUpPort.TabIndex = 3; this.numericUpPort.Value = new decimal(new int[] { 18250, @@ -91,9 +94,10 @@ private void InitializeComponent() // buttonStop // this.buttonStop.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(204))); - this.buttonStop.Location = new System.Drawing.Point(15, 179); + this.buttonStop.Location = new System.Drawing.Point(20, 220); + this.buttonStop.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); this.buttonStop.Name = "buttonStop"; - this.buttonStop.Size = new System.Drawing.Size(125, 33); + this.buttonStop.Size = new System.Drawing.Size(167, 41); this.buttonStop.TabIndex = 5; this.buttonStop.Text = "Stop"; this.buttonStop.UseVisualStyleBackColor = true; @@ -103,9 +107,10 @@ private void InitializeComponent() // this.buttonStart.Enabled = false; this.buttonStart.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(204))); - this.buttonStart.Location = new System.Drawing.Point(15, 222); + this.buttonStart.Location = new System.Drawing.Point(20, 273); + this.buttonStart.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); this.buttonStart.Name = "buttonStart"; - this.buttonStart.Size = new System.Drawing.Size(125, 33); + this.buttonStart.Size = new System.Drawing.Size(167, 41); this.buttonStart.TabIndex = 6; this.buttonStart.Text = "Start"; this.buttonStart.UseVisualStyleBackColor = true; @@ -113,11 +118,12 @@ private void InitializeComponent() // // sensitivityTrackBar // - this.sensitivityTrackBar.Location = new System.Drawing.Point(163, 93); + this.sensitivityTrackBar.Location = new System.Drawing.Point(217, 114); + this.sensitivityTrackBar.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); this.sensitivityTrackBar.Maximum = 100; this.sensitivityTrackBar.Minimum = 1; this.sensitivityTrackBar.Name = "sensitivityTrackBar"; - this.sensitivityTrackBar.Size = new System.Drawing.Size(141, 45); + this.sensitivityTrackBar.Size = new System.Drawing.Size(188, 53); this.sensitivityTrackBar.TabIndex = 7; this.sensitivityTrackBar.TickFrequency = 5; this.sensitivityTrackBar.Value = 50; @@ -127,9 +133,10 @@ private void InitializeComponent() // this.label3.AutoSize = true; this.label3.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(204))); - this.label3.Location = new System.Drawing.Point(169, 13); + this.label3.Location = new System.Drawing.Point(225, 16); + this.label3.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.label3.Name = "label3"; - this.label3.Size = new System.Drawing.Size(73, 20); + this.label3.Size = new System.Drawing.Size(91, 25); this.label3.TabIndex = 8; this.label3.Text = "Steering:"; // @@ -137,9 +144,10 @@ private void InitializeComponent() // this.label4.AutoSize = true; this.label4.Font = new System.Drawing.Font("Microsoft Sans Serif", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(204))); - this.label4.Location = new System.Drawing.Point(170, 74); + this.label4.Location = new System.Drawing.Point(227, 91); + this.label4.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.label4.Name = "label4"; - this.label4.Size = new System.Drawing.Size(71, 16); + this.label4.Size = new System.Drawing.Size(83, 20); this.label4.TabIndex = 9; this.label4.Text = "Sensitivity:"; // @@ -148,9 +156,10 @@ private void InitializeComponent() this.labelStatus.AutoSize = true; this.labelStatus.Font = new System.Drawing.Font("Microsoft Sans Serif", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(204))); this.labelStatus.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(0)))), ((int)(((byte)(192)))), ((int)(((byte)(0))))); - this.labelStatus.Location = new System.Drawing.Point(16, 98); + this.labelStatus.Location = new System.Drawing.Point(21, 121); + this.labelStatus.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.labelStatus.Name = "labelStatus"; - this.labelStatus.Size = new System.Drawing.Size(59, 16); + this.labelStatus.Size = new System.Drawing.Size(68, 20); this.labelStatus.TabIndex = 10; this.labelStatus.Text = "Enabled"; // @@ -159,9 +168,10 @@ private void InitializeComponent() this.label7.AutoSize = true; this.label7.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(204))); this.label7.ForeColor = System.Drawing.SystemColors.ControlText; - this.label7.Location = new System.Drawing.Point(16, 13); + this.label7.Location = new System.Drawing.Point(21, 16); + this.label7.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.label7.Name = "label7"; - this.label7.Size = new System.Drawing.Size(78, 20); + this.label7.Size = new System.Drawing.Size(99, 25); this.label7.TabIndex = 11; this.label7.Text = "Server IP:"; // @@ -170,9 +180,10 @@ private void InitializeComponent() this.labelIp.AutoSize = true; this.labelIp.Font = new System.Drawing.Font("Microsoft Sans Serif", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(204))); this.labelIp.ForeColor = System.Drawing.SystemColors.ControlText; - this.labelIp.Location = new System.Drawing.Point(16, 39); + this.labelIp.Location = new System.Drawing.Point(21, 48); + this.labelIp.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.labelIp.Name = "labelIp"; - this.labelIp.Size = new System.Drawing.Size(80, 16); + this.labelIp.Size = new System.Drawing.Size(102, 20); this.labelIp.TabIndex = 12; this.labelIp.Text = "192.168.0.16"; // @@ -180,18 +191,19 @@ private void InitializeComponent() // this.labelSensitivity.Font = new System.Drawing.Font("Microsoft Sans Serif", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(204))); this.labelSensitivity.ForeColor = System.Drawing.SystemColors.ControlText; - this.labelSensitivity.Location = new System.Drawing.Point(213, 122); + this.labelSensitivity.Location = new System.Drawing.Point(284, 150); + this.labelSensitivity.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0); this.labelSensitivity.Name = "labelSensitivity"; - this.labelSensitivity.Size = new System.Drawing.Size(40, 16); + this.labelSensitivity.Size = new System.Drawing.Size(53, 20); this.labelSensitivity.TabIndex = 13; this.labelSensitivity.Text = "50"; this.labelSensitivity.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; // // MainForm // - this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); + this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 16F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; - this.ClientSize = new System.Drawing.Size(315, 264); + this.ClientSize = new System.Drawing.Size(420, 325); this.Controls.Add(this.labelSensitivity); this.Controls.Add(this.labelIp); this.Controls.Add(this.label7); @@ -205,11 +217,12 @@ private void InitializeComponent() this.Controls.Add(this.label2); this.Controls.Add(this.label1); this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle; + this.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4); this.MaximizeBox = false; this.Name = "MainForm"; this.ShowIcon = false; this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen; - this.Text = "Truck Remote Server 1.13.1"; + this.Text = "Truck Remote Server 1.2"; this.FormClosing += new System.Windows.Forms.FormClosingEventHandler(this.MainForm_FormClosing); ((System.ComponentModel.ISupportInitialize)(this.numericUpPort)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.sensitivityTrackBar)).EndInit(); diff --git a/Properties/AssemblyInfo.cs b/Properties/AssemblyInfo.cs index e96adb7..a4f9b13 100644 --- a/Properties/AssemblyInfo.cs +++ b/Properties/AssemblyInfo.cs @@ -10,7 +10,7 @@ [assembly: AssemblyConfiguration("")] [assembly: AssemblyCompany("")] [assembly: AssemblyProduct("TruckRemoteServer")] -[assembly: AssemblyCopyright("Copyright © 2019")] +[assembly: AssemblyCopyright("Copyright © 2021")] [assembly: AssemblyTrademark("")] [assembly: AssemblyCulture("")]