UI: Fix for Qt 6.1

This commit is contained in:
Nodir Temirkhodjaev 2023-12-21 20:14:53 +03:00
parent 26a6761a1d
commit ba170e70cb

View File

@ -3,6 +3,7 @@
#include <QActionEvent> #include <QActionEvent>
#include <QBoxLayout> #include <QBoxLayout>
#include <QCheckBox> #include <QCheckBox>
#include <QCoreApplication>
#include <QLabel> #include <QLabel>
#include <QLineEdit> #include <QLineEdit>
#include <QMenu> #include <QMenu>
@ -192,7 +193,7 @@ void ControlUtil::relayoutMenu(QMenu *menu, QAction *action)
} }
QActionEvent e(QEvent::ActionChanged, action); QActionEvent e(QEvent::ActionChanged, action);
qApp->sendEvent(menu, &e); QCoreApplication::sendEvent(menu, &e);
} }
QBoxLayout *ControlUtil::createLayoutByWidgets(const QList<QWidget *> &widgets, Qt::Orientation o) QBoxLayout *ControlUtil::createLayoutByWidgets(const QList<QWidget *> &widgets, Qt::Orientation o)