Esempio n. 1
0
        private void OnOptionReportClicked(object sender, RoutedEventArgs e)
        {
            if (collectInfoManager == null)
                throw new InvalidOperationException("CollectInfoManager is not initialized (D8BF3BF5D96B)");

            if (collectInfoManager.GetCollectInfoOption())
            {
                ReportIssueFeedback reportIssueWindow = new ReportIssueFeedback();
                if (null != Application.Current)
                    reportIssueWindow.Owner = Application.Current.MainWindow;
                reportIssueWindow.Closing += OnReportIssueWindowClosing;
                reportIssueWindow.Show();
            }
            else
            {
                new PopupDialog(ResourceNames.Warning, UiStrings.ReportIssueDisabled, string.Empty, string.Empty, "Ok");
            }
        }
        private void OnReportButtonClick(object sender, RoutedEventArgs e)
        {
            ITextEditorSettings settings = textCore.TextEditorSettings;
            if (settings.CollectFeedback == false)
            {
                ReportIssueFeedbackDialog reportIssueFeedback = new ReportIssueFeedbackDialog();
                if (null != Application.Current)
                    reportIssueFeedback.Owner = Application.Current.MainWindow;
                reportIssueFeedback.ShowDialog();
                return;
            }

            ReportIssueFeedback reportIssueWindow = new ReportIssueFeedback();
            if (null != Application.Current)
                reportIssueWindow.Owner = Application.Current.MainWindow;
            reportIssueWindow.Closing += OnReportIssueWindowClosing;
            reportIssueWindow.Show();
        }