Core: Fix build failures and warnings

This commit is contained in:
wmayer
2024-05-07 14:08:42 +02:00
committed by wwmayer
parent c1bc3b6e9a
commit e86272fab2
3 changed files with 5 additions and 5 deletions

View File

@@ -588,7 +588,7 @@ qsizetype PythonWrapper::toEnum(PyObject* pyPtr)
#if defined (HAVE_SHIBOKEN) && defined(HAVE_PYSIDE)
return Shiboken::Enum::getValue(pyPtr);
#else
return toEnum(Py::Object(pyPtr);
return toEnum(Py::Object(pyPtr));
#endif
}

View File

@@ -809,7 +809,7 @@ bool ToolBarManager::addToolBarToArea(QObject *source, QMouseEvent *ev)
}
} else {
tbIndex = idx;
QTimer::singleShot(10, tb, [tb,this]() {
QTimer::singleShot(10, tb, [tb]() {
if (!lastArea)
return;
else {
@@ -839,7 +839,7 @@ void ToolBarManager::populateUndockMenu(QMenu *menu, ToolBarArea *area)
undockAction->setText(action->text());
undockAction->setToolTip(tooltip);
menu->addAction(undockAction);
QObject::connect(undockAction, &QAction::triggered, [area, toolbar, this]() {
QObject::connect(undockAction, &QAction::triggered, [area, toolbar]() {
if (toolbar->parentWidget() == getMainWindow()) {
return;
}
@@ -856,8 +856,9 @@ void ToolBarManager::populateUndockMenu(QMenu *menu, ToolBarArea *area)
toolbar->topLevelChanged(true);
});
};
if (area)
if (area) {
area->foreachToolBar(addMenuUndockItem);
}
else {
statusBarArea->foreachToolBar(addMenuUndockItem);
menuBarLeftArea->foreachToolBar(addMenuUndockItem);

View File

@@ -167,7 +167,6 @@ private:
int _toolBarIconSize = 0;
int _statusBarIconSize = 0;
int _menuBarIconSize = 0;
mutable bool restored = false;
};
} // namespace Gui