new fix for switching beats
This commit is contained in:
@@ -29,10 +29,8 @@ export default class TrackView extends Rung implements ISubscriber<EventTypeSubs
|
||||
|
||||
constructor(options: TrackUINodeOptions) {
|
||||
super(options);
|
||||
this.title = <h3></h3> as HTMLHeadingElement;
|
||||
this.setTrack(options.track);
|
||||
this.title = <h3
|
||||
innerText={this.track.getName()}>
|
||||
</h3> as HTMLHeadingElement;
|
||||
}
|
||||
|
||||
getTitleNode(): HTMLHeadingElement {
|
||||
@@ -43,6 +41,7 @@ export default class TrackView extends Rung implements ISubscriber<EventTypeSubs
|
||||
if (track) {
|
||||
this.track = track;
|
||||
this.sub?.unbind();
|
||||
this.title.innerText = this.track.getName();
|
||||
this.sub = this.track.addSubscriber(this, EventTypeSubscriptions);
|
||||
this.redraw();
|
||||
} else {
|
||||
@@ -164,4 +163,4 @@ export default class TrackView extends Rung implements ISubscriber<EventTypeSubs
|
||||
window.addEventListener("mouseup", () => {
|
||||
TrackView.selectingUnits = false;
|
||||
TrackView.deselectingUnits = false;
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user