[libcalamaresui] Special margins for QML view steps

If there are no surrounding panels, drop the margin around the QML on
the assumption it needs to be full screen under special circumstances.
main
Adriaan de Groot 5 years ago
parent d952faf909
commit 68aecf6a26

@ -151,6 +151,22 @@ QmlViewStep::widget()
return m_widget;
}
QSize
QmlViewStep::widgetMargins( Qt::Orientations panelSides )
{
// If any panels around it, use the standard, but if all the
// panels are hidden, like on full-screen with subsumed navigation,
// then no margins.
if ( panelSides )
{
return ViewStep::widgetMargins( panelSides );
}
else
{
return QSize( 0, 0 );
}
}
void
QmlViewStep::loadComplete()
{

@ -55,6 +55,7 @@ public:
virtual QString prettyName() const override;
virtual QWidget* widget() override;
virtual QSize widgetMargins( Qt::Orientations panelSides ) override;
virtual bool isNextEnabled() const override;
virtual bool isBackEnabled() const override;

Loading…
Cancel
Save