summaryrefslogtreecommitdiff
path: root/src/ui/devicespage.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/ui/devicespage.h')
-rw-r--r--src/ui/devicespage.h42
1 files changed, 42 insertions, 0 deletions
diff --git a/src/ui/devicespage.h b/src/ui/devicespage.h
new file mode 100644
index 0000000..49081f4
--- /dev/null
+++ b/src/ui/devicespage.h
@@ -0,0 +1,42 @@
+#pragma once
+
+#include <tqwidget.h>
+#include <tqmap.h>
+#include <tqvaluelist.h>
+#include <tqstring.h>
+
+class PulseModel;
+class TQScrollView;
+class TQComboBox;
+class TQLabel;
+class TQVBoxLayout;
+
+struct PortWidgets {
+ TQLabel *dot;
+};
+
+class DevicesPage : public TQWidget
+{
+ TQ_OBJECT
+
+public:
+ explicit DevicesPage( PulseModel *model, TQWidget *parent = 0 );
+
+private slots:
+ void onCardAdded( uint32_t index );
+ void onCardRemoved( uint32_t index );
+ void onCardUpdated( uint32_t index );
+ void onProfileActivated( int comboIndex );
+
+private:
+ void rebuild();
+
+ PulseModel *m_model;
+ TQScrollView *m_scroll;
+ TQWidget *m_container;
+
+ TQMap<TQComboBox*, uint32_t> m_comboCard;
+ TQMap<TQComboBox*, TQValueList<TQString> > m_profileNames;
+ TQMap<uint32_t, TQComboBox*> m_cardCombo;
+ TQMap<uint32_t, TQValueList<PortWidgets> > m_cardPorts;
+};