From 1bde7b1deafaa43943c411707676225533b8e792 Mon Sep 17 00:00:00 2001 From: Xawotihs Date: Fri, 5 Nov 2010 07:20:01 +0000 Subject: [PATCH] Make it at least compile ... --- JGE/src/Qtmain.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/JGE/src/Qtmain.cpp b/JGE/src/Qtmain.cpp index bda570d94..31de1865f 100644 --- a/JGE/src/Qtmain.cpp +++ b/JGE/src/Qtmain.cpp @@ -358,6 +358,9 @@ void JGEQtRenderer::mouseMoveEvent(QMouseEvent *event) { // this is intended to convert window coordinate into game coordinate. // this is correct only if the game and window have the same aspect ratio, otherwise, it's just wrong + int actualWidth = (int) JRenderer::GetInstance()->GetActualWidth(); + int actualHeight = (int) JRenderer::GetInstance()->GetActualHeight(); + g_engine->LeftClicked((event->pos().x()*SCREEN_WIDTH)/actualWidth, (event->pos().y()*SCREEN_HEIGHT)/actualHeight); event->accept(); }