From 94a367fd5913aceb8e0923468294327fc6599b88 Mon Sep 17 00:00:00 2001
From: Denis <93516910+Bussun@users.noreply.github.com>
Date: Sun, 5 Dec 2021 16:20:43 +0100
Subject: [PATCH] Beta code v0.7
---
BMGEditor/Program.cs | 9 +--
BMGEditor/UI/BMGEditForm.Designer.cs | 2 +-
BMGEditor/UI/BMGEditForm.cs | 1 +
BMGEditor/UI/MainForm.cs | 10 +--
BMGEditor/UI/PreferencesAbout.Designer.cs | 62 +++++++++++++++++
BMGEditor/UI/PreferencesAbout.cs | 13 ++++
BMGEditor/UI/PreferencesAbout.resx | 81 -----------------------
7 files changed, 81 insertions(+), 97 deletions(-)
diff --git a/BMGEditor/Program.cs b/BMGEditor/Program.cs
index a02bf41..ca11517 100644
--- a/BMGEditor/Program.cs
+++ b/BMGEditor/Program.cs
@@ -1,20 +1,15 @@
using System;
-using System.Linq;
-using System.Collections.Generic;
using System.Windows.Forms;
-using System.Text;
-using System.Globalization;
using System.Net.Http;
using System.IO;
-using System.Threading;
namespace BMGEditor
{
public static class Variables
{
public const string softwareName = "Luma";
- public const string softwareVersion = "v0.6";
- public const UInt64 softwareInternalVersion = 60;
+ public const string softwareVersion = "v0.7";
+ public const UInt64 softwareInternalVersion = 70;
public const UInt64 build = 1; //Getting ready for 1.0
public const bool isBeta = true;
}
diff --git a/BMGEditor/UI/BMGEditForm.Designer.cs b/BMGEditor/UI/BMGEditForm.Designer.cs
index e0496af..abe11cb 100644
--- a/BMGEditor/UI/BMGEditForm.Designer.cs
+++ b/BMGEditor/UI/BMGEditForm.Designer.cs
@@ -92,7 +92,7 @@
//
this.openSettingsBtn.Name = "openSettingsBtn";
this.openSettingsBtn.Size = new System.Drawing.Size(180, 22);
- this.openSettingsBtn.Text = "Preferences";
+ this.openSettingsBtn.Text = "About";
this.openSettingsBtn.Click += new System.EventHandler(this.openSettingsBtn_Click);
//
// quitBtn
diff --git a/BMGEditor/UI/BMGEditForm.cs b/BMGEditor/UI/BMGEditForm.cs
index 5a68494..2a639eb 100644
--- a/BMGEditor/UI/BMGEditForm.cs
+++ b/BMGEditor/UI/BMGEditForm.cs
@@ -11,6 +11,7 @@ namespace BMGEditor
private Bcsv m_BCSV = null;
private bool arcOpen = false;
+ [Obsolete]
public BMGEditForm(RarcFilesystem m_ARC)
{
InitializeComponent();
diff --git a/BMGEditor/UI/MainForm.cs b/BMGEditor/UI/MainForm.cs
index fc9da78..409244a 100644
--- a/BMGEditor/UI/MainForm.cs
+++ b/BMGEditor/UI/MainForm.cs
@@ -1,11 +1,4 @@
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;
namespace BMGEditor
@@ -76,7 +69,8 @@ namespace BMGEditor
private void button1_Click(object sender, EventArgs e)
{
- MessageBox.Show("BMG Editor by Bussun", "About", MessageBoxButtons.OK, MessageBoxIcon.Information);
+ Form aboutForm = new PreferencesAbout();
+ aboutForm.Show();
}
private void openTextEditorEmptyBtn_Click(object sender, EventArgs e)
diff --git a/BMGEditor/UI/PreferencesAbout.Designer.cs b/BMGEditor/UI/PreferencesAbout.Designer.cs
index 07d4d3b..522fec5 100644
--- a/BMGEditor/UI/PreferencesAbout.Designer.cs
+++ b/BMGEditor/UI/PreferencesAbout.Designer.cs
@@ -30,6 +30,11 @@
{
this.label1 = new System.Windows.Forms.Label();
this.label2 = new System.Windows.Forms.Label();
+ this.label3 = new System.Windows.Forms.Label();
+ this.closeFormBtn = new System.Windows.Forms.Button();
+ this.label4 = new System.Windows.Forms.Label();
+ this.checkUpdateBtn = new System.Windows.Forms.Button();
+ this.label5 = new System.Windows.Forms.Label();
this.SuspendLayout();
//
// label1
@@ -52,11 +57,63 @@
this.label2.TabIndex = 1;
this.label2.Text = "A BMG editor for Super Mario Galaxy";
//
+ // label3
+ //
+ this.label3.AutoSize = true;
+ this.label3.Location = new System.Drawing.Point(21, 84);
+ this.label3.Name = "label3";
+ this.label3.Size = new System.Drawing.Size(45, 15);
+ this.label3.TabIndex = 2;
+ this.label3.Text = "Version";
+ //
+ // closeFormBtn
+ //
+ this.closeFormBtn.Location = new System.Drawing.Point(261, 148);
+ this.closeFormBtn.Name = "closeFormBtn";
+ this.closeFormBtn.Size = new System.Drawing.Size(75, 23);
+ this.closeFormBtn.TabIndex = 3;
+ this.closeFormBtn.Text = "Close";
+ this.closeFormBtn.UseVisualStyleBackColor = true;
+ this.closeFormBtn.Click += new System.EventHandler(this.closeFormBtn_Click);
+ //
+ // label4
+ //
+ this.label4.AutoSize = true;
+ this.label4.Location = new System.Drawing.Point(21, 110);
+ this.label4.Name = "label4";
+ this.label4.Size = new System.Drawing.Size(34, 15);
+ this.label4.TabIndex = 4;
+ this.label4.Text = "Build";
+ //
+ // checkUpdateBtn
+ //
+ this.checkUpdateBtn.Location = new System.Drawing.Point(129, 148);
+ this.checkUpdateBtn.Name = "checkUpdateBtn";
+ this.checkUpdateBtn.Size = new System.Drawing.Size(126, 23);
+ this.checkUpdateBtn.TabIndex = 5;
+ this.checkUpdateBtn.Text = "Check for updates";
+ this.checkUpdateBtn.UseVisualStyleBackColor = true;
+ this.checkUpdateBtn.Click += new System.EventHandler(this.checkUpdateBtn_Click);
+ //
+ // label5
+ //
+ this.label5.AutoSize = true;
+ this.label5.Location = new System.Drawing.Point(21, 152);
+ this.label5.Name = "label5";
+ this.label5.Size = new System.Drawing.Size(94, 15);
+ this.label5.TabIndex = 6;
+ this.label5.Text = "Made by Bussun";
+ //
// PreferencesAbout
//
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 15F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(348, 183);
+ this.Controls.Add(this.label5);
+ this.Controls.Add(this.checkUpdateBtn);
+ this.Controls.Add(this.label4);
+ this.Controls.Add(this.closeFormBtn);
+ this.Controls.Add(this.label3);
this.Controls.Add(this.label2);
this.Controls.Add(this.label1);
this.MaximizeBox = false;
@@ -75,5 +132,10 @@
private System.Windows.Forms.Label label1;
private System.Windows.Forms.Label label2;
+ private System.Windows.Forms.Label label3;
+ private System.Windows.Forms.Button closeFormBtn;
+ private System.Windows.Forms.Label label4;
+ private System.Windows.Forms.Button checkUpdateBtn;
+ private System.Windows.Forms.Label label5;
}
}
\ No newline at end of file
diff --git a/BMGEditor/UI/PreferencesAbout.cs b/BMGEditor/UI/PreferencesAbout.cs
index 16b99e7..46c7ccc 100644
--- a/BMGEditor/UI/PreferencesAbout.cs
+++ b/BMGEditor/UI/PreferencesAbout.cs
@@ -15,6 +15,19 @@ namespace BMGEditor
public PreferencesAbout()
{
InitializeComponent();
+ Text = "About this software";
+ label3.Text = $"Version: {Variables.softwareVersion}";
+ label4.Text = $"Build number: {Variables.softwareInternalVersion}";
+ }
+
+ private void closeFormBtn_Click(object sender, EventArgs e)
+ {
+ Dispose();
+ }
+
+ private void checkUpdateBtn_Click(object sender, EventArgs e)
+ {
+ Program.CheckUpdates();
}
}
}
diff --git a/BMGEditor/UI/PreferencesAbout.resx b/BMGEditor/UI/PreferencesAbout.resx
index e4190f3..f298a7b 100644
--- a/BMGEditor/UI/PreferencesAbout.resx
+++ b/BMGEditor/UI/PreferencesAbout.resx
@@ -57,85 +57,4 @@
System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- Segoe UI, 21.75pt, style=Bold
-
-
- 93, 40
-
-
- PreferencesAbout
-
-
- $this
-
-
-
- CenterParent
-
-
- label2
-
-
- System.Windows.Forms.Form, System.Windows.Forms, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- label1
-
-
- Luma
-
-
-
- True
-
-
- 0
-
-
- A BMG editor for Super Mario Galaxy
-
-
- 1
-
-
- 7, 15
-
-
- PreferencesAbout
-
-
- System.Windows.Forms.Label, System.Windows.Forms, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- $this
-
-
- 243, 20
-
-
- Segoe UI, 11.25pt, style=Italic
-
-
- 1
-
-
- 348, 183
-
-
- 21, 49
-
-
- True
-
-
- 12, 9
-
-
- System.Windows.Forms.Label, System.Windows.Forms, Culture=neutral, PublicKeyToken=b77a5c561934e089
-
-
- 0
-
\ No newline at end of file