Ejemplo n.º 1
0
        static void CurrentDomain_UnhandledException(object sender, UnhandledExceptionEventArgs args)
        {
            Exception e = (Exception)args.ExceptionObject;

            SingleInstance <App> .Cleanup();

            Current.Dispatcher.Invoke(new Action(() =>
            {
                var box = new ErrorWindow(e);
                box.ShowDialog();
            }));
        }
Ejemplo n.º 2
0
        static void CurrentDomain_UnhandledException(object sender, UnhandledExceptionEventArgs args)
        {
            MessageBox.Show("WiitarThing is about to crash. Press OK to show the crash message.", "Sorry", MessageBoxButton.OK, MessageBoxImage.Error);

            Exception e = (Exception)args.ExceptionObject;

            SingleInstance <App> .Cleanup();

            Current.Dispatcher.Invoke(new Action(() =>
            {
                var box = new ErrorWindow(e);
                box.ShowDialog();
            }));
        }
Ejemplo n.º 3
0
        static void CurrentDomain_UnhandledException(object sender, UnhandledExceptionEventArgs args)
        {
            Exception e = (Exception)args.ExceptionObject;

            // Ignore this native code exception.
            // Can't handle it, and it doesn't seem to have any negative effects.
            if (e.StackTrace.Contains(NATIVE_OVERLAPPED))
            {
                return;
            }

            SingleInstance <App> .Cleanup();

            Current.Dispatcher.Invoke(new Action(() =>
            {
                var box = new ErrorWindow(e);
                box.ShowDialog();
            }));
        }
Ejemplo n.º 4
0
        static void CurrentDomain_UnhandledException(object sender, UnhandledExceptionEventArgs args)
        {
            //MessageBox.Show("WiitarThing is about to crash. Press OK to show the crash message.", "Sorry", MessageBoxButton.OK, MessageBoxImage.Error);

            Exception e = (Exception)args.ExceptionObject;

            WiitarDebug.Log($"ERROR:\n----------------------------------------\n{e.ToString()}\n----------------------------------------", WiitarDebug.LogLevel.Error);

            var box = new ErrorWindow(e);

            box.ShowDialog();

            SingleInstance <App> .Cleanup();

            //Current.Dispatcher.Invoke(new Action(() =>
            //{
            //    var box = new ErrorWindow(e);
            //    box.ShowDialog();
            //}));
        }