feat: persist piano roll zoom level into project; fixed an issue in the horizontal auto-scrolling logic in piano roll window

This commit is contained in:
Xiaohan-Tian
2026-05-18 22:21:00 -07:00
parent 97dad696b2
commit a0fe283ab5
15 changed files with 321 additions and 22 deletions
+9
View File
@@ -15,6 +15,7 @@ export class KGPianoRollState {
private currentMode: string = "ionian"; // Default mode
private automationViewEnabled: boolean = false;
private currentAutomationType: string = "pitch-bend";
private pianoRollZoom: number = 1;
private sheetMusicViewEnabled: boolean = false;
private sheetMusicTrackScopeEnabled: boolean = false;
private sheetQuantization: string = '16,48';
@@ -86,6 +87,14 @@ export class KGPianoRollState {
this.currentAutomationType = type;
}
public getPianoRollZoom(): number {
return this.pianoRollZoom;
}
public setPianoRollZoom(zoom: number): void {
this.pianoRollZoom = zoom;
}
public getSheetMusicViewEnabled(): boolean {
return this.sheetMusicViewEnabled;
}