diff --git a/ItIsOn/MainWindow.xaml.cs b/ItIsOn/MainWindow.xaml.cs index 442c789..b4dbb68 100644 --- a/ItIsOn/MainWindow.xaml.cs +++ b/ItIsOn/MainWindow.xaml.cs @@ -35,7 +35,7 @@ public MainWindow() myNotifyIcon.BalloonTipText = "Click the tray icon to show!"; myNotifyIcon.Text = "It Is ON! App"; myNotifyIcon.Icon = new System.Drawing.Icon("appicon.ico"); - myNotifyIcon.Click += new EventHandler(m_notifyIcon_Click); + myNotifyIcon.Click += new EventHandler(MyNotifyIcon_Click); } private void ScreensaverAndSleep_Click(object sender, RoutedEventArgs e) @@ -88,7 +88,7 @@ private void Window_Closing(object sender, CancelEventArgs e) myNotifyIcon = null; } - void OnStateChanged(object sender, EventArgs args) + private void OnStateChanged(object sender, EventArgs args) { if (WindowState == WindowState.Minimized) { @@ -103,22 +103,22 @@ void OnStateChanged(object sender, EventArgs args) myStoredWindowState = WindowState; } } - void OnIsVisibleChanged(object sender, DependencyPropertyChangedEventArgs args) + private void OnIsVisibleChanged(object sender, DependencyPropertyChangedEventArgs args) { CheckTrayIcon(); } - void m_notifyIcon_Click(object sender, EventArgs e) + private void MyNotifyIcon_Click(object sender, EventArgs e) { Show(); WindowState = myStoredWindowState; } - void CheckTrayIcon() + private void CheckTrayIcon() { ShowTrayIcon(!IsVisible); } - void ShowTrayIcon(bool show) + private void ShowTrayIcon(bool show) { if (myNotifyIcon != null) {