Esempio n. 1
0
        private void OnSnoopAttachFailed(object sender, AttachFailedEventArgs e)
        {
            ErrorDialog.ShowDialog(e.AttachException, "Can't Snoop the process", $"Failed to attach to '{e.WindowName}'.", exceptionAlreadyHandled: true);

            // TODO This should be implemented through the event broker, not like this.
            this.appChooser?.Refresh();
        }
Esempio n. 2
0
 void OnSnoopAttachFailed(object sender, AttachFailedEventArgs e)
 {
     MessageBox.Show
     (
         string.Format
         (
             "Failed to attach to {0}. Exception occured:{1}{2}",
             e.WindowName,
             Environment.NewLine,
             e.AttachException
         ),
         "Can't Snoop the process!"
     );
     if (_appChooser != null)
     {
         // TODO This should be implmemented through the event broker, not like this.
     }
 }
Esempio n. 3
0
 private void OnSnoopAttachFailed(object sender, AttachFailedEventArgs e)
 {
     System.Windows.MessageBox.Show
     (
         string.Format
         (
             "Failed to attach to {0}. Exception occured:{1}{2}",
             e.WindowName,
             Environment.NewLine,
             e.AttachException.ToString()
         ),
         "Can't Snoop the process!"
     );
     if (_appChooser != null)
     {
         // TODO This should be implmemented through the event broker, not like this.
         _appChooser.Refresh();
     }
 }
Esempio n. 4
0
 /// <summary>
 /// <see cref="WindowInfo.AttachFailed"/>事件处理函数
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 private void OnSnoopAttachFailed(object sender, AttachFailedEventArgs e)
 {
     System.Windows.MessageBox.Show($"Failed to attach to {e.WindowName}. Exception occured:{Environment.NewLine}{e.AttachException.ToString()}", "Can't Snoop the process!");
     // TODO This should be implmemented through the event broker, not like this.
     _appChooser?.Refresh();
 }