mirror of
https://github.com/f4exb/sdrangel.git
synced 2026-06-03 06:24:48 -04:00
Massive UI revamping (v7): Fixed sizing of feature windows. Part of #1209
This commit is contained in:
@@ -166,7 +166,18 @@ void AISGUI::onWidgetRolled(QWidget* widget, bool rollDown)
|
||||
(void) widget;
|
||||
(void) rollDown;
|
||||
|
||||
getRollupContents()->saveState(m_rollupState);
|
||||
RollupContents *rollupContents = getRollupContents();
|
||||
|
||||
if (rollupContents->hasExpandableWidgets()) {
|
||||
setSizePolicy(sizePolicy().horizontalPolicy(), QSizePolicy::Expanding);
|
||||
} else {
|
||||
setSizePolicy(sizePolicy().horizontalPolicy(), QSizePolicy::Fixed);
|
||||
}
|
||||
|
||||
int h = rollupContents->height() + getAdditionalHeight();
|
||||
resize(width(), h);
|
||||
|
||||
rollupContents->saveState(m_rollupState);
|
||||
applySettings();
|
||||
}
|
||||
|
||||
@@ -178,11 +189,14 @@ AISGUI::AISGUI(PluginAPI* pluginAPI, FeatureUISet *featureUISet, Feature *featur
|
||||
m_doApplySettings(true),
|
||||
m_lastFeatureState(0)
|
||||
{
|
||||
ui->setupUi(getRollupContents());
|
||||
getRollupContents()->arrangeRollups();
|
||||
m_helpURL = "plugins/feature/ais/readme.md";
|
||||
setAttribute(Qt::WA_DeleteOnClose, true);
|
||||
connect(getRollupContents(), SIGNAL(widgetRolled(QWidget*,bool)), this, SLOT(onWidgetRolled(QWidget*,bool)));
|
||||
m_helpURL = "plugins/feature/ais/readme.md";
|
||||
RollupContents *rollupContents = getRollupContents();
|
||||
ui->setupUi(rollupContents);
|
||||
setSizePolicy(rollupContents->sizePolicy());
|
||||
rollupContents->arrangeRollups();
|
||||
connect(rollupContents, SIGNAL(widgetRolled(QWidget*,bool)), this, SLOT(onWidgetRolled(QWidget*,bool)));
|
||||
|
||||
m_ais = reinterpret_cast<AIS*>(feature);
|
||||
m_ais->setMessageQueueToGUI(&m_inputMessageQueue);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user