Browse Source

[FIX] use jquery api

pull/131/head
Holger Brunn 10 years ago
parent
commit
257ed3b7d4
  1. 8
      web_menu_autohide/static/src/js/web_menu_autohide.js

8
web_menu_autohide/static/src/js/web_menu_autohide.js

@ -99,9 +99,9 @@ openerp.web_menu_autohide = function(instance)
}, },
on_click: function(e) on_click: function(e)
{ {
var on_main_menu = jQuery(e.srcElement)
var on_main_menu = jQuery(e.target)
.parents('#oe_main_menu_navbar').length > 0, .parents('#oe_main_menu_navbar').length > 0,
on_left_bar = jQuery(e.srcElement)
on_left_bar = jQuery(e.target)
.parents('.oe_leftbar').length > 0; .parents('.oe_leftbar').length > 0;
if(!on_left_bar && !on_main_menu && openerp.client.leftbar_hide_timeout_id) if(!on_left_bar && !on_main_menu && openerp.client.leftbar_hide_timeout_id)
{ {
@ -112,9 +112,9 @@ openerp.web_menu_autohide = function(instance)
}, },
on_mousemove: function(e) on_mousemove: function(e)
{ {
var on_main_menu = jQuery(e.srcElement)
var on_main_menu = jQuery(e.target)
.parents('#oe_main_menu_navbar').length > 0, .parents('#oe_main_menu_navbar').length > 0,
on_left_bar = jQuery(e.srcElement)
on_left_bar = jQuery(e.target)
.parents('.oe_leftbar').length > 0; .parents('.oe_leftbar').length > 0;
if(on_left_bar && openerp.client.leftbar_hide_timeout_id) if(on_left_bar && openerp.client.leftbar_hide_timeout_id)
{ {

Loading…
Cancel
Save