예제 #1
0
    public void ShowError(string title, string description, bool exitable, float duration)
    {
        ErrorModal m = (Instantiate(errorModal)).GetComponent <ErrorModal>();

        m.Init();
        m.ShowModal(title, description, exitable, duration);
    }
예제 #2
0
 private static void CurrentDomain_UnhandledException(object sender, UnhandledExceptionEventArgs e)
 {
     try
     {
         Logger logger = new Logger();
         Exception ex = (Exception)e.ExceptionObject;
         logger.Error("Unhandled exception occured in application. " + ex.Message, ex);
         Console.WriteLine("MyHandler caught : " + ex.Message);
         Console.WriteLine("Runtime terminating: {0}", e.IsTerminating);
         ErrorModal form = new ErrorModal(ex.Message);
         form.ShowDialog();
     }
     catch (Exception)
     {
     }
 }