X-Git-Url: http://git.euphorik.ch/?p=euphorik.git;a=blobdiff_plain;f=js%2FpageMinichat.js;fp=js%2FpageMinichat.js;h=0aa2142271c341e19441ef30d4098e6638f65829;hp=f4faa02071c3eade7fb151412877e98558af04a2;hb=beb0e9617b60e39a0493926a563574bb9cd9765b;hpb=bb56b61b6b93b3fd69f2b3bfabf3fcb2e31e6ee7 diff --git a/js/pageMinichat.js b/js/pageMinichat.js index f4faa02..0aa2142 100755 --- a/js/pageMinichat.js +++ b/js/pageMinichat.js @@ -380,6 +380,16 @@ Conversation.prototype.enleverMiseEnEvidence = function() $("#conversations .message").removeClass("cache") } +Conversation.prototype.colorerEntetes = function() +{ + +} + +Conversation.prototype.decolorerEntetes = function() +{ + +} + /** * Défini la page courante et s'il l'on se trouve sur la dernière page. * @pageCourante la page courante @@ -918,18 +928,10 @@ Messages.prototype.rafraichirMessages = function(vider) this.pageEvent.waitEvent( function() { return thisMessages.getJSONrafraichirMessages() }, - function(data) - { - if (vider) - { - thisMessages.viderMessages() - vider = false - } - - // en fonction du message - switch(data["reply"]) - { - case "new_troll" : + { + "new_troll" : + function(data) + { thisMessages.trollIdCourant = data["troll_id"] $("#trollCourant .troll").html(thisMessages.formateur.traitementComplet(data["content"])).unbind("click").click( function() @@ -939,9 +941,15 @@ Messages.prototype.rafraichirMessages = function(vider) ) $("#trollCourant .troll a[@rel*=lightbox]").lightBox() - break - - case "new_messages" : + }, + "new_messages" : + function(data) + { + if (vider) + { + thisMessages.viderMessages() + vider = false + } // ajoute les messages reçus à leur conversation respective for (var numConv = 0; numConv < data["conversations"].length; numConv++) { @@ -951,8 +959,7 @@ Messages.prototype.rafraichirMessages = function(vider) thisMessages.client.supprimerConversation(numConv - 1) } } - break - } + } } ) }