From f1756dd1413fa602f536e057087583be2ddbd2b2 Mon Sep 17 00:00:00 2001 From: Alexander Lohnau Date: Thu, 11 Nov 2021 20:51:00 +0100 Subject: [PATCH] Port deprecated QLayout::margin call As the method impl suggests, the left value is preferred if all the values are the same. This is the case for the given layout. ```cpp int QLayout::margin() const { int left, top, right, bottom; getContentsMargins(&left, &top, &right, &bottom); if (left == top && top == right && right == bottom) { return left; } else { return -1; } } ``` --- src/views/tooltips/dolphinfilemetadatawidget.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/views/tooltips/dolphinfilemetadatawidget.cpp b/src/views/tooltips/dolphinfilemetadatawidget.cpp index b147135bf..e914593fb 100644 --- a/src/views/tooltips/dolphinfilemetadatawidget.cpp +++ b/src/views/tooltips/dolphinfilemetadatawidget.cpp @@ -66,7 +66,7 @@ DolphinFileMetaDataWidget::DolphinFileMetaDataWidget(QWidget* parent) : QHBoxLayout* layout = new QHBoxLayout(this); layout->addWidget(m_preview); - layout->addSpacing(layout->margin()); + layout->addSpacing(layout->contentsMargins().left()); layout->addLayout(textLayout); } -- 2.47.3