diff --git a/ControllerHelper/ControllerHelper.Designer.cs b/ControllerHelper/ControllerHelper.Designer.cs
index cccc10212..07c199393 100644
--- a/ControllerHelper/ControllerHelper.Designer.cs
+++ b/ControllerHelper/ControllerHelper.Designer.cs
@@ -904,8 +904,6 @@ private void InitializeComponent()
//
// b_ServiceStop
//
- this.b_ServiceStop.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
- | System.Windows.Forms.AnchorStyles.Right)));
this.b_ServiceStop.Enabled = false;
this.b_ServiceStop.Location = new System.Drawing.Point(323, 68);
this.b_ServiceStop.Name = "b_ServiceStop";
@@ -917,8 +915,6 @@ private void InitializeComponent()
//
// b_ServiceStart
//
- this.b_ServiceStart.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
- | System.Windows.Forms.AnchorStyles.Right)));
this.b_ServiceStart.Enabled = false;
this.b_ServiceStart.Location = new System.Drawing.Point(323, 22);
this.b_ServiceStart.Name = "b_ServiceStart";
@@ -930,8 +926,6 @@ private void InitializeComponent()
//
// b_ServiceDelete
//
- this.b_ServiceDelete.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
- | System.Windows.Forms.AnchorStyles.Right)));
this.b_ServiceDelete.Enabled = false;
this.b_ServiceDelete.Location = new System.Drawing.Point(127, 68);
this.b_ServiceDelete.Name = "b_ServiceDelete";
@@ -943,8 +937,6 @@ private void InitializeComponent()
//
// b_ServiceInstall
//
- this.b_ServiceInstall.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
- | System.Windows.Forms.AnchorStyles.Right)));
this.b_ServiceInstall.Enabled = false;
this.b_ServiceInstall.Location = new System.Drawing.Point(127, 22);
this.b_ServiceInstall.Name = "b_ServiceInstall";
@@ -1013,16 +1005,17 @@ private void InitializeComponent()
//
// ControllerHelper
//
- this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 15F);
- this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
+ this.AutoScaleDimensions = new System.Drawing.SizeF(96F, 96F);
+ this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Dpi;
+ this.AutoSize = true;
this.ClientSize = new System.Drawing.Size(741, 561);
this.Controls.Add(this.tabControl1);
this.DoubleBuffered = true;
- this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
- this.MaximizeBox = false;
+ this.MinimumSize = new System.Drawing.Size(757, 600);
this.Name = "ControllerHelper";
- this.SizeGripStyle = System.Windows.Forms.SizeGripStyle.Hide;
+ this.SizeGripStyle = System.Windows.Forms.SizeGripStyle.Show;
+ this.StartPosition = System.Windows.Forms.FormStartPosition.Manual;
this.Text = "ControllerHelper";
this.FormClosing += new System.Windows.Forms.FormClosingEventHandler(this.ControllerHelper_Close);
this.Load += new System.EventHandler(this.ControllerHelper_Load);
diff --git a/ControllerHelper/ControllerHelper.cs b/ControllerHelper/ControllerHelper.cs
index 32ec2b3d1..010601906 100644
--- a/ControllerHelper/ControllerHelper.cs
+++ b/ControllerHelper/ControllerHelper.cs
@@ -4,6 +4,7 @@
using System;
using System.Collections.Generic;
using System.Diagnostics;
+using System.Drawing;
using System.Globalization;
using System.IO;
using System.Reflection;
@@ -130,6 +131,11 @@ public ControllerHelper(string[] Arguments, ILogger logger)
cB_CloseMinimizes.Checked = CloseMinimises = Properties.Settings.Default.CloseMinimises;
cB_touchpad.Checked = HookMouse = Properties.Settings.Default.HookMouse;
+ // update Position and Size
+ Size = new Size(Properties.Settings.Default.MainWindowWidth, Properties.Settings.Default.MainWindowHeight);
+ Location = new Point(Properties.Settings.Default.MainWindowX, Properties.Settings.Default.MainWindowY);
+ WindowState = (FormWindowState)Properties.Settings.Default.WindowState;
+
if (StartMinimized)
{
WindowState = FormWindowState.Minimized;
@@ -299,11 +305,20 @@ private void ControllerHelper_Resize(object sender, EventArgs e)
private void ControllerHelper_Close(object sender, FormClosingEventArgs e)
{
+ // position and size settings
+ Properties.Settings.Default.MainWindowX = Location.X;
+ Properties.Settings.Default.MainWindowY = Location.Y;
+ Properties.Settings.Default.MainWindowWidth = Size.Width;
+ Properties.Settings.Default.MainWindowHeight = Size.Height;
+ Properties.Settings.Default.WindowState = (int)WindowState;
+
if (CloseMinimises && e.CloseReason == CloseReason.UserClosing)
{
e.Cancel = true;
WindowState = FormWindowState.Minimized;
}
+
+ Properties.Settings.Default.Save();
}
private void notifyIcon1_DoubleClick(object sender, EventArgs e)
diff --git a/ControllerHelper/Properties/Settings.Designer.cs b/ControllerHelper/Properties/Settings.Designer.cs
index f8d328662..9623d7cb9 100644
--- a/ControllerHelper/Properties/Settings.Designer.cs
+++ b/ControllerHelper/Properties/Settings.Designer.cs
@@ -1,10 +1,10 @@
//------------------------------------------------------------------------------
//
-// Ce code a été généré par un outil.
-// Version du runtime :4.0.30319.42000
+// This code was generated by a tool.
+// Runtime Version:4.0.30319.42000
//
-// Les modifications apportées à ce fichier peuvent provoquer un comportement incorrect et seront perdues si
-// le code est régénéré.
+// Changes to this file may cause incorrect behavior and will be lost if
+// the code is regenerated.
//
//------------------------------------------------------------------------------
@@ -12,7 +12,7 @@ namespace ControllerHelper.Properties {
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
- [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "16.10.0.0")]
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "17.0.3.0")]
internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase {
private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings())));
@@ -94,5 +94,65 @@ public bool FirstStart {
this["FirstStart"] = value;
}
}
+
+ [global::System.Configuration.UserScopedSettingAttribute()]
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+ [global::System.Configuration.DefaultSettingValueAttribute("0")]
+ public int MainWindowX {
+ get {
+ return ((int)(this["MainWindowX"]));
+ }
+ set {
+ this["MainWindowX"] = value;
+ }
+ }
+
+ [global::System.Configuration.UserScopedSettingAttribute()]
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+ [global::System.Configuration.DefaultSettingValueAttribute("0")]
+ public int MainWindowY {
+ get {
+ return ((int)(this["MainWindowY"]));
+ }
+ set {
+ this["MainWindowY"] = value;
+ }
+ }
+
+ [global::System.Configuration.UserScopedSettingAttribute()]
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+ [global::System.Configuration.DefaultSettingValueAttribute("0")]
+ public int MainWindowWidth {
+ get {
+ return ((int)(this["MainWindowWidth"]));
+ }
+ set {
+ this["MainWindowWidth"] = value;
+ }
+ }
+
+ [global::System.Configuration.UserScopedSettingAttribute()]
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+ [global::System.Configuration.DefaultSettingValueAttribute("0")]
+ public int MainWindowHeight {
+ get {
+ return ((int)(this["MainWindowHeight"]));
+ }
+ set {
+ this["MainWindowHeight"] = value;
+ }
+ }
+
+ [global::System.Configuration.UserScopedSettingAttribute()]
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+ [global::System.Configuration.DefaultSettingValueAttribute("0")]
+ public int WindowState {
+ get {
+ return ((int)(this["WindowState"]));
+ }
+ set {
+ this["WindowState"] = value;
+ }
+ }
}
}
diff --git a/ControllerHelper/Properties/Settings.settings b/ControllerHelper/Properties/Settings.settings
index 3bfdb3c50..f7c550db5 100644
--- a/ControllerHelper/Properties/Settings.settings
+++ b/ControllerHelper/Properties/Settings.settings
@@ -20,5 +20,20 @@
True
+
+ 0
+
+
+ 0
+
+
+ 0
+
+
+ 0
+
+
+ 0
+
\ No newline at end of file
diff --git a/ControllerService/AssemblyInfo1.cs b/ControllerService/AssemblyInfo1.cs
index db7a5f66a..91ae59d24 100644
--- a/ControllerService/AssemblyInfo1.cs
+++ b/ControllerService/AssemblyInfo1.cs
@@ -19,5 +19,5 @@
// Numéro de build
// Révision
//
-[assembly: AssemblyVersion("0.8.1.5")]
-[assembly: AssemblyFileVersion("0.8.1.5")]
+[assembly: AssemblyVersion("0.8.1.6")]
+[assembly: AssemblyFileVersion("0.8.1.6")]