From eb67757b6c46683286b5eacb175f86b9b463ac1d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jan=20Gro=C3=9F?= Date: Fri, 14 May 2021 23:51:17 +0200 Subject: [PATCH] Updated UI layout --- Wallpaperchan/Form1.Designer.cs | 78 ++++++++++++++++++++++++++------- Wallpaperchan/Form1.cs | 4 +- Wallpaperchan/Form1.resx | 2 +- 3 files changed, 66 insertions(+), 18 deletions(-) diff --git a/Wallpaperchan/Form1.Designer.cs b/Wallpaperchan/Form1.Designer.cs index 354e12a..ca7a6de 100644 --- a/Wallpaperchan/Form1.Designer.cs +++ b/Wallpaperchan/Form1.Designer.cs @@ -50,12 +50,17 @@ namespace Wallpaperchan this.btnPause = new System.Windows.Forms.Button(); this.btnToggleGrid = new System.Windows.Forms.Button(); this.label1 = new System.Windows.Forms.Label(); + this.label2 = new System.Windows.Forms.Label(); + this.slideshowGroup = new System.Windows.Forms.GroupBox(); + this.wallpaperGroup = new System.Windows.Forms.GroupBox(); ((System.ComponentModel.ISupportInitialize)(this.delay)).BeginInit(); + this.slideshowGroup.SuspendLayout(); + this.wallpaperGroup.SuspendLayout(); this.SuspendLayout(); // // btnSelectFolder // - this.btnSelectFolder.Location = new System.Drawing.Point(1608, 39); + this.btnSelectFolder.Location = new System.Drawing.Point(993, 93); this.btnSelectFolder.Name = "btnSelectFolder"; this.btnSelectFolder.Size = new System.Drawing.Size(182, 40); this.btnSelectFolder.TabIndex = 0; @@ -65,18 +70,19 @@ namespace Wallpaperchan // // path // - this.path.Location = new System.Drawing.Point(813, 39); + this.path.Location = new System.Drawing.Point(211, 95); this.path.Name = "path"; this.path.Size = new System.Drawing.Size(767, 35); this.path.TabIndex = 1; // // btnApplyWallpaper // - this.btnApplyWallpaper.Location = new System.Drawing.Point(1608, 117); + this.btnApplyWallpaper.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnApplyWallpaper.Location = new System.Drawing.Point(79, 105); this.btnApplyWallpaper.Name = "btnApplyWallpaper"; this.btnApplyWallpaper.Size = new System.Drawing.Size(182, 40); this.btnApplyWallpaper.TabIndex = 3; - this.btnApplyWallpaper.Text = "Apply wallpaper"; + this.btnApplyWallpaper.Text = "Apply selected"; this.btnApplyWallpaper.UseVisualStyleBackColor = true; this.btnApplyWallpaper.Click += new System.EventHandler(this.button2_Click); // @@ -129,7 +135,7 @@ namespace Wallpaperchan // this.status.AutoSize = true; this.status.ForeColor = System.Drawing.SystemColors.ControlLightLight; - this.status.Location = new System.Drawing.Point(1456, 127); + this.status.Location = new System.Drawing.Point(211, 149); this.status.Name = "status"; this.status.Size = new System.Drawing.Size(68, 30); this.status.TabIndex = 5; @@ -143,7 +149,7 @@ namespace Wallpaperchan // // delay // - this.delay.Location = new System.Drawing.Point(1191, 125); + this.delay.Location = new System.Drawing.Point(199, 43); this.delay.Name = "delay"; this.delay.Size = new System.Drawing.Size(87, 35); this.delay.TabIndex = 6; @@ -158,7 +164,7 @@ namespace Wallpaperchan // this.delayLabel.AutoSize = true; this.delayLabel.ForeColor = System.Drawing.SystemColors.ControlLightLight; - this.delayLabel.Location = new System.Drawing.Point(1284, 127); + this.delayLabel.Location = new System.Drawing.Point(49, 45); this.delayLabel.Name = "delayLabel"; this.delayLabel.Size = new System.Drawing.Size(118, 30); this.delayLabel.TabIndex = 7; @@ -166,9 +172,10 @@ namespace Wallpaperchan // // btnPause // - this.btnPause.Location = new System.Drawing.Point(1822, 117); + this.btnPause.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnPause.Location = new System.Drawing.Point(76, 107); this.btnPause.Name = "btnPause"; - this.btnPause.Size = new System.Drawing.Size(131, 40); + this.btnPause.Size = new System.Drawing.Size(182, 40); this.btnPause.TabIndex = 8; this.btnPause.Text = "Pause"; this.btnPause.UseVisualStyleBackColor = true; @@ -176,6 +183,8 @@ namespace Wallpaperchan // // btnToggleGrid // + this.btnToggleGrid.FlatStyle = System.Windows.Forms.FlatStyle.Flat; + this.btnToggleGrid.ForeColor = System.Drawing.SystemColors.ControlLightLight; this.btnToggleGrid.Location = new System.Drawing.Point(39, 193); this.btnToggleGrid.Name = "btnToggleGrid"; this.btnToggleGrid.Size = new System.Drawing.Size(131, 40); @@ -188,27 +197,60 @@ namespace Wallpaperchan // this.label1.AutoSize = true; this.label1.Font = new System.Drawing.Font("Segoe Script", 15.85714F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point); - this.label1.ForeColor = System.Drawing.SystemColors.ButtonShadow; - this.label1.Location = new System.Drawing.Point(54, 59); + this.label1.ForeColor = System.Drawing.SystemColors.ControlLightLight; + this.label1.Location = new System.Drawing.Point(30, 9); this.label1.Name = "label1"; this.label1.Size = new System.Drawing.Size(345, 61); this.label1.TabIndex = 10; this.label1.Text = "Wallpaper-chan"; // + // label2 + // + this.label2.AutoSize = true; + this.label2.ForeColor = System.Drawing.SystemColors.ControlLightLight; + this.label2.Location = new System.Drawing.Point(39, 98); + this.label2.Name = "label2"; + this.label2.Size = new System.Drawing.Size(166, 30); + this.label2.TabIndex = 11; + this.label2.Text = "Wallpaper folder"; + // + // slideshowGroup + // + this.slideshowGroup.Controls.Add(this.delayLabel); + this.slideshowGroup.Controls.Add(this.delay); + this.slideshowGroup.Controls.Add(this.btnPause); + this.slideshowGroup.ForeColor = System.Drawing.SystemColors.ControlLightLight; + this.slideshowGroup.Location = new System.Drawing.Point(1603, 39); + this.slideshowGroup.Name = "slideshowGroup"; + this.slideshowGroup.Size = new System.Drawing.Size(350, 175); + this.slideshowGroup.TabIndex = 12; + this.slideshowGroup.TabStop = false; + this.slideshowGroup.Text = "Slideshow"; + // + // wallpaperGroup + // + this.wallpaperGroup.Controls.Add(this.btnApplyWallpaper); + this.wallpaperGroup.ForeColor = System.Drawing.SystemColors.ControlLightLight; + this.wallpaperGroup.Location = new System.Drawing.Point(1217, 39); + this.wallpaperGroup.Name = "wallpaperGroup"; + this.wallpaperGroup.Size = new System.Drawing.Size(350, 175); + this.wallpaperGroup.TabIndex = 13; + this.wallpaperGroup.TabStop = false; + this.wallpaperGroup.Text = "Wallpaper"; + // // MainForm // this.AutoScaleDimensions = new System.Drawing.SizeF(12F, 30F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; this.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(35)))), ((int)(((byte)(39)))), ((int)(((byte)(42))))); this.ClientSize = new System.Drawing.Size(1999, 1029); + this.Controls.Add(this.wallpaperGroup); + this.Controls.Add(this.slideshowGroup); + this.Controls.Add(this.label2); this.Controls.Add(this.label1); this.Controls.Add(this.btnToggleGrid); - this.Controls.Add(this.btnPause); - this.Controls.Add(this.delayLabel); - this.Controls.Add(this.delay); this.Controls.Add(this.status); this.Controls.Add(this.listView1); - this.Controls.Add(this.btnApplyWallpaper); this.Controls.Add(this.path); this.Controls.Add(this.btnSelectFolder); this.Name = "MainForm"; @@ -216,6 +258,9 @@ namespace Wallpaperchan this.Load += new System.EventHandler(this.MainForm_Load); this.Shown += new System.EventHandler(this.MainForm_Shown); ((System.ComponentModel.ISupportInitialize)(this.delay)).EndInit(); + this.slideshowGroup.ResumeLayout(false); + this.slideshowGroup.PerformLayout(); + this.wallpaperGroup.ResumeLayout(false); this.ResumeLayout(false); this.PerformLayout(); @@ -236,6 +281,9 @@ namespace Wallpaperchan private System.Windows.Forms.Button btnPause; private System.Windows.Forms.Button btnToggleGrid; private System.Windows.Forms.Label label1; + private System.Windows.Forms.Label label2; + private System.Windows.Forms.GroupBox slideshowGroup; + private System.Windows.Forms.GroupBox wallpaperGroup; } } diff --git a/Wallpaperchan/Form1.cs b/Wallpaperchan/Form1.cs index eb967f6..e6f4286 100644 --- a/Wallpaperchan/Form1.cs +++ b/Wallpaperchan/Form1.cs @@ -130,7 +130,7 @@ namespace Wallpaperchan { return; } - this.status.Text = String.Format("Current Image: {0} \nNext image in: {1}", currentImageIndex, remainingSeconds); + this.status.Text = String.Format("Current Image: {0} \nNext wallpaper in: {1} \nLoaded {2} wallpapers", currentImageIndex, remainingSeconds, listView1.Items.Count); this.remainingSeconds--; if (this.remainingSeconds <= 0) { @@ -160,7 +160,7 @@ namespace Wallpaperchan private void MainForm_Load(object sender, EventArgs e) { - + this.listView1.Items.Clear(); } private void MainForm_Shown(object sender, EventArgs e) diff --git a/Wallpaperchan/Form1.resx b/Wallpaperchan/Form1.resx index 6a2d0d2..871eb64 100644 --- a/Wallpaperchan/Form1.resx +++ b/Wallpaperchan/Form1.resx @@ -62,7 +62,7 @@ AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj01LjAuNS4w LCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2VuPWI3N2E1YzU2MTkzNGUwODkFAQAAACZTeXN0 ZW0uV2luZG93cy5Gb3Jtcy5JbWFnZUxpc3RTdHJlYW1lcgEAAAAERGF0YQcCAgAAAAkDAAAADwMAAAAI - phcAAk1TRnQBSQFMAgEBBQEAASABAAEgAQABMAEBAasBAAT/ARkBAAj/AUIBTQE2BwABNgMAASgDAAHA + phcAAk1TRnQBSQFMAgEBBQEAAUABAAFAAQABMAEBAasBAAT/ARkBAAj/AUIBTQE2BwABNgMAASgDAAHA AQQCAAFWAQECAAEBAQABGAUAAYABCQETEQABIgE/AU0BGwEwAT0BGQErATUBGAEnAS8BGwEtATABHQEy AS8BGwExAS8BGgEuATEBGQEwATcBIgFBAUwBGAEvATkBFgEmAS8BFwEkAS0BGwEjASsBGAEeASYBGAEg ASkBGwElATABIwE0AT4BJAE2AUABKgFBAUwBMQFXAWcBQQGGAZcBQQF9AYgBRgF/AZMBWQGlAccBQwF1