source: src-qt4/pc-mixer/MixerGUI.h @ caf88c8

releng/10.0.1releng/10.0.2releng/10.0.3releng/10.1
Last change on this file since caf88c8 was caf88c8, checked in by Ken Moore <ken@…>, 9 months ago

Add a new utility: pc-mixer
This utility is a tray application that is a front-end to the "mixer" CLI tool, granting control over volumes and other audio settings.
The tray portion of it is complete, still need to finish filling out the full mixer GUI tomorrow.

  • Property mode set to 100644
File size: 835 bytes
Line 
1#ifndef _PC_MIXER_GUI_H
2#define _PC_MIXER_GUI_H
3
4#include <QMainWindow>
5#include <QSettings>
6#include <QCloseEvent>
7#include <QCoreApplication>
8
9#include "MixerBackend.h"
10
11namespace Ui{
12        class MixerGUI;
13};
14
15class MixerGUI : public QMainWindow{
16        Q_OBJECT
17public:
18        MixerGUI(QSettings*);
19        ~MixerGUI();
20
21        void updateGUI(); //For the tray to call before the GUI becomes active
22
23private:
24        Ui::MixerGUI *ui;
25        QSettings *settings;
26        bool closing;
27
28private slots:
29        void hideGUI(){
30          this->hide();
31        }
32        void closeApplication(){
33          closing = true;
34          this->close();
35        }
36       
37        void changeDefaultTrayDevice(QString device);
38        void itemChanged(QString device); //for individual device adjustments
39
40protected:
41        void closeEvent(QCloseEvent *event){
42          if(!closing){
43            event->ignore();
44            hideGUI();
45          }
46        }
47       
48signals:
49        void updateTray();
50       
51};
52
53#endif
Note: See TracBrowser for help on using the repository browser.