Revision 79f92570 trunk/Pithos.Client.WPF/App.xaml.cs

b/trunk/Pithos.Client.WPF/App.xaml.cs
41 41
#endregion
42 42
using System;
43 43
using System.Collections.Generic;
44
using System.Drawing;
45 44
using System.IO;
46 45
using System.Linq;
47 46
using System.Reflection;
......
49 48
using System.Threading;
50 49
using System.Threading.Tasks;
51 50
using System.Windows;
52
using System.Windows.Media;
53
using System.Windows.Media.Imaging;
54
using AppLimit.NetSparkle;
55 51
using Caliburn.Micro;
56 52
using Pithos.Client.WPF.Properties;
57 53
using log4net.Appender;
......
67 63
    {
68 64
        private static readonly log4net.ILog Log = log4net.LogManager.GetLogger( MethodBase.GetCurrentMethod().DeclaringType );
69 65

  
70
        private Sparkle _sparkle;
71 66

  
72 67

  
73 68
        public App()
......
80 75
            AppDomain.CurrentDomain.UnhandledException += OnUnhandledException;
81 76
            TaskScheduler.UnobservedTaskException += OnUnobservedException;
82 77

  
83
            _sparkle = new Sparkle(Settings.Default.UpdateUrl);
84
            _sparkle.updateDetected += OnUpdateDetected;
85
            _sparkle.ShowDiagnosticWindow = true;
78
            //_sparkle = new Sparkle(Settings.Default.UpdateUrl);
79
            //_sparkle.updateDetected += OnUpdateDetected;
80
            //_sparkle.ShowDiagnosticWindow = true;
86 81
            
87
//            _sparkle.ApplicationIcon=Image.
88
            _sparkle.StartLoop(true,true);
82
            //Must delay opening the upgrade window
83
            //to avoid Windows Messages sent by the TaskbarIcon
84
            //TaskEx.Delay(5000).ContinueWith(_=>_sparkle.StartLoop(true,true),TaskScheduler.FromCurrentSynchronizationContext());
89 85

  
90 86
            //Fix incorrect proxy settings by switching to default proxy, if the proxy server settings is empty
91 87
            if (Settings.Default.UseManualProxy && String.IsNullOrWhiteSpace(Settings.Default.ProxyServer))
......
97 93
            InitializeComponent();            
98 94
        }
99 95

  
96
/*
100 97
        private void OnUpdateDetected(object sender, UpdateDetectedEventArgs e)
101 98
        {
102 99
            Log.InfoFormat("Update Detected {0}",e.LatestVersion.Version);    
103 100
        }
101
*/
104 102

  
105 103
        private static void InitializeLogging()
106 104
        {

Also available in: Unified diff