diff --git a/libsound/src/capturedevicecontroller.h b/libsound/src/capturedevicecontroller.h index ba70662..e2fb639 100644 --- a/libsound/src/capturedevicecontroller.h +++ b/libsound/src/capturedevicecontroller.h @@ -1,86 +1,85 @@ /* * Copyright 2013 Andreas Cord-Landwehr * * This library is free software; you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published * by the Free Software Foundation; either version 2.1 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public License * along with this program. If not, see . */ #ifndef CAPTUREDEVICECONTROLLER_H #define CAPTUREDEVICECONTROLLER_H #include "libsound_export.h" #include class CaptureDeviceControllerPrivate; -class QUrl; /** * \class CaptureDeviceController * * This singleton class provides a controller for the sound capture device. */ class LIBSOUND_EXPORT CaptureDeviceController : public QObject { Q_OBJECT public: enum State { StoppedState, RecordingState, PausedState }; /** * Returns self reference to the controller. First call of this method initializes * capture device controller. * * \return self reference */ static CaptureDeviceController & self(); void startCapture(const QString &filePath); CaptureDeviceController::State state() const; void stopCapture(); void setDevice(const QString &deviceIdentifier); /** * \return list of available capture devices */ QList devices() const; public Q_SLOTS: Q_SIGNALS: void captureStarted(); void captureStopped(); private: Q_DISABLE_COPY(CaptureDeviceController) /** * \internal * Private constructor, \ref self(). */ CaptureDeviceController(); /** * Private destructor. */ ~CaptureDeviceController(); const QScopedPointer d; }; #endif diff --git a/libsound/src/qtmultimediabackend/qtmultimediacapturebackend.h b/libsound/src/qtmultimediabackend/qtmultimediacapturebackend.h index f8130c8..2c1394e 100644 --- a/libsound/src/qtmultimediabackend/qtmultimediacapturebackend.h +++ b/libsound/src/qtmultimediabackend/qtmultimediacapturebackend.h @@ -1,53 +1,51 @@ /* * Copyright 2016 Andreas Cord-Landwehr * * This library is free software; you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published * by the Free Software Foundation; either version 2.1 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public License * along with this program. If not, see . */ #ifndef QTMULTIMEDIACAPTUREBACKEND_H #define QTMULTIMEDIACAPTUREBACKEND_H #include "capturedevicecontroller.h" #include "capturebackendinterface.h" #include #include class QAudioRecorder; -class QMediaRecorder; -class QMediaObject; class QtMultimediaCaptureBackend : public CaptureBackendInterface { Q_OBJECT public: explicit QtMultimediaCaptureBackend(QObject *parent); virtual ~QtMultimediaCaptureBackend(); void startCapture(const QString &filePath) Q_DECL_OVERRIDE; void stopCapture() Q_DECL_OVERRIDE; CaptureDeviceController::State captureState() const Q_DECL_OVERRIDE; QStringList devices() const Q_DECL_OVERRIDE; void setDevice(const QString &deviceIdentifier) Q_DECL_OVERRIDE; private: QAudioRecorder *m_recorder; QString m_device; }; #endif diff --git a/src/core/editorsession.h b/src/core/editorsession.h index f1b62d9..a962e2e 100644 --- a/src/core/editorsession.h +++ b/src/core/editorsession.h @@ -1,121 +1,120 @@ /* * Copyright 2013-2015 Andreas Cord-Landwehr * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as * published by the Free Software Foundation; either version 2 of * the License or (at your option) version 3 or any later version * accepted by the membership of KDE e.V. (or its successor approved * by the membership of KDE e.V.), which shall act as a proxy * defined in Section 14 of version 3 of the license. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program. If not, see . */ #ifndef EDITORSESSION_H #define EDITORSESSION_H #include "artikulatecore_export.h" #include "course.h" #include "phrase.h" -class QString; class Skeleton; class Language; class Course; class Unit; class ResourceManager; /** * \class EditorSession * * An object of this class is used to set the current state of the editor. By this, we put all logic * how language, skeleton and course fit to each other into this class. The main concept is that * we have to fundamentally different workflows that both are modeled in this class: * * 1. Skeleton based workflow * - a skeleton is selected * - every language is available, since eventually the course should be available in every language * - for every language, there is at most one course (there is none only in case it is not created yet) * - adding new units or phrases is only possible in the skeleton course * - every course can update/sync with the skeleton * * 2. Course based workflow * - there is no skeleton from which the course is derived * - the base is a language that is selected first * - for a language there can be none to arbitrarily many courses * * The main switch is \c EditorSession::setSkeletonMode(bool) */ class ARTIKULATECORE_EXPORT EditorSession : public QObject { Q_OBJECT Q_PROPERTY(bool skeletonMode READ skeletonMode WRITE setSkeletonMode NOTIFY skeletonModeChanged) Q_PROPERTY(bool editSkeleton READ isEditSkeleton WRITE setEditSkeleton NOTIFY editSkeletonChanged) Q_PROPERTY(Skeleton *skeleton READ skeleton WRITE setSkeleton NOTIFY skeletonChanged) Q_PROPERTY(Language *language READ language WRITE setLanguage NOTIFY languageChanged) Q_PROPERTY(Course *course READ course WRITE setCourse NOTIFY courseChanged) Q_PROPERTY(Unit *unit READ unit WRITE setUnit NOTIFY unitChanged) Q_PROPERTY(Phrase *phrase READ phrase WRITE setPhrase NOTIFY phraseChanged) Q_PROPERTY(bool hasNextPhrase READ hasNextPhrase NOTIFY phraseChanged) Q_PROPERTY(bool hasPreviousPhrase READ hasPreviousPhrase NOTIFY phraseChanged) public: explicit EditorSession(QObject *parent = nullptr); void setResourceManager(ResourceManager *manager); void setSkeletonMode(bool enabled=true); bool skeletonMode() const; void setEditSkeleton(bool enabled=true); bool isEditSkeleton() const; Skeleton * skeleton() const; void setSkeleton(Skeleton *skeleton); Language * language() const; void setLanguage(Language *language); Course * course() const; void setCourse(Course *course); Unit * unit() const; void setUnit(Unit *unit); Phrase * phrase() const; void setPhrase(Phrase *phrase); Phrase::Type phraseType() const; void setPhraseType(Phrase::Type type); bool hasPreviousPhrase() const; bool hasNextPhrase() const; Q_INVOKABLE void switchToPreviousPhrase(); Q_INVOKABLE void switchToNextPhrase(); Q_INVOKABLE void updateCourseFromSkeleton(); private: Phrase * nextPhrase() const; Phrase * previousPhrase() const; Q_SIGNALS: void editSkeletonChanged(); void skeletonModeChanged(); void skeletonChanged(); void languageChanged(); void courseChanged(); void unitChanged(); void phraseChanged(); private: Q_DISABLE_COPY(EditorSession) ResourceManager * m_resourceManager; bool m_skeletonMode; bool m_editSkeleton; Skeleton *m_skeleton; Language *m_language; Course *m_course; Course *m_tmpCourseWhileSkeletonEditing; Unit *m_unit; Phrase *m_phrase; }; #endif diff --git a/src/core/trainingsession.h b/src/core/trainingsession.h index aa57a23..791e0fd 100644 --- a/src/core/trainingsession.h +++ b/src/core/trainingsession.h @@ -1,88 +1,87 @@ /* * Copyright 2013-2015 Andreas Cord-Landwehr * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as * published by the Free Software Foundation; either version 2 of * the License or (at your option) version 3 or any later version * accepted by the membership of KDE e.V. (or its successor approved * by the membership of KDE e.V.), which shall act as a proxy * defined in Section 14 of version 3 of the license. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program. If not, see . */ #ifndef TRAININGSESSION_H #define TRAININGSESSION_H #include "artikulatecore_export.h" #include "course.h" #include "phrase.h" -class QString; class Language; class Course; class Unit; class PhonemeGroup; namespace LearnerProfile { class ProfileManager; } /** * \class TrainingSession */ class ARTIKULATECORE_EXPORT TrainingSession : public QObject { Q_OBJECT Q_PROPERTY(Language *language READ language WRITE setLanguage NOTIFY languageChanged) Q_PROPERTY(Course *course READ course WRITE setCourse NOTIFY courseChanged) Q_PROPERTY(Unit *unit READ unit WRITE setUnit NOTIFY unitChanged) Q_PROPERTY(Phrase *phrase READ phrase WRITE setPhrase NOTIFY phraseChanged) Q_PROPERTY(bool hasNextPhrase READ hasNextPhrase NOTIFY phraseChanged) public: explicit TrainingSession(QObject *parent = nullptr); void setProfileManager(LearnerProfile::ProfileManager *manager); Language * language() const; void setLanguage(Language *language); Course * course() const; void setCourse(Course *course); Unit * unit() const; void setUnit(Unit *unit); PhonemeGroup * phonemeGroup() const; void setPhonemeGroup(PhonemeGroup *phonemeGroup); Phrase::Type phraseType() const; void setPhraseType(Phrase::Type type); Phrase * phrase() const; void setPhrase(Phrase *phrase); bool hasPreviousPhrase() const; bool hasNextPhrase() const; Q_INVOKABLE void showNextPhrase(); Q_INVOKABLE void skipPhrase(); Q_SIGNALS: void languageChanged(); void courseChanged(); void unitChanged(); void phraseChanged(); private:; Q_DISABLE_COPY(TrainingSession) Phrase * nextPhrase() const; void updateGoal(); LearnerProfile::ProfileManager *m_profileManager; Language *m_language; Course *m_course; Unit *m_unit; Phrase *m_phrase; }; #endif diff --git a/src/mainwindow_editor.h b/src/mainwindow_editor.h index 38b9452..bc8dc6f 100644 --- a/src/mainwindow_editor.h +++ b/src/mainwindow_editor.h @@ -1,73 +1,71 @@ /* * Copyright 2015 Andreas Cord-Landwehr * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as * published by the Free Software Foundation; either version 2 of * the License or (at your option) version 3 or any later version * accepted by the membership of KDE e.V. (or its successor approved * by the membership of KDE e.V.), which shall act as a proxy * defined in Section 14 of version 3 of the license. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program. If not, see . */ #ifndef MAINWINDOW_EDITOR_H #define MAINWINDOW_EDITOR_H #include #include #include "core/resourcemanager.h" #include "core/trainingsession.h" class EditorSession; -class KActionCollection; -class KMenu; class QQuickWidget; class MainWindowEditor : public KXmlGuiWindow { Q_OBJECT Q_PROPERTY(ResourceManager *globalResourceManager READ resourceManager CONSTANT) public: /** * Default Constructor */ MainWindowEditor(); /** * Default Destructor */ virtual ~MainWindowEditor(); ResourceManager * resourceManager() const; void setupActions(); QSize sizeHint() const Q_DECL_OVERRIDE { return QSize(1000, 700); } bool queryClose() Q_DECL_OVERRIDE; public Q_SLOTS: void showSettingsDialog(); void save(); void quit(); Q_SIGNALS: void modeChanged(bool); private: ResourceManager *m_resourceManager; EditorSession *m_editorSession; QQuickWidget *m_widget; }; #endif diff --git a/src/models/coursefiltermodel.h b/src/models/coursefiltermodel.h index 6b56a3a..ba95660 100644 --- a/src/models/coursefiltermodel.h +++ b/src/models/coursefiltermodel.h @@ -1,65 +1,64 @@ /* * Copyright 2014-2015 Andreas Cord-Landwehr * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as * published by the Free Software Foundation; either version 2 of * the License or (at your option) version 3 or any later version * accepted by the membership of KDE e.V. (or its successor approved * by the membership of KDE e.V.), which shall act as a proxy * defined in Section 14 of version 3 of the license. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program. If not, see . */ #ifndef COURSEFILTERMODEL_H #define COURSEFILTERMODEL_H #include class Course; class CourseModel; -class QSignalMapper; class CourseFilterModel : public QSortFilterProxyModel { Q_OBJECT Q_PROPERTY(CourseModel *courseModel READ courseModel WRITE setCourseModel NOTIFY courseModelChanged) Q_PROPERTY(CourseResourceView view READ view WRITE setView NOTIFY viewChanged) Q_PROPERTY(int filteredCount READ filteredCount NOTIFY filteredCountChanged) public: Q_ENUMS(CourseResourceView); enum CourseResourceView { OnlyGetHotNewStuffResources = 1, OnlyContributorResources = 2, AllResources = 3 }; explicit CourseFilterModel(QObject *parent = nullptr); CourseModel * courseModel() const; void setCourseModel(CourseModel* courseModel); int filteredCount() const; virtual bool lessThan(const QModelIndex &left, const QModelIndex &right) const Q_DECL_OVERRIDE; virtual bool filterAcceptsRow(int source_row, const QModelIndex &source_parent) const Q_DECL_OVERRIDE; void setView(CourseResourceView view); CourseResourceView view() const; Q_INVOKABLE QVariant course(int row) const; Q_SIGNALS: void courseModelChanged(); void viewChanged(); void sortOptionChanged(); void filteredCountChanged(); private: CourseModel *m_courseModel; CourseResourceView m_view; }; #endif diff --git a/src/models/languagemodel.h b/src/models/languagemodel.h index 165e748..33f69b1 100644 --- a/src/models/languagemodel.h +++ b/src/models/languagemodel.h @@ -1,62 +1,61 @@ /* * Copyright 2013-2015 Andreas Cord-Landwehr * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as * published by the Free Software Foundation; either version 2 of * the License or (at your option) version 3 or any later version * accepted by the membership of KDE e.V. (or its successor approved * by the membership of KDE e.V.), which shall act as a proxy * defined in Section 14 of version 3 of the license. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program. If not, see . */ #ifndef LANGUAGEMODEL_H #define LANGUAGEMODEL_H #include class LanguageResourceModel; class Language; -class QSignalMapper; class LanguageModel : public QSortFilterProxyModel { Q_OBJECT Q_PROPERTY(LanguageResourceModel *resourceModel READ resourceModel WRITE setResourceModel NOTIFY resourceModelChanged) Q_PROPERTY(LanguageResourceView view READ view WRITE setView NOTIFY viewChanged) public: Q_ENUMS(LanguageResourceView); enum LanguageResourceView { NonEmptyContributorOnlyResources, NonEmptyGhnsOnlyLanguages, NonEmptyLanguages, AllLanguages }; explicit LanguageModel(QObject *parent = nullptr); LanguageResourceModel * resourceModel() const; void setResourceModel(LanguageResourceModel *resourceModel); virtual bool lessThan(const QModelIndex &left, const QModelIndex &right) const Q_DECL_OVERRIDE; void setView(LanguageResourceView view); LanguageResourceView view() const; Q_INVOKABLE QVariant language(int index) const; Q_SIGNALS: void resourceModelChanged(); void viewChanged(); private: LanguageResourceModel *m_resourceModel; LanguageResourceView m_view; }; #endif diff --git a/src/models/phrasefiltermodel.h b/src/models/phrasefiltermodel.h index 95fd7c8..83e8ee3 100644 --- a/src/models/phrasefiltermodel.h +++ b/src/models/phrasefiltermodel.h @@ -1,72 +1,71 @@ /* * Copyright 2013-2015 Andreas Cord-Landwehr * Copyright 2013 Samikshan Bairagya * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as * published by the Free Software Foundation; either version 2 of * the License or (at your option) version 3 or any later version * accepted by the membership of KDE e.V. (or its successor approved * by the membership of KDE e.V.), which shall act as a proxy * defined in Section 14 of version 3 of the license. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program. If not, see . */ #ifndef PHRASEFILTERMODEL_H #define PHRASEFILTERMODEL_H #include class PhraseListModel; -class QSignalMapper; class PhraseFilterModel : public QSortFilterProxyModel { Q_OBJECT Q_PROPERTY(PhraseListModel *phraseModel READ phraseModel WRITE setPhraseModel NOTIFY phraseModelChanged) Q_PROPERTY(bool hideExcluded READ isHideExcluded WRITE setHideExcluded NOTIFY hideExcludedChanged) Q_PROPERTY(bool hideNotRecorded READ isHideNotRecorded WRITE setHideNotRecorded NOTIFY hideNotRecordedChanged) Q_PROPERTY(SortOption sortOption READ sortOption WRITE setSortOption NOTIFY sortOptionChanged) Q_PROPERTY(int filteredCount READ filteredCount NOTIFY filteredCountChanged) public: Q_ENUMS(SortOption) enum SortOption { Id, Type }; explicit PhraseFilterModel(QObject *parent = nullptr); PhraseListModel * phraseModel() const; void setPhraseModel(PhraseListModel* phraseModel); void setSortOption(SortOption option = Id); SortOption sortOption() const; int filteredCount() const; virtual bool lessThan(const QModelIndex &left, const QModelIndex &right) const Q_DECL_OVERRIDE; virtual bool filterAcceptsRow(int source_row, const QModelIndex &source_parent) const Q_DECL_OVERRIDE; void setHideExcluded(bool hide=true); bool isHideExcluded() const; void setHideNotRecorded(bool hide=true); bool isHideNotRecorded() const; Q_SIGNALS: void phraseModelChanged(); void hideExcludedChanged(); void hideNotRecordedChanged(); void sortOptionChanged(); void filteredCountChanged(); private: PhraseListModel *m_phraseModel; bool m_hideExcluded; bool m_hideNotRecorded; SortOption m_sortOption; }; #endif diff --git a/src/models/skeletonmodel.h b/src/models/skeletonmodel.h index d5a6648..98ff03d 100644 --- a/src/models/skeletonmodel.h +++ b/src/models/skeletonmodel.h @@ -1,77 +1,76 @@ /* * Copyright 2013-2015 Andreas Cord-Landwehr * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as * published by the Free Software Foundation; either version 2 of * the License or (at your option) version 3 or any later version * accepted by the membership of KDE e.V. (or its successor approved * by the membership of KDE e.V.), which shall act as a proxy * defined in Section 14 of version 3 of the license. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program. If not, see . */ #ifndef SKELETONMODEL_H #define SKELETONMODEL_H #include class ResourceManager; class Course; class Skeleton; -class Language; class QSignalMapper; class SkeletonModel : public QAbstractListModel { Q_OBJECT Q_PROPERTY(ResourceManager *resourceManager READ resourceManager WRITE setResourceManager NOTIFY resourceManagerChanged) Q_PROPERTY(int count READ count NOTIFY countChanged) public: enum courseRoles { TitleRole = Qt::UserRole + 1, DescriptionRole, IdRole, DataRole }; explicit SkeletonModel(QObject *parent = nullptr); void setResourceManager(ResourceManager *resourceManager); /** * Reimplemented from QAbstractListModel::roleNames() */ virtual QHash roleNames() const Q_DECL_OVERRIDE; ResourceManager * resourceManager() const; virtual QVariant data(const QModelIndex &index, int role = Qt::DisplayRole) const Q_DECL_OVERRIDE; virtual int rowCount(const QModelIndex &parent = QModelIndex()) const Q_DECL_OVERRIDE; virtual QVariant headerData(int section, Qt::Orientation orientation, int role = Qt::DisplayRole) const Q_DECL_OVERRIDE; int count() const; Q_INVOKABLE QVariant skeleton(int index) const; Q_SIGNALS: void skeletonChanged(int index); void resourceManagerChanged(); void countChanged(); private Q_SLOTS: void onSkeletonAboutToBeAdded(Course *skeleton, int index); void onSkeletonAdded(); void onSkeletonsAboutToBeRemoved(int first, int last); void onSkeletonsRemoved(); void emitSkeletonChanged(int row); private: void updateMappings(); ResourceManager *m_resourceManager; QSignalMapper *m_signalMapper; }; #endif // SKELETONMODEL_H diff --git a/src/models/unitfiltermodel.h b/src/models/unitfiltermodel.h index 1cd5ab8..afa372e 100644 --- a/src/models/unitfiltermodel.h +++ b/src/models/unitfiltermodel.h @@ -1,53 +1,52 @@ /* * Copyright 2014-2015 Andreas Cord-Landwehr * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as * published by the Free Software Foundation; either version 2 of * the License or (at your option) version 3 or any later version * accepted by the membership of KDE e.V. (or its successor approved * by the membership of KDE e.V.), which shall act as a proxy * defined in Section 14 of version 3 of the license. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program. If not, see . */ #ifndef UNITFILTERMODEL_H #define UNITFILTERMODEL_H #include class UnitModel; -class QSignalMapper; class UnitFilterModel : public QSortFilterProxyModel { Q_OBJECT Q_PROPERTY(UnitModel *unitModel READ unitModel WRITE setUnitModel NOTIFY unitModelChanged) Q_PROPERTY(int filteredCount READ filteredCount NOTIFY filteredCountChanged) public: explicit UnitFilterModel(QObject *parent = nullptr); UnitModel * unitModel() const; void setUnitModel(UnitModel* unitModel); int filteredCount() const; virtual bool lessThan(const QModelIndex &left, const QModelIndex &right) const Q_DECL_OVERRIDE; virtual bool filterAcceptsRow(int source_row, const QModelIndex &source_parent) const Q_DECL_OVERRIDE; Q_SIGNALS: void unitModelChanged(); void viewChanged(); void sortOptionChanged(); void filteredCountChanged(); private: UnitModel *m_unitModel; }; #endif diff --git a/src/ui/resourcesdialogpage.h b/src/ui/resourcesdialogpage.h index 50ad2f3..d26c706 100644 --- a/src/ui/resourcesdialogpage.h +++ b/src/ui/resourcesdialogpage.h @@ -1,48 +1,47 @@ /* * Copyright 2013-2015 Andreas Cord-Landwehr * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as * published by the Free Software Foundation; either version 2 of * the License or (at your option) version 3 or any later version * accepted by the membership of KDE e.V. (or its successor approved * by the membership of KDE e.V.), which shall act as a proxy * defined in Section 14 of version 3 of the license. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program. If not, see . */ #ifndef RESOURCESDIALOGPAGE_H #define RESOURCESDIALOGPAGE_H #include "ui_resourcesdialogpage.h" #include class ResourceManager; -class Course; class ResourcesDialogPage : public QWidget { Q_OBJECT public: explicit ResourcesDialogPage(ResourceManager *resourceMgr); virtual ~ResourcesDialogPage(); public Q_SLOTS: void saveSettings(); void loadSettings(); private: Ui::ResourcesDialogPage *ui; ResourceManager *m_resourceManager; bool m_restartNeeded; }; #endif diff --git a/src/ui/sounddevicedialogpage.h b/src/ui/sounddevicedialogpage.h index 7a52714..e2f86bb 100644 --- a/src/ui/sounddevicedialogpage.h +++ b/src/ui/sounddevicedialogpage.h @@ -1,57 +1,56 @@ /* * Copyright 2013 Andreas Cord-Landwehr * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as * published by the Free Software Foundation; either version 2 of * the License or (at your option) version 3 or any later version * accepted by the membership of KDE e.V. (or its successor approved * by the membership of KDE e.V.), which shall act as a proxy * defined in Section 14 of version 3 of the license. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program. If not, see . */ #ifndef SOUNDDEVICEDIALOGPAGE_H #define SOUNDDEVICEDIALOGPAGE_H #include "ui_sounddevicedialogpage.h" #include #include -class QMediaPlayer; class SoundDeviceDialogPage : public QWidget { Q_OBJECT public: SoundDeviceDialogPage(); ~SoundDeviceDialogPage(); public slots: void saveSettings(); void loadSettings(); void playTestSound(); void playRecordedSound(); void recordSound(); void updatePlayButtonIcons(); void stopPlaying(); void stopRecord(); void setVolume(int volume); private: Ui::SoundDeviceDialogPage *ui; QList m_audioInputs; QList m_audioOutputs; QTemporaryFile m_recordTestFile; }; #endif