1 /* 2 * Cantata 3 * 4 * Copyright (c) 2011-2020 Craig Drummond <craig.p.drummond@gmail.com> 5 * 6 * ---- 7 * 8 * This program is free software; you can redistribute it and/or modify 9 * it under the terms of the GNU General Public License as published by 10 * the Free Software Foundation; either version 2 of the License, or 11 * (at your option) any later version. 12 * 13 * This program is distributed in the hope that it will be useful, 14 * but WITHOUT ANY WARRANTY; without even the implied warranty of 15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 16 * General Public License for more details. 17 * 18 * You should have received a copy of the GNU General Public License 19 * along with this program; see the file COPYING. If not, write to 20 * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, 21 * Boston, MA 02110-1301, USA. 22 */ 23 24 #ifndef FILENAMESCHEMEDIALOG_H 25 #define FILENAMESCHEMEDIALOG_H 26 27 #include "ui_filenameschemedialog.h" 28 #include "support/dialog.h" 29 #include "mpd-interface/song.h" 30 #include "deviceoptions.h" 31 32 class FilenameSchemeDialog : public Dialog, Ui::FilenameSchemeDialog 33 { 34 Q_OBJECT 35 36 public: 37 FilenameSchemeDialog(QWidget *parent); 38 void show(const DeviceOptions &opts); 39 40 Q_SIGNALS: 41 void scheme(const QString &text); 42 43 private Q_SLOTS: 44 void showHelp(); 45 void enableOkButton(); 46 void insertVariable(); 47 void updateExample(); 48 49 private: 50 void slotButtonClicked(int button) override; 51 52 private: 53 DeviceOptions origOpts; 54 Song exampleSong; 55 }; 56 57 #endif 58