Add ManualWeighingDialog

This commit is contained in:
2023-08-01 16:34:22 +02:00
parent 704337aa1d
commit 75dfdb155b
6 changed files with 127 additions and 3 deletions

View File

@ -7,6 +7,7 @@ using System.Diagnostics;
using System.Text.RegularExpressions;
using System.IO.Ports;
using System.Net.Sockets;
using Elwig.Dialogs;
namespace Elwig.Helpers {
public static partial class Utils {
@ -134,5 +135,10 @@ namespace Elwig.Helpers {
}
return i;
}
public static (int, string?)? ShowManualWeighingDialog() {
var d = new ManualWeighingDialog();
return d.ShowDialog() == true ? (d.Weight, d.Reason) : null;
}
}
}