This is an automated email from the git hooks/post-receive script. New commit to branch feature/sync in repository jtimer. See https://gitlab.nuiton.org/chorem/jtimer.git commit 2635e0d65d6c09224e1c6a337ba5daef6939bd22 Author: servantie <servantie.c@gmail.com> Date: Fri Jun 10 09:54:08 2016 +0200 edited to change update into synchronization --- .../chorem/jtimer/ui/report/TimerTaskUpdaterView.java | 16 +++++++++------- .../org/chorem/jtimer/resources/JTimer.properties | 4 ++-- .../org/chorem/jtimer/resources/JTimer_fr.properties | 4 ++-- .../report/resources/TimerTaskUpdaterView_fr.properties | 2 +- 4 files changed, 14 insertions(+), 12 deletions(-) diff --git a/src/main/java/org/chorem/jtimer/ui/report/TimerTaskUpdaterView.java b/src/main/java/org/chorem/jtimer/ui/report/TimerTaskUpdaterView.java index 3c9f162..6fdc404 100644 --- a/src/main/java/org/chorem/jtimer/ui/report/TimerTaskUpdaterView.java +++ b/src/main/java/org/chorem/jtimer/ui/report/TimerTaskUpdaterView.java @@ -93,7 +93,6 @@ public class TimerTaskUpdaterView extends FrameView implements DocumentListener /** * UpdaterView constructor. - * * @param application parent reference * @param core core reference * @param task the task to update @@ -470,28 +469,31 @@ public class TimerTaskUpdaterView extends FrameView implements DocumentListener connection.disconnect(); } catch (MalformedURLException e) { log.error("URL malformed"); - //abort synchronization of this task if the url is wrong } catch (ProtocolException e) { log.error("Protocol error."); } catch (UnsupportedEncodingException e) { log.error("Problem with encoding"); } catch (IOException e) { log.error("Problem with the connection"); - //abort synchronization of this task if connection impossible } if (hasUpdated) { core.getData().editTaskLastSync(task, LocalDateTime.now()); } else { - log.error("Update error, wrong URL?"); String message = getResourceMap().getString("action.updateError"); String title = getResourceMap().getString("action.updateErrorTitle"); - infoBox(message, title); + errorBox(message, title); } + canUpdate = false; } - public static void infoBox(String infoMessage, String titleBar) + /** + * Method to display an error message (in case the sync goes wrong) + * @param errorMessage the message to display + * @param titleBar the title of the frame + */ + public static void errorBox(String errorMessage, String titleBar) { - JOptionPane.showMessageDialog(null, infoMessage, "Erreur : " + titleBar, JOptionPane.ERROR_MESSAGE); + JOptionPane.showMessageDialog(null, errorMessage, titleBar, JOptionPane.ERROR_MESSAGE); } @Override public void changedUpdate(DocumentEvent e) { diff --git a/src/main/resources/org/chorem/jtimer/resources/JTimer.properties b/src/main/resources/org/chorem/jtimer/resources/JTimer.properties index a926505..5233547 100644 --- a/src/main/resources/org/chorem/jtimer/resources/JTimer.properties +++ b/src/main/resources/org/chorem/jtimer/resources/JTimer.properties @@ -62,9 +62,9 @@ editTask.Action.text = &Edit Task editTask.Action.accelerator = F2 editTask.Action.shortDescription = Edit task -updateTask.Action.text = &Update Task +updateTask.Action.text = &Synchronise Task updateTask.Action.accelerator = F5 -updateTask.Action.shortDescription = Update task +updateTask.Action.shortDescription = Synchronise task closeTask.Action.text = &Open/Close Task closeTask.Action.accelerator = control O diff --git a/src/main/resources/org/chorem/jtimer/resources/JTimer_fr.properties b/src/main/resources/org/chorem/jtimer/resources/JTimer_fr.properties index eb4c7e3..c7ab52b 100644 --- a/src/main/resources/org/chorem/jtimer/resources/JTimer_fr.properties +++ b/src/main/resources/org/chorem/jtimer/resources/JTimer_fr.properties @@ -42,8 +42,8 @@ editTask.Action.text = \u00C9dition de la t\u00E2ch&e editTask.Action.shortDescription = \u00C9dition de la t\u00E2che -updateTask.Action.text = &Mettre \u00E0 jour -updateTask.Action.shortDescription = Mettre \u00E0 jour +updateTask.Action.text = &Synchroniser la t\u00E2che +updateTask.Action.shortDescription = Synchroniser closeTask.Action.text = &Ouvrir/Fermer la t\u00E2che closeTask.Action.shortDescription = Ouvrir ou fermer la t\u00E2che diff --git a/src/main/resources/org/chorem/jtimer/ui/report/resources/TimerTaskUpdaterView_fr.properties b/src/main/resources/org/chorem/jtimer/ui/report/resources/TimerTaskUpdaterView_fr.properties index d34c270..9dd1b73 100644 --- a/src/main/resources/org/chorem/jtimer/ui/report/resources/TimerTaskUpdaterView_fr.properties +++ b/src/main/resources/org/chorem/jtimer/ui/report/resources/TimerTaskUpdaterView_fr.properties @@ -46,7 +46,7 @@ isIncludingAnnotations.Action.text = Inclure les annotations generateUpdate.Action.text = &G\u00E9n\u00E9rer generateUpdate.Action.icon = applications-system.png -generateUpdate.Action.shortDescription = G\u00E9n\u00E9rer les données de synchronisation +generateUpdate.Action.shortDescription = G\u00E9n\u00E9rer les donn\u00E9es de synchronisation sendUpdate.Action.text = &Envoyer sendUpdate.Action.icon = mail-forward.png -- To stop receiving notification emails like this one, please contact chorem.org SCM administrator <admin+scm@chorem.org>.