Utils: Make the second parameter to LayoutBuilder::attach() an enum

More explicit and more potential options (e.g. "treat grid as form")
than a bool.

Change-Id: I89413efe30410160c38b0e524ba64288dde2332e
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
This commit is contained in:
hjk
2022-07-26 11:35:19 +02:00
parent b883a096ff
commit b97c495d2b
21 changed files with 42 additions and 37 deletions

View File

@@ -45,6 +45,8 @@
#include <QRegularExpression>
#include <QUuid>
using namespace Utils;
namespace GitLab {
static bool hostValid(const QString &host)
@@ -92,7 +94,7 @@ GitLabServerWidget::GitLabServerWidget(Mode m, QWidget *parent)
m_secure.setDefaultValue(true);
m_secure.setEnabled(m == Edit);
using namespace Utils::Layouting;
using namespace Layouting;
Row {
Form {
@@ -102,7 +104,7 @@ GitLabServerWidget::GitLabServerWidget(Mode m, QWidget *parent)
m_port,
m_secure
},
}.attachTo(this, m == Edit);
}.attachTo(this, m == Edit ? WithMargins : WithoutMargins);
}
GitLabServer GitLabServerWidget::gitLabServer() const