mirror of
https://github.com/leozide/leocad
synced 2024-12-26 21:58:44 +01:00
Compile fix.
This commit is contained in:
parent
1bef9e001e
commit
0e9581efb4
1 changed files with 4 additions and 0 deletions
|
@ -798,8 +798,12 @@ void lcQPropertiesTree::slotColorButtonClicked()
|
||||||
connect(Popup, SIGNAL(selected(int)), SLOT(slotSetValue(int)));
|
connect(Popup, SIGNAL(selected(int)), SLOT(slotSetValue(int)));
|
||||||
Popup->setMinimumSize(300, 200);
|
Popup->setMinimumSize(300, 200);
|
||||||
|
|
||||||
|
#if (QT_VERSION >= QT_VERSION_CHECK(5, 10, 0))
|
||||||
QScreen* Screen = QGuiApplication::screenAt(Button->mapToGlobal(Button->rect().bottomLeft()));
|
QScreen* Screen = QGuiApplication::screenAt(Button->mapToGlobal(Button->rect().bottomLeft()));
|
||||||
const QRect ScreenRect = Screen ? Screen->geometry() : QApplication::desktop()->geometry();
|
const QRect ScreenRect = Screen ? Screen->geometry() : QApplication::desktop()->geometry();
|
||||||
|
#else
|
||||||
|
const QRect ScreenRect = QApplication::desktop()->geometry();
|
||||||
|
#endif
|
||||||
|
|
||||||
QPoint pos = Button->mapToGlobal(Button->rect().bottomLeft());
|
QPoint pos = Button->mapToGlobal(Button->rect().bottomLeft());
|
||||||
if (pos.x() < ScreenRect.left())
|
if (pos.x() < ScreenRect.left())
|
||||||
|
|
Loading…
Reference in a new issue