mirror of
https://github.com/f4exb/sdrangel.git
synced 2026-06-02 14:04:46 -04:00
Massive UI revamping (v7): Fixed sizing of channel windows. Part of #1209
This commit is contained in:
@@ -22,6 +22,7 @@
|
||||
#include <QTime>
|
||||
#include <QDebug>
|
||||
#include <QMessageBox>
|
||||
#include <QResizeEvent>
|
||||
|
||||
#include <cmath>
|
||||
|
||||
@@ -66,11 +67,13 @@ DATVModGUI::DATVModGUI(PluginAPI* pluginAPI, DeviceUISet *deviceUISet, BasebandS
|
||||
m_tickCount(0),
|
||||
m_enableNavTime(false)
|
||||
{
|
||||
ui->setupUi(getRollupContents());
|
||||
getRollupContents()->arrangeRollups();
|
||||
m_helpURL = "plugins/channeltx/moddatv/readme.md";
|
||||
setAttribute(Qt::WA_DeleteOnClose, true);
|
||||
connect(getRollupContents(), SIGNAL(widgetRolled(QWidget*,bool)), this, SLOT(onWidgetRolled(QWidget*,bool)));
|
||||
m_helpURL = "plugins/channeltx/moddatv/readme.md";
|
||||
RollupContents *rollupContents = getRollupContents();
|
||||
ui->setupUi(rollupContents);
|
||||
setSizePolicy(rollupContents->sizePolicy());
|
||||
rollupContents->arrangeRollups();
|
||||
connect(rollupContents, SIGNAL(widgetRolled(QWidget*,bool)), this, SLOT(onWidgetRolled(QWidget*,bool)));
|
||||
connect(this, SIGNAL(customContextMenuRequested(const QPoint &)), this, SLOT(onMenuDialogCalled(const QPoint &)));
|
||||
|
||||
m_datvMod = (DATVMod*) channelTx;
|
||||
@@ -150,6 +153,14 @@ bool DATVModGUI::deserialize(const QByteArray& data)
|
||||
}
|
||||
}
|
||||
|
||||
void DATVModGUI::resizeEvent(QResizeEvent* size)
|
||||
{
|
||||
int maxWidth = getRollupContents()->maximumWidth();
|
||||
int minHeight = getRollupContents()->minimumHeight() + getAdditionalHeight();
|
||||
resize(width() < maxWidth ? width() : maxWidth, minHeight);
|
||||
size->accept();
|
||||
}
|
||||
|
||||
bool DATVModGUI::handleMessage(const Message& message)
|
||||
{
|
||||
if (DATVModReport::MsgReportTsFileSourceStreamData::match(message))
|
||||
|
||||
Reference in New Issue
Block a user