Example #1
0
 private VersionChecker CreateVersionChecker(ICoolConfiguration coolConfiguration)
 {
     return new VersionChecker
     {
         MinCheckTime = TimeSpan.FromSeconds(1),
         CurrentVersion = Version.Parse(textBoxAzzulVersion.Text),
         AppInfoProvider = new HttpAppVersionInfoProvider
         {
             Url = GetRepositoryUrl(coolConfiguration),
             AppName = "Azzul"
         }
     };
 }
Example #2
0
 private static string GetRepositoryUrl(ICoolConfiguration coolConfiguration)
 {
     bool existsCustomUrl = coolConfiguration.CoolConfig != null && !string.IsNullOrEmpty(coolConfiguration.CoolConfig.Update.Url);
     return existsCustomUrl ? coolConfiguration.CoolConfig.Update.Url : DefaultCheckUrl;
 }
Example #3
0
 public VersioningOptions(ICoolConfiguration coolConfiguration)
 {
     if (coolConfiguration == null) throw new ArgumentNullException("coolConfiguration");
     this.coolConfiguration = coolConfiguration;
 }