Subversion Repositories eFlore/Applications.del

Rev

Rev 1953 | Rev 2056 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 1953 Rev 2050
Line 1... Line 1...
1
package org.tela_botanica.del.client.utils;
1
package org.tela_botanica.del.client.utils;
Line -... Line 2...
-
 
2
 
-
 
3
import org.tela_botanica.del.client.i18n.I18n;
2
 
4
 
Line 3... Line 5...
3
import com.google.gwt.i18n.client.NumberFormat;
5
import com.google.gwt.i18n.client.NumberFormat;
Line 4... Line 6...
4
 
6
 
Line 44... Line 46...
44
	    	patternNb.insert(0, 0);
46
	    	patternNb.insert(0, 0);
45
	    }
47
	    }
Line 46... Line 48...
46
	    
48
	    
47
	    return NumberFormat.getFormat(patternNb.toString()).format(valeur);
49
	    return NumberFormat.getFormat(patternNb.toString()).format(valeur);
-
 
50
	}
-
 
51
	
-
 
52
	public static String getCorrespondanceChaineEvenementObs(String evenement, int nb) {
-
 
53
		String trad = "";
-
 
54
		
-
 
55
		// Arghhhh pourquoi on ne peut pas faire de switch sur une string !!!!!!
-
 
56
		// arggh arrrghghhhhhh
-
 
57
		if(evenement.equals("nouveau_vote")) {
-
 
58
			trad = nb > 1 ? I18n.getMessages().nouveauxVotes(nb+"") : I18n.getVocabulary().nouveauVote();
-
 
59
		}
-
 
60
		
-
 
61
		if(evenement.equals("nouveau_commentaire")) {
-
 
62
			trad = nb > 1 ? I18n.getMessages().nouveauxCommentaires(nb+"") : I18n.getVocabulary().nouveauCommentaire();
-
 
63
		}
-
 
64
			
-
 
65
		if(evenement.equals("nouvelle_observation")) {
-
 
66
			trad = I18n.getVocabulary().nouvelleObservation();
-
 
67
		}
-
 
68
		
-
 
69
		if(evenement.equals("nouveau_commentaire_vous_a_obs_autre")) {
-
 
70
			trad = I18n.getVocabulary().nouveauCommentaireVousAObsAutre();
-
 
71
		}
-
 
72
		
-
 
73
		if(evenement.equals("nouveau_commentaire_autre_sur_obs_vous")) {
-
 
74
			trad = I18n.getVocabulary().nouveauCommentaireAutreSurObsVous();
-
 
75
		}
-
 
76
		
-
 
77
		if(evenement.equals("nouvelle_proposition_vous_a_obs_autre")) {
-
 
78
			trad = I18n.getVocabulary().nouvellePropositionVousAObsAutre();
-
 
79
		}
-
 
80
		
-
 
81
		if(evenement.equals("nouvelle_proposition_autre_sur_obs_vous")) {
-
 
82
			trad = I18n.getVocabulary().nouvellePropositionAutreSurObsVous();
-
 
83
		}
-
 
84
		
-
 
85
		if(evenement.equals("nouveau_vote_vous_a_com_autre")) {
-
 
86
			trad = I18n.getVocabulary().nouveauVoteVousAComAutre();
-
 
87
		}
-
 
88
		
-
 
89
		if(evenement.equals("nouveau_vote_autre_sur_com_vous")) {
-
 
90
			trad = I18n.getVocabulary().nouveauVoteAutreSurComVous();
-
 
91
		}
-
 
92
		
-
 
93
		if(evenement.equals("nouvelle_validation_vous_a_prop_autre")) {
-
 
94
			trad = I18n.getVocabulary().nouvelleValidationVousAPropAutre();
-
 
95
		}
-
 
96
		
-
 
97
		if(evenement.equals("nouvelle_validation_autre_sur_prop_vous")) {
-
 
98
			trad = I18n.getVocabulary().nouvelleValidationAutreAPropVous();
-
 
99
		}
-
 
100
		
-
 
101
		return trad;
48
	}
102
	}