diff --git a/sdrbase/gui/samplingdevicecontrol.cpp b/sdrbase/gui/samplingdevicecontrol.cpp new file mode 100644 index 000000000..db21994c0 --- /dev/null +++ b/sdrbase/gui/samplingdevicecontrol.cpp @@ -0,0 +1,48 @@ +/////////////////////////////////////////////////////////////////////////////////// +// Copyright (C) 2015 Edouard Griffiths, F4EXB // +// // +// This program is free software; you can redistribute it and/or modify // +// it under the terms of the GNU General Public License as published by // +// the Free Software Foundation as version 3 of the License, or // +// // +// This program is distributed in the hope that it will be useful, // +// but WITHOUT ANY WARRANTY; without even the implied warranty of // +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // +// GNU General Public License V3 for more details. // +// // +// You should have received a copy of the GNU General Public License // +// along with this program. If not, see . // +/////////////////////////////////////////////////////////////////////////////////// + +#include "gui/samplingdevicecontrol.h" +#include "gui/pluginsdialog.h" +#include "plugin/pluginmanager.h" +#include "ui_samplingdevicecontrol.h" + + +SamplingDeviceControl::SamplingDeviceControl(QWidget* parent) : + QWidget(parent), + ui(new Ui::SamplingDeviceControl), + m_pluginManager(0) +{ + ui->setupUi(this); +} + +SamplingDeviceControl::~SamplingDeviceControl() +{ + delete ui; +} + +QComboBox *SamplingDeviceControl::getDeviceSelector() +{ + return ui->deviceSelect; +} + +void SamplingDeviceControl::on_showLoadedPlugins_clicked(bool checked) +{ + if (m_pluginManager) + { + PluginsDialog pluginsDialog(m_pluginManager, this); + pluginsDialog.exec(); + } +} diff --git a/sdrbase/gui/samplingdevicecontrol.h b/sdrbase/gui/samplingdevicecontrol.h new file mode 100644 index 000000000..1380c8fd6 --- /dev/null +++ b/sdrbase/gui/samplingdevicecontrol.h @@ -0,0 +1,52 @@ +/////////////////////////////////////////////////////////////////////////////////// +// Copyright (C) 2015 Edouard Griffiths, F4EXB // +// // +// This program is free software; you can redistribute it and/or modify // +// it under the terms of the GNU General Public License as published by // +// the Free Software Foundation as version 3 of the License, or // +// // +// This program is distributed in the hope that it will be useful, // +// but WITHOUT ANY WARRANTY; without even the implied warranty of // +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // +// GNU General Public License V3 for more details. // +// // +// You should have received a copy of the GNU General Public License // +// along with this program. If not, see . // +/////////////////////////////////////////////////////////////////////////////////// + +#ifndef SDRBASE_GUI_SAMPLINGDEVICECONTROL_H_ +#define SDRBASE_GUI_SAMPLINGDEVICECONTROL_H_ + + +#include +#include + +#include "util/export.h" + +namespace Ui { + class SamplingDeviceControl; +} + +class ChannelMarker; +class PluginManager; + +class SDRANGEL_API SamplingDeviceControl : public QWidget { + Q_OBJECT + +public: + explicit SamplingDeviceControl(QWidget* parent = NULL); + ~SamplingDeviceControl(); + + void setPluginManager(PluginManager *pluginManager) { m_pluginManager = pluginManager; } + QComboBox *getDeviceSelector(); + +private: + Ui::SamplingDeviceControl* ui; + PluginManager *m_pluginManager; + +private slots: + void on_showLoadedPlugins_clicked(bool checked); +}; + + +#endif /* SDRBASE_GUI_SAMPLINGDEVICECONTROL_H_ */ diff --git a/sdrbase/gui/samplingdevicecontrol.ui b/sdrbase/gui/samplingdevicecontrol.ui new file mode 100644 index 000000000..c1d86db89 --- /dev/null +++ b/sdrbase/gui/samplingdevicecontrol.ui @@ -0,0 +1,103 @@ + + + SamplingDeviceControl + + + + 0 + 0 + 300 + 76 + + + + + 300 + 76 + + + + + Sans Serif + 9 + + + + Title & Color + + + + + + + + + 22 + 16777215 + + + + Dev + + + + + + + Select sampling device + + + + + + + + + + + + 0 + 0 + + + + + 30 + 16777215 + + + + Chan + + + + + + + Add a new channel + + + + + + + + 20 + 16777215 + + + + Show loaded plugins + + + ? + + + + + + + + + +