( function( $ ) {
   $.fn.dropDownMenu = function( options ) {
      var settings = $.extend( {
         enterTimeout : 200,
         leaveTimeout : 500
      }, options );
      this.children( 'li' ).map( function() {
         var listItem = $( this );
         if( listItem.children( 'ul' ).length ) {
            listItem.addClass( 'has-submenu' ).myHoverIntent( {
               enter : {
                  delay    : settings.enterTimeout,
                  callback : function() {
                     this.addClass( 'hover' );
                  }
               },
               leave : {
                  delay    : settings.leaveTimeout,
                  callback : function() {
                     this.removeClass( 'hover' );
                  }
               }
            } );
         }
      } );
      return this;
} } ) ( jQuery );
