diff --git a/ConfigEditor/ConfigEditor.csproj b/ConfigEditor/ConfigEditor.csproj
index 3e0fc19..a3892a9 100644
--- a/ConfigEditor/ConfigEditor.csproj
+++ b/ConfigEditor/ConfigEditor.csproj
@@ -46,14 +46,17 @@
-
+
Form
-
- Form1.cs
+
+ MainForm.cs
+
+ MainForm.cs
+
ResXFileCodeGenerator
Resources.Designer.cs
diff --git a/ConfigEditor/Form1.Designer.cs b/ConfigEditor/Form1.Designer.cs
deleted file mode 100644
index e0c0f20..0000000
--- a/ConfigEditor/Form1.Designer.cs
+++ /dev/null
@@ -1,40 +0,0 @@
-namespace ConfigEditor
-{
- partial class Form1
- {
- ///
- /// Обязательная переменная конструктора.
- ///
- private System.ComponentModel.IContainer components = null;
-
- ///
- /// Освободить все используемые ресурсы.
- ///
- /// истинно, если управляемый ресурс должен быть удален; иначе ложно.
- protected override void Dispose(bool disposing)
- {
- if (disposing && (components != null))
- {
- components.Dispose();
- }
- base.Dispose(disposing);
- }
-
- #region Код, автоматически созданный конструктором форм Windows
-
- ///
- /// Требуемый метод для поддержки конструктора — не изменяйте
- /// содержимое этого метода с помощью редактора кода.
- ///
- private void InitializeComponent()
- {
- this.components = new System.ComponentModel.Container();
- this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
- this.ClientSize = new System.Drawing.Size(800, 450);
- this.Text = "Form1";
- }
-
- #endregion
- }
-}
-
diff --git a/ConfigEditor/Form1.cs b/ConfigEditor/Form1.cs
deleted file mode 100644
index 89b4fd2..0000000
--- a/ConfigEditor/Form1.cs
+++ /dev/null
@@ -1,12 +0,0 @@
-using System.Windows.Forms;
-
-namespace ConfigEditor
-{
- public partial class Form1: Form
- {
- public Form1()
- {
- InitializeComponent();
- }
- }
-}
diff --git a/ConfigEditor/MainForm.Designer.cs b/ConfigEditor/MainForm.Designer.cs
new file mode 100644
index 0000000..a3a35be
--- /dev/null
+++ b/ConfigEditor/MainForm.Designer.cs
@@ -0,0 +1,160 @@
+namespace ConfigEditor
+{
+ partial class MainForm
+ {
+ ///
+ /// Обязательная переменная конструктора.
+ ///
+ private System.ComponentModel.IContainer components = null;
+
+ ///
+ /// Освободить все используемые ресурсы.
+ ///
+ /// истинно, если управляемый ресурс должен быть удален; иначе ложно.
+ protected override void Dispose(bool disposing)
+ {
+ if (disposing && (components != null))
+ {
+ components.Dispose();
+ }
+ base.Dispose(disposing);
+ }
+
+ #region Код, автоматически созданный конструктором форм Windows
+
+ ///
+ /// Требуемый метод для поддержки конструктора — не изменяйте
+ /// содержимое этого метода с помощью редактора кода.
+ ///
+ private void InitializeComponent()
+ {
+ this.richTextBox1 = new System.Windows.Forms.RichTextBox();
+ this.menuStrip1 = new System.Windows.Forms.MenuStrip();
+ this.файлToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
+ this.открытьToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
+ this.сохранитьToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
+ this.сохранитьКакToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
+ this.toolStripSeparator1 = new System.Windows.Forms.ToolStripSeparator();
+ this.сгенерироватьMD5ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
+ this.toolStripSeparator2 = new System.Windows.Forms.ToolStripSeparator();
+ this.закрытьФайлToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
+ this.закрытьToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
+ this.menuStrip1.SuspendLayout();
+ this.SuspendLayout();
+ //
+ // richTextBox1
+ //
+ this.richTextBox1.Dock = System.Windows.Forms.DockStyle.Fill;
+ this.richTextBox1.Font = new System.Drawing.Font("Calibri", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(204)));
+ this.richTextBox1.Location = new System.Drawing.Point(0, 24);
+ this.richTextBox1.Name = "richTextBox1";
+ this.richTextBox1.Size = new System.Drawing.Size(800, 426);
+ this.richTextBox1.TabIndex = 0;
+ this.richTextBox1.Text = "";
+ //
+ // menuStrip1
+ //
+ this.menuStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
+ this.файлToolStripMenuItem});
+ this.menuStrip1.Location = new System.Drawing.Point(0, 0);
+ this.menuStrip1.Name = "menuStrip1";
+ this.menuStrip1.Size = new System.Drawing.Size(800, 24);
+ this.menuStrip1.TabIndex = 1;
+ this.menuStrip1.Text = "menuStrip1";
+ //
+ // файлToolStripMenuItem
+ //
+ this.файлToolStripMenuItem.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
+ this.открытьToolStripMenuItem,
+ this.сохранитьToolStripMenuItem,
+ this.сохранитьКакToolStripMenuItem,
+ this.toolStripSeparator1,
+ this.сгенерироватьMD5ToolStripMenuItem,
+ this.toolStripSeparator2,
+ this.закрытьФайлToolStripMenuItem,
+ this.закрытьToolStripMenuItem});
+ this.файлToolStripMenuItem.Name = "файлToolStripMenuItem";
+ this.файлToolStripMenuItem.Size = new System.Drawing.Size(48, 20);
+ this.файлToolStripMenuItem.Text = "Файл";
+ //
+ // открытьToolStripMenuItem
+ //
+ this.открытьToolStripMenuItem.Name = "открытьToolStripMenuItem";
+ this.открытьToolStripMenuItem.Size = new System.Drawing.Size(185, 22);
+ this.открытьToolStripMenuItem.Text = "Открыть";
+ this.открытьToolStripMenuItem.Click += new System.EventHandler(this.открытьToolStripMenuItem_Click);
+ //
+ // сохранитьToolStripMenuItem
+ //
+ this.сохранитьToolStripMenuItem.Name = "сохранитьToolStripMenuItem";
+ this.сохранитьToolStripMenuItem.Size = new System.Drawing.Size(185, 22);
+ this.сохранитьToolStripMenuItem.Text = "Сохранить";
+ //
+ // сохранитьКакToolStripMenuItem
+ //
+ this.сохранитьКакToolStripMenuItem.Name = "сохранитьКакToolStripMenuItem";
+ this.сохранитьКакToolStripMenuItem.Size = new System.Drawing.Size(185, 22);
+ this.сохранитьКакToolStripMenuItem.Text = "Сохранить как...";
+ //
+ // toolStripSeparator1
+ //
+ this.toolStripSeparator1.Name = "toolStripSeparator1";
+ this.toolStripSeparator1.Size = new System.Drawing.Size(182, 6);
+ //
+ // сгенерироватьMD5ToolStripMenuItem
+ //
+ this.сгенерироватьMD5ToolStripMenuItem.Name = "сгенерироватьMD5ToolStripMenuItem";
+ this.сгенерироватьMD5ToolStripMenuItem.Size = new System.Drawing.Size(185, 22);
+ this.сгенерироватьMD5ToolStripMenuItem.Text = "Сгенерировать MD5";
+ //
+ // toolStripSeparator2
+ //
+ this.toolStripSeparator2.Name = "toolStripSeparator2";
+ this.toolStripSeparator2.Size = new System.Drawing.Size(182, 6);
+ //
+ // закрытьФайлToolStripMenuItem
+ //
+ this.закрытьФайлToolStripMenuItem.Name = "закрытьФайлToolStripMenuItem";
+ this.закрытьФайлToolStripMenuItem.Size = new System.Drawing.Size(185, 22);
+ this.закрытьФайлToolStripMenuItem.Text = "Закрыть файл";
+ //
+ // закрытьToolStripMenuItem
+ //
+ this.закрытьToolStripMenuItem.Name = "закрытьToolStripMenuItem";
+ this.закрытьToolStripMenuItem.Size = new System.Drawing.Size(185, 22);
+ this.закрытьToolStripMenuItem.Text = "Закрыть";
+ this.закрытьToolStripMenuItem.Click += new System.EventHandler(this.закрытьToolStripMenuItem_Click);
+ //
+ // Form1
+ //
+ this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
+ this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
+ this.ClientSize = new System.Drawing.Size(800, 450);
+ this.Controls.Add(this.richTextBox1);
+ this.Controls.Add(this.menuStrip1);
+ this.MainMenuStrip = this.menuStrip1;
+ this.Name = "Form1";
+ this.Text = "SaveWizard Config Editor";
+ this.menuStrip1.ResumeLayout(false);
+ this.menuStrip1.PerformLayout();
+ this.ResumeLayout(false);
+ this.PerformLayout();
+
+ }
+
+ #endregion
+
+ private System.Windows.Forms.RichTextBox richTextBox1;
+ private System.Windows.Forms.MenuStrip menuStrip1;
+ private System.Windows.Forms.ToolStripMenuItem файлToolStripMenuItem;
+ private System.Windows.Forms.ToolStripMenuItem открытьToolStripMenuItem;
+ private System.Windows.Forms.ToolStripMenuItem сохранитьToolStripMenuItem;
+ private System.Windows.Forms.ToolStripMenuItem сохранитьКакToolStripMenuItem;
+ private System.Windows.Forms.ToolStripSeparator toolStripSeparator1;
+ private System.Windows.Forms.ToolStripMenuItem сгенерироватьMD5ToolStripMenuItem;
+ private System.Windows.Forms.ToolStripSeparator toolStripSeparator2;
+ private System.Windows.Forms.ToolStripMenuItem закрытьФайлToolStripMenuItem;
+ private System.Windows.Forms.ToolStripMenuItem закрытьToolStripMenuItem;
+ }
+}
+
diff --git a/ConfigEditor/MainForm.cs b/ConfigEditor/MainForm.cs
new file mode 100644
index 0000000..44fd88d
--- /dev/null
+++ b/ConfigEditor/MainForm.cs
@@ -0,0 +1,30 @@
+using System.IO;
+using System.Windows.Forms;
+
+namespace ConfigEditor
+{
+ public partial class MainForm: Form
+ {
+ public MainForm()
+ {
+ InitializeComponent();
+ }
+
+ private void открытьToolStripMenuItem_Click(object sender, System.EventArgs e)
+ {
+ OpenFileDialog ofd = new OpenFileDialog()
+ {
+ Title = "Выберите файл конфигурации",
+ Filter = "Файл *.json|*.json",
+ Multiselect = false
+ };
+ if (ofd.ShowDialog() == DialogResult.OK)
+ richTextBox1.Text = File.ReadAllText(ofd.FileName);
+ }
+
+ private void закрытьToolStripMenuItem_Click(object sender, System.EventArgs e)
+ {
+ Application.Exit();
+ }
+ }
+}
diff --git a/ConfigEditor/Form1.resx b/ConfigEditor/MainForm.resx
similarity index 100%
rename from ConfigEditor/Form1.resx
rename to ConfigEditor/MainForm.resx
diff --git a/ConfigEditor/Program.cs b/ConfigEditor/Program.cs
index b4c1631..a86e583 100644
--- a/ConfigEditor/Program.cs
+++ b/ConfigEditor/Program.cs
@@ -16,7 +16,7 @@ namespace ConfigEditor
{
Application.EnableVisualStyles();
Application.SetCompatibleTextRenderingDefault(false);
- Application.Run(new Form1());
+ Application.Run(new MainForm());
}
}
}