web/data/cubicweb.lazy.js
author Adrien Di Mascio <Adrien.DiMascio@logilab.fr>
Fri, 22 May 2009 00:02:28 +0200
changeset 1895 bf46668f9cac
parent 559 7cfd3d11edc8
child 5658 7b9553a9db65
permissions -rw-r--r--
[javascript] include ui.slider.js (jquery plugin). NOTE: we must find a way to deal with multiple jquery plugins


function load_now(eltsel, holesel, reloadable) {
    var lazydiv = jQuery(eltsel);
    var hole = lazydiv.children(holesel);
    if ((hole.length == 0) && !reloadable) {
	/* the hole is already filled */
	return;
    }
    lazydiv.loadxhtml(lazydiv.attr('cubicweb:loadurl'));
}

function trigger_load(divid) {
    jQuery('#lazy-' + divid).trigger('load_' + divid);
}