File indexing completed on 2024-04-21 04:48:17
0001 /* AUDEX CDDA EXTRACTOR 0002 * SPDX-FileCopyrightText: Copyright (C) 2007 Marco Nelles 0003 * <https://userbase.kde.org/Audex> 0004 * 0005 * SPDX-License-Identifier: GPL-3.0-or-later 0006 */ 0007 0008 #ifndef FLACWIDGET_H 0009 #define FLACWIDGET_H 0010 0011 #include <QDir> 0012 #include <QWidget> 0013 0014 #include "utils/encoderassistant.h" 0015 #include "utils/error.h" 0016 #include "utils/parameters.h" 0017 0018 #include "ui_flacwidgetUI.h" 0019 0020 class flacWidgetUI : public QWidget, public Ui::FLACWidgetUI 0021 { 0022 public: 0023 explicit flacWidgetUI(QWidget *parent) 0024 : QWidget(parent) 0025 { 0026 setupUi(this); 0027 } 0028 }; 0029 0030 class flacWidget : public flacWidgetUI 0031 { 0032 Q_OBJECT 0033 public: 0034 explicit flacWidget(Parameters *parameters, QWidget *parent = nullptr); 0035 ~flacWidget() override; 0036 inline Error lastError() const 0037 { 0038 return error; 0039 } 0040 inline bool isChanged() const 0041 { 0042 return changed; 0043 } 0044 public Q_SLOTS: 0045 bool save(); 0046 Q_SIGNALS: 0047 void triggerChanged(); 0048 private Q_SLOTS: 0049 void compression_changed_by_slider(int compression); 0050 void compression_changed_by_spinbox(int compression); 0051 void trigger_changed(); 0052 0053 private: 0054 Parameters *parameters; 0055 Error error; 0056 bool changed; 0057 }; 0058 0059 #endif