public void ShowWarning(string msg) { Dispatcher.BeginInvoke(new Action(delegate { FlashScreen(-1); var prompt = new CameraControl.Plugins.windows.DialogPrompt(msg); prompt.ShowDialog(); FlashScreenStop(); })); }
private void on_txt_Barcode_KeyUp(object sender, System.Windows.Input.KeyEventArgs e) { if (ServiceProvider.DeviceManager.SelectedCameraDevice != null && ServiceProvider.DeviceManager.SelectedCameraDevice.IsBusy) { Dispatcher.BeginInvoke(new Action(delegate { var prompt = new CameraControl.Plugins.windows.DialogPrompt("Should not clear barcode: transfers still pending."); prompt.ShowDialog(); })); return; } Barcode = txt_Barcode.Text; // Expedite update BarcodeUsed = false; CheckBarcode(); }