]> git.saurik.com Git - veency.git/blobdiff - Tweak.mm
Solve issues determining client window on retina displays.
[veency.git] / Tweak.mm
index 8c86455cef38eb7cec1b7af02e4c9227c4ababa6..5902a7823b969a2f40a9fdf5a908b2f262cc802b 100644 (file)
--- a/Tweak.mm
+++ b/Tweak.mm
@@ -306,11 +306,12 @@ static bool iPad1_;
 static void VNCPointer(int buttons, int x, int y, rfbClientPtr client) {
     if (ratio_ == 0)
         return;
 static void VNCPointer(int buttons, int x, int y, rfbClientPtr client) {
     if (ratio_ == 0)
         return;
-    x /= ratio_;
-    y /= ratio_;
 
     CGPoint location = {x, y};
 
 
     CGPoint location = {x, y};
 
+    x /= ratio_;
+    y /= ratio_;
+
     if (width_ > height_) {
         int t(x);
         x = height_ / ratio_ - 1 - y;
     if (width_ > height_) {
         int t(x);
         x = height_ / ratio_ - 1 - y;