text: /*	
   * jQuery mmenu dragOpen addon
   * @requires mmenu 4.0.0 or later
   *
   * mmenu.frebsite.nl
   *	
   * Copyright (c) Fred Heusschen
   * www.frebsite.nl
   *
   * Dual licensed under the MIT and GPL licenses.
   * http://en.wikipedia.org/wiki/MIT_License
   * http://en.wikipedia.org/wiki/GNU_General_Public_License
   */
  !function(e){function t(e,t,a){return t>e&&(e=t),e>a&&(e=a),e}var a="mmenu",o="dragOpen";e[a].prototype["_addon_"+o]=function(){var n=this,r=this.opts[o];if(e.fn.hammer){var d=e[a]._c,i=(e[a]._d,e[a]._e);d.add("dragging"),i.add("dragleft dragright dragup dragdown dragend");var s=e[a].glbl;if("boolean"==typeof r&&(r={open:r}),"object"!=typeof r&&(r={}),"number"!=typeof r.maxStartPos&&(r.maxStartPos="left"==this.opts.position||"right"==this.opts.position?150:50),r=e.extend(!0,{},e[a].defaults[o],r),r.open){var g=0,p=!1,c=0,h=0,l="width";switch(this.opts.position){case"left":case"right":l="width";break;default:l="height"}switch(this.opts.position){case"left":var u={events:i.dragleft+" "+i.dragright,open_dir:"right",close_dir:"left",delta:"deltaX",page:"pageX",negative:!1};break;case"right":var u={events:i.dragleft+" "+i.dragright,open_dir:"left",close_dir:"right",delta:"deltaX",page:"pageX",negative:!0};break;case"top":var u={events:i.dragup+" "+i.dragdown,open_dir:"down",close_dir:"up",delta:"deltaY",page:"pageY",negative:!1};break;case"bottom":var u={events:i.dragup+" "+i.dragdown,open_dir:"up",close_dir:"down",delta:"deltaY",page:"pageY",negative:!0}}$dragNode=this.__valueOrFn(r.pageNode,this.$menu,s.$page),"string"==typeof $dragNode&&($dragNode=e($dragNode)),$dragNode.hammer().on(i.touchstart+" "+i.mousedown,function(e){if("touchstart"==e.type)var t=e.originalEvent.touches[0]||e.originalEvent.changedTouches[0],a=t[u.page];else if("mousedown"==e.type)var a=e[u.page];switch(n.opts.position){case"right":case"bottom":a>=s.$wndw[l]()-r.maxStartPos&&(g=1);break;default:a<=r.maxStartPos&&(g=1)}}).on(u.events+" "+i.dragend,function(e){g>0&&(e.gesture.preventDefault(),e.stopPropagation())}).on(u.events,function(e){var a=u.negative?-e.gesture[u.delta]:e.gesture[u.delta];if(p=a>c?u.open_dir:u.close_dir,c=a,c>r.threshold&&1==g){if(s.$html.hasClass(d.opened))return;g=2,n._openSetup(),s.$html.addClass(d.dragging),h=t(s.$wndw[l]()*n.conf[o][l].perc,n.conf[o][l].min,n.conf[o][l].max)}if(2==g){var i=s.$page;switch(n.opts.zposition){case"front":i=n.$menu;break;case"next":i=i.add(n.$menu)}i.css(n.opts.position,t(c,10,h))}}).on(i.dragend,function(){if(2==g){var e=s.$page;switch(n.opts.zposition){case"front":e=n.$menu;break;case"next":e=e.add(n.$menu)}s.$html.removeClass(d.dragging),e.css(n.opts.position,""),p==u.open_dir?n._openFinish():n.close()}g=0})}}},e[a].defaults[o]={open:!1,threshold:50},e[a].configuration[o]={width:{perc:.8,min:140,max:440},height:{perc:.8,min:140,max:880}},e[a].addons=e[a].addons||[],e[a].addons.push(o)}(jQuery);