From d2d6d2fe110852e46ee2bbd0cebb04ecc8b04c48 Mon Sep 17 00:00:00 2001 From: goyuken Date: Mon, 26 May 2014 04:50:30 +0000 Subject: [PATCH] make errors clearer on drag and drop --- BizHawk.Client.EmuHawk/MainForm.Events.cs | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/BizHawk.Client.EmuHawk/MainForm.Events.cs b/BizHawk.Client.EmuHawk/MainForm.Events.cs index 80e7a333cf..c7a48337b3 100644 --- a/BizHawk.Client.EmuHawk/MainForm.Events.cs +++ b/BizHawk.Client.EmuHawk/MainForm.Events.cs @@ -2121,6 +2121,18 @@ namespace BizHawk.Client.EmuHawk private void FormDragDrop(object sender, DragEventArgs e) { + try + { + FormDragDrop_internal(sender, e); + } + catch (Exception ex) + { + MessageBox.Show("Exception on drag and drop:\n" + ex.ToString()); + } + } + + private void FormDragDrop_internal(object sender, DragEventArgs e) + { var filePaths = (string[])e.Data.GetData(DataFormats.FileDrop); var isLua = false; foreach (var path in filePaths)