Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/sugar/graphics
diff options
context:
space:
mode:
authorMarco Pesenti Gritti <marco@localhost.localdomain>2006-10-18 19:50:14 (GMT)
committer Marco Pesenti Gritti <marco@localhost.localdomain>2006-10-18 19:50:14 (GMT)
commite098bdf8ebfdf4a403f48479699ba767df020957 (patch)
tree5331f0752bad1823d115fa91c37504e71c294f6c /sugar/graphics
parent6c375a20f3e08f28d3a9fa6d020f71aca9b9bcd3 (diff)
Fix out of screen computation. Release 0.37
Diffstat (limited to 'sugar/graphics')
-rw-r--r--sugar/graphics/menushell.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/sugar/graphics/menushell.py b/sugar/graphics/menushell.py
index c99db00..48183e1 100644
--- a/sugar/graphics/menushell.py
+++ b/sugar/graphics/menushell.py
@@ -92,10 +92,10 @@ class MenuShell(gobject.GObject):
if x + menu_w > gtk.gdk.screen_width():
[x, y] = [left_x, left_y]
- x = min(x, gtk.gdk.screen_width())
+ x = min(x, gtk.gdk.screen_width() - menu_w)
x = max(0, x)
- y = min(y, gtk.gdk.screen_height())
+ y = min(y, gtk.gdk.screen_height() - menu_h)
y = max(0, y)
return [x, y]