diff --git a/FizzyLauncher.csproj b/FizzyLauncher.csproj
index b9a227e..5946eca 100644
--- a/FizzyLauncher.csproj
+++ b/FizzyLauncher.csproj
@@ -12,9 +12,9 @@
Hi, I'm Ray
Fizzy Launcher
Ray Lam
- 0.2.3.006
- 0.2.3.006
- 0.2.3.006
+ 0.2.3.009
+ 0.2.3.009
+ 0.2.3.009
diff --git a/MainForm.Designer.cs b/MainForm.Designer.cs
index 3ebc4a4..de4f811 100644
--- a/MainForm.Designer.cs
+++ b/MainForm.Designer.cs
@@ -284,7 +284,7 @@ namespace FizzyLauncher
this.aboutToolStripMenuItem1.Text = "&About";
this.aboutToolStripMenuItem1.Click += new System.EventHandler(this.aboutToolStripMenuItem1_Click);
//
- // panel1
+ // tileContainer1
//
this.tileContainer1.AutoScroll = true;
this.tileContainer1.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink;
@@ -292,15 +292,14 @@ namespace FizzyLauncher
this.tileContainer1.Dock = System.Windows.Forms.DockStyle.Fill;
this.tileContainer1.Location = new System.Drawing.Point(0, 24);
this.tileContainer1.Margin = new System.Windows.Forms.Padding(0);
- this.tileContainer1.Name = "panel1";
+ this.tileContainer1.Name = "tileContainer1";
this.tileContainer1.Padding = new System.Windows.Forms.Padding(10, 10, 10, 20);
this.tileContainer1.Size = new System.Drawing.Size(633, 376);
this.tileContainer1.TabIndex = 3;
//
// MainForm
//
- this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 15F);
- this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
+ this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None;
this.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(250)))), ((int)(((byte)(250)))), ((int)(((byte)(250)))));
this.BackgroundImageLayout = System.Windows.Forms.ImageLayout.None;
this.ClientSize = new System.Drawing.Size(633, 400);
diff --git a/MainForm.cs b/MainForm.cs
index 344d063..a182ece 100644
--- a/MainForm.cs
+++ b/MainForm.cs
@@ -50,6 +50,8 @@ namespace FizzyLauncher
{
base.OnLoad(e);
+ this.AutoScaleMode = AutoScaleMode.None;
+
ThreadControl.SetVisible(this, false);
ThreadControl.SetSize(this, this.MinimumSize);
}
@@ -60,8 +62,13 @@ namespace FizzyLauncher
ThreadControl.SetVisible(this, false);
- string jsonfigFilename = Path.ChangeExtension(Application.ExecutablePath, "jsonfig");
- if (File.Exists(jsonfigFilename))
+ string[] commandLineArgs = Environment.GetCommandLineArgs();
+
+ string jsonfigFilename = null;
+ if (string.IsNullOrWhiteSpace(jsonfigFilename)) jsonfigFilename = parseOpenFile_FromCMD(commandLineArgs);
+ if (string.IsNullOrWhiteSpace(jsonfigFilename)) jsonfigFilename = Path.ChangeExtension(Application.ExecutablePath, "jsonfig");
+
+ if (!string.IsNullOrWhiteSpace(jsonfigFilename) && File.Exists(jsonfigFilename))
{
await loadFile(jsonfigFilename);
}
@@ -236,6 +243,42 @@ namespace FizzyLauncher
}
}
+ protected string parseOpenFile_FromCMD(string[] args)
+ {
+ if (args.Length <= 1)
+ {
+ return null;
+ }
+
+ int i = 1;
+ while (true)
+ {
+ if (i > (args.Length - 1))
+ {
+ break;
+ }
+
+ switch (args[i].Trim().ToLower())
+ {
+ case "-o":
+ case "-open":
+ if ((i + 1) > (args.Length - 1)) break;
+
+ string openFilename = args[(i + 1)];
+ if (string.IsNullOrWhiteSpace(openFilename)) break;
+ if (!File.Exists(openFilename)) break;
+
+ return openFilename;
+
+ i++;
+ break;
+ }
+
+ i++;
+ }
+
+ return null;
+ }
protected void newSession()
{
diff --git a/installer-64.iss b/installer-64.iss
index 190547f..4c4984e 100644
--- a/installer-64.iss
+++ b/installer-64.iss
@@ -2,7 +2,7 @@
; SEE THE DOCUMENTATION FOR DETAILS ON CREATING INNO SETUP SCRIPT FILES!
#define MyAppName "Fizzy Launcher"
-#define MyAppVersion "0.2.3.006"
+#define MyAppVersion "0.2.3.009"
#define MyAppPublisher "Hi, I'm Ray"
#define MyAppURL "https://www.hiimray.co.uk/software-fizzy-launcher"
#define MyAppExeName "fizzylauncher.exe"
diff --git a/installer-86.iss b/installer-86.iss
index 66e4836..95a55f0 100644
--- a/installer-86.iss
+++ b/installer-86.iss
@@ -2,7 +2,7 @@
; SEE THE DOCUMENTATION FOR DETAILS ON CREATING INNO SETUP SCRIPT FILES!
#define MyAppName "Fizzy Launcher"
-#define MyAppVersion "0.2.3.006"
+#define MyAppVersion "0.2.3.009"
#define MyAppPublisher "Hi, I'm Ray"
#define MyAppURL "https://www.hiimray.co.uk/software-fizzy-launcher"
#define MyAppExeName "fizzylauncher.exe"