Modified Exit code to call App Shutdown in every case
authorPanagiotis Kanavos <pkanavos@gmail.com>
Mon, 23 Apr 2012 18:27:18 +0000 (21:27 +0300)
committerPanagiotis Kanavos <pkanavos@gmail.com>
Mon, 23 Apr 2012 18:27:18 +0000 (21:27 +0300)
trunk/Pithos.Client.WPF/Shell/ShellViewModel.cs

index d9109be..d7f06e1 100644 (file)
@@ -668,12 +668,13 @@ namespace Pithos.Client.WPF {
                 var view = GetView() as Window;
                 if (view != null)
                     view.Close();
-                else
-                    Application.Current.Shutdown();
             }
             catch (Exception exc)
             {
-                Log.Info("Exception while exiting", exc);
+                Log.Info("Exception while exiting", exc);                
+            }
+            finally
+            {
                 Application.Current.Shutdown();
             }
         }