コード例 #1
0
 public ClockForm()
 {
     InitializeComponent();
     StartClockThread();
     originalHeight = Size.Height;
     ToggleHeight();
     ClockToolTip.SetToolTip(SyncButton, "Click this button to immediately synchronize your system clock with the NIST atomic clock.");
     ClockToolTip.SetToolTip(SyncStatusLabel, "Displays time of most recent sync, and how much your clock was adjusted.");
     ClockToolTip.SetToolTip(MyWebSiteLink, myWebSite.AbsoluteUri);
 }
コード例 #2
0
 private void ToggleHeight()
 {
     if (Size.Height == originalHeight)
     {
         Size = new Size(Size.Width, Size.Height - extraHeight);
         ClockToolTip.SetToolTip(TogglerLink, "Click here to show options and more information.");
     }
     else
     {
         Size = new Size(Size.Width, Size.Height + extraHeight);
         ClockToolTip.SetToolTip(TogglerLink, "Click here to show smaller clock display.");
     }
 }