MuseScore  3.4
Music composition and notation
crashreporter.h
Go to the documentation of this file.
1 //=============================================================================
2 // MuseScore
3 // Music Composition & Notation
4 //
5 // Copyright (C) 2019 Werner Schweer and others
6 //
7 // This program is free software; you can redistribute it and/or modify
8 // it under the terms of the GNU General Public License version 2.
9 //
10 // This program is distributed in the hope that it will be useful,
11 // but WITHOUT ANY WARRANTY; without even the implied warranty of
12 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 // GNU General Public License for more details.
14 //
15 // You should have received a copy of the GNU General Public License
16 // along with this program; if not, write to the Free Software
17 // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
18 //=============================================================================
19 
20 #ifndef __CRASHREPORTER_H__
21 #define __CRASHREPORTER_H__
22 
23 #include <QNetworkAccessManager>
24 #include <QWidget>
25 #include <QUrl>
26 
27 namespace Ui {
28  class CrashReporter;
29  }
30 
31 namespace Ms {
32 
33 //---------------------------------------------------------
34 // CrashReporter
35 //---------------------------------------------------------
36 
37 class CrashReporter : public QWidget {
38  Q_OBJECT
39 
40  Ui::CrashReporter* _ui;
41  QString _miniDump;
42  QUrl _uploadUrl;
43  QNetworkAccessManager* _networkManager = nullptr;
44 
45  void uploadReport();
46 
47  private slots:
48  void on_sendReportButton_clicked();
49  void on_cancelButton_clicked();
50  void onUploadFinished(QNetworkReply*);
51 
52  public:
53  CrashReporter(const QString& miniDumpFile, const QUrl& uploadUrl);
54  CrashReporter(const CrashReporter&) = delete;
55  CrashReporter& operator=(const CrashReporter&) = delete;
56  ~CrashReporter();
57  };
58 
59 } // namespace Ms
60 
61 #endif
Definition: crashreporter.h:27
QUrl _uploadUrl
Definition: crashreporter.h:42
Ui::CrashReporter * _ui
Definition: crashreporter.h:40
Definition: aeolus.cpp:26
QString _miniDump
Definition: crashreporter.h:41
Definition: crashreporter.h:37