TASTudio - another fix for the designer regarding the PlaybackBox, support column click toggling boolean buttons for the selected rows
This commit is contained in:
parent
288e0351b6
commit
77cae08afa
|
@ -17,6 +17,7 @@ namespace BizHawk.Client.EmuHawk
|
|||
|
||||
public TAStudio Tastudio { get; set; }
|
||||
|
||||
[DesignerSerializationVisibilityAttribute(DesignerSerializationVisibility.Hidden)]
|
||||
public bool TurboSeek
|
||||
{
|
||||
get
|
||||
|
|
|
@ -694,6 +694,7 @@ namespace BizHawk.Client.EmuHawk
|
|||
this.TasView.UseCompatibleStateImageBehavior = false;
|
||||
this.TasView.View = System.Windows.Forms.View.Details;
|
||||
this.TasView.RightMouseScrolled += new BizHawk.Client.EmuHawk.TasListView.RightMouseScrollEventHandler(this.TasView_MouseWheel);
|
||||
this.TasView.ColumnClick += new System.Windows.Forms.ColumnClickEventHandler(this.TasView_ColumnClick);
|
||||
this.TasView.SelectedIndexChanged += new System.EventHandler(this.TasView_SelectedIndexChanged);
|
||||
this.TasView.KeyDown += new System.Windows.Forms.KeyEventHandler(this.TasView_KeyDown);
|
||||
this.TasView.MouseDoubleClick += new System.Windows.Forms.MouseEventHandler(this.TasView_MouseDoubleClick);
|
||||
|
|
|
@ -1,8 +1,10 @@
|
|||
using System;
|
||||
using System.Drawing;
|
||||
using System.Linq;
|
||||
using System.Windows.Forms;
|
||||
|
||||
using BizHawk.Client.Common;
|
||||
using BizHawk.Client.EmuHawk.WinFormExtensions;
|
||||
|
||||
namespace BizHawk.Client.EmuHawk
|
||||
{
|
||||
|
@ -156,6 +158,28 @@ namespace BizHawk.Client.EmuHawk
|
|||
|
||||
#region Events
|
||||
|
||||
private void TasView_ColumnClick(object sender, ColumnClickEventArgs e)
|
||||
{
|
||||
if (TasView.SelectedIndices().Any())
|
||||
{
|
||||
var columnName = TasView.Columns[e.Column].Name;
|
||||
|
||||
if (columnName == FrameColumnName)
|
||||
{
|
||||
// TODO: add marker to LastSelectedIndex
|
||||
}
|
||||
else if (columnName != MarkerColumnName) // TODO: what about float?
|
||||
{
|
||||
foreach (var index in TasView.SelectedIndices())
|
||||
{
|
||||
ToggleBoolState(index, columnName);
|
||||
}
|
||||
|
||||
RefreshDialog();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void TasView_MouseDown(object sender, MouseEventArgs e)
|
||||
{
|
||||
if (e.Button == MouseButtons.Middle)
|
||||
|
|
Loading…
Reference in New Issue