mirror of
https://github.com/f4exb/sdrangel.git
synced 2026-06-01 13:47:01 -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:
@@ -18,7 +18,6 @@
|
||||
#include <QDebug>
|
||||
#include <QMessageBox>
|
||||
#include <QFileDialog>
|
||||
#include <QResizeEvent>
|
||||
|
||||
#include <libbladeRF.h>
|
||||
|
||||
@@ -49,7 +48,7 @@ Bladerf1InputGui::Bladerf1InputGui(DeviceUISet *deviceUISet, QWidget* parent) :
|
||||
m_sampleSource = (Bladerf1Input*) m_deviceUISet->m_deviceAPI->getSampleSource();
|
||||
|
||||
ui->setupUi(getContents());
|
||||
setSizePolicy(QSizePolicy::Fixed, QSizePolicy::Fixed);
|
||||
sizeToContents();
|
||||
getContents()->setStyleSheet("#Bladerf1InputGui { background-color: rgb(64, 64, 64); }");
|
||||
m_helpURL = "plugins/samplesource/bladerf1input/readme.md";
|
||||
ui->centerFrequency->setColorMapper(ColorMapper(ColorMapper::GrayGold));
|
||||
@@ -118,12 +117,6 @@ bool Bladerf1InputGui::deserialize(const QByteArray& data)
|
||||
}
|
||||
}
|
||||
|
||||
void Bladerf1InputGui::resizeEvent(QResizeEvent* size)
|
||||
{
|
||||
adjustSize();
|
||||
size->accept();
|
||||
}
|
||||
|
||||
bool Bladerf1InputGui::handleMessage(const Message& message)
|
||||
{
|
||||
if (Bladerf1Input::MsgConfigureBladerf1::match(message))
|
||||
|
||||
@@ -72,9 +72,6 @@ private:
|
||||
bool handleMessage(const Message& message);
|
||||
void makeUIConnections();
|
||||
|
||||
protected:
|
||||
void resizeEvent(QResizeEvent* size);
|
||||
|
||||
private slots:
|
||||
void handleInputMessages();
|
||||
void on_centerFrequency_changed(quint64 value);
|
||||
|
||||
Reference in New Issue
Block a user