/** * Class mootools qui permet de gérer un disclaimer */ var MooDisclaimer = new Class({ getOptions: function() { return {} }, initialize: function(domain, flags, texts, options) { this.setOptions(this.getOptions(), options); this.domain = domain; this.flags = flags; this.texts = texts; if(Cookie.read('disclaimer_dsp')!='hide') { this.build(); } }, centerize: function() { var body_size = $(document.body).getSize(); this.discl_el.setStyles({ 'top':((body_size.y/2)-125+window.getScrollTop())+'px', 'left':((body_size.x/2)-280+window.getScrollLeft())+'px' }); }, build: function() { var mentions_array = new Array( this.texts.disc_mention_1, this.texts.disc_mention_2, this.texts.disc_mention_3, this.texts.disc_mention_4, this.texts.disc_mention_5, this.texts.disc_mention_6, this.texts.disc_mention_7, this.texts.disc_mention_8 ); //on cree la liste ul avec les mentions var ul_el = new Element('ul'); ul_el.adopt(new Element('h1',{'html':this.texts.disc_title+' : '})); for(var i=0;i