X-Git-Url: http://git.hungrycats.org/cgi-bin/gitweb.cgi?p=xscreensaver;a=blobdiff_plain;f=OSX%2Fgrabclient-osx.m;fp=OSX%2Fgrabclient-osx.m;h=045039d3762bc9aed0d4cf2980f4c138cfd7eadf;hp=8542d12786111d6ad1d7006a729129a227369acf;hb=78add6e627ee5f10e1fa6f3852602ea5066eee5a;hpb=39809ded547bdbb08207d3e514950425215b4410 diff --git a/OSX/grabclient-osx.m b/OSX/grabclient-osx.m index 8542d127..045039d3 100644 --- a/OSX/grabclient-osx.m +++ b/OSX/grabclient-osx.m @@ -286,6 +286,8 @@ osx_grab_desktop_image (Screen *screen, Window xwindow, Drawable drawable, use it if when being compiled against the 10.5 SDK or later. */ +extern float jwxyz_scale (Window); /* jwxyzI.h */ + /* Loads an image into the Drawable, returning once the image is loaded. */ Bool @@ -307,10 +309,11 @@ osx_grab_desktop_image (Screen *screen, Window xwindow, Drawable drawable, // Grab only the rectangle of the screen underlying this window. // CGRect cgrect; + double s = jwxyz_scale (xwindow); cgrect.origin.x = window_x; cgrect.origin.y = window_y; - cgrect.size.width = xgwa.width; - cgrect.size.height = xgwa.height; + cgrect.size.width = xgwa.width / s; + cgrect.size.height = xgwa.height / s; /* If a password is required to unlock the screen, a large black window will be on top of all of the desktop windows by the time