summaryrefslogtreecommitdiff
path: root/src/ui/tmixtray.h
blob: 08a5fb585e888ec287fedb276cdda04a89a56631 (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
#pragma once

#include <ksystemtray.h>

class AudioDevice;
class PulseModel;
class TmixPopup;

class TmixTray : public KSystemTray
{
    TQ_OBJECT

public:
    TmixTray( TQWidget *parent );
    void setDevice( AudioDevice *dev );
    void setModel( PulseModel *model );

public slots:
    void updateIcon();
    void onRecordingActive( bool active );
    void onDeviceAdded( AudioDevice *dev );

protected:
    void mousePressEvent( TQMouseEvent *e );
    void wheelEvent( TQWheelEvent *e );
    void contextMenuAboutToShow( TDEPopupMenu *menu );

private:
    void updateRecordingTray();

    PulseModel   *m_model;
    AudioDevice  *m_device;
    KSystemTray  *m_recTray;
    TmixPopup    *m_popup;
    int           m_recordingCount;
};