new 4475edb243ed4627f4c5f2c470ca40b3def034d4
[tagua/yd.git] / src / pref_preferences.h
blob14db1bf67e174c08bcf6978dd2dec9df4baa73dd
1 /*
2 Copyright (c) 2006 Paolo Capriotti <p.capriotti@gmail.com>
3 (c) 2006 Maurizio Monge <maurizio.monge@kdemail.net>
5 This program is free software; you can redistribute it and/or modify
6 it under the terms of the GNU General Public License as published by
7 the Free Software Foundation; either version 2 of the License, or
8 (at your option) any later version.
9 */
11 #ifndef PREFERENCES__PREFERENCES_H
12 #define PREFERENCES__PREFERENCES_H
14 #include <list>
15 #include "ui_preferences.h"
18 class PrefBase : public QWidget {
19 Q_OBJECT
21 public:
22 PrefBase(QWidget *parent = 0) : QWidget(parent) {}
24 public Q_SLOTS:
25 virtual void apply() = 0;
29 class Preferences : public QDialog
30 , private Ui::Preferences {
31 Q_OBJECT
33 std::list<PrefBase*> m_pages;
35 public:
36 Preferences(const QString& currentVariant, QWidget *parent = 0);
37 ~Preferences();
39 Q_SIGNALS:
40 void applied();
42 public Q_SLOTS:
43 void apply();
46 #endif //PREFERENCES__PREFERENCES_H