/[svn]/qsampler/trunk/src/qsamplerDeviceForm.h
ViewVC logotype

Annotation of /qsampler/trunk/src/qsamplerDeviceForm.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1510 - (hide annotations) (download) (as text)
Thu Nov 22 14:17:24 2007 UTC (16 years, 4 months ago) by capela
File MIME type: text/x-c++hdr
File size: 2782 byte(s)
- Qt4 migration: code cleanup, personal standards beautification :)

1 capela 1464 // qsamplerDeviceForm.h
2     //
3     /****************************************************************************
4     Copyright (C) 2004-2007, rncbc aka Rui Nuno Capela. All rights reserved.
5     Copyright (C) 2007, Christian Schoenebeck
6 schoenebeck 1461
7 capela 1464 This program is free software; you can redistribute it and/or
8     modify it under the terms of the GNU General Public License
9     as published by the Free Software Foundation; either version 2
10     of the License, or (at your option) any later version.
11    
12     This program is distributed in the hope that it will be useful,
13     but WITHOUT ANY WARRANTY; without even the implied warranty of
14     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15     GNU General Public License for more details.
16    
17     You should have received a copy of the GNU General Public License along
18     with this program; if not, write to the Free Software Foundation, Inc.,
19     51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
20    
21     *****************************************************************************/
22    
23     #ifndef __qsamplerDeviceForm_h
24     #define __qsamplerDeviceForm_h
25    
26 schoenebeck 1461 #include "ui_qsamplerDeviceForm.h"
27    
28 capela 1473 #include "qsamplerDevice.h"
29 schoenebeck 1461
30 capela 1499
31 schoenebeck 1461 namespace QSampler {
32    
33     class MainForm;
34    
35 capela 1509 class DeviceForm : public QDialog
36     {
37     Q_OBJECT
38    
39 schoenebeck 1461 public:
40 capela 1509
41 capela 1510 DeviceForm(QWidget *pParent = NULL, Qt::WindowFlags wflags = 0);
42     ~DeviceForm();
43 schoenebeck 1461
44 capela 1510 void setDeviceTypeMode(qsamplerDevice::DeviceType deviceType);
45     void setDriverName(const QString& sDriverName);
46     void setDevice(qsamplerDevice *pDevice);
47 schoenebeck 1461
48 capela 1509 public slots:
49 schoenebeck 1461
50 capela 1510 void createDevice();
51     void deleteDevice();
52     void refreshDevices();
53     void selectDriver(const QString& sDriverName);
54     void selectDevice();
55     void selectDevicePort(int iPort);
56     void changeDeviceParam(int iRow, int iCol);
57     void changeDevicePortParam(int iRow, int iCol);
58     void deviceListViewContextMenu(const QPoint& pos);
59     void stabilizeForm();
60 schoenebeck 1461
61 capela 1510 void updateCellRenderers();
62     void updateCellRenderers(
63     const QModelIndex& topLeft, const QModelIndex& bottomRight);
64     void updatePortCellRenderers();
65     void updatePortCellRenderers(
66     const QModelIndex& topLeft, const QModelIndex& bottomRight);
67    
68 capela 1509 signals:
69    
70 capela 1510 void devicesChanged();
71 capela 1509
72 schoenebeck 1461 protected:
73 capela 1509
74 capela 1510 void showEvent(QShowEvent* pShowEvent);
75     void hideEvent(QHideEvent* pHideEvent);
76 capela 1509
77     private:
78    
79 capela 1510 Ui::qsamplerDeviceForm m_ui;
80 capela 1509
81 capela 1510 DeviceParamModel m_deviceParamModel;
82     DeviceParamDelegate m_deviceParamDelegate;
83 capela 1509
84 capela 1510 PortParamModel m_devicePortParamModel;
85     DeviceParamDelegate m_devicePortParamDelegate;
86 capela 1509
87 capela 1510 lscp_client_t *m_pClient;
88     int m_iDirtySetup;
89     int m_iDirtyCount;
90     bool m_bNewDevice;
91     qsamplerDevice::DeviceType m_deviceType;
92     qsamplerDevice::DeviceType m_deviceTypeMode;
93     qsamplerDeviceItem *m_pAudioItems;
94     qsamplerDeviceItem *m_pMidiItems;
95 schoenebeck 1461 };
96    
97     } // namespace QSampler
98    
99 capela 1510
100 capela 1464 #endif // __qsamplerDeviceForm_h
101    
102    
103     // end of qsamplerDeviceForm.h

  ViewVC Help
Powered by ViewVC