summaryrefslogtreecommitdiff
path: root/src/ui/alsa/alsamixerwindow.h
blob: 8d8ef4f2e9d1c178b0c3b8f8a9f1e6bd32c36d1a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
#pragma once

#include <tdemainwindow.h>
#include <tqptrlist.h>

class AlsaModel;
class AlsaDevice;
class AlsaDevicesPage;
#include "alsadevicewidget.h"
class AlsaTray;
class TQComboBox;
class TQTabWidget;
class TQHBoxLayout;
class TQWidget;

class AlsaMixerWindow : public TDEMainWindow
{
    TQ_OBJECT
public:
    explicit AlsaMixerWindow( AlsaModel *model, TQWidget *parent = 0 );

    void setTray( AlsaTray *tray ) { m_tray = tray; }

signals:
    void settingsChanged();

public slots:
    void bringToFront();
    void quit();

protected:
    bool queryClose();
    void showEvent( TQShowEvent *e );

private slots:
    void onCardChanged( int idx );
    void onDeviceAdded( AlsaDevice *dev );
    void showPreferences();
    void showAbout();

private:
    void rebuildTabs( int cardIndex );

    AlsaModel  *m_model;
    AlsaTray   *m_tray;
    bool        m_posRestored;
    TQComboBox  *m_cardCombo;
    TQTabWidget *m_tabs;
    TQWidget    *m_outputPage;
    TQWidget    *m_inputPage;
    TQHBoxLayout *m_outputLayout;
    TQHBoxLayout *m_inputLayout;
    TQPtrList<AlsaDeviceWidget> m_widgets;
    AlsaDevicesPage *m_devicesPage;
};