]> git.nothing2do.fr Git - diary-mobile.git/commitdiff
added a QMutex to download file one by one (cause QString file unicity
authorNorbert Moutarde <norbert.moutarde@nothing2do.eu>
Thu, 5 Jun 2014 19:10:36 +0000 (21:10 +0200)
committerNorbert Moutarde <norbert.moutarde@nothing2do.eu>
Thu, 5 Jun 2014 19:10:36 +0000 (21:10 +0200)
!)

diary-mobile_en_EN.ts
diary-mobile_fr_FR.ts
main.cpp
mainwindow.cpp
mainwindow.h

index cef814ae5cbf7fd598a9be3c260f6de394d42f6f..365e75ebef90a7317c3c2a1f455176ff47f0d8bb 100644 (file)
 <context>
     <name>MainWindow</name>
     <message>
-        <location filename="mainwindow.cpp" line="66"/>
+        <location filename="mainwindow.cpp" line="69"/>
         <source>first button file</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="66"/>
+        <location filename="mainwindow.cpp" line="69"/>
         <source>Enter the URL to download the first buttons file</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="201"/>
+        <location filename="mainwindow.cpp" line="204"/>
         <source>get file</source>
         <comment>title to ask file</comment>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="205"/>
+        <location filename="mainwindow.cpp" line="208"/>
         <source>box</source>
         <comment>box title to show a text</comment>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="220"/>
+        <location filename="mainwindow.cpp" line="223"/>
         <source>set</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="231"/>
+        <location filename="mainwindow.cpp" line="234"/>
         <source>Enter ID of button to edit</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="250"/>
+        <location filename="mainwindow.cpp" line="253"/>
         <source>&amp;File</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="251"/>
+        <location filename="mainwindow.cpp" line="254"/>
         <source>&amp;Start</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="251"/>
+        <location filename="mainwindow.cpp" line="254"/>
         <source>Ctrl+S</source>
         <comment>File|Start</comment>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="252"/>
+        <location filename="mainwindow.cpp" line="255"/>
         <source>&amp;Back</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="252"/>
+        <location filename="mainwindow.cpp" line="255"/>
         <source>Ctrl+B</source>
         <comment>File|Back</comment>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="254"/>
+        <location filename="mainwindow.cpp" line="257"/>
         <source>sendRAW</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="254"/>
+        <location filename="mainwindow.cpp" line="257"/>
         <source>Ctrl+L</source>
         <comment>File|Upload</comment>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="255"/>
+        <location filename="mainwindow.cpp" line="258"/>
         <source>Reset RAW</source>
         <oldsource>Reset Ui</oldsource>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="256"/>
+        <location filename="mainwindow.cpp" line="259"/>
         <source>&amp;Quit</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="256"/>
+        <location filename="mainwindow.cpp" line="259"/>
         <source>Ctrl+Q</source>
         <comment>File|Quit</comment>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="258"/>
+        <location filename="mainwindow.cpp" line="261"/>
         <source>&amp;Buttons</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="260"/>
+        <location filename="mainwindow.cpp" line="263"/>
         <source>Ctrl+D</source>
         <comment>Buttons|Add</comment>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="261"/>
+        <location filename="mainwindow.cpp" line="264"/>
         <source>Ctrl+V</source>
         <comment>Buttons|Save</comment>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="263"/>
+        <location filename="mainwindow.cpp" line="266"/>
         <source>Ctrl+E</source>
         <comment>Buttons|&amp;Edit</comment>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="253"/>
+        <location filename="mainwindow.cpp" line="256"/>
         <source>&amp;View/Hide menu</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="265"/>
+        <location filename="mainwindow.cpp" line="268"/>
         <source>&amp;Help</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="266"/>
-        <location filename="mainwindow.cpp" line="408"/>
+        <location filename="mainwindow.cpp" line="269"/>
+        <location filename="mainwindow.cpp" line="411"/>
         <source>New entry</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="267"/>
+        <location filename="mainwindow.cpp" line="270"/>
         <source>getButtons</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="268"/>
+        <location filename="mainwindow.cpp" line="271"/>
         <source>About Qt</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="268"/>
+        <location filename="mainwindow.cpp" line="271"/>
         <source>ctrl+H</source>
         <comment>Help|About Qt</comment>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="269"/>
+        <location filename="mainwindow.cpp" line="272"/>
         <source>C&amp;reate Database</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="269"/>
+        <location filename="mainwindow.cpp" line="272"/>
         <source>Ctrl+R</source>
         <comment>Help|CreateDB</comment>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="430"/>
+        <location filename="mainwindow.cpp" line="433"/>
         <source>label</source>
         <comment>Title of box where ask for new button&apos;s label</comment>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="430"/>
+        <location filename="mainwindow.cpp" line="433"/>
         <source>Enter his label</source>
         <comment>his/her/?they? I&apos;ve forget my school lesson</comment>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="432"/>
+        <location filename="mainwindow.cpp" line="435"/>
         <source>keyword</source>
         <comment>Title of box where ask for new button&apos;s keyword</comment>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="432"/>
+        <location filename="mainwindow.cpp" line="435"/>
         <source>Enter they keyword (no limit !)</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="434"/>
+        <location filename="mainwindow.cpp" line="437"/>
         <source>action</source>
         <comment>Title of box where ask for new button&apos;s action</comment>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="434"/>
+        <location filename="mainwindow.cpp" line="437"/>
         <source>Enter his action</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="253"/>
+        <location filename="mainwindow.cpp" line="256"/>
         <source>Ctrl+T</source>
         <comment>File|View menu</comment>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="190"/>
+        <location filename="mainwindow.cpp" line="193"/>
         <source>choice</source>
         <comment>title of box who ask multiple choice</comment>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="190"/>
+        <location filename="mainwindow.cpp" line="193"/>
         <source>Please choose an action.</source>
         <comment>text to ask multiple choice</comment>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="259"/>
+        <location filename="mainwindow.cpp" line="262"/>
         <source>&amp;Download</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="259"/>
+        <location filename="mainwindow.cpp" line="262"/>
         <source>Ctrl+W</source>
         <comment>Buttons|Downlad</comment>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="260"/>
+        <location filename="mainwindow.cpp" line="263"/>
         <source>A&amp;dd</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="261"/>
+        <location filename="mainwindow.cpp" line="264"/>
         <source>Sa&amp;v</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="262"/>
+        <location filename="mainwindow.cpp" line="265"/>
         <source>Reset</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="262"/>
+        <location filename="mainwindow.cpp" line="265"/>
         <source>Ctrl+Z</source>
         <comment>Buttons|Reset</comment>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="263"/>
+        <location filename="mainwindow.cpp" line="266"/>
         <source>&amp;Edit</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="471"/>
+        <location filename="mainwindow.cpp" line="474"/>
         <source>chooseButtonDB</source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="471"/>
+        <location filename="mainwindow.cpp" line="474"/>
         <source>Enter the keyword : </source>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="492"/>
+        <location filename="mainwindow.cpp" line="495"/>
         <source>keyword</source>
         <comment>Title of box where ask for button&apos;s keyword</comment>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="492"/>
+        <location filename="mainwindow.cpp" line="495"/>
         <source>new keyword</source>
         <comment>question to get new button&apos;s keyword</comment>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="494"/>
+        <location filename="mainwindow.cpp" line="497"/>
         <source>label</source>
         <comment>Title of box where ask for button&apos;s label</comment>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="494"/>
+        <location filename="mainwindow.cpp" line="497"/>
         <source>new label</source>
         <comment>question to get new button&apos;s label</comment>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="496"/>
+        <location filename="mainwindow.cpp" line="499"/>
         <source>action</source>
         <comment>Title of box where ask for button&apos;s action</comment>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="496"/>
+        <location filename="mainwindow.cpp" line="499"/>
         <source>new action</source>
         <comment>question to get new button&apos;s action</comment>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="540"/>
+        <location filename="mainwindow.cpp" line="543"/>
         <source>RAWsent</source>
         <comment>message title when data has been send</comment>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="540"/>
+        <location filename="mainwindow.cpp" line="543"/>
         <source>sendRAW finish</source>
         <comment>message text when data has been send</comment>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="623"/>
+        <location filename="mainwindow.cpp" line="626"/>
         <source>Upload finish : </source>
         <comment>pop-up when data has been sent</comment>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="627"/>
+        <location filename="mainwindow.cpp" line="630"/>
         <source>uploadDB</source>
         <comment>pop-up title when data has been sent</comment>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="681"/>
+        <location filename="mainwindow.cpp" line="685"/>
         <source>Uisent</source>
         <comment>pop-up title when buttons has been sent</comment>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="681"/>
+        <location filename="mainwindow.cpp" line="685"/>
         <source>savbuttons finish</source>
         <comment>pop-up text when buttons has been sent</comment>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="687"/>
+        <location filename="mainwindow.cpp" line="691"/>
         <source>Enter the keyword : </source>
         <comment>ask keyword to get buttons</comment>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="687"/>
+        <location filename="mainwindow.cpp" line="691"/>
         <source>getButtons</source>
         <comment>title to ask keyword fot getbuttons</comment>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="744"/>
+        <location filename="mainwindow.cpp" line="752"/>
         <source>writeFile</source>
-        <comment>pop-up title when file has been write</comment>
+        <comment>pop-up title when file has been written</comment>
         <translation type="unfinished"></translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="744"/>
-        <source>File writen</source>
-        <comment>pop-up text when file has been written</comment>
+        <location filename="mainwindow.cpp" line="752"/>
+        <source>File written : </source>
         <translation type="unfinished"></translation>
     </message>
 </context>
index 119b343ed8e5d9a7ada7fabccd097d525f479ecc..caa978e2f04295178e0f8b8e49bcce0383e1221e 100644 (file)
@@ -4,12 +4,12 @@
 <context>
     <name>MainWindow</name>
     <message>
-        <location filename="mainwindow.cpp" line="66"/>
+        <location filename="mainwindow.cpp" line="69"/>
         <source>first button file</source>
         <translation>Premier fichier de bouton</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="66"/>
+        <location filename="mainwindow.cpp" line="69"/>
         <source>Enter the URL to download the first buttons file</source>
         <translation>Entrez l&apos;URL pour télécharger vos boutons</translation>
     </message>
         <translation type="obsolete">choisissez une action</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="201"/>
+        <location filename="mainwindow.cpp" line="204"/>
         <source>get file</source>
         <comment>title to ask file</comment>
         <translation>choisissez un fichier</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="205"/>
+        <location filename="mainwindow.cpp" line="208"/>
         <source>box</source>
         <comment>box title to show a text</comment>
         <translation>info</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="220"/>
+        <location filename="mainwindow.cpp" line="223"/>
         <source>set</source>
         <translation>définir</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="231"/>
+        <location filename="mainwindow.cpp" line="234"/>
         <source>Enter ID of button to edit</source>
         <translation>Entrez l&apos;ID du bouton à éditer</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="250"/>
+        <location filename="mainwindow.cpp" line="253"/>
         <source>&amp;File</source>
         <translation>&amp;Fichier</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="251"/>
+        <location filename="mainwindow.cpp" line="254"/>
         <source>&amp;Start</source>
         <translation>&amp;Départ</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="251"/>
+        <location filename="mainwindow.cpp" line="254"/>
         <source>Ctrl+S</source>
         <comment>File|Start</comment>
         <translation>Ctrl+D</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="252"/>
+        <location filename="mainwindow.cpp" line="255"/>
         <source>&amp;Back</source>
         <translation>&amp;Retour</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="252"/>
+        <location filename="mainwindow.cpp" line="255"/>
         <source>Ctrl+B</source>
         <comment>File|Back</comment>
         <translation>Ctrl+R</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="259"/>
+        <location filename="mainwindow.cpp" line="262"/>
         <source>Ctrl+W</source>
         <comment>Buttons|Downlad</comment>
         <translation>Ctrl+D</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="254"/>
+        <location filename="mainwindow.cpp" line="257"/>
         <source>sendRAW</source>
         <translation>Envoyer les données</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="254"/>
+        <location filename="mainwindow.cpp" line="257"/>
         <source>Ctrl+L</source>
         <comment>File|Upload</comment>
         <translation>Ctrl+L</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="255"/>
+        <location filename="mainwindow.cpp" line="258"/>
         <source>Reset RAW</source>
         <oldsource>Reset Ui</oldsource>
-        <translation>Réinitialiser les boutons</translation>
+        <translation>Réinitialiser les donnés</translation>
     </message>
     <message>
         <source>Ctrl+Z</source>
         <translation type="obsolete">Ctrl+Z</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="256"/>
+        <location filename="mainwindow.cpp" line="259"/>
         <source>&amp;Quit</source>
         <translation>&amp;Quitter</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="256"/>
+        <location filename="mainwindow.cpp" line="259"/>
         <source>Ctrl+Q</source>
         <comment>File|Quit</comment>
         <translation>Ctrl+Q</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="258"/>
+        <location filename="mainwindow.cpp" line="261"/>
         <source>&amp;Buttons</source>
         <translation>Boutons</translation>
     </message>
         <translation type="obsolete">A&amp;jouter un boutons</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="260"/>
+        <location filename="mainwindow.cpp" line="263"/>
         <source>Ctrl+D</source>
         <comment>Buttons|Add</comment>
-        <translation>Ctrl+J</translation>
+        <translation>Ctrl+D</translation>
     </message>
     <message>
         <source>Sa&amp;v buttons</source>
         <translation type="obsolete">Sauvegardez les boutons</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="261"/>
+        <location filename="mainwindow.cpp" line="264"/>
         <source>Ctrl+V</source>
         <comment>Buttons|Save</comment>
         <translation>Ctrl+V</translation>
         <translation type="obsolete">&amp;Editer les boutons</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="263"/>
+        <location filename="mainwindow.cpp" line="266"/>
         <source>Ctrl+E</source>
         <comment>Buttons|&amp;Edit</comment>
         <translation>Ctrl+E</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="253"/>
+        <location filename="mainwindow.cpp" line="256"/>
         <source>&amp;View/Hide menu</source>
         <translation>Voir/Cacher le menu</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="190"/>
+        <location filename="mainwindow.cpp" line="193"/>
         <source>choice</source>
         <comment>title of box who ask multiple choice</comment>
         <translation>Choix</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="190"/>
+        <location filename="mainwindow.cpp" line="193"/>
         <source>Please choose an action.</source>
         <comment>text to ask multiple choice</comment>
         <translation>Choisissez une action</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="253"/>
+        <location filename="mainwindow.cpp" line="256"/>
         <source>Ctrl+T</source>
         <comment>File|View menu</comment>
         <translation>Ctrl+C</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="265"/>
+        <location filename="mainwindow.cpp" line="268"/>
         <source>&amp;Help</source>
         <translation>Aide</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="266"/>
-        <location filename="mainwindow.cpp" line="408"/>
+        <location filename="mainwindow.cpp" line="269"/>
+        <location filename="mainwindow.cpp" line="411"/>
         <source>New entry</source>
         <translation>Nouvelle entré</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="267"/>
+        <location filename="mainwindow.cpp" line="270"/>
         <source>getButtons</source>
         <translation>getButtons</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="268"/>
+        <location filename="mainwindow.cpp" line="271"/>
         <source>About Qt</source>
         <translation>A propos de Qt</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="268"/>
+        <location filename="mainwindow.cpp" line="271"/>
         <source>ctrl+H</source>
         <comment>Help|About Qt</comment>
         <translation>Ctrl+A</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="269"/>
+        <location filename="mainwindow.cpp" line="272"/>
         <source>C&amp;reate Database</source>
         <translation>C&amp;réer une base de donné</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="269"/>
+        <location filename="mainwindow.cpp" line="272"/>
         <source>Ctrl+R</source>
         <comment>Help|CreateDB</comment>
         <translation>Ctrl+R</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="430"/>
+        <location filename="mainwindow.cpp" line="433"/>
         <source>label</source>
         <comment>Title of box where ask for new button&apos;s label</comment>
         <translation>Etiquette</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="430"/>
+        <location filename="mainwindow.cpp" line="433"/>
         <source>Enter his label</source>
         <comment>his/her/?they? I&apos;ve forget my school lesson</comment>
         <translation>Entrez son étiquette</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="432"/>
+        <location filename="mainwindow.cpp" line="435"/>
         <source>keyword</source>
         <comment>Title of box where ask for new button&apos;s keyword</comment>
         <translation>mot-clé</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="432"/>
+        <location filename="mainwindow.cpp" line="435"/>
         <source>Enter they keyword (no limit !)</source>
         <translation>Entrez les mots clé (no limit !)</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="434"/>
+        <location filename="mainwindow.cpp" line="437"/>
         <source>action</source>
         <comment>Title of box where ask for new button&apos;s action</comment>
         <translation>action</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="434"/>
+        <location filename="mainwindow.cpp" line="437"/>
         <source>Enter his action</source>
         <translation>Entrez son action</translation>
     </message>
         <translation type="obsolete">0 (non) ou 1 (oui)?</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="259"/>
+        <location filename="mainwindow.cpp" line="262"/>
         <source>&amp;Download</source>
         <translation>&amp;Téléchargement</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="260"/>
+        <location filename="mainwindow.cpp" line="263"/>
         <source>A&amp;dd</source>
         <translation>Nouveau</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="261"/>
+        <location filename="mainwindow.cpp" line="264"/>
         <source>Sa&amp;v</source>
         <translation>Sauvegardez</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="262"/>
+        <location filename="mainwindow.cpp" line="265"/>
         <source>Reset</source>
         <translation>Remise à zéro</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="262"/>
+        <location filename="mainwindow.cpp" line="265"/>
         <source>Ctrl+Z</source>
         <comment>Buttons|Reset</comment>
         <translation>Ctrl+Z</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="263"/>
+        <location filename="mainwindow.cpp" line="266"/>
         <source>&amp;Edit</source>
         <translation>Editez</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="471"/>
+        <location filename="mainwindow.cpp" line="474"/>
         <source>chooseButtonDB</source>
         <translation>chooseButtonDB</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="471"/>
+        <location filename="mainwindow.cpp" line="474"/>
         <source>Enter the keyword : </source>
         <translation>Entrez le mot-clé : </translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="492"/>
+        <location filename="mainwindow.cpp" line="495"/>
         <source>keyword</source>
         <comment>Title of box where ask for button&apos;s keyword</comment>
         <translation>mot-clé</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="492"/>
+        <location filename="mainwindow.cpp" line="495"/>
         <source>new keyword</source>
         <comment>question to get new button&apos;s keyword</comment>
         <translation>nouveau mot-clé</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="494"/>
+        <location filename="mainwindow.cpp" line="497"/>
         <source>label</source>
         <comment>Title of box where ask for button&apos;s label</comment>
         <translation>étiquette</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="494"/>
+        <location filename="mainwindow.cpp" line="497"/>
         <source>new label</source>
         <comment>question to get new button&apos;s label</comment>
         <translation>nouvel étiquette</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="496"/>
+        <location filename="mainwindow.cpp" line="499"/>
         <source>action</source>
         <comment>Title of box where ask for button&apos;s action</comment>
         <translation>action</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="496"/>
+        <location filename="mainwindow.cpp" line="499"/>
         <source>new action</source>
         <comment>question to get new button&apos;s action</comment>
         <translation>nouvelle action</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="540"/>
+        <location filename="mainwindow.cpp" line="543"/>
         <source>RAWsent</source>
         <comment>message title when data has been send</comment>
         <translation>RAWsent</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="540"/>
+        <location filename="mainwindow.cpp" line="543"/>
         <source>sendRAW finish</source>
         <comment>message text when data has been send</comment>
         <translation>données envoyées</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="623"/>
+        <location filename="mainwindow.cpp" line="626"/>
         <source>Upload finish : </source>
         <comment>pop-up when data has been sent</comment>
         <translation>Upload finit : </translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="627"/>
+        <location filename="mainwindow.cpp" line="630"/>
         <source>uploadDB</source>
         <comment>pop-up title when data has been sent</comment>
         <translation>uploadDB</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="681"/>
+        <location filename="mainwindow.cpp" line="685"/>
         <source>Uisent</source>
         <comment>pop-up title when buttons has been sent</comment>
         <translation>Envoyé</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="681"/>
+        <location filename="mainwindow.cpp" line="685"/>
         <source>savbuttons finish</source>
         <comment>pop-up text when buttons has been sent</comment>
         <translation>boutons sauvegardés sur le serveur</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="687"/>
+        <location filename="mainwindow.cpp" line="691"/>
         <source>Enter the keyword : </source>
         <comment>ask keyword to get buttons</comment>
         <translation>Entrez le mot-clé : </translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="687"/>
+        <location filename="mainwindow.cpp" line="691"/>
         <source>getButtons</source>
         <comment>title to ask keyword fot getbuttons</comment>
         <translation>getBoutons</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="744"/>
+        <location filename="mainwindow.cpp" line="752"/>
         <source>writeFile</source>
-        <comment>pop-up title when file has been write</comment>
-        <translation>writeFile</translation>
+        <comment>pop-up title when file has been written</comment>
+        <translation>fichier</translation>
     </message>
     <message>
-        <location filename="mainwindow.cpp" line="744"/>
-        <source>File writen</source>
-        <comment>pop-up text when file has been written</comment>
-        <translation>Fichier écrit</translation>
+        <location filename="mainwindow.cpp" line="752"/>
+        <source>File written : </source>
+        <translation>Fichier écrit : </translation>
     </message>
 </context>
 </TS>
index 71d04de6b80372f0558d2b61aa1609881e044404..35bfe7c4e42f489e28af88bb494f16ca4c12f964 100644 (file)
--- a/main.cpp
+++ b/main.cpp
 
 int main(int argc, char *argv[])
 {
-    QApplication a(argc, argv);
+    QApplication app(argc, argv);
     QTextCodec::setCodecForLocale(QTextCodec::codecForName("UTF-8"));
     QString locale = QLocale::system().name();//.section('_', 0, 0)
     qDebug()<<"local="<<locale;
     QTranslator translator;
-    translator.load(QString("diary-mobile_") + locale/*, QLibraryInfo::location(QLibraryInfo::TranslationsPath)*/);
-    a.installTranslator(&translator);
+    translator.load(QString("diary-mobile_") + locale);
+    app.installTranslator(&translator);
     MainWindow w;
     w.show();
 
-    return a.exec();
+    return app.exec();
 }
index 55a3cc31b73af047348f0352eecc5f9bd006f53e..b5a06719c1f05876e04d5ba14dafe635432cb021 100644 (file)
@@ -42,11 +42,13 @@ MainWindow::MainWindow(QWidget *parent) : QMainWindow(parent)
 {
     qDebug()<<"begin of MainWindows";
     conf=new QSettings(QString("FwF"), QString("diary-mobile"), this);
+
     if(conf->allKeys().size()==0){
         qDebug()<<"first";
         firstrun();
         download(QString("http://www.nothing2do.eu/diary-mobile_")+ QLocale::system().name()+ QString(".qm"));
         connect(m, SIGNAL(downloaded()), SLOT(writeTr()));
+
         conf->setValue(QString("first"), 1);
     };
     screen=new QWidget(this);
@@ -259,7 +261,7 @@ void MainWindow::createMenuBar(){
     EditMenu->addAction(trUtf8("&Download"), this, SLOT(downloadUi()),QKeySequence(trUtf8("Ctrl+W", "Buttons|Downlad")));
     EditMenu->addAction(trUtf8("A&dd"), this, SLOT(addButtonDB()), QKeySequence(trUtf8("Ctrl+D", "Buttons|Add")));
     EditMenu->addAction(trUtf8("Sa&v"), this, SLOT(savButtons()), QKeySequence(trUtf8("Ctrl+V", "Buttons|Save")));
-    FileMenu->addAction(trUtf8("Reset"), this, SLOT(resetUi()), QKeySequence(trUtf8("Ctrl+Z", "Buttons|Reset")));
+    EditMenu->addAction(trUtf8("Reset"), this, SLOT(resetUi()), QKeySequence(trUtf8("Ctrl+Z", "Buttons|Reset")));
     EditMenu->addAction(trUtf8("&Edit"), this, SLOT(chooseButtonDB()), QKeySequence(trUtf8("Ctrl+E", "Buttons|&Edit")));
     menuBar()->addMenu(EditMenu);
     HelpMenu=new QMenu(trUtf8("&Help"));
@@ -651,6 +653,7 @@ void MainWindow::download(const QString & a){
 }
 void MainWindow::download(const QString & a, const QString & b){
     qDebug()<<"download("<<a<<") in "<<b;
+    d.lock();
     QUrl url(a);
     m = new FileDownloader(url, this);
     file=b;
@@ -729,7 +732,7 @@ void MainWindow::removeButton(const QString & keyword, const QString & label, co
 }
 void MainWindow::writeTr(){
     QString a="diary-mobile_" + QLocale::system().name()+".qm";
-    qDebug()<<"a="<<a;
+    qDebug()<<"writeTr->a="<<a;
     QFile file(a);
     file.open(QIODevice::WriteOnly);
     file.write(m->downloadedData());
@@ -741,5 +744,6 @@ void MainWindow::writeFile(){
     QDataStream str(&tmp);
     str<<m->downloadedData();
     m->disconnect();
-    QMessageBox::information(this, trUtf8("writeFile", "pop-up title when file has been write"), trUtf8("File writen", "pop-up text when file has been written"));
+    d.unlock();
+    QMessageBox::information(this, trUtf8("writeFile", "pop-up title when file has been written"), trUtf8("File written : "+file.toLocal8Bit(), "pop-up text when file has been written"));
 }
index c6986e98b245792f1bd163c8c6d620985064644e..f1108d6606bb5d2f22bb0434014132b663aa0bbc 100644 (file)
@@ -45,9 +45,6 @@
 //#include <QTableWidget>
 #include <QTextEdit>
 //#include <QScrollArea>
-#ifndef FILEDOWNLOADER_H
-#define FILEDOWNLOADER_H
-
 #include <QObject>
 #include <QByteArray>
 #include <QNetworkAccessManager>
 #include <QTranslator>
 #include <QLocale>
 
+#ifndef FILEDOWNLOADER_H
+#define FILEDOWNLOADER_H
+
+
 class FileDownloader : public QObject
 {
     Q_OBJECT
@@ -173,7 +174,8 @@ private:
     //sax2 xml;
     //QsKineticScroller * ks;
     //QScrollArea * scroll;
-    QMutex sql,updatelocker;
+
+    QMutex sql,updatelocker,d;
     QWidget *screen;
     QGridLayout *grid;
     QLabel *label;