Skip to content

Commit

Permalink
Merge pull request #787 from oxygen-dioxide/editing-macro
Browse files Browse the repository at this point in the history
Show a dialog when editing macros throw an error
  • Loading branch information
stakira authored Jul 28, 2023
2 parents 6f2ea1f + 906e835 commit db972e4
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion OpenUtau/ViewModels/PianoRollViewModel.cs
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,11 @@ public PianoRollViewModel() {

noteBatchEditCommand = ReactiveCommand.Create<BatchEdit>(edit => {
if (NotesViewModel.Part != null) {
edit.Run(NotesViewModel.Project, NotesViewModel.Part, NotesViewModel.Selection.ToList(), DocManager.Inst);
try{
edit.Run(NotesViewModel.Project, NotesViewModel.Part, NotesViewModel.Selection.ToList(), DocManager.Inst);
}catch(System.Exception e){
DocManager.Inst.ExecuteCmd(new ErrorMessageNotification("Failed to run editing macro",e));
}
}
});
NoteBatchEdits.AddRange(new List<BatchEdit>() {
Expand Down

0 comments on commit db972e4

Please sign in to comment.