X-Git-Url: http://git.euphorik.ch/?p=euphorik.git;a=blobdiff_plain;f=js%2Feuphorik.js;h=d040dc3d5fcaceb368d0c5a4961123803c078b4f;hp=8aaf875f088c5b6a6cf8f7bb315002ef9a0639ac;hb=3ea00589df90388456e8587b1bebdeab0f7e99fa;hpb=d547231312e9e9c2f2c055673e0186334bbb67fd diff --git a/js/euphorik.js b/js/euphorik.js index 8aaf875..d040dc3 100755 --- a/js/euphorik.js +++ b/js/euphorik.js @@ -74,6 +74,8 @@ function Util() }) } +var messageType = {informatif: 0, question: 1, erreur: 2} + /** * Affiche une boite de dialogue avec un message à l'intérieur. * @param message le message (string) @@ -105,9 +107,7 @@ Util.prototype.messageDialogue = function(message, type, boutons) $("#info").slideDown(200) this.timeoutMessageDialogue = setTimeout(fermer, conf.tempsAffichageMessageDialogue) -} - -var messageType = {informatif: 0, question: 1, erreur: 2} +} /** * Utilisé pour l'envoie de donnée avec la méthode ajax de jQuery. @@ -282,6 +282,11 @@ Formateur.prototype.getSmilesHTML = function() return XHTML } +/** + * Formatage complet d'un texte. + * @M le message + * @pseudo facultatif, permet de contruire le label des images sous la forme : " : " + */ Formateur.prototype.traitementComplet = function(M, pseudo) { return this.traiterLiensConv(this.traiterSmiles(this.traiterURL(this.remplacerBalisesHTML(M), pseudo))) @@ -327,9 +332,6 @@ Formateur.prototype.remplacerBalisesHTML = function(M) Formateur.prototype.traiterURL = function(M, pseudo) { thisFormateur = this - - if (pseudo == undefined) - pseudo = "" var traitementUrl = function(url) { @@ -337,7 +339,7 @@ Formateur.prototype.traiterURL = function(M, pseudo) if (!thisFormateur.regexTestProtocoleExiste.test(url)) url = "http://" + url var extension = thisFormateur.getShort(url) - return "[" + extension[0] + "]" + return "[" + extension[0] + "]" } return M.replace(this.regexUrl, traitementUrl) } @@ -418,7 +420,8 @@ function Client(util) } Client.prototype.resetDonneesPersonnelles = function() -{ +{ + this.id = 0 this.pseudo = conf.pseudoDefaut this.login = "" this.password = "" @@ -690,7 +693,8 @@ Client.prototype.chargerDonnees = function(data) { this.cookie = data["cookie"] this.setCookie() - + + this.id = data["id"] this.login = data["login"] this.pseudo = data["nick"] this.email = data["email"]