Subversion Repositories eFlore/Applications.del

Compare Revisions

Ignore whitespace Rev 1861 → Rev 1862

/trunk/src/org/tela_botanica/del/client/vues/identiplante/resultats/ResultatsIdentiplanteVue.ui.xml
13,9 → 13,9
<g:HTMLPanel ui:field="zoneTri" styleName="droite {style.zoneTri} petit">
<g:Label text="{constants.tri}" styleName="gauche"/>
<g:HTMLPanel ui:field="triParDate" styleName="gauche">
<g:Label text="{constants.triParDate}" styleName="gauche {style.date}" ui:field="labelDate"/>
<g:Button title="{constants.triParDateAscendant}" ui:field="triParDateAscendant" styleName="{style.boutonTriAsc} gauche" />
<g:Button title="{constants.triParDateDescendant}" ui:field="triParDateDescendant" styleName="{style.boutonTriDesc} gauche" />
<g:Label text="{constants.triParDate}" title="{constants.triParDateObsTooltip}" styleName="gauche {style.date}" ui:field="labelDate"/>
<g:Button title="{constants.triParDateObsAscendant}" ui:field="triParDateAscendant" styleName="{style.boutonTriAsc} gauche" />
<g:Button title="{constants.triParDateObsDescendant}" ui:field="triParDateDescendant" styleName="{style.boutonTriDesc} gauche" />
</g:HTMLPanel>
</g:HTMLPanel>
</g:HTMLPanel>
/trunk/src/org/tela_botanica/del/client/vues/pictoflora/resultats/ResultatPictofloraPresenteur.java
54,9 → 54,9
 
public HasWidgets getPanneauPaginationHaut();
 
public HasClickHandlers getTriParNbVotesAscendant();
public HasClickHandlers getTriParMoyenneArithmetiqueAscendant();
 
public HasClickHandlers getTriParNbVotesDescendant();
public HasClickHandlers getTriParMoyenneArithmetiqueDescendant();
 
public HasClickHandlers getTriParPointsAscendant();
 
76,15 → 76,15
 
public HTMLPanel getImageTable();
 
public HasClickHandlers getLabelVote();
public HasClickHandlers getLabelMoyenneArithmetique();
 
public void masquerVoteAscendant();
public void masquerMoyenneArithmetiqueAscendant();
 
public void masquerVoteDescendant();
public void masquerMoyenneArithmetiqueDescendant();
 
public void afficherVoteAscendant();
public void afficherMoyenneArithmetiqueAscendant();
 
public void afficherVoteDescendant();
public void afficherMoyenneArithmetiqueDescendant();
 
public HasClickHandlers getLabelDate();
 
121,7 → 121,7
private Vue vue;
private ImageService imageService;
private final ProtocoleService protocoleService;
private ModeTri triCourantVote = ModeTri.TRI_ASCENDANT;
private ModeTri triCourantMoyenneArithmetique = ModeTri.TRI_ASCENDANT;
private ModeTri triCourantPoints = ModeTri.TRI_ASCENDANT;
private ModeTri triCourantDate = ModeTri.TRI_DESCENDANT;
private ModeTri triCourantTag = ModeTri.TRI_DESCENDANT;
137,8 → 137,8
vue.startChargement();
rechercherImagesEtCreerWidgetPagination();
gererEvenements();
vue.masquerVoteDescendant();
vue.masquerVoteAscendant();
vue.masquerMoyenneArithmetiqueDescendant();
vue.masquerMoyenneArithmetiqueAscendant();
vue.masquerDateDescendant();
vue.masquerDateAscendant();
vue.masquerTagAscendant();
151,31 → 151,30
private void initialiserAPartirInfosCache() {
InformationsRecherche infos = CacheClient.getInstance().getInformationsRechercheImage();
if(infos.getTriParDate() != ModeTri.PAS_DE_TRI) {
if (infos.getTriParDate() != ModeTri.PAS_DE_TRI) {
mettreAJourAffichageTriDate();
}
if(infos.getTriParNbVotes() != ModeTri.PAS_DE_TRI) {
mettreAJourAffichageTriVote();
if (infos.getTriParMoyenneArithmetique() != ModeTri.PAS_DE_TRI) {
mettreAJourAffichageTriMoyenneArithmetique();
}
if(infos.getTriParNbTags() != ModeTri.PAS_DE_TRI) {
if (infos.getTriParNbTags() != ModeTri.PAS_DE_TRI) {
mettreAjourAffichageTriTag();
}
}
 
public void gererEvenements() {
ClickHandler surClicTriVote = new ClickHandler() {
ClickHandler surClicTriMoyenneArithmetique = new ClickHandler() {
@Override
public void onClick(ClickEvent event) {
surClicTriVote();
surClicTriMoyenneArithmetique();
}
};
 
vue.getLabelVote().addClickHandler(surClicTriVote);
vue.getTriParNbVotesAscendant().addClickHandler(surClicTriVote);
vue.getTriParNbVotesDescendant().addClickHandler(surClicTriVote);
vue.getLabelMoyenneArithmetique().addClickHandler(surClicTriMoyenneArithmetique);
vue.getTriParMoyenneArithmetiqueAscendant().addClickHandler(surClicTriMoyenneArithmetique);
vue.getTriParMoyenneArithmetiqueDescendant().addClickHandler(surClicTriMoyenneArithmetique);
 
ClickHandler surClicTriPoints = new ClickHandler() {
@Override
214,7 → 213,7
@Override
public void onChangementProtocole(EvenementChangementProtocole event) {
InformationsRecherche informationsRechercheImages = CacheClient.getInstance().getInformationsRechercheImage();
if (informationsRechercheImages.getTriParNbVotes() != ModeTri.PAS_DE_TRI) {
if (informationsRechercheImages.getTriParMoyenneArithmetique() != ModeTri.PAS_DE_TRI) {
informationsRechercheImages.setIdProtocoleSelectionne(event.getProtocole().getId() + "");
chargerEtAfficherImagesPageEnCours();
}
223,11 → 222,12
}
 
protected void surClicTriTag() {
triCourantTag = (triCourantTag == ModeTri.TRI_ASCENDANT) ? ModeTri.TRI_DESCENDANT : ModeTri.TRI_ASCENDANT;
mettreAjourAffichageTriTag();
InformationsRecherche informationsRechercheImages = CacheClient.getInstance().getInformationsRechercheImage();
informationsRechercheImages.setTriParNbTags(triCourantTag);
informationsRechercheImages.setTriParDate(ModeTri.PAS_DE_TRI);
informationsRechercheImages.setTriParNbVotes(ModeTri.PAS_DE_TRI);
informationsRechercheImages.setTriParMoyenneArithmetique(ModeTri.PAS_DE_TRI);
informationsRechercheImages.setTriParNbPoints(ModeTri.PAS_DE_TRI);
chargerEtAfficherImagesPageEnCours();
}
235,26 → 235,25
private void mettreAjourAffichageTriTag() {
vue.masquerDateDescendant();
vue.masquerDateAscendant();
vue.masquerVoteDescendant();
vue.masquerVoteAscendant();
vue.masquerMoyenneArithmetiqueDescendant();
vue.masquerMoyenneArithmetiqueAscendant();
vue.masquerPointsAscendant();
vue.masquerPointsDescendant();
if (triCourantTag == ModeTri.TRI_ASCENDANT) {
triCourantTag = ModeTri.TRI_DESCENDANT;
vue.masquerTagDescendant();
vue.afficherTagAscendant();
} else {
vue.masquerTagAscendant();
vue.afficherTagDescendant();
} else {
triCourantTag = ModeTri.TRI_ASCENDANT;
vue.masquerTagDescendant();
vue.afficherTagAscendant();
}
}
 
public void surClicTriVote() {
mettreAJourAffichageTriVote();
public void surClicTriMoyenneArithmetique() {
triCourantMoyenneArithmetique = (triCourantMoyenneArithmetique == ModeTri.TRI_ASCENDANT) ? ModeTri.TRI_DESCENDANT : ModeTri.TRI_ASCENDANT;
mettreAJourAffichageTriMoyenneArithmetique();
InformationsRecherche informationsRechercheImages = CacheClient.getInstance().getInformationsRechercheImage();
int IdProtocole = CacheClient.getInstance().getProtocoleCourant().getId();
informationsRechercheImages.setTriParNbVotes(triCourantVote);
informationsRechercheImages.setTriParMoyenneArithmetique(triCourantMoyenneArithmetique);
informationsRechercheImages.setIdProtocoleSelectionne(IdProtocole + "");
informationsRechercheImages.setTriParDate(ModeTri.PAS_DE_TRI);
informationsRechercheImages.setTriParNbTags(ModeTri.PAS_DE_TRI);
262,7 → 261,7
chargerEtAfficherImagesPageEnCours();
}
private void mettreAJourAffichageTriVote() {
private void mettreAJourAffichageTriMoyenneArithmetique() {
vue.masquerDateDescendant();
vue.masquerDateAscendant();
vue.masquerTagAscendant();
269,18 → 268,17
vue.masquerTagDescendant();
vue.masquerPointsAscendant();
vue.masquerPointsDescendant();
if (triCourantVote == ModeTri.TRI_ASCENDANT) {
triCourantVote = ModeTri.TRI_DESCENDANT;
vue.masquerVoteAscendant();
vue.afficherVoteDescendant();
if (triCourantMoyenneArithmetique == ModeTri.TRI_ASCENDANT) {
vue.masquerMoyenneArithmetiqueDescendant();
vue.afficherMoyenneArithmetiqueAscendant();
} else {
triCourantVote = ModeTri.TRI_ASCENDANT;
vue.masquerVoteDescendant();
vue.afficherVoteAscendant();
vue.masquerMoyenneArithmetiqueAscendant();
vue.afficherMoyenneArithmetiqueDescendant();
}
}
 
public void surClicTriPoints() {
triCourantPoints = (triCourantPoints == ModeTri.TRI_ASCENDANT) ? ModeTri.TRI_DESCENDANT : ModeTri.TRI_ASCENDANT;
mettreAJourAffichageTriPoints();
InformationsRecherche informationsRechercheImages = CacheClient.getInstance().getInformationsRechercheImage();
int IdProtocole = CacheClient.getInstance().getProtocoleCourant().getId();
288,7 → 286,7
informationsRechercheImages.setIdProtocoleSelectionne(IdProtocole + "");
informationsRechercheImages.setTriParDate(ModeTri.PAS_DE_TRI);
informationsRechercheImages.setTriParNbTags(ModeTri.PAS_DE_TRI);
informationsRechercheImages.setTriParNbVotes(ModeTri.PAS_DE_TRI);
informationsRechercheImages.setTriParMoyenneArithmetique(ModeTri.PAS_DE_TRI);
chargerEtAfficherImagesPageEnCours();
}
297,24 → 295,23
vue.masquerDateAscendant();
vue.masquerTagAscendant();
vue.masquerTagDescendant();
vue.masquerVoteAscendant();
vue.masquerVoteDescendant();
vue.masquerMoyenneArithmetiqueAscendant();
vue.masquerMoyenneArithmetiqueDescendant();
if (triCourantPoints == ModeTri.TRI_ASCENDANT) {
triCourantPoints = ModeTri.TRI_DESCENDANT;
vue.masquerPointsDescendant();
vue.afficherPointsAscendant();
} else {
vue.masquerPointsAscendant();
vue.afficherPointsDescendant();
} else {
triCourantPoints = ModeTri.TRI_ASCENDANT;
vue.masquerPointsDescendant();
vue.afficherPointsAscendant();
}
}
 
public void surClicTriDate() {
triCourantDate = (triCourantDate == ModeTri.TRI_ASCENDANT) ? ModeTri.TRI_DESCENDANT : ModeTri.TRI_ASCENDANT;
mettreAJourAffichageTriDate();
InformationsRecherche informationsRechercheImages = CacheClient.getInstance().getInformationsRechercheImage();
informationsRechercheImages.setTriParDate(triCourantDate);
informationsRechercheImages.setTriParNbVotes(ModeTri.PAS_DE_TRI);
informationsRechercheImages.setTriParMoyenneArithmetique(ModeTri.PAS_DE_TRI);
informationsRechercheImages.setTriParNbTags(ModeTri.PAS_DE_TRI);
informationsRechercheImages.setTriParNbPoints(ModeTri.PAS_DE_TRI);
chargerEtAfficherImagesPageEnCours();
323,18 → 320,16
private void mettreAJourAffichageTriDate() {
vue.masquerTagAscendant();
vue.masquerTagDescendant();
vue.masquerVoteDescendant();
vue.masquerVoteAscendant();
vue.masquerMoyenneArithmetiqueDescendant();
vue.masquerMoyenneArithmetiqueAscendant();
vue.masquerPointsAscendant();
vue.masquerPointsDescendant();
if (triCourantDate == ModeTri.TRI_ASCENDANT) {
triCourantDate = ModeTri.TRI_DESCENDANT;
vue.masquerDateDescendant();
vue.afficherDateAscendant();
} else {
vue.masquerDateAscendant();
vue.afficherDateDescendant();
} else {
triCourantDate = ModeTri.TRI_ASCENDANT;
vue.masquerDateDescendant();
vue.afficherDateAscendant();
}
}
 
/trunk/src/org/tela_botanica/del/client/vues/pictoflora/resultats/ResultatPictofloraVue.java
37,13 → 37,13
HTMLPanel imageTable;
 
@UiField
Button triParNbVotesAscendant, triParNbVotesDescendant, triParDateAscendant, triParDateDescendant, triParNbTagsAscendant, triParNbTagsDescendant, triParPointsAscendant, triParPointsDescendant;
Button triParMoyenneArithmetiqueAscendant, triParMoyenneArithmetiqueDescendant, triParDateAscendant, triParDateDescendant, triParNbTagsAscendant, triParNbTagsDescendant, triParPointsAscendant, triParPointsDescendant;
 
@UiField
Label aucunResultat;
@UiField
Label labelVote, labelDate, labelTag, labelPoints;
Label labelMoyenneArithmetique, labelDate, labelTag, labelPoints;
// Constructeur
61,7 → 61,6
}
 
public void creerPanneauxObservations(int taille) {
 
panneauxImages.clear();
for (int i = 0; i < taille; i++) {
Panel imagePanel = new HTMLPanel("");
125,12 → 124,12
return panneauxImages;
}
 
public Button getTriParNbVotesAscendant() {
return triParNbVotesAscendant;
public Button getTriParMoyenneArithmetiqueAscendant() {
return triParMoyenneArithmetiqueAscendant;
}
 
public Button getTriParNbVotesDescendant() {
return triParNbVotesDescendant;
public Button getTriParMoyenneArithmetiqueDescendant() {
return triParMoyenneArithmetiqueDescendant;
}
 
public Button getTriParDateAscendant() {
151,28 → 150,28
 
@Override
public Label getLabelVote() {
return labelVote;
public Label getLabelMoyenneArithmetique() {
return labelMoyenneArithmetique;
}
 
@Override
public void masquerVoteAscendant() {
triParNbVotesAscendant.setVisible(false);
public void masquerMoyenneArithmetiqueAscendant() {
triParMoyenneArithmetiqueAscendant.setVisible(false);
}
@Override
public void masquerVoteDescendant() {
triParNbVotesDescendant.setVisible(false);
public void masquerMoyenneArithmetiqueDescendant() {
triParMoyenneArithmetiqueDescendant.setVisible(false);
}
@Override
public void afficherVoteAscendant() {
triParNbVotesAscendant.setVisible(true);
public void afficherMoyenneArithmetiqueAscendant() {
triParMoyenneArithmetiqueAscendant.setVisible(true);
}
@Override
public void afficherVoteDescendant() {
triParNbVotesDescendant.setVisible(true);
public void afficherMoyenneArithmetiqueDescendant() {
triParMoyenneArithmetiqueDescendant.setVisible(true);
}
 
@Override
/trunk/src/org/tela_botanica/del/client/vues/pictoflora/resultats/ResultatPictoflora.css
8,24 → 8,12
padding-bottom: 20px
}
 
.votes {
.moyenneArithmetique, .points, .date, .tag {
padding-left: 10px;
padding-top: 3px;
cursor: pointer;
}
 
.date {
padding-left: 10px;
padding-top: 3px;
cursor: pointer;
}
 
.tag {
padding-left: 10px;
padding-top: 3px;
cursor: pointer;
}
 
.zoneTri {
padding-left: 10px;
float: right;
/trunk/src/org/tela_botanica/del/client/vues/pictoflora/resultats/ResultatPictofloraVue.ui.xml
14,23 → 14,23
<g:HTMLPanel ui:field="zoneTri" styleName="gauche {style.zoneTri} petit">
<g:Label text="{constants.tri}" styleName="gauche {style.labeltri}"/>
<g:HTMLPanel ui:field="triParNbVotes" styleName="gauche">
<g:Label text="{constants.triParNbVotes}" styleName="gauche {style.votes}" ui:field="labelVote"/>
<g:Button title="{constants.triParNbVotesAscendant}" ui:field="triParNbVotesAscendant" styleName="{style.boutonTriAsc} gauche" />
<g:Button title="{constants.triParNbVotesDescendant}" ui:field="triParNbVotesDescendant" styleName="{style.boutonTriDesc} gauche" />
<g:HTMLPanel ui:field="triParDate" styleName="gauche">
<g:Label text="{constants.triParDate}" title="{constants.triParDateTooltip}" styleName="gauche {style.date}" ui:field="labelDate"/>
<g:Button title="{constants.triParDateAscendant}" ui:field="triParDateAscendant" styleName="{style.boutonTriAsc} gauche" />
<g:Button title="{constants.triParDateDescendant}" ui:field="triParDateDescendant" styleName="{style.boutonTriDesc} gauche" />
</g:HTMLPanel>
<g:HTMLPanel ui:field="triParMoyenneArithmetique" styleName="gauche">
<g:Label text="{constants.triParMoyenneArithmetique}" title="{constants.triParMoyenneArithmetiqueTooltip}" styleName="gauche {style.moyenneArithmetique}" ui:field="labelMoyenneArithmetique"/>
<g:Button title="{constants.triParMoyenneArithmetiqueAscendant}" ui:field="triParMoyenneArithmetiqueAscendant" styleName="{style.boutonTriAsc} gauche" />
<g:Button title="{constants.triParMoyenneArithmetiqueDescendant}" ui:field="triParMoyenneArithmetiqueDescendant" styleName="{style.boutonTriDesc} gauche" />
</g:HTMLPanel>
<g:HTMLPanel ui:field="triParPoints" styleName="gauche">
<g:Label text="{constants.triParNbPoints}" styleName="gauche {style.votes}" ui:field="labelPoints"/>
<g:Label text="{constants.triParNbPoints}" title="{constants.triParNbPointsTooltip}" styleName="gauche {style.points}" ui:field="labelPoints"/>
<g:Button title="{constants.triParNbPointsAscendant}" ui:field="triParPointsAscendant" styleName="{style.boutonTriAsc} gauche" />
<g:Button title="{constants.triParNbPointsDescendant}" ui:field="triParPointsDescendant" styleName="{style.boutonTriDesc} gauche" />
</g:HTMLPanel>
<g:HTMLPanel ui:field="triParDate" styleName="gauche">
<g:Label text="{constants.triParDate}" styleName="gauche {style.date}" ui:field="labelDate"/>
<g:Button title="{constants.triParDateAscendant}" ui:field="triParDateAscendant" styleName="{style.boutonTriAsc} gauche" />
<g:Button title="{constants.triParDateDescendant}" ui:field="triParDateDescendant" styleName="{style.boutonTriDesc} gauche" />
</g:HTMLPanel>
<g:HTMLPanel ui:field="triParNbTags" styleName="gauche">
<g:Label text="{constants.triParNbTags}" styleName="gauche {style.tag}" ui:field="labelTag"/>
<g:Label text="{constants.triParNbTags}" title="{constants.triParNbTagsTooltip}" styleName="gauche {style.tag}" ui:field="labelTag"/>
<g:Button title="{constants.triParNbTagsAscendant}" ui:field="triParNbTagsAscendant" styleName="{style.boutonTriAsc} gauche" />
<g:Button title="{constants.triParNbTagsDescendant}" ui:field="triParNbTagsDescendant" styleName="{style.boutonTriDesc} gauche" />
</g:HTMLPanel>