Fully compilable for Qt 6, removed some obsolete code.
This commit is contained in:
parent
1af029458a
commit
37db4d84ec
@ -12,10 +12,7 @@
|
||||
DynamicShortcutsWidget::DynamicShortcutsWidget(QWidget* parent) : QWidget(parent) {
|
||||
// Create layout for this control and set is as active.
|
||||
m_layout = new QGridLayout(this);
|
||||
|
||||
#if QT_VERSION_MAJOR <= 5
|
||||
m_layout->setMargin(0);
|
||||
#endif
|
||||
m_layout->setContentsMargins({});
|
||||
|
||||
setLayout(m_layout);
|
||||
}
|
||||
|
@ -13,10 +13,7 @@ ShortcutCatcher::ShortcutCatcher(QWidget* parent)
|
||||
// Setup layout of the control
|
||||
m_layout = new QHBoxLayout(this);
|
||||
|
||||
#if QT_VERSION_MAJOR <= 5
|
||||
m_layout->setMargin(0);
|
||||
#endif
|
||||
|
||||
m_layout->setContentsMargins({});
|
||||
m_layout->setSpacing(1);
|
||||
|
||||
// Create reset button.
|
||||
|
@ -259,11 +259,9 @@ void FeedMessageViewer::initializeViews() {
|
||||
auto* message_layout = new QVBoxLayout(m_messagesWidget);
|
||||
|
||||
// Set layout properties.
|
||||
#if QT_VERSION_MAJOR <= 5
|
||||
central_layout->setMargin(0);
|
||||
feed_layout->setMargin(0);
|
||||
message_layout->setMargin(0);
|
||||
#endif
|
||||
central_layout->setContentsMargins({});
|
||||
feed_layout->setContentsMargins({});
|
||||
message_layout->setContentsMargins({});
|
||||
|
||||
central_layout->setSpacing(0);
|
||||
feed_layout->setSpacing(0);
|
||||
|
@ -19,12 +19,10 @@ WidgetWithStatus::WidgetWithStatus(QWidget* parent)
|
||||
m_iconOk = qApp->icons()->fromTheme(QSL("dialog-yes"));
|
||||
|
||||
// Set layout properties.
|
||||
#if QT_VERSION_MAJOR <= 5
|
||||
m_layout->setMargin(0);
|
||||
#endif
|
||||
m_layout->setContentsMargins({});
|
||||
|
||||
setLayout(m_layout);
|
||||
setStatus(StatusType::Information, QString());
|
||||
setStatus(StatusType::Information, {});
|
||||
}
|
||||
|
||||
void WidgetWithStatus::setStatus(WidgetWithStatus::StatusType status, const QString& tooltip_text) {
|
||||
|
@ -19,11 +19,7 @@ EmailRecipientControl::EmailRecipientControl(const QString& recipient, QWidget*
|
||||
lay->addWidget(m_txtRecipient = new QLineEdit(this), 1);
|
||||
lay->addWidget(m_btnCloseMe = new PlainToolButton(this));
|
||||
|
||||
#if QT_VERSION_MAJOR <= 5
|
||||
lay->setMargin(0);
|
||||
#endif
|
||||
|
||||
lay->setContentsMargins(0, 0, 0, 0);
|
||||
lay->setContentsMargins({});
|
||||
|
||||
m_cmbRecipientType->setFocusPolicy(Qt::FocusPolicy::NoFocus);
|
||||
m_btnCloseMe->setFocusPolicy(Qt::FocusPolicy::NoFocus);
|
||||
|
@ -23,11 +23,7 @@ FormAddEditEmail::FormAddEditEmail(GmailServiceRoot* root, QWidget* parent)
|
||||
|
||||
GuiUtilities::applyDialogProperties(*this, qApp->icons()->fromTheme(QSL("mail-message-new")));
|
||||
|
||||
#if QT_VERSION_MAJOR <= 5
|
||||
m_ui.m_layoutAdder->setMargin(0);
|
||||
#endif
|
||||
|
||||
m_ui.m_layoutAdder->setContentsMargins(0, 0, 0, 0);
|
||||
m_ui.m_layoutAdder->setContentsMargins({});
|
||||
|
||||
m_ui.m_btnAdder->setIcon(qApp->icons()->fromTheme(QSL("list-add")));
|
||||
m_ui.m_btnAdder->setToolTip(tr("Add new recipient."));
|
||||
|
Loading…
x
Reference in New Issue
Block a user