Fixes for building on ubuntu
This commit is contained in:
parent
56ecceb9b3
commit
e55b6b43e3
|
@ -1 +1 @@
|
||||||
Subproject commit 9ee4e6ac6cb1fa6b7db45099ae37026db2d2c49c
|
Subproject commit 8524191df613b9149369ed8578a6c4ea3038552b
|
|
@ -281,7 +281,7 @@ bool CGizmo::TransformFromInput(const CRay& rkRay, CCamera& rCamera)
|
||||||
|
|
||||||
// Calculate normalized cursor position
|
// Calculate normalized cursor position
|
||||||
QPoint CursorPos = QCursor::pos();
|
QPoint CursorPos = QCursor::pos();
|
||||||
QRect Geom = QApplication::screenAt(CursorPos)->geometry();
|
QRect Geom = QApplication::desktop()->screenGeometry();
|
||||||
CVector2f MouseCoords(
|
CVector2f MouseCoords(
|
||||||
(((2.f * CursorPos.x()) / Geom.width()) - 1.f),
|
(((2.f * CursorPos.x()) / Geom.width()) - 1.f),
|
||||||
(1.f - ((2.f * CursorPos.y()) / Geom.height()))
|
(1.f - ((2.f * CursorPos.y()) / Geom.height()))
|
||||||
|
@ -618,8 +618,8 @@ void CGizmo::UpdateTransform()
|
||||||
|
|
||||||
void CGizmo::WrapCursor()
|
void CGizmo::WrapCursor()
|
||||||
{
|
{
|
||||||
|
QRect Geom = QApplication::desktop()->screenGeometry();
|
||||||
QPoint CursorPos = QCursor::pos();
|
QPoint CursorPos = QCursor::pos();
|
||||||
QRect Geom = QApplication::screenAt(CursorPos)->geometry();
|
|
||||||
|
|
||||||
// Horizontal
|
// Horizontal
|
||||||
if (CursorPos.x() == Geom.width() - 1)
|
if (CursorPos.x() == Geom.width() - 1)
|
||||||
|
|
Loading…
Reference in New Issue