Skip to content

Commit

Permalink
Fixed behaviour for non-blocking message boxes
Browse files Browse the repository at this point in the history
  • Loading branch information
chrishamm committed Dec 24, 2022
1 parent 331b3b8 commit 8b9c4ef
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/components/dialogs/MessageBoxDialog.vue
Expand Up @@ -168,7 +168,7 @@ export default Vue.extend({
showSign: (value: number): string => (value > 0) ? `+${value}` : value.toString(),
async ok() {
this.shown = false;
if (this.messageBox.mode === MessageBoxMode.okOnly || this.messageBox.mode === MessageBoxMode.okCancel) {
if ([MessageBoxMode.closeOnly, MessageBoxMode.okCancel, MessageBoxMode.okCancel].includes(this.messageBox.mode)) {
await store.dispatch("machine/sendCode", `M292 S${this.messageBox.seq}`);
} else if (this.messageBox.mode === MessageBoxMode.intInput || this.messageBox.mode === MessageBoxMode.floatInput) {
await store.dispatch("machine/sendCode", `M292 R{${this.numberInput}} S${this.messageBox.seq}`);
Expand Down

0 comments on commit 8b9c4ef

Please sign in to comment.