diff --git a/BizHawk.Client.EmuHawk/tools/TAStudio/BookmarksBranchesBox.cs b/BizHawk.Client.EmuHawk/tools/TAStudio/BookmarksBranchesBox.cs index ab632c6731..884859aa53 100644 --- a/BizHawk.Client.EmuHawk/tools/TAStudio/BookmarksBranchesBox.cs +++ b/BizHawk.Client.EmuHawk/tools/TAStudio/BookmarksBranchesBox.cs @@ -45,7 +45,14 @@ namespace BizHawk.Client.EmuHawk public BookmarksBranchesBox() { InitializeComponent(); + SetupColumns(); + BranchView.QueryItemText += QueryItemText; + BranchView.QueryItemBkColor += QueryItemBkColor; + } + private void SetupColumns() + { + BranchView.AllColumns.Clear(); BranchView.AllColumns.AddRange(new[] { new RollColumn @@ -67,9 +74,6 @@ namespace BizHawk.Client.EmuHawk Width = 90 }, }); - - BranchView.QueryItemText += QueryItemText; - BranchView.QueryItemBkColor += QueryItemBkColor; } #region Query callbacks @@ -515,8 +519,13 @@ namespace BizHawk.Client.EmuHawk public void Restart() { - BranchView.DeselectAll(); BranchView.RowCount = Movie.Branches.Count; + + if (BranchView.RowCount == 0) + { + SetupColumns(); + } + BranchView.Refresh(); } diff --git a/BizHawk.Client.EmuHawk/tools/TAStudio/MarkerControl.cs b/BizHawk.Client.EmuHawk/tools/TAStudio/MarkerControl.cs index ed8273fdc9..7142a2bec8 100644 --- a/BizHawk.Client.EmuHawk/tools/TAStudio/MarkerControl.cs +++ b/BizHawk.Client.EmuHawk/tools/TAStudio/MarkerControl.cs @@ -18,7 +18,14 @@ namespace BizHawk.Client.EmuHawk public MarkerControl() { InitializeComponent(); + SetupColumns(); + MarkerView.QueryItemBkColor += MarkerView_QueryItemBkColor; + MarkerView.QueryItemText += MarkerView_QueryItemText; + } + private void SetupColumns() + { + MarkerView.AllColumns.Clear(); MarkerView.AllColumns.AddRange(new[] { new RollColumn @@ -34,9 +41,6 @@ namespace BizHawk.Client.EmuHawk Width = 125 } }); - - MarkerView.QueryItemBkColor += MarkerView_QueryItemBkColor; - MarkerView.QueryItemText += MarkerView_QueryItemText; } public InputRoll MarkerInputRoll => MarkerView; @@ -255,7 +259,8 @@ namespace BizHawk.Client.EmuHawk public void Restart() { - MarkerView.DeselectAll(); + SetupColumns(); + MarkerView.RowCount = Markers.Count; MarkerView.Refresh(); }