bugfix: check mouse location when clicking menu items, only activate menu if mouse is inside menu when clicking

T164
This commit is contained in:
discomfitor 2013-09-20 16:00:27 +01:00
parent b8f50a95f7
commit 77b2c5a7f4
2 changed files with 14 additions and 1 deletions

View File

@ -1,3 +1,7 @@
2013-09-20 Mike Blumenkrantz
* Check mouse location when clicking menus, only activate items when clicking in the menu
2013-09-19 Mike Blumenkrantz
* Fix bug where new files could not be created repeatedly

View File

@ -2969,7 +2969,16 @@ _e_menu_cb_mouse_up(void *data __UNUSED__, int type __UNUSED__, void *event)
*/
}
else
ret = _e_menu_active_call();
{
E_Menu *m = _e_menu_active_get();
if (m && E_INSIDE(ev->root.x, ev->root.y,
m->zone->x + m->cur.x,
m->zone->y + m->cur.y,
m->zone->x + m->cur.x + m->cur.w,
m->zone->y + m->cur.y + m->cur.h))
ret = _e_menu_active_call();
}
_e_menu_activate_maybe_drag = 0;
_e_menu_activate_dragging = 0;
if (ret == 1)