Ready for translation
authorYann Nave <ynave@ynave-laptop.(none)>
Sat, 7 Aug 2010 19:43:25 +0000 (21:43 +0200)
committerYann Nave <ynave@ynave-laptop.(none)>
Sat, 7 Aug 2010 19:43:25 +0000 (21:43 +0200)
Load translation file depend on local (ex: fr_FR)

Add french translation

main.cpp
vlcRemote.pro
vlcremote_fr_FR.qm [new file with mode: 0644]
vlcremote_fr_FR.ts [new file with mode: 0644]

index a725f09..b0145af 100644 (file)
--- a/main.cpp
+++ b/main.cpp
@@ -28,8 +28,14 @@ int main(int argc, char *argv[])
     QCoreApplication::setOrganizationDomain("medsoft.blogspot.com/");
     QCoreApplication::setApplicationName("Maemo VLC remote");
 
-    PlayerMainWindow * mainwindow = new PlayerMainWindow;
+    QString locale = QLocale::system().name();
+    QTranslator translator;
+    translator.load(QString(":/languages/vlcremote_") + locale);
+    a.installTranslator(&translator);
+
+    QTextCodec::setCodecForTr(QTextCodec::codecForName("utf8"));
 
+    PlayerMainWindow * mainwindow = new PlayerMainWindow;
 
     mainwindow->showMaximized();
 
index b1cb5d2..2b4e4fc 100644 (file)
@@ -30,3 +30,8 @@ FORMS += \
 
 OTHER_FILES += \
     vlc-remote.desktop
+
+RESOURCES += \
+    ressources.qrc
+
+TRANSLATIONS = vlcremote_fr_FR.ts
diff --git a/vlcremote_fr_FR.qm b/vlcremote_fr_FR.qm
new file mode 100644 (file)
index 0000000..ed673a5
Binary files /dev/null and b/vlcremote_fr_FR.qm differ
diff --git a/vlcremote_fr_FR.ts b/vlcremote_fr_FR.ts
new file mode 100644 (file)
index 0000000..018b60c
--- /dev/null
@@ -0,0 +1,195 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE TS>
+<TS version="2.0" language="fr_FR">
+<context>
+    <name>AboutDialog</name>
+    <message>
+        <location filename="aboutdialog.ui" line="14"/>
+        <source>Dialog</source>
+        <translation>À propos</translation>
+    </message>
+    <message>
+        <location filename="aboutdialog.ui" line="20"/>
+        <source>&lt;!DOCTYPE HTML PUBLIC &quot;-//W3C//DTD HTML 4.0//EN&quot; &quot;http://www.w3.org/TR/REC-html40/strict.dtd&quot;&gt;
+&lt;html&gt;&lt;head&gt;&lt;meta name=&quot;qrichtext&quot; content=&quot;1&quot; /&gt;&lt;style type=&quot;text/css&quot;&gt;
+p, li { white-space: pre-wrap; }
+&lt;/style&gt;&lt;/head&gt;&lt;body style=&quot; font-family:&apos;DejaVu Sans&apos;; font-size:14pt; font-weight:400; font-style:normal;&quot;&gt;
+&lt;table style=&quot;-qt-table-type: root; margin-top:4px; margin-bottom:4px; margin-left:4px; margin-right:4px;&quot;&gt;
+&lt;tr&gt;
+&lt;td style=&quot;border: none;&quot;&gt;
+&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;OMed &lt;/p&gt;
+&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;Application by Sacha schutz &lt;/p&gt;
+&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;istdasklar@gmail.com&lt;/p&gt;
+&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;a href=&quot;http://omedsoft.blogspot.com/&quot;&gt;&lt;span style=&quot; text-decoration: underline; color:#0000ff;&quot;&gt;http://omedsoft.blogspot.com/&lt;/span&gt;&lt;/a&gt;&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&lt;/body&gt;&lt;/html&gt;</source>
+        <translation>&lt;!DOCTYPE HTML PUBLIC &quot;-//W3C//DTD HTML 4.0//EN&quot; &quot;http://www.w3.org/TR/REC-html40/strict.dtd&quot;&gt;
+&lt;html&gt;&lt;head&gt;&lt;meta name=&quot;qrichtext&quot; content=&quot;1&quot; /&gt;&lt;style type=&quot;text/css&quot;&gt;
+p, li { white-space: pre-wrap; }
+&lt;/style&gt;&lt;/head&gt;&lt;body style=&quot; font-family:&apos;DejaVu Sans&apos;; font-size:14pt; font-weight:400; font-style:normal;&quot;&gt;
+&lt;table style=&quot;-qt-table-type: root; margin-top:4px; margin-bottom:4px; margin-left:4px; margin-right:4px;&quot;&gt;
+&lt;tr&gt;
+&lt;td style=&quot;border: none;&quot;&gt;
+&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;OMed &lt;/p&gt;
+&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;Application par Sacha schutz &lt;/p&gt;
+&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;istdasklar@gmail.com&lt;/p&gt;
+&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;a href=&quot;http://omedsoft.blogspot.com/&quot;&gt;&lt;span style=&quot; text-decoration: underline; color:#0000ff;&quot;&gt;http://omedsoft.blogspot.com/&lt;/span&gt;&lt;/a&gt;&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&lt;/body&gt;&lt;/html&gt;</translation>
+    </message>
+</context>
+<context>
+    <name>ConfigDialog</name>
+    <message>
+        <location filename="configdialog.ui" line="14"/>
+        <source>Dialog</source>
+        <translation>Configuration</translation>
+    </message>
+    <message>
+        <location filename="configdialog.ui" line="20"/>
+        <source>&lt;!DOCTYPE HTML PUBLIC &quot;-//W3C//DTD HTML 4.0//EN&quot; &quot;http://www.w3.org/TR/REC-html40/strict.dtd&quot;&gt;
+&lt;html&gt;&lt;head&gt;&lt;meta name=&quot;qrichtext&quot; content=&quot;1&quot; /&gt;&lt;style type=&quot;text/css&quot;&gt;
+p, li { white-space: pre-wrap; }
+&lt;/style&gt;&lt;/head&gt;&lt;body style=&quot; font-family:&apos;DejaVu Sans&apos;; font-size:14pt; font-weight:400; font-style:normal;&quot;&gt;
+&lt;table border=&quot;0&quot; style=&quot;-qt-table-type: root; margin-top:4px; margin-bottom:4px; margin-left:4px; margin-right:4px;&quot;&gt;
+&lt;tr&gt;
+&lt;td style=&quot;border: none;&quot;&gt;
+&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;Enter IP of VLC server.  &lt;/p&gt;
+&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;Example : &lt;span style=&quot; font-weight:600;&quot;&gt;192.168.0.8:8080&lt;/span&gt;&lt;/p&gt;
+&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;Be sure  you have properly configured Vlc&lt;/p&gt;
+&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt; and allows connection by adding this IP in /vlc/http/.hosts&lt;/p&gt;
+&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;More information on my blog : &lt;a href=&quot;http://omedsoft.blogspot.com/&quot;&gt;&lt;span style=&quot; text-decoration: underline; color:#0000ff;&quot;&gt;omed.blogspot.com&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&lt;/body&gt;&lt;/html&gt;</source>
+        <translation>&lt;!DOCTYPE HTML PUBLIC &quot;-//W3C//DTD HTML 4.0//EN&quot; &quot;http://www.w3.org/TR/REC-html40/strict.dtd&quot;&gt;
+&lt;html&gt;&lt;head&gt;&lt;meta name=&quot;qrichtext&quot; content=&quot;1&quot; /&gt;&lt;style type=&quot;text/css&quot;&gt;
+p, li { white-space: pre-wrap; }
+&lt;/style&gt;&lt;/head&gt;&lt;body style=&quot; font-family:&apos;DejaVu Sans&apos;; font-size:14pt; font-weight:400; font-style:normal;&quot;&gt;
+&lt;table border=&quot;0&quot; style=&quot;-qt-table-type: root; margin-top:4px; margin-bottom:4px; margin-left:4px; margin-right:4px;&quot;&gt;
+&lt;tr&gt;
+&lt;td style=&quot;border: none;&quot;&gt;
+&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;Mettre l&apos;ip du Serveur VLC.&lt;/p&gt;
+&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;Exemple : &lt;span style=&quot; font-weight:600;&quot;&gt;192.168.0.8:8080&lt;/span&gt;&lt;/p&gt;
+&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;Vous devez avoir configurer VLC correctement&lt;/p&gt;
+&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt; et autoriser les connexions en ajoutant l&apos;ip de votre N900 dans /vlc/http/.hosts&lt;/p&gt;
+&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;Plus d&apos;informations sur mon blog : &lt;a href=&quot;http://omedsoft.blogspot.com/&quot;&gt;&lt;span style=&quot; text-decoration: underline; color:#0000ff;&quot;&gt;omed.blogspot.com&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&lt;/body&gt;&lt;/html&gt;</translation>
+    </message>
+</context>
+<context>
+    <name>PlayListMainWindow</name>
+    <message>
+        <location filename="playlistmainwindow.ui" line="14"/>
+        <source>MainWindow</source>
+        <translation>Vlc remote</translation>
+    </message>
+    <message>
+        <location filename="playlistmainwindow.ui" line="22"/>
+        <location filename="playlistmainwindow.ui" line="27"/>
+        <location filename="playlistmainwindow.ui" line="32"/>
+        <source>not yet done</source>
+        <translation>fonctions pas encore développée</translation>
+    </message>
+    <message>
+        <location filename="playlistmainwindow.ui" line="42"/>
+        <source>Clear</source>
+        <translation>Vider</translation>
+    </message>
+    <message>
+        <location filename="playlistmainwindow.ui" line="49"/>
+        <source>Shuffle</source>
+        <translation>Aléatoire</translation>
+    </message>
+    <message>
+        <location filename="playlistmainwindow.ui" line="59"/>
+        <source>Loop</source>
+        <translation>Boucler</translation>
+    </message>
+    <message>
+        <location filename="playlistmainwindow.ui" line="69"/>
+        <source>Repeat</source>
+        <translation>Répéter</translation>
+    </message>
+    <message>
+        <location filename="playlistmainwindow.ui" line="104"/>
+        <source>menu</source>
+        <translation></translation>
+    </message>
+    <message>
+        <location filename="playlistmainwindow.ui" line="114"/>
+        <source>configuration</source>
+        <translation>Configuration</translation>
+    </message>
+    <message>
+        <location filename="playlistmainwindow.ui" line="119"/>
+        <source>About</source>
+        <translation>À propos</translation>
+    </message>
+</context>
+<context>
+    <name>PlayerMainWindow</name>
+    <message>
+        <location filename="playermainwindow.ui" line="14"/>
+        <source>MainWindow</source>
+        <translation>Vlc remote</translation>
+    </message>
+    <message>
+        <location filename="playermainwindow.ui" line="27"/>
+        <source>Information</source>
+        <translation>Information</translation>
+    </message>
+    <message>
+        <location filename="playermainwindow.ui" line="72"/>
+        <source>&lt;</source>
+        <translation>&lt;</translation>
+    </message>
+    <message>
+        <location filename="playermainwindow.ui" line="79"/>
+        <source>play</source>
+        <translation>Lire</translation>
+    </message>
+    <message>
+        <location filename="playermainwindow.ui" line="86"/>
+        <source>&gt;</source>
+        <translation>&gt;</translation>
+    </message>
+    <message>
+        <location filename="playermainwindow.ui" line="93"/>
+        <source>Pause</source>
+        <translation>Pause</translation>
+    </message>
+    <message>
+        <location filename="playermainwindow.ui" line="100"/>
+        <source>Stop</source>
+        <translation>Stop</translation>
+    </message>
+    <message>
+        <location filename="playermainwindow.ui" line="107"/>
+        <source>FS</source>
+        <translation>FS</translation>
+    </message>
+    <message>
+        <location filename="playermainwindow.ui" line="127"/>
+        <source>V+</source>
+        <translation>V+</translation>
+    </message>
+    <message>
+        <location filename="playermainwindow.ui" line="134"/>
+        <source>V-</source>
+        <translation>V-</translation>
+    </message>
+    <message>
+        <location filename="playermainwindow.ui" line="143"/>
+        <source>PlayList</source>
+        <translation>Liste de lecture</translation>
+    </message>
+    <message>
+        <location filename="playermainwindow.ui" line="160"/>
+        <source>menu</source>
+        <translation></translation>
+    </message>
+    <message>
+        <location filename="playermainwindow.ui" line="170"/>
+        <source>Configuration</source>
+        <translation>Configuration</translation>
+    </message>
+    <message>
+        <location filename="playermainwindow.ui" line="175"/>
+        <source>About</source>
+        <translation>À propos</translation>
+    </message>
+</context>
+</TS>