X-Git-Url: http://git.euphorik.ch/?p=euphorik.git;a=blobdiff_plain;f=js%2FpageAdmin.js;h=04b642c3e7b7689898658b1a0befb8962abdfeef;hp=2a6cbc18bb1758b4df6c9d7d29b1da5c60aad523;hb=3a3ceb24e4a4f3bbec9ec72c945b0cf1bb1ef1a6;hpb=cdff108e3b859493cff8e3f37fc8b52cb20d75d5 diff --git a/js/pageAdmin.js b/js/pageAdmin.js index 2a6cbc1..04b642c 100644 --- a/js/pageAdmin.js +++ b/js/pageAdmin.js @@ -28,7 +28,7 @@ euphorik.PageAdmin = function(client, formateur, util) { this.formateur = formateur; this.util = util; - this.pageEvent = new euphorik.PageEvent("admin", this.util); + this.comet = new Comet("admin", euphorik.conf.versionProtocole); // le timer qui rappelle periodiquement le rafraichissement des IP bannies this.timeoutIDmajIPs = null; @@ -80,7 +80,7 @@ euphorik.PageAdmin.prototype.charger = function() { * Interface des pages. */ euphorik.PageAdmin.prototype.decharger = function() { - this.pageEvent.stopAttenteCourante(); + this.comet.stopAttenteCourante(); // supprime le rafraichissement période des ips if (this.timeoutIDmajIPs) { @@ -224,7 +224,7 @@ euphorik.PageAdmin.prototype.deban = function(ip) { euphorik.PageAdmin.prototype.waitEvent = function() { var thisPageAdmin = this; - this.pageEvent.waitEvent( + this.comet.waitEvent( function() { return { "last_troll" : thisPageAdmin.trolls.dernierTroll }; }, { "troll_added" : function(data){ thisPageAdmin.trolls.ajouterTrollEvent(data); }, @@ -368,7 +368,7 @@ Trolls.prototype.modifier = function(id, content) { data: this.util.jsonVersAction(dataToSend), success: function(data) { - if (data.reply == "error") { + if (data.reply === "error") { thisTrolls.util.messageDialogue(data.error_message); } }