mirror of
https://github.com/f4exb/sdrangel.git
synced 2026-06-04 23:14:47 -04:00
Device GUIs: Constain window size via minimumSize/maximumSize, rather than handling resizeEvent. Add maximum button. Hide size buttons when window size is fixed
This commit is contained in:
@@ -19,7 +19,6 @@
|
||||
#include <QDebug>
|
||||
#include <QMessageBox>
|
||||
#include <QFileDialog>
|
||||
#include <QResizeEvent>
|
||||
|
||||
#include "dsp/dspengine.h"
|
||||
#include "dsp/dspcommands.h"
|
||||
@@ -50,7 +49,7 @@ PlutoSDRInputGui::PlutoSDRInputGui(DeviceUISet *deviceUISet, QWidget* parent) :
|
||||
m_sampleSource = (PlutoSDRInput*) m_deviceUISet->m_deviceAPI->getSampleSource();
|
||||
|
||||
ui->setupUi(getContents());
|
||||
setSizePolicy(QSizePolicy::Fixed, QSizePolicy::Fixed);
|
||||
sizeToContents();
|
||||
getContents()->setStyleSheet("#PlutoSDRInputGUI { background-color: rgb(64, 64, 64); }");
|
||||
m_helpURL = "plugins/samplesource/plutosdrinput/readme.md";
|
||||
ui->centerFrequency->setColorMapper(ColorMapper(ColorMapper::GrayGold));
|
||||
@@ -129,12 +128,6 @@ bool PlutoSDRInputGui::deserialize(const QByteArray& data)
|
||||
}
|
||||
}
|
||||
|
||||
void PlutoSDRInputGui::resizeEvent(QResizeEvent* size)
|
||||
{
|
||||
adjustSize();
|
||||
size->accept();
|
||||
}
|
||||
|
||||
bool PlutoSDRInputGui::handleMessage(const Message& message)
|
||||
{
|
||||
if (PlutoSDRInput::MsgConfigurePlutoSDR::match(message))
|
||||
|
||||
@@ -48,9 +48,6 @@ public:
|
||||
virtual bool deserialize(const QByteArray& data);
|
||||
virtual MessageQueue *getInputMessageQueue() { return &m_inputMessageQueue; }
|
||||
|
||||
protected:
|
||||
void resizeEvent(QResizeEvent* size);
|
||||
|
||||
private:
|
||||
Ui::PlutoSDRInputGUI* ui;
|
||||
PlutoSDRInputSettings m_settings;
|
||||
|
||||
Reference in New Issue
Block a user