MuseScore  3.4
Music composition and notation
recorderwidget.h
Go to the documentation of this file.
1 //=============================================================================
2 // MuseScore
3 // Music Composition & Notation
4 //
5 // Copyright (C) 2018 Werner Schweer
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 // as published by the Free Software Foundation and appearing in
10 // the file LICENCE.GPL
11 //=============================================================================
12 
13 #ifndef __SCRIPT_RECORDER_WIDGET_H__
14 #define __SCRIPT_RECORDER_WIDGET_H__
15 
16 #include "script.h"
17 
18 namespace Ui {
19  class ScriptRecorderWidget;
20  }
21 
22 namespace Ms {
23 
24 class MuseScore;
25 
26 //---------------------------------------------------------
27 // ScriptRecorderWidget
28 //---------------------------------------------------------
29 
30 class ScriptRecorderWidget : public QDockWidget {
31  Q_OBJECT
32 
33  private:
34  Ui::ScriptRecorderWidget* _ui;
37  QString _scriptDir;
38 
39  const QString& scriptDir() const { return _scriptDir; }
40  QString scriptFileName() const;
41  void updateDirLabel();
42  void updateActions();
43 
44  private slots:
45  void on_changeFolderButton_clicked();
46  void on_scriptNameEdit_textEdited();
47  void on_recordButton_clicked();
48  void on_replayButton_clicked();
49 
50  protected:
51  void changeEvent(QEvent* e) override;
52 
53  public:
54  explicit ScriptRecorderWidget(MuseScore* mscore, QWidget* parent = nullptr);
55  ScriptRecorderWidget(const ScriptRecorder&) = delete;
56  ScriptRecorderWidget& operator=(const ScriptRecorderWidget&) = delete;
58 
59  ScriptRecorder& scriptRecorder() { return _recorder; }
60  const ScriptRecorder& scriptRecorder() const { return _recorder; }
61  };
62 
63 } // namespace Ms
64 #endif
Definition: recorderwidget.h:30
MuseScore * _mscore
Definition: recorderwidget.h:35
Definition: musescore.h:180
Definition: crashreporter.h:27
Ui::ScriptRecorderWidget * _ui
Definition: recorderwidget.h:34
Definition: script.h:88
Definition: aeolus.cpp:26
QString _scriptDir
Definition: recorderwidget.h:37
const ScriptRecorder & scriptRecorder() const
Definition: recorderwidget.h:60
ScriptRecorder & scriptRecorder()
Definition: recorderwidget.h:59
ScriptRecorder _recorder
Definition: recorderwidget.h:36
MScore * mscore
Definition: musescore.cpp:171
const QString & scriptDir() const
Definition: recorderwidget.h:39