Skip to content

Commit

Permalink
修复在倒数日开始零点几天时显示数值异常的问题
Browse files Browse the repository at this point in the history
  • Loading branch information
STBBRD committed Apr 2, 2024
1 parent bda122b commit d0e7295
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion ZongziTEK_Blackboard_Sticker/Pages/CountdownPage.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ private void Timer_Tick(object sender, EventArgs e)
TimeSpan timeSpan = MainWindow.Settings.InfoBoard.CountdownDate - DateTime.Now;
string countdownName = MainWindow.Settings.InfoBoard.CountdownName;
if (MainWindow.Settings.InfoBoard.CountdownName.Length == 0) countdownName = "倒数日";
if (timeSpan.Days < 0)
if (timeSpan.TotalDays < 0)
{
LabelDays.Foreground = new SolidColorBrush(Color.FromArgb(255, 0, 204, 0));
LabelName.Content = countdownName + "已开始";
Expand Down

0 comments on commit d0e7295

Please sign in to comment.