clamp to parent height, not parent y co-ordinate.
authorDerek Foreman <derekf@osg.samsung.com>
Thu, 26 Feb 2015 20:27:52 +0000 (15:27 -0500)
committerMike Blumenkrantz <zmike@osg.samsung.com>
Thu, 26 Feb 2015 20:27:52 +0000 (15:27 -0500)
Summary:
Clamping to Y makes pop ups get shifted up if a window is
near the top of the screen.

Reviewers: devilhorns, zmike

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D2060

src/modules/wl_desktop_shell/e_mod_main.c

index 4ac59c0..a70267a 100644 (file)
@@ -1318,7 +1318,7 @@ _e_xdg_shell_cb_popup_get(struct wl_client *client, struct wl_resource *resource
    if (ec->parent)
      {
         cdata->popup.x = E_CLAMP(x, 0, ec->parent->client.w);
-        cdata->popup.y = E_CLAMP(y, 0, ec->parent->client.y);
+        cdata->popup.y = E_CLAMP(y, 0, ec->parent->client.h);
      }
    else
      {