popupMenu: Don't slide menus when we're changing them

As calling close() will drop the grab, we were inadverdently
re-closing menus, causing them to re-animate with a full animation.

https://bugzilla.gnome.org/show_bug.cgi?id=689954
This commit is contained in:
Jasper St. Pierre
2012-12-10 03:55:14 -05:00
parent ca2ee22827
commit b42af9aa99
2 changed files with 13 additions and 8 deletions

View File

@ -2173,7 +2173,11 @@ const PopupMenuManager = new Lang.Class({
return -1;
},
_closeMenu: function(menu) {
menu.close(BoxPointer.PopupAnimation.FULL);
_closeMenu: function(isUser, menu) {
// If this isn't a user action, we called close()
// on the BoxPointer ourselves, so we shouldn't
// reanimate.
if (isUser)
menu.close(BoxPointer.PopupAnimation.FULL);
}
});