Focus on mouseover so spacebar may be used for pressing complete
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
7
Tidstagning/Form1.Designer.cs
generated
7
Tidstagning/Form1.Designer.cs
generated
@ -164,8 +164,11 @@
|
||||
//
|
||||
this.grid.AllowUserToAddRows = false;
|
||||
this.grid.AllowUserToDeleteRows = false;
|
||||
this.grid.AllowUserToResizeColumns = false;
|
||||
this.grid.AllowUserToResizeRows = false;
|
||||
this.grid.AutoGenerateColumns = false;
|
||||
this.grid.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
|
||||
this.grid.ClipboardCopyMode = System.Windows.Forms.DataGridViewClipboardCopyMode.Disable;
|
||||
this.grid.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
|
||||
this.grid.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
|
||||
this.Complete,
|
||||
@ -174,7 +177,9 @@
|
||||
this.txtLog.SetColumnSpan(this.grid, 2);
|
||||
this.grid.DataSource = this.entryBindingSource;
|
||||
this.grid.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.grid.EditMode = System.Windows.Forms.DataGridViewEditMode.EditProgrammatically;
|
||||
this.grid.Location = new System.Drawing.Point(273, 3);
|
||||
this.grid.MultiSelect = false;
|
||||
this.grid.Name = "grid";
|
||||
this.grid.ReadOnly = true;
|
||||
this.grid.RowHeadersWidthSizeMode = System.Windows.Forms.DataGridViewRowHeadersWidthSizeMode.AutoSizeToAllHeaders;
|
||||
@ -182,6 +187,7 @@
|
||||
this.grid.RowTemplate.DefaultCellStyle.Font = new System.Drawing.Font("Microsoft Sans Serif", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.grid.RowTemplate.Height = 30;
|
||||
this.grid.RowTemplate.ReadOnly = true;
|
||||
this.grid.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect;
|
||||
this.grid.Size = new System.Drawing.Size(1039, 542);
|
||||
this.grid.TabIndex = 0;
|
||||
this.grid.CellClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.grid_Click);
|
||||
@ -315,6 +321,7 @@
|
||||
this.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink;
|
||||
this.ClientSize = new System.Drawing.Size(1315, 694);
|
||||
this.Controls.Add(this.txtLog);
|
||||
this.DoubleBuffered = true;
|
||||
this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
|
||||
this.Name = "Form1";
|
||||
this.Text = "Tidstagning";
|
||||
|
@ -14,7 +14,6 @@ namespace Tidstagning
|
||||
Relay horn;
|
||||
Procedure startprocedure = new Procedure();
|
||||
|
||||
int OldRow = 0;
|
||||
public Form1()
|
||||
{
|
||||
InitializeComponent();
|
||||
@ -182,20 +181,36 @@ namespace Tidstagning
|
||||
|
||||
private void grid_CellMouseEnter(object sender, DataGridViewCellEventArgs e)
|
||||
{
|
||||
if (e.RowIndex > -1)
|
||||
if (e.RowIndex > -1 )
|
||||
{
|
||||
grid.Rows[e.RowIndex].Selected = true;
|
||||
grid.Rows[e.RowIndex].Height = 60;
|
||||
try
|
||||
{
|
||||
grid.Rows[e.RowIndex].Selected = true;
|
||||
grid.Rows[e.RowIndex].Height = 60;
|
||||
grid.CurrentCell = grid.Rows[e.RowIndex].Cells[e.ColumnIndex];
|
||||
if (btnStop.Enabled)
|
||||
{
|
||||
grid.Focus();
|
||||
}
|
||||
}
|
||||
catch { }
|
||||
}
|
||||
}
|
||||
|
||||
private void grid_CellMouseLeave(object sender, DataGridViewCellEventArgs e)
|
||||
{
|
||||
if (e.RowIndex > -1)
|
||||
if (e.RowIndex > -1 )
|
||||
{
|
||||
grid.Rows[e.RowIndex].Selected = false;
|
||||
grid.Rows[e.RowIndex].Height = 30;
|
||||
try
|
||||
{
|
||||
grid.Rows[e.RowIndex].Selected = false;
|
||||
grid.Rows[e.RowIndex].Height = 30;
|
||||
|
||||
}
|
||||
catch
|
||||
{ }
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user