
$(function() {
    $.extend(Base, {
        Loading: {

        showTimeout: function(options){
         if (document.getElementById('loaddiv')) {
        document.getElementById('loaddiv').className = 'load';
          setTimeout(options.calback, 50);
        }
        },

            show: function (message=null) {
                 if (document.getElementById('loaddiv')) {
                      document.getElementById('loaddiv').className = 'load';
                }
            },
            showInBlock: function (target, options) {
                 if (document.getElementById('loaddiv')) {
                     document.getElementById('loaddiv').className = 'load';
                 }
            },
            hide: function(){
                 if (document.getElementById('loaddiv')) {
                      document.getElementById('loaddiv').className = '';
                 }
            },

            _qxLoading: function (box) {

                return {

                    ver: function () {

                        console.log("Base.Loading 1.0");
                        console.log("Requiere: Base 1.0");
                    }
                }
            }
        }
    });

    $.fn.QxLoading = function () {

        var loading = this;

        return Base.Box._qxLoading(loading);
    }
    
}); 