Fix updates not showing 'check failed' when no internect connection.

This commit is contained in:
UnknownShadow200 2016-05-09 16:33:54 +10:00
parent cc57a1960a
commit 319d40fe37
2 changed files with 9 additions and 3 deletions

View File

@ -50,11 +50,17 @@ namespace Launcher {
}
Build dev, stable;
public override void Tick() {
if( checkTask.Done ) return;
public override void Tick() {;
if( checkTask.Done && checkTask.Exception == null ) return;
if( !checkTask.TaskTick( SuccessfulUpdateCheck, this ) ) {
view.LastStable = DateTime.MaxValue;
view.LastDev = DateTime.MaxValue;
checkTask.Exception = null;
LauncherWidget w = widgets[view.devIndex - 1];
game.ClearArea( w.X, w.Y, w.Width, w.Height );
w = widgets[view.relIndex - 1];
game.ClearArea( w.X, w.Y, w.Width, w.Height );
Resize();
}
}

View File

@ -70,7 +70,7 @@ namespace Launcher {
}
string GetDateString( DateTime last ) {
if( last == DateTime.MaxValue ) return "Update check failed";
if( last == DateTime.MaxValue ) return "&cCheck failed";
if( last == DateTime.MinValue ) return "Checking..";
return last.ToString( dateFormat );
}