blob: c311cb87dcc3a3b9b3684b25d8e381753f702b7e [file] [log] [blame]
Edric Milaret627500d2015-03-27 16:41:40 -04001/***************************************************************************
Edric Milaret4bba46d2015-04-29 16:33:38 -04002 * Copyright (C) 2015 by Savoir-Faire Linux *
Edric Milaret627500d2015-03-27 16:41:40 -04003 * Author: Edric Ladent Milaret <edric.ladent-milaret@savoirfairelinux.com>*
4 * *
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 3 of the License, or *
8 * (at your option) any later version. *
9 * *
10 * This program is distributed in the hope that it will be useful, *
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of *
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
13 * GNU General Public License for more details. *
14 * *
15 * You should have received a copy of the GNU General Public License *
16 * along with this program. If not, see <http://www.gnu.org/licenses/>. *
17 **************************************************************************/
18
19#ifndef CONFIGURATIONWIDGET_H
20#define CONFIGURATIONWIDGET_H
21
22#include <QWidget>
23#include <QItemSelection>
24
25#include "navwidget.h"
26#include "accountdetails.h"
27
28#include "accountmodel.h"
29#include "video/devicemodel.h"
30#include "audio/codecmodel.h"
31
32namespace Ui {
33class ConfigurationWidget;
34}
35
36class ConfigurationWidget : public NavWidget
37{
38 Q_OBJECT
39
40public:
41 explicit ConfigurationWidget(QWidget *parent = 0);
42 ~ConfigurationWidget();
43 void atExit();
44
Edric Milaret3aeae3a2015-06-01 17:31:54 -040045
46protected:
47 void showEvent(QShowEvent *event);
48
Edric Milaret627500d2015-03-27 16:41:40 -040049//UI SLOTS
50private slots:
51 void on_deviceBox_currentIndexChanged(int index);
52 void on_sizeBox_currentIndexChanged(int index);
53 void on_rateBox_currentIndexChanged(int index);
Edric Milaret627500d2015-03-27 16:41:40 -040054 void on_deleteAccountButton_clicked();
55 void on_addAccountButton_clicked();
Edric Milaret94b4aab2015-05-08 12:10:44 -040056 void on_startupBox_toggled(bool checked);
Edric Milaret627500d2015-03-27 16:41:40 -040057
58private slots:
59 void accountSelected(QItemSelection itemSel);
Edric Milaret94b4aab2015-05-08 12:10:44 -040060 void deviceIndexChanged(int index);
Edric Milaret4bba46d2015-04-29 16:33:38 -040061
Edric Milaret627500d2015-03-27 16:41:40 -040062private:
63 Ui::ConfigurationWidget *ui;
64 AccountModel* accountModel_;
65 Video::DeviceModel* deviceModel_;
66 CodecModel* codecModel_;
67 bool isLoading_;
68 AccountDetails* accountDetails_;
69};
70
71#endif // CONFIGURATIONWIDGET_H