]> git.eshelyaron.com Git - emacs.git/commitdiff
(fit_to_screen): Don't put the menu off the left or top.
authorRichard M. Stallman <rms@gnu.org>
Sat, 8 Oct 1994 04:16:17 +0000 (04:16 +0000)
committerRichard M. Stallman <rms@gnu.org>
Sat, 8 Oct 1994 04:16:17 +0000 (04:16 +0000)
lwlib/xlwmenu.c

index 4b5e589538f42878bd816323ab5efda2ff8b4d8d..28a23bae6edfd19e649b28aac05c75928117ae5f 100644 (file)
@@ -750,6 +750,8 @@ fit_to_screen (mw, ws, previous_ws, horizontal_p)
        ws->x = previous_ws->x - ws->width;
       else
        ws->x = screen_width - ws->width;
+      if (ws->x < 0)
+        ws->x = 0;
     }
   if (ws->y < 0)
     ws->y = 0;
@@ -759,6 +761,8 @@ fit_to_screen (mw, ws, previous_ws, horizontal_p)
        ws->y = previous_ws->y - ws->height;
       else
        ws->y = screen_height - ws->height;
+      if (ws->y < 0) 
+        ws->y = 0;
     }
 }