/**
 * FormExtras: Client-Funktionen für Forms
 * Tastendrücke, Widgets, etc
 *
 * @version     0.1
 * @author      Rs
 * @requires    jQuery 1.3.2
 * @requires    jQuery.helpBubbles.js
 *
 */

var FormExtras = {

    init: function() {
    },

    /**
     * ampel-icon
     */
    ampel : {
      handler: function(node){
        // bei Mouseover wird die Hilfsblase entweder
        // angezeigt oder ausgeblendet.
        $(node).hover(function(){
            if( $(this).data('helpBubble') ) {
              $(this).removeBubble();
            } else {
              $(this).createBubble($(this).text(), {type: 'sticky'});
            }
        },function(){
          if( $(this).data('helpBubble') ) $(this).removeBubble();
        });
      }
    }
}

