Пример #1
0
 private static void OnIconChanged(DependencyObject target, DependencyPropertyChangedEventArgs e)
 {
     if (!DesignerProperties.GetIsInDesignMode(target))
     {
         TrayIcon control = (TrayIcon)target;
         control._trayIcon.Icon = FromImageSource(control.Icon);
     }
 }
Пример #2
0
        private static void OnVisibilityChanged(DependencyObject target, DependencyPropertyChangedEventArgs e)
        {
            TrayIcon control = (TrayIcon)target;

            control._trayIcon.Visible = control.Visibility == Visibility.Visible;
        }
Пример #3
0
        private static void OnTextChanged(DependencyObject target, DependencyPropertyChangedEventArgs e)
        {
            TrayIcon control = (TrayIcon)target;

            control._trayIcon.Text = control.Text;
        }