Регулировка трекбара

Signed-off-by: Lev Rusanov <30170278+JDM170@users.noreply.github.com>
This commit is contained in:
2023-03-12 17:34:26 +07:00
parent 2f0f213781
commit 40ad1eef26
3 changed files with 8 additions and 6 deletions

1
Form1.Designer.cs generated
View File

@@ -155,6 +155,7 @@
this.Controls.Add(this.textBox1);
this.Controls.Add(this.btn_stop);
this.Controls.Add(this.btn_start);
this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
this.Name = "Form1";
this.Text = "Учимся печатать быстро";
this.Load += new System.EventHandler(this.Form1_Load);

View File

@@ -6,7 +6,7 @@ namespace WindowsFormsApp1
{
public partial class Form1 : Form
{
int timerInterval = 2000;
int timerInterval = 500;
int lastSymbol = 0;
int pass_count = 0;
int err_count = 0;
@@ -20,9 +20,13 @@ namespace WindowsFormsApp1
private void Form1_Load(object sender, EventArgs e)
{
this.MinimizeBox = false;
this.MaximizeBox = false;
timer.Tick += new EventHandler(timerCallback);
trackBar1.Maximum = timerInterval;
trackBar1.Minimum = timerInterval - 1000;
trackBar1.Minimum = timerInterval;
//trackBar1.Maximum = timerInterval + 1000;
trackBar1.Maximum = timerInterval + 500;
trackBar1.Value = trackBar1.Maximum;
}
private void timerCallback(object sender, EventArgs e)

View File

@@ -1,7 +1,4 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace WindowsFormsApp1