$=jQuery jQuery(document).ready(function(){var myEvents={click:function(e){if(jQuery(this).hasClass('menu-item-has-children')){jQuery(this).find('.mean-expand').addClass('mean-clicked').text('-');} jQuery(this).siblings('li').find('.mean-expand').removeClass('mean-clicked').text('+');jQuery(this).children('.sub-menu').show().end().siblings('li').find('ul').hide();},keydown:function(e){stoppropagation();if(keycode==9){if(!shiftkey&&(jQuery('.mean-bar li').index(jQuery(this))==(jQuery('.mean-bar li').length-1))){jQuery('.meanclose').trigger('click');}else if(jQuery('.mean-bar li').index(jQuery(this))==0){$('.meanclose').removeClass('onfocus');} else if(shiftkey&&jQuery('.mean-bar li').index(jQuery(this))===0) jQuery('.mean-bar ul:first > li:last').focus().blur();}},keyup:function(e){stoppropagation();if(keycode==9){if(cancelkeyup)cancelkeyup=false;else apply(this,arguments);}}} jQuery(document).on('click','li',click).on('keydown','li',keydown).on('keyup','li',keyup);jQuery('.mean-bar li').each(function(i){tabindex=i;});jQuery('.search-box-wrap form').on('focusout',function(){var $elem=jQuery(this);setTimeout(function(){if(!$find(':focus').length){jQuery('.search-container .search-toggle').trigger('click');jQuery('.search-container .search-toggle').focus();}},0);});jQuery(document).on('click','.search-container .search-toggle',function(){$(this).closest('.search-container').toggleClass('search-active');});});