Traduction dans les controller

This commit is contained in:
nawfe 2020-05-14 13:20:32 +02:00
parent 4951e7798e
commit cee8e76215
7 changed files with 20 additions and 20 deletions

View File

@ -26,7 +26,7 @@ public class MenuJoueurController implements Initializable{
public void changeZoneToScrollPaneJoueur(MouseEvent me) throws IOException {
final URL fxmlURL = getClass().getResource("/ihm/ressources/ScrollPaneJoueur.fxml");
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", Locale.ENGLISH);
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", ParametreController.LaLangue);
final FXMLLoader fxmlLoader = new FXMLLoader(fxmlURL, bundle);
AnchorPane bp = fxmlLoader.load();
ImageView iv = ((ImageView)me.getSource());

View File

@ -22,7 +22,7 @@ public class PiocherVisionController implements Initializable{
public void voirCarte(MouseEvent mouseEvent) throws IOException{
final URL fxmlURL = getClass().getResource("/ihm/ressources/jouer_Son_Tour_donner_vision.fxml");
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", Locale.FRANCE);
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", ParametreController.LaLangue);
final FXMLLoader fxmlLoader = new FXMLLoader(fxmlURL, bundle);
Pane pane = fxmlLoader.load();

View File

@ -204,7 +204,7 @@ public class PlateauController implements Initializable {
public void seReveler(int numJoueur) throws IOException {
System.out.println(listJoueur.get(numJoueur).getNom() + " se revele");
final URL fxmlURL = getClass().getResource("/ihm/ressources/Reveler_son_identite.fxml");
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", Locale.FRANCE);
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", ParametreController.LaLangue);
final FXMLLoader fxmlLoader = new FXMLLoader(fxmlURL, bundle);
Parent root = fxmlLoader.load();
@ -232,7 +232,7 @@ public class PlateauController implements Initializable {
public void consulterSaCarte(int numJoueur) throws IOException {
System.out.println(listJoueur.get(numJoueur).getNom() + " consulte sa carte");
final URL fxmlURL = getClass().getResource("/ihm/ressources/afficher_carte_perso.fxml");
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", Locale.FRANCE);
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", ParametreController.LaLangue);
final FXMLLoader fxmlLoader = new FXMLLoader(fxmlURL, bundle);
Parent root = fxmlLoader.load();
@ -267,7 +267,7 @@ public class PlateauController implements Initializable {
public void afficherChoisir(Joueur j, Contexte contexte) throws IOException {
final URL fxmlURL = getClass().getResource("/ihm/ressources/choisirBoolean.fxml");
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", Locale.FRANCE);
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", ParametreController.LaLangue);
final FXMLLoader fxmlLoader = new FXMLLoader(fxmlURL, bundle);
Pane root = (Pane) fxmlLoader.load();
this.cb = fxmlLoader.getController();
@ -292,7 +292,7 @@ public class PlateauController implements Initializable {
public void afficherChoisirEquipementVole(Joueur j, List<CarteEquipement> lce) throws IOException {
final URL fxmlURL = getClass().getResource("/ihm/ressources/Jouer_tour(2a)voler_equipement.fxml");
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", Locale.FRANCE);
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", ParametreController.LaLangue);
final FXMLLoader fxmlLoader = new FXMLLoader(fxmlURL, bundle);
Pane root = (Pane) fxmlLoader.load();
this.ce = fxmlLoader.getController();
@ -307,7 +307,7 @@ public class PlateauController implements Initializable {
public void afficherAlterationVie(Joueur j, int valeur) throws IOException, InterruptedException {
final URL fxmlURL = getClass().getResource("/ihm/ressources/AlterationVieZJ.fxml");
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", Locale.FRANCE);
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", ParametreController.LaLangue);
final FXMLLoader fxmlLoader = new FXMLLoader(fxmlURL, bundle);
Pane root = (Pane) fxmlLoader.load();
AlterationVieZJ avzj = fxmlLoader.getController();
@ -336,7 +336,7 @@ public class PlateauController implements Initializable {
public void afficherLieu(Joueur j) throws IOException {
final URL fxmlURL = getClass().getResource("/ihm/ressources/LieuZJ.fxml");
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", Locale.FRANCE);
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", ParametreController.LaLangue);
final FXMLLoader fxmlLoader = new FXMLLoader(fxmlURL, bundle);
Pane root = (Pane) fxmlLoader.load();
LieuZJ lzj = fxmlLoader.getController();
@ -361,7 +361,7 @@ public class PlateauController implements Initializable {
public void afficherChoisirJoueur(Joueur j, List<Joueur> joueurs, Contexte contexte) throws IOException {
final URL fxmlURL = getClass().getResource("/ihm/ressources/choixJoueurAttq.fxml");
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", Locale.FRANCE);
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", ParametreController.LaLangue);
final FXMLLoader fxmlLoader = new FXMLLoader(fxmlURL, bundle);
Pane root = (Pane) fxmlLoader.load();
@ -391,7 +391,7 @@ public class PlateauController implements Initializable {
public void afficherPiocher(Joueur j) throws IOException {
final URL fxmlURL = getClass().getResource("/ihm/ressources/Jouer_tour(2b)piocher_carte.fxml");
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", Locale.FRANCE);
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", ParametreController.LaLangue);
final FXMLLoader fxmlLoader = new FXMLLoader(fxmlURL, bundle);
Pane root = (Pane)fxmlLoader.load();
@ -402,7 +402,7 @@ public class PlateauController implements Initializable {
public void afficherEffet(Joueur j) throws IOException {
final URL fxmlURL = getClass().getResource("/ihm/ressources/Jouer_tour(2b)piocher_carte.fxml");
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", Locale.FRANCE);
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", ParametreController.LaLangue);
final FXMLLoader fxmlLoader = new FXMLLoader(fxmlURL, bundle);
Pane root = (Pane)fxmlLoader.load();
@ -461,7 +461,7 @@ public class PlateauController implements Initializable {
System.out.println("Jeu en pause ...");
final URL fxmlURL = getClass().getResource("/ihm/ressources/Pause.fxml");
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", Locale.FRANCE);
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", ParametreController.LaLangue);
final FXMLLoader fxmlLoader = new FXMLLoader(fxmlURL, bundle);
Pane root = (Pane) fxmlLoader.load();
@ -491,7 +491,7 @@ public class PlateauController implements Initializable {
public void close() throws IOException {
final URL fxmlURL = PlateauController.class.getResource("/ihm/ressources/Menu.fxml");
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", Locale.FRANCE);
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", ParametreController.LaLangue);
final FXMLLoader fxmlLoader = new FXMLLoader(fxmlURL, bundle);
Pane pane = fxmlLoader.load();
rootPane.getChildren().setAll(pane);
@ -522,7 +522,7 @@ public class PlateauController implements Initializable {
public void afficherVision(Joueur j, CartePiochable cartePiochable) throws IOException {
final URL fxmlURL = getClass().getResource("/ihm/ressources/RecevoirCarte.fxml");
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", Locale.FRANCE);
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", ParametreController.LaLangue);
final FXMLLoader fxmlLoader = new FXMLLoader(fxmlURL, bundle);
Pane root = (Pane) fxmlLoader.load();
RecevoirCarte lzj = fxmlLoader.getController();

View File

@ -40,7 +40,7 @@ public class PlateauControllerTest implements Initializable {
Pane p;
try {
final URL fxmlURL = getClass().getResource("/ihm/ressources/MenuJoueur.fxml");
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", Locale.ENGLISH);
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", ParametreController.LaLangue);
final FXMLLoader fxmlLoader = new FXMLLoader(fxmlURL, bundle);
p = fxmlLoader.load();
@ -165,7 +165,7 @@ public class PlateauControllerTest implements Initializable {
public boolean choisir(Joueur j) throws IOException {
final URL fxmlURL = getClass().getResource("/ihm/ressources/choisirBoolean.fxml");
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", Locale.ENGLISH);
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", ParametreController.LaLangue);
final FXMLLoader fxmlLoader = new FXMLLoader(fxmlURL, bundle);
Parent root = fxmlLoader.load();

View File

@ -189,7 +189,7 @@ public class PlayersController implements Initializable{
gj.setConfiguration(new Configuration(this.joueurs));
final URL fxmlURL = getClass().getResource("/ihm/ressources/PlateauTest2.fxml");
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", Locale.FRENCH);
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", ParametreController.LaLangue);
final FXMLLoader fxmlLoader = new FXMLLoader(fxmlURL, bundle);
AnchorPane root = fxmlLoader.load();
PlateauController pc = fxmlLoader.getController();
@ -324,7 +324,7 @@ public class PlayersController implements Initializable{
EffetSonore.playSoundEffect(fileSound1);
final URL fxmlURL = getClass().getResource("/ihm/ressources/Menu.fxml");
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", Locale.FRANCE);
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", ParametreController.LaLangue);
final FXMLLoader fxmlLoader = new FXMLLoader(fxmlURL, bundle);
Pane pane = fxmlLoader.load();

View File

@ -100,7 +100,7 @@ public class ReglesControlleur implements Initializable {
EffetSonore.playSoundEffect(fileSound1);
System.out.println("Retour au Menu");
final URL fxmlURL = getClass().getResource("/ihm/ressources/Menu.fxml");
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", Locale.FRANCE);
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", ParametreController.LaLangue);
final FXMLLoader fxmlLoader = new FXMLLoader(fxmlURL, bundle);
AnchorPane pane = fxmlLoader.load();
Scene scene = new Scene(pane);

View File

@ -29,7 +29,7 @@ public class ScrollPaneJoueurController implements Initializable{
public void changeZoneJoueurToMenuJoueur(MouseEvent me) throws IOException {
final URL fxmlURL = getClass().getResource("/ihm/ressources/MenuJoueur.fxml");
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", Locale.FRENCH);
final ResourceBundle bundle = ResourceBundle.getBundle("domaine.properties.langue", ParametreController.LaLangue);
final FXMLLoader fxmlLoader = new FXMLLoader(fxmlURL, bundle);
BorderPane bp = fxmlLoader.load();
ImageView iv = ((ImageView)me.getSource());