Refactored update checks into a separate thread, for better code reusability.
This commit is contained in:
parent
3932df90f8
commit
d5dcb9ad42
@ -348,6 +348,7 @@ del "$(TargetDir)imageformats\q???d4.dll"
|
|||||||
<ClCompile Include="src\Registry_Decoder.cpp" />
|
<ClCompile Include="src\Registry_Decoder.cpp" />
|
||||||
<ClCompile Include="src\Registry_Encoder.cpp" />
|
<ClCompile Include="src\Registry_Encoder.cpp" />
|
||||||
<ClCompile Include="src\ShellIntegration.cpp" />
|
<ClCompile Include="src\ShellIntegration.cpp" />
|
||||||
|
<ClCompile Include="src\Thread_CheckUpdate.cpp" />
|
||||||
<ClCompile Include="src\Thread_CPUObserver.cpp" />
|
<ClCompile Include="src\Thread_CPUObserver.cpp" />
|
||||||
<ClCompile Include="src\Thread_CueSplitter.cpp" />
|
<ClCompile Include="src\Thread_CueSplitter.cpp" />
|
||||||
<ClCompile Include="src\Thread_DiskObserver.cpp" />
|
<ClCompile Include="src\Thread_DiskObserver.cpp" />
|
||||||
@ -393,6 +394,7 @@ del "$(TargetDir)imageformats\q???d4.dll"
|
|||||||
<ClCompile Include="tmp\MOC_Registry_Decoder.cpp" />
|
<ClCompile Include="tmp\MOC_Registry_Decoder.cpp" />
|
||||||
<ClCompile Include="tmp\MOC_Registry_Encoder.cpp" />
|
<ClCompile Include="tmp\MOC_Registry_Encoder.cpp" />
|
||||||
<ClCompile Include="tmp\MOC_ShellIntegration.cpp" />
|
<ClCompile Include="tmp\MOC_ShellIntegration.cpp" />
|
||||||
|
<ClCompile Include="tmp\MOC_Thread_CheckUpdate.cpp" />
|
||||||
<ClCompile Include="tmp\MOC_Thread_CPUObserver.cpp" />
|
<ClCompile Include="tmp\MOC_Thread_CPUObserver.cpp" />
|
||||||
<ClCompile Include="tmp\MOC_Thread_CueSplitter.cpp" />
|
<ClCompile Include="tmp\MOC_Thread_CueSplitter.cpp" />
|
||||||
<ClCompile Include="tmp\MOC_Thread_DiskObserver.cpp" />
|
<ClCompile Include="tmp\MOC_Thread_DiskObserver.cpp" />
|
||||||
@ -569,6 +571,17 @@ del "$(TargetDir)imageformats\q???d4.dll"
|
|||||||
<Outputs Condition="'$(Configuration)|$(Platform)'=='Release_Static|Win32'">$(SolutionDir)tmp\MOC_%(Filename).cpp;%(Outputs)</Outputs>
|
<Outputs Condition="'$(Configuration)|$(Platform)'=='Release_Static|Win32'">$(SolutionDir)tmp\MOC_%(Filename).cpp;%(Outputs)</Outputs>
|
||||||
</CustomBuild>
|
</CustomBuild>
|
||||||
<ClInclude Include="src\JobObject.h" />
|
<ClInclude Include="src\JobObject.h" />
|
||||||
|
<CustomBuild Include="src\Thread_CheckUpdate.h">
|
||||||
|
<Command Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">"$(QTDIR)\bin\moc.exe" -o "$(SolutionDir)tmp\MOC_%(Filename).cpp" "%(FullPath)"</Command>
|
||||||
|
<Command Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">"$(QTDIR)\bin\moc.exe" -o "$(SolutionDir)tmp\MOC_%(Filename).cpp" "%(FullPath)"</Command>
|
||||||
|
<Command Condition="'$(Configuration)|$(Platform)'=='Release_Static|Win32'">"$(QTDIR)\bin\moc.exe" -o "$(SolutionDir)tmp\MOC_%(Filename).cpp" "%(FullPath)"</Command>
|
||||||
|
<Message Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">MOC "$(SolutionDir)tmp\MOC_%(Filename).cpp"</Message>
|
||||||
|
<Message Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">MOC "$(SolutionDir)tmp\MOC_%(Filename).cpp"</Message>
|
||||||
|
<Message Condition="'$(Configuration)|$(Platform)'=='Release_Static|Win32'">MOC "$(SolutionDir)tmp\MOC_%(Filename).cpp"</Message>
|
||||||
|
<Outputs Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(SolutionDir)tmp\MOC_%(Filename).cpp;%(Outputs)</Outputs>
|
||||||
|
<Outputs Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(SolutionDir)tmp\MOC_%(Filename).cpp;%(Outputs)</Outputs>
|
||||||
|
<Outputs Condition="'$(Configuration)|$(Platform)'=='Release_Static|Win32'">$(SolutionDir)tmp\MOC_%(Filename).cpp;%(Outputs)</Outputs>
|
||||||
|
</CustomBuild>
|
||||||
<ClInclude Include="src\Tools.h" />
|
<ClInclude Include="src\Tools.h" />
|
||||||
<CustomBuild Include="src\Tool_WaveProperties.h">
|
<CustomBuild Include="src\Tool_WaveProperties.h">
|
||||||
<Command Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">"$(QTDIR)\bin\moc.exe" -o "$(SolutionDir)tmp\MOC_%(Filename).cpp" "%(FullPath)"</Command>
|
<Command Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">"$(QTDIR)\bin\moc.exe" -o "$(SolutionDir)tmp\MOC_%(Filename).cpp" "%(FullPath)"</Command>
|
||||||
|
@ -415,6 +415,12 @@
|
|||||||
<ClCompile Include="src\Global_Utils.cpp">
|
<ClCompile Include="src\Global_Utils.cpp">
|
||||||
<Filter>Source Files</Filter>
|
<Filter>Source Files</Filter>
|
||||||
</ClCompile>
|
</ClCompile>
|
||||||
|
<ClCompile Include="src\Thread_CheckUpdate.cpp">
|
||||||
|
<Filter>Source Files\Threads</Filter>
|
||||||
|
</ClCompile>
|
||||||
|
<ClCompile Include="tmp\MOC_Thread_CheckUpdate.cpp">
|
||||||
|
<Filter>Generated Files\MOC</Filter>
|
||||||
|
</ClCompile>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ClInclude Include="src\Config.h">
|
<ClInclude Include="src\Config.h">
|
||||||
@ -549,6 +555,9 @@
|
|||||||
<ClInclude Include="etc\Prerequisites\strnatcmp\include\strnatcmp.h">
|
<ClInclude Include="etc\Prerequisites\strnatcmp\include\strnatcmp.h">
|
||||||
<Filter>Header Files\Misc\3rd Party</Filter>
|
<Filter>Header Files\Misc\3rd Party</Filter>
|
||||||
</ClInclude>
|
</ClInclude>
|
||||||
|
<ClInclude Include="src\Thread_CheckUpdate.h">
|
||||||
|
<Filter>Header Files\Threads</Filter>
|
||||||
|
</ClInclude>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<CustomBuild Include="gui\DropBox.ui">
|
<CustomBuild Include="gui\DropBox.ui">
|
||||||
|
@ -3300,22 +3300,22 @@
|
|||||||
<context>
|
<context>
|
||||||
<name>QApplication</name>
|
<name>QApplication</name>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Global_Win32.cpp" line="994"/>
|
<location filename="../../src/Global_Win32.cpp" line="1010"/>
|
||||||
<source>Executable '%1' doesn't support Windows compatibility mode.</source>
|
<source>Executable '%1' doesn't support Windows compatibility mode.</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Global_Win32.cpp" line="936"/>
|
<location filename="../../src/Global_Win32.cpp" line="952"/>
|
||||||
<source>Executable '%1' requires Qt v%2, but found Qt v%3.</source>
|
<source>Executable '%1' requires Qt v%2, but found Qt v%3.</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Global_Win32.cpp" line="941"/>
|
<location filename="../../src/Global_Win32.cpp" line="957"/>
|
||||||
<source>Executable '%1' was built for Qt '%2', but found Qt '%3'.</source>
|
<source>Executable '%1' was built for Qt '%2', but found Qt '%3'.</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Global_Win32.cpp" line="953"/>
|
<location filename="../../src/Global_Win32.cpp" line="969"/>
|
||||||
<source>Executable '%1' requires Windows XP or later.</source>
|
<source>Executable '%1' requires Windows XP or later.</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
@ -3384,105 +3384,104 @@
|
|||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="278"/>
|
<location filename="../../src/Dialog_Update.cpp" line="168"/>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="550"/>
|
<location filename="../../src/Dialog_Update.cpp" line="349"/>
|
||||||
<source>Build</source>
|
<source>Build</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="279"/>
|
<location filename="../../src/Dialog_Update.cpp" line="169"/>
|
||||||
<source>Unknown</source>
|
<source>Unknown</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="387"/>
|
<location filename="../../src/Dialog_Update.cpp" line="278"/>
|
||||||
<source>Testing your internet connection, please wait...</source>
|
<source>Testing your internet connection, please wait...</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="402"/>
|
<location filename="../../src/Dialog_Update.cpp" line="299"/>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="987"/>
|
|
||||||
<source>It appears that the computer currently is offline!</source>
|
<source>It appears that the computer currently is offline!</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="405"/>
|
<location filename="../../src/Dialog_Update.cpp" line="300"/>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="990"/>
|
<location filename="../../src/Dialog_Update.cpp" line="305"/>
|
||||||
<source>Please make sure your computer is connected to the internet and try again.</source>
|
<source>Please make sure your computer is connected to the internet and try again.</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="463"/>
|
<location filename="../../src/Dialog_Update.cpp" line="304"/>
|
||||||
<source>Network connectivity test has failed!</source>
|
<source>Network connectivity test has failed!</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="466"/>
|
<location filename="../../src/Dialog_Update.cpp" line="281"/>
|
||||||
<source>Please make sure your internet connection is working properly and try again.</source>
|
|
||||||
<translation type="unfinished"></translation>
|
|
||||||
</message>
|
|
||||||
<message>
|
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="480"/>
|
|
||||||
<source>Checking for new updates online, please wait...</source>
|
<source>Checking for new updates online, please wait...</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="535"/>
|
<location filename="../../src/Dialog_Update.cpp" line="309"/>
|
||||||
<source>Failed to fetch update information from server!</source>
|
<source>Failed to fetch update information from server!</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="540"/>
|
<location filename="../../src/Dialog_Update.cpp" line="310"/>
|
||||||
<source>Sorry, the update server might be busy at this time. Plase try again later.</source>
|
<source>Sorry, the update server might be busy at this time. Plase try again later.</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="552"/>
|
<location filename="../../src/Dialog_Update.cpp" line="348"/>
|
||||||
<source>More information available at:</source>
|
<source>More information available at:</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="558"/>
|
<location filename="../../src/Dialog_Update.cpp" line="284"/>
|
||||||
<source>A new version of LameXP is available!</source>
|
<source>A new version of LameXP is available!</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="560"/>
|
<location filename="../../src/Dialog_Update.cpp" line="275"/>
|
||||||
|
<source>Initializing, please wait...</source>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<location filename="../../src/Dialog_Update.cpp" line="285"/>
|
||||||
<source>We highly recommend all users to install this update as soon as possible.</source>
|
<source>We highly recommend all users to install this update as soon as possible.</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="569"/>
|
<location filename="../../src/Dialog_Update.cpp" line="289"/>
|
||||||
<source>No new updates available at this time.</source>
|
<source>No new updates available at this time.</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="571"/>
|
<location filename="../../src/Dialog_Update.cpp" line="290"/>
|
||||||
<source>Your version of LameXP is still up-to-date. Please check for updates regularly!</source>
|
<source>Your version of LameXP is still up-to-date. Please check for updates regularly!</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="580"/>
|
<location filename="../../src/Dialog_Update.cpp" line="294"/>
|
||||||
<source>Your version appears to be newer than the latest release.</source>
|
<source>Your version appears to be newer than the latest release.</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="582"/>
|
<location filename="../../src/Dialog_Update.cpp" line="295"/>
|
||||||
<source>This usually indicates your are currently using a pre-release version of LameXP.</source>
|
<source>This usually indicates your are currently using a pre-release version of LameXP.</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="871"/>
|
<location filename="../../src/Dialog_Update.cpp" line="377"/>
|
||||||
<source>Update is being downloaded, please be patient...</source>
|
<source>Update is being downloaded, please be patient...</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="918"/>
|
<location filename="../../src/Dialog_Update.cpp" line="423"/>
|
||||||
<source>Update ready to install. Applicaion will quit...</source>
|
<source>Update ready to install. Applicaion will quit...</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="926"/>
|
<location filename="../../src/Dialog_Update.cpp" line="431"/>
|
||||||
<source>Update failed. Please try again or download manually!</source>
|
<source>Update failed. Please try again or download manually!</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
|
@ -293,11 +293,11 @@
|
|||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<source>BerliOS Developer</source>
|
<source>BerliOS Developer</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<source>CodePlex</source>
|
<source>CodePlex</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation></translation>
|
||||||
</message>
|
</message>
|
||||||
</context>
|
</context>
|
||||||
<context>
|
<context>
|
||||||
@ -2600,7 +2600,7 @@
|
|||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<source>Executable '%1' requires Windows XP or later.</source>
|
<source>Executable '%1' requires Windows XP or later.</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation>Programm '%1' benötigt Windows XP oder neuer.</translation>
|
||||||
</message>
|
</message>
|
||||||
</context>
|
</context>
|
||||||
<context>
|
<context>
|
||||||
@ -2667,10 +2667,6 @@
|
|||||||
<source>Network connectivity test has failed!</source>
|
<source>Network connectivity test has failed!</source>
|
||||||
<translation>Test der Netzwerkverbindung fehlgeschlagen!</translation>
|
<translation>Test der Netzwerkverbindung fehlgeschlagen!</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
|
||||||
<source>Please make sure your internet connection is working properly and try again.</source>
|
|
||||||
<translation>Bitte prüfen Sie Ihre Internetverbindung und versuchen Sie es dann noch einmal.</translation>
|
|
||||||
</message>
|
|
||||||
<message>
|
<message>
|
||||||
<source>Checking for new updates online, please wait...</source>
|
<source>Checking for new updates online, please wait...</source>
|
||||||
<translation>Suche online nach neuen Updates, bitte warten...</translation>
|
<translation>Suche online nach neuen Updates, bitte warten...</translation>
|
||||||
@ -2735,5 +2731,9 @@
|
|||||||
<source>Please make sure your computer is connected to the internet and try again.</source>
|
<source>Please make sure your computer is connected to the internet and try again.</source>
|
||||||
<translation>Aktivieren Sie Ihre Internetverbindung und versuchen Sie es dann noch einmal.</translation>
|
<translation>Aktivieren Sie Ihre Internetverbindung und versuchen Sie es dann noch einmal.</translation>
|
||||||
</message>
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Initializing, please wait...</source>
|
||||||
|
<translation>Initialisiere, bitte warten...</translation>
|
||||||
|
</message>
|
||||||
</context>
|
</context>
|
||||||
</TS>
|
</TS>
|
||||||
|
@ -2670,10 +2670,6 @@
|
|||||||
<source>Network connectivity test has failed!</source>
|
<source>Network connectivity test has failed!</source>
|
||||||
<translation>¡La prueba de conexión a internet ha fallado!</translation>
|
<translation>¡La prueba de conexión a internet ha fallado!</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
|
||||||
<source>Please make sure your internet connection is working properly and try again.</source>
|
|
||||||
<translation>Por favor, asegúrese de que su conexión a internet funciona correctamente y vuelva a intentarlo.</translation>
|
|
||||||
</message>
|
|
||||||
<message>
|
<message>
|
||||||
<source>Checking for new updates online, please wait...</source>
|
<source>Checking for new updates online, please wait...</source>
|
||||||
<translation>Comprobando en busca de nuevas actualizaciones, espere por favor...</translation>
|
<translation>Comprobando en busca de nuevas actualizaciones, espere por favor...</translation>
|
||||||
@ -2734,5 +2730,9 @@
|
|||||||
<source>Please make sure your computer is connected to the internet and try again.</source>
|
<source>Please make sure your computer is connected to the internet and try again.</source>
|
||||||
<translation>Por favor, asegurese de que tiene conexión a internet y vuelva a intentarlo.</translation>
|
<translation>Por favor, asegurese de que tiene conexión a internet y vuelva a intentarlo.</translation>
|
||||||
</message>
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Initializing, please wait...</source>
|
||||||
|
<translation type="unfinished">Iniciando, espere por favor...</translation>
|
||||||
|
</message>
|
||||||
</context>
|
</context>
|
||||||
</TS>
|
</TS>
|
||||||
|
@ -2681,10 +2681,6 @@ Ouvrir le dossier récursivement...</translation>
|
|||||||
<source>Network connectivity test has failed!</source>
|
<source>Network connectivity test has failed!</source>
|
||||||
<translation>Le test de connectivité réseau a échoué!</translation>
|
<translation>Le test de connectivité réseau a échoué!</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
|
||||||
<source>Please make sure your internet connection is working properly and try again.</source>
|
|
||||||
<translation>Assurez-vous que votre connexion internet fonctionne correctement et essayez à nouveau.</translation>
|
|
||||||
</message>
|
|
||||||
<message>
|
<message>
|
||||||
<source>Checking for new updates online, please wait...</source>
|
<source>Checking for new updates online, please wait...</source>
|
||||||
<translation>Vérification des nouvelles mises à jour en ligne, patientez...</translation>
|
<translation>Vérification des nouvelles mises à jour en ligne, patientez...</translation>
|
||||||
@ -2745,5 +2741,9 @@ Ouvrir le dossier récursivement...</translation>
|
|||||||
<source>Please make sure your computer is connected to the internet and try again.</source>
|
<source>Please make sure your computer is connected to the internet and try again.</source>
|
||||||
<translation>Veuillez vous assurer que votre ordinateur est connecté à internet et essayez à nouveau.</translation>
|
<translation>Veuillez vous assurer que votre ordinateur est connecté à internet et essayez à nouveau.</translation>
|
||||||
</message>
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Initializing, please wait...</source>
|
||||||
|
<translation type="unfinished">Initialisation, patientez...</translation>
|
||||||
|
</message>
|
||||||
</context>
|
</context>
|
||||||
</TS>
|
</TS>
|
||||||
|
@ -2667,10 +2667,6 @@
|
|||||||
<source>Network connectivity test has failed!</source>
|
<source>Network connectivity test has failed!</source>
|
||||||
<translation>Il test di connessione di rete è fallito!</translation>
|
<translation>Il test di connessione di rete è fallito!</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
|
||||||
<source>Please make sure your internet connection is working properly and try again.</source>
|
|
||||||
<translation>Per favore assicurati che la tua connessione internet sia funzionante e prova ancora.</translation>
|
|
||||||
</message>
|
|
||||||
<message>
|
<message>
|
||||||
<source>Checking for new updates online, please wait...</source>
|
<source>Checking for new updates online, please wait...</source>
|
||||||
<translation>Ricerca di nuovi aggiornamenti in rete, attendere prego...</translation>
|
<translation>Ricerca di nuovi aggiornamenti in rete, attendere prego...</translation>
|
||||||
@ -2735,5 +2731,9 @@
|
|||||||
<source>Please make sure your computer is connected to the internet and try again.</source>
|
<source>Please make sure your computer is connected to the internet and try again.</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Initializing, please wait...</source>
|
||||||
|
<translation type="unfinished">Inizializzazione, attendere prego...</translation>
|
||||||
|
</message>
|
||||||
</context>
|
</context>
|
||||||
</TS>
|
</TS>
|
||||||
|
@ -2653,10 +2653,6 @@
|
|||||||
<source>Network connectivity test has failed!</source>
|
<source>Network connectivity test has failed!</source>
|
||||||
<translation type="unfinished">네트워크 연결 테스트가 실패되었습니다!</translation>
|
<translation type="unfinished">네트워크 연결 테스트가 실패되었습니다!</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
|
||||||
<source>Please make sure your internet connection is working properly and try again.</source>
|
|
||||||
<translation type="unfinished">인터넷에 연결되어 있는지 확인하고 다시 시도하시기 바랍니다.</translation>
|
|
||||||
</message>
|
|
||||||
<message>
|
<message>
|
||||||
<source>Checking for new updates online, please wait...</source>
|
<source>Checking for new updates online, please wait...</source>
|
||||||
<translation type="unfinished">새로운 업데이트 점검중, 잠시만 기다려 주십시오...</translation>
|
<translation type="unfinished">새로운 업데이트 점검중, 잠시만 기다려 주십시오...</translation>
|
||||||
@ -2717,5 +2713,9 @@
|
|||||||
<source>Please make sure your computer is connected to the internet and try again.</source>
|
<source>Please make sure your computer is connected to the internet and try again.</source>
|
||||||
<translation type="unfinished">인터넷 연결을 확인하고 다시 시도하시기 바랍니다.</translation>
|
<translation type="unfinished">인터넷 연결을 확인하고 다시 시도하시기 바랍니다.</translation>
|
||||||
</message>
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Initializing, please wait...</source>
|
||||||
|
<translation type="unfinished">초기화중, 잠시만 기다려 주십시오...</translation>
|
||||||
|
</message>
|
||||||
</context>
|
</context>
|
||||||
</TS>
|
</TS>
|
||||||
|
@ -3337,22 +3337,22 @@
|
|||||||
<context>
|
<context>
|
||||||
<name>QApplication</name>
|
<name>QApplication</name>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Global_Win32.cpp" line="994"/>
|
<location filename="../../src/Global_Win32.cpp" line="1010"/>
|
||||||
<source>Executable '%1' doesn't support Windows compatibility mode.</source>
|
<source>Executable '%1' doesn't support Windows compatibility mode.</source>
|
||||||
<translation type="unfinished">Plik wykonywalny '%1' nie działa w trybie kompatybilności z Windows.</translation>
|
<translation type="unfinished">Plik wykonywalny '%1' nie działa w trybie kompatybilności z Windows.</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Global_Win32.cpp" line="936"/>
|
<location filename="../../src/Global_Win32.cpp" line="952"/>
|
||||||
<source>Executable '%1' requires Qt v%2, but found Qt v%3.</source>
|
<source>Executable '%1' requires Qt v%2, but found Qt v%3.</source>
|
||||||
<translation type="unfinished">Plik wykonywalny '%1' wymaga Qt v%2, znaleziono jednak Qt v%3.</translation>
|
<translation type="unfinished">Plik wykonywalny '%1' wymaga Qt v%2, znaleziono jednak Qt v%3.</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Global_Win32.cpp" line="941"/>
|
<location filename="../../src/Global_Win32.cpp" line="957"/>
|
||||||
<source>Executable '%1' was built for Qt '%2', but found Qt '%3'.</source>
|
<source>Executable '%1' was built for Qt '%2', but found Qt '%3'.</source>
|
||||||
<translation type="unfinished">Plik wykonywalny "%1" został skompilowany dla Qt "%2", znaleziono "%3".</translation>
|
<translation type="unfinished">Plik wykonywalny "%1" został skompilowany dla Qt "%2", znaleziono "%3".</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Global_Win32.cpp" line="953"/>
|
<location filename="../../src/Global_Win32.cpp" line="969"/>
|
||||||
<source>Executable '%1' requires Windows XP or later.</source>
|
<source>Executable '%1' requires Windows XP or later.</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
@ -3421,105 +3421,104 @@
|
|||||||
<translation type="unfinished">Zamknij</translation>
|
<translation type="unfinished">Zamknij</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="278"/>
|
<location filename="../../src/Dialog_Update.cpp" line="168"/>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="550"/>
|
<location filename="../../src/Dialog_Update.cpp" line="349"/>
|
||||||
<source>Build</source>
|
<source>Build</source>
|
||||||
<translation type="unfinished">Build</translation>
|
<translation type="unfinished">Build</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="279"/>
|
<location filename="../../src/Dialog_Update.cpp" line="169"/>
|
||||||
<source>Unknown</source>
|
<source>Unknown</source>
|
||||||
<translation type="unfinished">Nieznana</translation>
|
<translation type="unfinished">Nieznana</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="387"/>
|
<location filename="../../src/Dialog_Update.cpp" line="278"/>
|
||||||
<source>Testing your internet connection, please wait...</source>
|
<source>Testing your internet connection, please wait...</source>
|
||||||
<translation type="unfinished">Testowanie połączenia internetowego, prosze czekać...</translation>
|
<translation type="unfinished">Testowanie połączenia internetowego, prosze czekać...</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="402"/>
|
<location filename="../../src/Dialog_Update.cpp" line="299"/>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="987"/>
|
|
||||||
<source>It appears that the computer currently is offline!</source>
|
<source>It appears that the computer currently is offline!</source>
|
||||||
<translation type="unfinished">LameXP wykrył brak dostępu do internetu!</translation>
|
<translation type="unfinished">LameXP wykrył brak dostępu do internetu!</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="405"/>
|
<location filename="../../src/Dialog_Update.cpp" line="300"/>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="990"/>
|
<location filename="../../src/Dialog_Update.cpp" line="305"/>
|
||||||
<source>Please make sure your computer is connected to the internet and try again.</source>
|
<source>Please make sure your computer is connected to the internet and try again.</source>
|
||||||
<translation type="unfinished">Upewnij się że komputer jest podłączony do internetu i spróbuj ponownie.</translation>
|
<translation type="unfinished">Upewnij się że komputer jest podłączony do internetu i spróbuj ponownie.</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="463"/>
|
<location filename="../../src/Dialog_Update.cpp" line="304"/>
|
||||||
<source>Network connectivity test has failed!</source>
|
<source>Network connectivity test has failed!</source>
|
||||||
<translation type="unfinished">Test połączenia internetowego zakończony niepowodzeniem!</translation>
|
<translation type="unfinished">Test połączenia internetowego zakończony niepowodzeniem!</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="466"/>
|
<location filename="../../src/Dialog_Update.cpp" line="281"/>
|
||||||
<source>Please make sure your internet connection is working properly and try again.</source>
|
|
||||||
<translation type="unfinished">Upewnij się że połączenie internetowe działa prawidłowo i spróbuj ponownie.</translation>
|
|
||||||
</message>
|
|
||||||
<message>
|
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="480"/>
|
|
||||||
<source>Checking for new updates online, please wait...</source>
|
<source>Checking for new updates online, please wait...</source>
|
||||||
<translation type="unfinished">Sprawdzanie aktualizacji online, prosze czekać...</translation>
|
<translation type="unfinished">Sprawdzanie aktualizacji online, prosze czekać...</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="535"/>
|
<location filename="../../src/Dialog_Update.cpp" line="309"/>
|
||||||
<source>Failed to fetch update information from server!</source>
|
<source>Failed to fetch update information from server!</source>
|
||||||
<translation type="unfinished">Pobieranie informacji z serwera zakończone niepowodzeniem!</translation>
|
<translation type="unfinished">Pobieranie informacji z serwera zakończone niepowodzeniem!</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="540"/>
|
<location filename="../../src/Dialog_Update.cpp" line="310"/>
|
||||||
<source>Sorry, the update server might be busy at this time. Plase try again later.</source>
|
<source>Sorry, the update server might be busy at this time. Plase try again later.</source>
|
||||||
<translation type="unfinished">Serwer aktualizacji wydaje się nie odpowiadać w tej chwili. Prosze spróbować później.</translation>
|
<translation type="unfinished">Serwer aktualizacji wydaje się nie odpowiadać w tej chwili. Prosze spróbować później.</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="552"/>
|
<location filename="../../src/Dialog_Update.cpp" line="348"/>
|
||||||
<source>More information available at:</source>
|
<source>More information available at:</source>
|
||||||
<translation type="unfinished">Więcej informacji tutaj:</translation>
|
<translation type="unfinished">Więcej informacji tutaj:</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="558"/>
|
<location filename="../../src/Dialog_Update.cpp" line="284"/>
|
||||||
<source>A new version of LameXP is available!</source>
|
<source>A new version of LameXP is available!</source>
|
||||||
<translation type="unfinished">Dostępna nowa wersja LameXP!</translation>
|
<translation type="unfinished">Dostępna nowa wersja LameXP!</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="560"/>
|
<location filename="../../src/Dialog_Update.cpp" line="275"/>
|
||||||
|
<source>Initializing, please wait...</source>
|
||||||
|
<translation type="unfinished">Inicjowanie, prosze czekać...</translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<location filename="../../src/Dialog_Update.cpp" line="285"/>
|
||||||
<source>We highly recommend all users to install this update as soon as possible.</source>
|
<source>We highly recommend all users to install this update as soon as possible.</source>
|
||||||
<translation type="unfinished">Jest wysoce zalecane aby zainstalować tę aktualizację jak najszybciej.</translation>
|
<translation type="unfinished">Jest wysoce zalecane aby zainstalować tę aktualizację jak najszybciej.</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="569"/>
|
<location filename="../../src/Dialog_Update.cpp" line="289"/>
|
||||||
<source>No new updates available at this time.</source>
|
<source>No new updates available at this time.</source>
|
||||||
<translation type="unfinished">Nie ma nowych aktualizacji w tej chwili.</translation>
|
<translation type="unfinished">Nie ma nowych aktualizacji w tej chwili.</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="571"/>
|
<location filename="../../src/Dialog_Update.cpp" line="290"/>
|
||||||
<source>Your version of LameXP is still up-to-date. Please check for updates regularly!</source>
|
<source>Your version of LameXP is still up-to-date. Please check for updates regularly!</source>
|
||||||
<translation type="unfinished">Posiadasz najnowszą wersję LameXP. Sprawdzaj aktualizacje regularnie!</translation>
|
<translation type="unfinished">Posiadasz najnowszą wersję LameXP. Sprawdzaj aktualizacje regularnie!</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="580"/>
|
<location filename="../../src/Dialog_Update.cpp" line="294"/>
|
||||||
<source>Your version appears to be newer than the latest release.</source>
|
<source>Your version appears to be newer than the latest release.</source>
|
||||||
<translation type="unfinished">Posiadasz nowszą wersję LameXP niż ostatnie wydanie.</translation>
|
<translation type="unfinished">Posiadasz nowszą wersję LameXP niż ostatnie wydanie.</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="582"/>
|
<location filename="../../src/Dialog_Update.cpp" line="295"/>
|
||||||
<source>This usually indicates your are currently using a pre-release version of LameXP.</source>
|
<source>This usually indicates your are currently using a pre-release version of LameXP.</source>
|
||||||
<translation type="unfinished">To wskazuje na to, że posiadasz wersję alfa LameXP.</translation>
|
<translation type="unfinished">To wskazuje na to, że posiadasz wersję alfa LameXP.</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="871"/>
|
<location filename="../../src/Dialog_Update.cpp" line="377"/>
|
||||||
<source>Update is being downloaded, please be patient...</source>
|
<source>Update is being downloaded, please be patient...</source>
|
||||||
<translation type="unfinished">Pobieranie aktualizacji w toku, prosze czekać...</translation>
|
<translation type="unfinished">Pobieranie aktualizacji w toku, prosze czekać...</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="918"/>
|
<location filename="../../src/Dialog_Update.cpp" line="423"/>
|
||||||
<source>Update ready to install. Applicaion will quit...</source>
|
<source>Update ready to install. Applicaion will quit...</source>
|
||||||
<translation type="unfinished">Aktualizacja gotowa do instalacji. Teraz program zostanie zamknięty...</translation>
|
<translation type="unfinished">Aktualizacja gotowa do instalacji. Teraz program zostanie zamknięty...</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="926"/>
|
<location filename="../../src/Dialog_Update.cpp" line="431"/>
|
||||||
<source>Update failed. Please try again or download manually!</source>
|
<source>Update failed. Please try again or download manually!</source>
|
||||||
<translation type="unfinished">Aktualizacja zakończona niepowodzeniem. Prosze spróbować ponownie lub zainstalować ręcznie!</translation>
|
<translation type="unfinished">Aktualizacja zakończona niepowodzeniem. Prosze spróbować ponownie lub zainstalować ręcznie!</translation>
|
||||||
</message>
|
</message>
|
||||||
|
@ -2695,10 +2695,6 @@
|
|||||||
<source>Network connectivity test has failed!</source>
|
<source>Network connectivity test has failed!</source>
|
||||||
<translation type="unfinished">Нет соединения с сетью!</translation>
|
<translation type="unfinished">Нет соединения с сетью!</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
|
||||||
<source>Please make sure your internet connection is working properly and try again.</source>
|
|
||||||
<translation type="unfinished">Проверьте доступность интернет соединения и попробуйте снова.</translation>
|
|
||||||
</message>
|
|
||||||
<message>
|
<message>
|
||||||
<source>Checking for new updates online, please wait...</source>
|
<source>Checking for new updates online, please wait...</source>
|
||||||
<translation type="unfinished">Проверяю обновления, пожалуйста, подождите...</translation>
|
<translation type="unfinished">Проверяю обновления, пожалуйста, подождите...</translation>
|
||||||
@ -2760,5 +2756,9 @@
|
|||||||
<source>Please make sure your computer is connected to the internet and try again.</source>
|
<source>Please make sure your computer is connected to the internet and try again.</source>
|
||||||
<translation type="unfinished">Пожалуйста, проверьте, что ваш компьютер подключен к интернету и попробуйте снова.</translation>
|
<translation type="unfinished">Пожалуйста, проверьте, что ваш компьютер подключен к интернету и попробуйте снова.</translation>
|
||||||
</message>
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Initializing, please wait...</source>
|
||||||
|
<translation type="unfinished">Инициализация, пожалуйста, подождите...</translation>
|
||||||
|
</message>
|
||||||
</context>
|
</context>
|
||||||
</TS>
|
</TS>
|
||||||
|
@ -3320,22 +3320,22 @@
|
|||||||
<context>
|
<context>
|
||||||
<name>QApplication</name>
|
<name>QApplication</name>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Global_Win32.cpp" line="994"/>
|
<location filename="../../src/Global_Win32.cpp" line="1010"/>
|
||||||
<source>Executable '%1' doesn't support Windows compatibility mode.</source>
|
<source>Executable '%1' doesn't support Windows compatibility mode.</source>
|
||||||
<translation>EXE-filen '%1' stöder inte Windows kompatibilitetsläge.</translation>
|
<translation>EXE-filen '%1' stöder inte Windows kompatibilitetsläge.</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Global_Win32.cpp" line="936"/>
|
<location filename="../../src/Global_Win32.cpp" line="952"/>
|
||||||
<source>Executable '%1' requires Qt v%2, but found Qt v%3.</source>
|
<source>Executable '%1' requires Qt v%2, but found Qt v%3.</source>
|
||||||
<translation>EXE-filen '%1' kräver Qt v%2, du har Qt v%3.</translation>
|
<translation>EXE-filen '%1' kräver Qt v%2, du har Qt v%3.</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Global_Win32.cpp" line="941"/>
|
<location filename="../../src/Global_Win32.cpp" line="957"/>
|
||||||
<source>Executable '%1' was built for Qt '%2', but found Qt '%3'.</source>
|
<source>Executable '%1' was built for Qt '%2', but found Qt '%3'.</source>
|
||||||
<translation>EXE-filen '%1' är byggd för Qt '%2', du har Qt '%3'.</translation>
|
<translation>EXE-filen '%1' är byggd för Qt '%2', du har Qt '%3'.</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Global_Win32.cpp" line="953"/>
|
<location filename="../../src/Global_Win32.cpp" line="969"/>
|
||||||
<source>Executable '%1' requires Windows XP or later.</source>
|
<source>Executable '%1' requires Windows XP or later.</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
@ -3404,105 +3404,104 @@
|
|||||||
<translation>Stäng</translation>
|
<translation>Stäng</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="278"/>
|
<location filename="../../src/Dialog_Update.cpp" line="168"/>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="550"/>
|
<location filename="../../src/Dialog_Update.cpp" line="349"/>
|
||||||
<source>Build</source>
|
<source>Build</source>
|
||||||
<translation>Build</translation>
|
<translation>Build</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="279"/>
|
<location filename="../../src/Dialog_Update.cpp" line="169"/>
|
||||||
<source>Unknown</source>
|
<source>Unknown</source>
|
||||||
<translation>Okänd</translation>
|
<translation>Okänd</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="387"/>
|
<location filename="../../src/Dialog_Update.cpp" line="278"/>
|
||||||
<source>Testing your internet connection, please wait...</source>
|
<source>Testing your internet connection, please wait...</source>
|
||||||
<translation>Kontrollerar iInternetanslutningen, vänta...</translation>
|
<translation>Kontrollerar iInternetanslutningen, vänta...</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="402"/>
|
<location filename="../../src/Dialog_Update.cpp" line="299"/>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="987"/>
|
|
||||||
<source>It appears that the computer currently is offline!</source>
|
<source>It appears that the computer currently is offline!</source>
|
||||||
<translation>Datorn verkar inte vara ansluten till Internet!</translation>
|
<translation>Datorn verkar inte vara ansluten till Internet!</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="405"/>
|
<location filename="../../src/Dialog_Update.cpp" line="300"/>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="990"/>
|
<location filename="../../src/Dialog_Update.cpp" line="305"/>
|
||||||
<source>Please make sure your computer is connected to the internet and try again.</source>
|
<source>Please make sure your computer is connected to the internet and try again.</source>
|
||||||
<translation>Tillse att datorn är ansluten till Internet och försök igen.</translation>
|
<translation>Tillse att datorn är ansluten till Internet och försök igen.</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="463"/>
|
<location filename="../../src/Dialog_Update.cpp" line="304"/>
|
||||||
<source>Network connectivity test has failed!</source>
|
<source>Network connectivity test has failed!</source>
|
||||||
<translation>Anslutningskontrollen misslyckades!</translation>
|
<translation>Anslutningskontrollen misslyckades!</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="466"/>
|
<location filename="../../src/Dialog_Update.cpp" line="281"/>
|
||||||
<source>Please make sure your internet connection is working properly and try again.</source>
|
|
||||||
<translation>Tillse att Internetuppkopplingen fungerar korrekt och försök igen.</translation>
|
|
||||||
</message>
|
|
||||||
<message>
|
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="480"/>
|
|
||||||
<source>Checking for new updates online, please wait...</source>
|
<source>Checking for new updates online, please wait...</source>
|
||||||
<translation>Söker nya uppdateringar, vänta...</translation>
|
<translation>Söker nya uppdateringar, vänta...</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="535"/>
|
<location filename="../../src/Dialog_Update.cpp" line="309"/>
|
||||||
<source>Failed to fetch update information from server!</source>
|
<source>Failed to fetch update information from server!</source>
|
||||||
<translation>Kunde inte hämta uppdateringsinformation från servern!</translation>
|
<translation>Kunde inte hämta uppdateringsinformation från servern!</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="540"/>
|
<location filename="../../src/Dialog_Update.cpp" line="310"/>
|
||||||
<source>Sorry, the update server might be busy at this time. Plase try again later.</source>
|
<source>Sorry, the update server might be busy at this time. Plase try again later.</source>
|
||||||
<translation>Uppdateringsservern kan vara upptagen. Försök senare.</translation>
|
<translation>Uppdateringsservern kan vara upptagen. Försök senare.</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="552"/>
|
<location filename="../../src/Dialog_Update.cpp" line="348"/>
|
||||||
<source>More information available at:</source>
|
<source>More information available at:</source>
|
||||||
<translation>Mer information hittas på:</translation>
|
<translation>Mer information hittas på:</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="558"/>
|
<location filename="../../src/Dialog_Update.cpp" line="284"/>
|
||||||
<source>A new version of LameXP is available!</source>
|
<source>A new version of LameXP is available!</source>
|
||||||
<translation>En ny version av LameXP finns tillgänglig!</translation>
|
<translation>En ny version av LameXP finns tillgänglig!</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="560"/>
|
<location filename="../../src/Dialog_Update.cpp" line="275"/>
|
||||||
|
<source>Initializing, please wait...</source>
|
||||||
|
<translation type="unfinished">Initierar, vänta...</translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<location filename="../../src/Dialog_Update.cpp" line="285"/>
|
||||||
<source>We highly recommend all users to install this update as soon as possible.</source>
|
<source>We highly recommend all users to install this update as soon as possible.</source>
|
||||||
<translation>Vi rekommenderar alla användare att installera denna uppdatering så snart som möjligt.</translation>
|
<translation>Vi rekommenderar alla användare att installera denna uppdatering så snart som möjligt.</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="569"/>
|
<location filename="../../src/Dialog_Update.cpp" line="289"/>
|
||||||
<source>No new updates available at this time.</source>
|
<source>No new updates available at this time.</source>
|
||||||
<translation>Det finns inga nya uppdateringar.</translation>
|
<translation>Det finns inga nya uppdateringar.</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="571"/>
|
<location filename="../../src/Dialog_Update.cpp" line="290"/>
|
||||||
<source>Your version of LameXP is still up-to-date. Please check for updates regularly!</source>
|
<source>Your version of LameXP is still up-to-date. Please check for updates regularly!</source>
|
||||||
<translation>Din version av LameXP är uppdaterad. Kontrollera regelbundet!</translation>
|
<translation>Din version av LameXP är uppdaterad. Kontrollera regelbundet!</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="580"/>
|
<location filename="../../src/Dialog_Update.cpp" line="294"/>
|
||||||
<source>Your version appears to be newer than the latest release.</source>
|
<source>Your version appears to be newer than the latest release.</source>
|
||||||
<translation>Din version verkar vara nyare än senaste 'Release'.</translation>
|
<translation>Din version verkar vara nyare än senaste 'Release'.</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="582"/>
|
<location filename="../../src/Dialog_Update.cpp" line="295"/>
|
||||||
<source>This usually indicates your are currently using a pre-release version of LameXP.</source>
|
<source>This usually indicates your are currently using a pre-release version of LameXP.</source>
|
||||||
<translation>Det innebär normalt att du använder en beta-version av LameXP.</translation>
|
<translation>Det innebär normalt att du använder en beta-version av LameXP.</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="871"/>
|
<location filename="../../src/Dialog_Update.cpp" line="377"/>
|
||||||
<source>Update is being downloaded, please be patient...</source>
|
<source>Update is being downloaded, please be patient...</source>
|
||||||
<translation>Uppdatering laddas ner, vänta...</translation>
|
<translation>Uppdatering laddas ner, vänta...</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="918"/>
|
<location filename="../../src/Dialog_Update.cpp" line="423"/>
|
||||||
<source>Update ready to install. Applicaion will quit...</source>
|
<source>Update ready to install. Applicaion will quit...</source>
|
||||||
<translation>Uppdatering klar att installeras. Programmet kommer att avslutas...</translation>
|
<translation>Uppdatering klar att installeras. Programmet kommer att avslutas...</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Update.cpp" line="926"/>
|
<location filename="../../src/Dialog_Update.cpp" line="431"/>
|
||||||
<source>Update failed. Please try again or download manually!</source>
|
<source>Update failed. Please try again or download manually!</source>
|
||||||
<translation>Uppdateringen misslyckades. Försök igen, eller ladda ner manuellt!</translation>
|
<translation>Uppdateringen misslyckades. Försök igen, eller ladda ner manuellt!</translation>
|
||||||
</message>
|
</message>
|
||||||
|
@ -2652,10 +2652,6 @@
|
|||||||
<source>Network connectivity test has failed!</source>
|
<source>Network connectivity test has failed!</source>
|
||||||
<translation>網絡連接測試失敗 !</translation>
|
<translation>網絡連接測試失敗 !</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
|
||||||
<source>Please make sure your internet connection is working properly and try again.</source>
|
|
||||||
<translation>請確保您的網絡連接正常工作,然后再試.</translation>
|
|
||||||
</message>
|
|
||||||
<message>
|
<message>
|
||||||
<source>Checking for new updates online, please wait...</source>
|
<source>Checking for new updates online, please wait...</source>
|
||||||
<translation>在線更新檢查新的版本,請稍候...</translation>
|
<translation>在線更新檢查新的版本,請稍候...</translation>
|
||||||
@ -2716,5 +2712,9 @@
|
|||||||
<source>Please make sure your computer is connected to the internet and try again.</source>
|
<source>Please make sure your computer is connected to the internet and try again.</source>
|
||||||
<translation>請確保您的計算機連接到 Internet,然后重試.</translation>
|
<translation>請確保您的計算機連接到 Internet,然后重試.</translation>
|
||||||
</message>
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Initializing, please wait...</source>
|
||||||
|
<translation type="unfinished">正在初始化,請稍候...</translation>
|
||||||
|
</message>
|
||||||
</context>
|
</context>
|
||||||
</TS>
|
</TS>
|
||||||
|
@ -2689,10 +2689,6 @@
|
|||||||
<source>Network connectivity test has failed!</source>
|
<source>Network connectivity test has failed!</source>
|
||||||
<translation>Збій перевірки мережевого з'єднання!</translation>
|
<translation>Збій перевірки мережевого з'єднання!</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
|
||||||
<source>Please make sure your internet connection is working properly and try again.</source>
|
|
||||||
<translation>Будь ласка, впевніться, що ваше інтернет-з'єднання працює коректно і спробуйте знову.</translation>
|
|
||||||
</message>
|
|
||||||
<message>
|
<message>
|
||||||
<source>Checking for new updates online, please wait...</source>
|
<source>Checking for new updates online, please wait...</source>
|
||||||
<translation>Йде перевірка оновлень онлайн, будь ласка, зачекайте...</translation>
|
<translation>Йде перевірка оновлень онлайн, будь ласка, зачекайте...</translation>
|
||||||
@ -2753,5 +2749,9 @@
|
|||||||
<source>Update failed. Please try again or download manually!</source>
|
<source>Update failed. Please try again or download manually!</source>
|
||||||
<translation>Збій оновлення. Будь ласка, спробуйте ще раз або завантажте оновлення самостійно!</translation>
|
<translation>Збій оновлення. Будь ласка, спробуйте ще раз або завантажте оновлення самостійно!</translation>
|
||||||
</message>
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Initializing, please wait...</source>
|
||||||
|
<translation type="unfinished">Ініціалізація, будь ласка, зачекайте...</translation>
|
||||||
|
</message>
|
||||||
</context>
|
</context>
|
||||||
</TS>
|
</TS>
|
||||||
|
@ -2652,10 +2652,6 @@
|
|||||||
<source>Network connectivity test has failed!</source>
|
<source>Network connectivity test has failed!</source>
|
||||||
<translation>网络连接测试失败 !</translation>
|
<translation>网络连接测试失败 !</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
|
||||||
<source>Please make sure your internet connection is working properly and try again.</source>
|
|
||||||
<translation>请确保您的网络连接正常工作,然后再试。</translation>
|
|
||||||
</message>
|
|
||||||
<message>
|
<message>
|
||||||
<source>Checking for new updates online, please wait...</source>
|
<source>Checking for new updates online, please wait...</source>
|
||||||
<translation>在线检查新的版本,请稍候...</translation>
|
<translation>在线检查新的版本,请稍候...</translation>
|
||||||
@ -2716,5 +2712,9 @@
|
|||||||
<source>Please make sure your computer is connected to the internet and try again.</source>
|
<source>Please make sure your computer is connected to the internet and try again.</source>
|
||||||
<translation>请确保您的计算机连接到 Internet,然后重试。</translation>
|
<translation>请确保您的计算机连接到 Internet,然后重试。</translation>
|
||||||
</message>
|
</message>
|
||||||
|
<message>
|
||||||
|
<source>Initializing, please wait...</source>
|
||||||
|
<translation type="unfinished">正在初始化,请稍候...</translation>
|
||||||
|
</message>
|
||||||
</context>
|
</context>
|
||||||
</TS>
|
</TS>
|
||||||
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -35,7 +35,7 @@
|
|||||||
#define VER_LAMEXP_MINOR_LO 9
|
#define VER_LAMEXP_MINOR_LO 9
|
||||||
#define VER_LAMEXP_TYPE Alpha
|
#define VER_LAMEXP_TYPE Alpha
|
||||||
#define VER_LAMEXP_PATCH 7
|
#define VER_LAMEXP_PATCH 7
|
||||||
#define VER_LAMEXP_BUILD 1454
|
#define VER_LAMEXP_BUILD 1458
|
||||||
#define VER_LAMEXP_CONFG 1348
|
#define VER_LAMEXP_CONFG 1348
|
||||||
|
|
||||||
///////////////////////////////////////////////////////////////////////////////
|
///////////////////////////////////////////////////////////////////////////////
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -27,6 +27,7 @@
|
|||||||
class UpdateInfo;
|
class UpdateInfo;
|
||||||
class SettingsModel;
|
class SettingsModel;
|
||||||
class QMovie;
|
class QMovie;
|
||||||
|
class UpdateCheckThread;
|
||||||
|
|
||||||
//UIC forward declartion
|
//UIC forward declartion
|
||||||
namespace Ui {
|
namespace Ui {
|
||||||
@ -53,6 +54,11 @@ private slots:
|
|||||||
void logButtonClicked(void);
|
void logButtonClicked(void);
|
||||||
void progressBarValueChanged(int value);
|
void progressBarValueChanged(int value);
|
||||||
|
|
||||||
|
void threadStatusChanged(const int status);
|
||||||
|
void threadProgressChanged(const int progress);
|
||||||
|
void threadMessageLogged(const QString &message);
|
||||||
|
void threadFinished(void);
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
virtual void showEvent(QShowEvent *event);
|
virtual void showEvent(QShowEvent *event);
|
||||||
virtual void closeEvent(QCloseEvent *event);
|
virtual void closeEvent(QCloseEvent *event);
|
||||||
@ -65,24 +71,19 @@ protected:
|
|||||||
private:
|
private:
|
||||||
Ui::UpdateDialog *ui; //for Qt UIC
|
Ui::UpdateDialog *ui; //for Qt UIC
|
||||||
|
|
||||||
bool tryUpdateMirror(UpdateInfo *updateInfo, const QString &url);
|
const QString m_binaryUpdater;
|
||||||
bool getFile(const QString &url, const QString &outFile, unsigned int maxRedir = 5, bool *httpOk = NULL);
|
|
||||||
bool checkSignature(const QString &file, const QString &signature);
|
|
||||||
bool parseVersionInfo(const QString &file, UpdateInfo *updateInfo);
|
|
||||||
void testKnownWebSites(void);
|
|
||||||
|
|
||||||
UpdateInfo *m_updateInfo;
|
UpdateCheckThread *m_thread;
|
||||||
QStringList *m_logFile;
|
QStringList *m_logFile;
|
||||||
SettingsModel *m_settings;
|
SettingsModel *m_settings;
|
||||||
QMovie *m_animator;
|
QMovie *m_animator;
|
||||||
|
|
||||||
const QString m_binaryWGet;
|
|
||||||
const QString m_binaryGnuPG;
|
|
||||||
const QString m_binaryUpdater;
|
|
||||||
const QString m_binaryKeys;
|
|
||||||
unsigned long m_updaterProcess;
|
unsigned long m_updaterProcess;
|
||||||
|
|
||||||
bool m_success;
|
bool m_success;
|
||||||
bool m_updateReadyToInstall;
|
bool m_updateReadyToInstall;
|
||||||
bool m_firstShow;
|
bool m_firstShow;
|
||||||
|
|
||||||
|
void testKnownHosts(void);
|
||||||
|
|
||||||
};
|
};
|
||||||
|
710
src/Thread_CheckUpdate.cpp
Normal file
710
src/Thread_CheckUpdate.cpp
Normal file
@ -0,0 +1,710 @@
|
|||||||
|
///////////////////////////////////////////////////////////////////////////////
|
||||||
|
// LameXP - Audio Encoder Front-End
|
||||||
|
// Copyright (C) 2004-2013 LoRd_MuldeR <MuldeR2@GMX.de>
|
||||||
|
//
|
||||||
|
// This program is free software; you can redistribute it and/or modify
|
||||||
|
// it under the terms of the GNU General Public License as published by
|
||||||
|
// the Free Software Foundation; either version 2 of the License, or
|
||||||
|
// (at your option) any later version, but always including the *additional*
|
||||||
|
// restrictions defined in the "License.txt" file.
|
||||||
|
//
|
||||||
|
// This program is distributed in the hope that it will be useful,
|
||||||
|
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
// GNU General Public License for more details.
|
||||||
|
//
|
||||||
|
// You should have received a copy of the GNU General Public License along
|
||||||
|
// with this program; if not, write to the Free Software Foundation, Inc.,
|
||||||
|
// 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||||
|
//
|
||||||
|
// http://www.gnu.org/licenses/gpl-2.0.txt
|
||||||
|
///////////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
#include "Thread_CheckUpdate.h"
|
||||||
|
|
||||||
|
#include "Global.h"
|
||||||
|
|
||||||
|
#include <QStringList>
|
||||||
|
#include <QFile>
|
||||||
|
#include <QFileInfo>
|
||||||
|
#include <QProcess>
|
||||||
|
#include <QUrl>
|
||||||
|
#include <QEventLoop>
|
||||||
|
#include <QTimer>
|
||||||
|
|
||||||
|
///////////////////////////////////////////////////////////////////////////////
|
||||||
|
// CONSTANTS
|
||||||
|
///////////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
static const char *header_id = "!Update";
|
||||||
|
static const char *section_id = "LameXP";
|
||||||
|
|
||||||
|
static const char *mirror_url_postfix[] =
|
||||||
|
{
|
||||||
|
"update.ver",
|
||||||
|
"update_beta.ver",
|
||||||
|
NULL
|
||||||
|
};
|
||||||
|
|
||||||
|
static const char *update_mirrors_prim[] =
|
||||||
|
{
|
||||||
|
"http://muldersoft.com/",
|
||||||
|
"http://mulder.bplaced.net/",
|
||||||
|
"http://mulder.cwsurf.de/",
|
||||||
|
"http://mulder.6te.net/",
|
||||||
|
"http://mulder.webuda.com/",
|
||||||
|
"http://mulder.byethost13.com/",
|
||||||
|
"http://muldersoft.kilu.de/",
|
||||||
|
"http://muldersoft.zxq.net/",
|
||||||
|
"http://lamexp.sourceforge.net/",
|
||||||
|
"http://lamexp.berlios.de/",
|
||||||
|
"http://lordmulder.github.com/LameXP/",
|
||||||
|
"http://lord_mulder.bitbucket.org/",
|
||||||
|
"http://www.tricksoft.de/",
|
||||||
|
NULL
|
||||||
|
};
|
||||||
|
|
||||||
|
static const char *update_mirrors_back[] =
|
||||||
|
{
|
||||||
|
"http://mplayer.savedonthe.net/",
|
||||||
|
NULL
|
||||||
|
};
|
||||||
|
|
||||||
|
static const char *known_hosts[] = //Taken form: http://www.alexa.com/topsites !!!
|
||||||
|
{
|
||||||
|
"http://www.163.com/",
|
||||||
|
"http://www.ac3filter.net/",
|
||||||
|
"http://www.amazon.com/",
|
||||||
|
"http://www.aol.com/",
|
||||||
|
"http://www.apache.org/",
|
||||||
|
"http://www.apple.com/",
|
||||||
|
"http://www.adobe.com/",
|
||||||
|
"http://www.avidemux.org/",
|
||||||
|
"http://www.babylon.com/",
|
||||||
|
"http://www.baidu.com/",
|
||||||
|
"http://www.bbc.co.uk/",
|
||||||
|
"http://www.berlios.de/",
|
||||||
|
"http://www.bing.com/",
|
||||||
|
"http://www.cnet.com/",
|
||||||
|
"http://cnzz.com/",
|
||||||
|
"http://codecs.com/",
|
||||||
|
"http://www.codeplex.com/",
|
||||||
|
"http://qt.digia.com/",
|
||||||
|
"http://www.ebay.com/",
|
||||||
|
"http://www.equation.com/",
|
||||||
|
"http://fc2.com/",
|
||||||
|
"http://www.ffmpeg.org/",
|
||||||
|
"http://www.flickr.com/",
|
||||||
|
"http://blog.gitorious.org/",
|
||||||
|
"http://git-scm.com/",
|
||||||
|
"http://www.gnome.org/",
|
||||||
|
"http://www.gnu.org/",
|
||||||
|
"http://go.com/",
|
||||||
|
"http://code.google.com/",
|
||||||
|
"http://www.heise.de/",
|
||||||
|
"http://www.huffingtonpost.co.uk/",
|
||||||
|
"http://www.iana.org/",
|
||||||
|
"http://www.imdb.com/",
|
||||||
|
"http://www.imgburn.com/",
|
||||||
|
"http://imgur.com/",
|
||||||
|
"http://en.jd.com/",
|
||||||
|
"http://mirrors.kernel.org/",
|
||||||
|
"http://www.libav.org/",
|
||||||
|
"http://www.linkedin.com/about-us",
|
||||||
|
"http://www.livedoor.com/",
|
||||||
|
"http://www.livejournal.com/",
|
||||||
|
"http://mail.ru/",
|
||||||
|
"http://www.mediafire.com/",
|
||||||
|
"http://www.mozilla.org/en-US/",
|
||||||
|
"http://mplayerhq.hu/",
|
||||||
|
"http://www.msn.com/?st=1",
|
||||||
|
"http://oss.netfarm.it/",
|
||||||
|
"http://www.nytimes.com/",
|
||||||
|
"http://www.opera.com/",
|
||||||
|
"http://www.portablefreeware.com/",
|
||||||
|
"http://qt-project.org/",
|
||||||
|
"http://www.quakelive.com/",
|
||||||
|
"http://www.seamonkey-project.org/",
|
||||||
|
"http://www.sina.com.cn/",
|
||||||
|
"http://www.sohu.com/",
|
||||||
|
"http://www.soso.com/",
|
||||||
|
"http://sourceforge.net/",
|
||||||
|
"http://www.spiegel.de/",
|
||||||
|
"http://tdm-gcc.tdragon.net/",
|
||||||
|
"http://www.tdrsmusic.com/",
|
||||||
|
"http://www.ubuntu.com/",
|
||||||
|
"http://status.twitter.com/",
|
||||||
|
"http://www.uol.com.br/",
|
||||||
|
"http://www.videohelp.com/",
|
||||||
|
"http://www.videolan.org/",
|
||||||
|
"http://www.weibo.com/",
|
||||||
|
"http://www.wikipedia.org/",
|
||||||
|
"http://www.winamp.com/",
|
||||||
|
"http://wordpress.com/",
|
||||||
|
"http://us.yahoo.com/",
|
||||||
|
"http://www.yandex.ru/",
|
||||||
|
"http://www.youtube.com/",
|
||||||
|
"http://www.zedo.com/",
|
||||||
|
"http://ffmpeg.zeranoe.com/",
|
||||||
|
NULL
|
||||||
|
};
|
||||||
|
|
||||||
|
static const int MIN_CONNSCORE = 8;
|
||||||
|
static const int VERSION_INFO_EXPIRES_MONTHS = 6;
|
||||||
|
static char *USER_AGENT_STR = "Mozilla/5.0 (X11; Linux i686; rv:7.0.1) Gecko/20111106 IceCat/7.0.1";
|
||||||
|
|
||||||
|
//Helper function
|
||||||
|
static int getMaxProgress(void)
|
||||||
|
{
|
||||||
|
int counter = MIN_CONNSCORE + 2;
|
||||||
|
for(int i = 0; update_mirrors_prim[i]; i++) counter++;
|
||||||
|
for(int i = 0; update_mirrors_back[i]; i++) counter++;
|
||||||
|
return counter;
|
||||||
|
}
|
||||||
|
|
||||||
|
////////////////////////////////////////////////////////////
|
||||||
|
// Update Info Class
|
||||||
|
////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
UpdateInfo::UpdateInfo(void)
|
||||||
|
{
|
||||||
|
resetInfo();
|
||||||
|
}
|
||||||
|
|
||||||
|
void UpdateInfo::resetInfo(void)
|
||||||
|
{
|
||||||
|
m_buildNo = 0;
|
||||||
|
m_buildDate.setDate(1900, 1, 1);
|
||||||
|
m_downloadSite.clear();
|
||||||
|
m_downloadAddress.clear();
|
||||||
|
m_downloadFilename.clear();
|
||||||
|
m_downloadFilecode.clear();
|
||||||
|
}
|
||||||
|
|
||||||
|
////////////////////////////////////////////////////////////
|
||||||
|
// Constructor & Destructor
|
||||||
|
////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
UpdateCheckThread::UpdateCheckThread(const bool betaUpdates, const bool testMode)
|
||||||
|
:
|
||||||
|
m_updateInfo(new UpdateInfo()),
|
||||||
|
m_betaUpdates(betaUpdates),
|
||||||
|
m_testMode(testMode),
|
||||||
|
m_binaryWGet(lamexp_lookup_tool("wget.exe")),
|
||||||
|
m_binaryGnuPG(lamexp_lookup_tool("gpgv.exe")),
|
||||||
|
m_binaryKeys(lamexp_lookup_tool("gpgv.gpg")),
|
||||||
|
m_maxProgress(getMaxProgress())
|
||||||
|
{
|
||||||
|
m_success = false;
|
||||||
|
m_status = UpdateStatus_NotStartedYet;
|
||||||
|
m_progress = 0;
|
||||||
|
|
||||||
|
if(m_binaryWGet.isEmpty() || m_binaryGnuPG.isEmpty() || m_binaryKeys.isEmpty())
|
||||||
|
{
|
||||||
|
THROW("Tools not initialized correctly!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
UpdateCheckThread::~UpdateCheckThread(void)
|
||||||
|
{
|
||||||
|
delete m_updateInfo;
|
||||||
|
}
|
||||||
|
|
||||||
|
////////////////////////////////////////////////////////////
|
||||||
|
// Protected functions
|
||||||
|
////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
void UpdateCheckThread::run(void)
|
||||||
|
{
|
||||||
|
qDebug("Update checker thread started!");
|
||||||
|
|
||||||
|
try
|
||||||
|
{
|
||||||
|
m_testMode ? testKnownHosts() : checkForUpdates();
|
||||||
|
}
|
||||||
|
catch(const std::exception &error)
|
||||||
|
{
|
||||||
|
fflush(stdout); fflush(stderr);
|
||||||
|
fprintf(stderr, "\nGURU MEDITATION !!!\n\nException error:\n%s\n", error.what());
|
||||||
|
lamexp_fatal_exit(L"Unhandeled C++ exception error, application will exit!");
|
||||||
|
}
|
||||||
|
catch(...)
|
||||||
|
{
|
||||||
|
fflush(stdout); fflush(stderr);
|
||||||
|
fprintf(stderr, "\nGURU MEDITATION !!!\n\nUnknown exception error!\n");
|
||||||
|
lamexp_fatal_exit(L"Unhandeled C++ exception error, application will exit!");
|
||||||
|
}
|
||||||
|
|
||||||
|
qDebug("Update checker thread completed.");
|
||||||
|
}
|
||||||
|
|
||||||
|
void UpdateCheckThread::checkForUpdates(void)
|
||||||
|
{
|
||||||
|
// ----- Initialization ----- //
|
||||||
|
|
||||||
|
m_success = false;
|
||||||
|
m_updateInfo->resetInfo();
|
||||||
|
setProgress(0);
|
||||||
|
|
||||||
|
// ----- Test Internet Connection ----- //
|
||||||
|
|
||||||
|
int connectionScore = 0;
|
||||||
|
|
||||||
|
log("Checking internet connection...");
|
||||||
|
setStatus(UpdateStatus_CheckingConnection);
|
||||||
|
|
||||||
|
const int networkStatus = lamexp_network_status();
|
||||||
|
if(networkStatus == lamexp_network_non)
|
||||||
|
{
|
||||||
|
log("", "Operating system reports that the computer is currently offline !!!");
|
||||||
|
setProgress(m_maxProgress);
|
||||||
|
setStatus(UpdateStatus_ErrorNoConnection);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
setProgress(1);
|
||||||
|
|
||||||
|
// ----- Test Known Hosts Connectivity ----- //
|
||||||
|
|
||||||
|
QStringList hostList;
|
||||||
|
for(int i = 0; known_hosts[i]; i++)
|
||||||
|
{
|
||||||
|
hostList << QString::fromLatin1(known_hosts[i]);
|
||||||
|
}
|
||||||
|
|
||||||
|
lamexp_seed_rand();
|
||||||
|
while(!hostList.isEmpty())
|
||||||
|
{
|
||||||
|
QString currentHost = hostList.takeAt(lamexp_rand() % hostList.count());
|
||||||
|
if(connectionScore < MIN_CONNSCORE)
|
||||||
|
{
|
||||||
|
log("", "Testing host:", currentHost);
|
||||||
|
QString outFile = QString("%1/%2.htm").arg(lamexp_temp_folder2(), lamexp_rand_str());
|
||||||
|
bool httpOk = false;
|
||||||
|
if(getFile(currentHost, outFile, 0, &httpOk))
|
||||||
|
{
|
||||||
|
connectionScore++;
|
||||||
|
setProgress(qBound(1, connectionScore + 1, MIN_CONNSCORE + 1));
|
||||||
|
lamexp_sleep(64);
|
||||||
|
}
|
||||||
|
if(httpOk)
|
||||||
|
{
|
||||||
|
connectionScore++;
|
||||||
|
setProgress(qBound(1, connectionScore + 1, MIN_CONNSCORE + 1));
|
||||||
|
lamexp_sleep(64);
|
||||||
|
}
|
||||||
|
QFile::remove(outFile);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if(connectionScore < MIN_CONNSCORE)
|
||||||
|
{
|
||||||
|
setProgress(m_maxProgress);
|
||||||
|
setStatus(UpdateStatus_ErrorConnectionTestFailed);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
// ----- Build Mirror List ----- //
|
||||||
|
|
||||||
|
log("", "----", "", "Checking for updates online...");
|
||||||
|
setStatus(UpdateStatus_FetchingUpdates);
|
||||||
|
|
||||||
|
QStringList mirrorList;
|
||||||
|
for(int index = 0; update_mirrors_prim[index]; index++)
|
||||||
|
{
|
||||||
|
mirrorList << QString::fromLatin1(update_mirrors_prim[index]);
|
||||||
|
}
|
||||||
|
|
||||||
|
lamexp_seed_rand();
|
||||||
|
if(const int len = mirrorList.count())
|
||||||
|
{
|
||||||
|
const int rounds = len * 1097;
|
||||||
|
for(int i = 0; i < rounds; i++)
|
||||||
|
{
|
||||||
|
mirrorList.swap(i % len, lamexp_rand() % len);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
for(int index = 0; update_mirrors_back[index]; index++)
|
||||||
|
{
|
||||||
|
mirrorList << QString::fromLatin1(update_mirrors_back[index]);
|
||||||
|
}
|
||||||
|
|
||||||
|
// ----- Fetch Update Info From Server ----- //
|
||||||
|
|
||||||
|
while(!mirrorList.isEmpty())
|
||||||
|
{
|
||||||
|
QString currentMirror = mirrorList.takeFirst();
|
||||||
|
setProgress(m_progress + 1);
|
||||||
|
if(!m_success)
|
||||||
|
{
|
||||||
|
if(tryUpdateMirror(m_updateInfo, currentMirror))
|
||||||
|
{
|
||||||
|
m_success = true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
lamexp_sleep(64);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
setProgress(m_maxProgress);
|
||||||
|
|
||||||
|
if(m_success)
|
||||||
|
{
|
||||||
|
if(m_updateInfo->m_buildNo > lamexp_version_build())
|
||||||
|
{
|
||||||
|
setStatus(UpdateStatus_CompletedUpdateAvailable);
|
||||||
|
}
|
||||||
|
else if(m_updateInfo->m_buildNo == lamexp_version_build())
|
||||||
|
{
|
||||||
|
setStatus(UpdateStatus_CompletedNoUpdates);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
setStatus(UpdateStatus_CompletedNewVersionOlder);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
setStatus(UpdateStatus_ErrorFetchUpdateInfo);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void UpdateCheckThread::testKnownHosts(void)
|
||||||
|
{
|
||||||
|
QStringList hostList;
|
||||||
|
for(int i = 0; known_hosts[i]; i++)
|
||||||
|
{
|
||||||
|
hostList << QString::fromLatin1(known_hosts[i]);
|
||||||
|
}
|
||||||
|
|
||||||
|
qDebug("\n[Known Hosts]");
|
||||||
|
log("Testing all known hosts...", "", "---");
|
||||||
|
|
||||||
|
int hostCount = hostList.count();
|
||||||
|
while(!hostList.isEmpty())
|
||||||
|
{
|
||||||
|
QString currentHost = hostList.takeFirst();
|
||||||
|
qDebug("Testing: %s", currentHost.toLatin1().constData());
|
||||||
|
log("", "Testing:", currentHost, "");
|
||||||
|
QString outFile = QString("%1/%2.htm").arg(lamexp_temp_folder2(), lamexp_rand_str());
|
||||||
|
bool httpOk = false;
|
||||||
|
if(!getFile(currentHost, outFile, 0, &httpOk))
|
||||||
|
{
|
||||||
|
if(httpOk)
|
||||||
|
{
|
||||||
|
qWarning("\nConnectivity test was SLOW on the following site:\n%s\n", currentHost.toLatin1().constData());
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
qWarning("\nConnectivity test FAILED on the following site:\n%s\n", currentHost.toLatin1().constData());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
log("", "---");
|
||||||
|
QFile::remove(outFile);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
////////////////////////////////////////////////////////////
|
||||||
|
// PRIVATE FUNCTIONS
|
||||||
|
////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
void UpdateCheckThread::setStatus(const int status)
|
||||||
|
{
|
||||||
|
if(m_status != status)
|
||||||
|
{
|
||||||
|
m_status = status;
|
||||||
|
emit statusChanged(status);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void UpdateCheckThread::setProgress(const int progress)
|
||||||
|
{
|
||||||
|
if(m_progress != progress)
|
||||||
|
{
|
||||||
|
m_progress = progress;
|
||||||
|
emit progressChanged(progress);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void UpdateCheckThread::log(const QString &str1, const QString &str2, const QString &str3, const QString &str4)
|
||||||
|
{
|
||||||
|
if(!str1.isNull()) emit messageLogged(str1);
|
||||||
|
if(!str2.isNull()) emit messageLogged(str2);
|
||||||
|
if(!str3.isNull()) emit messageLogged(str3);
|
||||||
|
if(!str4.isNull()) emit messageLogged(str4);
|
||||||
|
}
|
||||||
|
|
||||||
|
bool UpdateCheckThread::tryUpdateMirror(UpdateInfo *updateInfo, const QString &url)
|
||||||
|
{
|
||||||
|
bool success = false;
|
||||||
|
log("", "Trying mirror:", url);
|
||||||
|
|
||||||
|
QString randPart = lamexp_rand_str();
|
||||||
|
QString outFileVersionInfo = QString("%1/%2.ver").arg(lamexp_temp_folder2(), randPart);
|
||||||
|
QString outFileSignature = QString("%1/%2.sig").arg(lamexp_temp_folder2(), randPart);
|
||||||
|
|
||||||
|
log("", "Downloading update info:");
|
||||||
|
bool ok1 = getFile(QString("%1%2").arg(url, mirror_url_postfix[m_betaUpdates ? 1 : 0]), outFileVersionInfo);
|
||||||
|
|
||||||
|
log("", "Downloading signature:");
|
||||||
|
bool ok2 = getFile(QString("%1%2.sig").arg(url, mirror_url_postfix[m_betaUpdates ? 1 : 0]), outFileSignature);
|
||||||
|
|
||||||
|
if(ok1 && ok2)
|
||||||
|
{
|
||||||
|
log("", "Download okay, checking signature:");
|
||||||
|
if(checkSignature(outFileVersionInfo, outFileSignature))
|
||||||
|
{
|
||||||
|
log("", "Signature okay, parsing info:");
|
||||||
|
success = parseVersionInfo(outFileVersionInfo, updateInfo);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
log("", "Bad signature, take care!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
log("", "Download has failed!");
|
||||||
|
}
|
||||||
|
|
||||||
|
QFile::remove(outFileVersionInfo);
|
||||||
|
QFile::remove(outFileSignature);
|
||||||
|
|
||||||
|
return success;
|
||||||
|
}
|
||||||
|
|
||||||
|
bool UpdateCheckThread::getFile(const QString &url, const QString &outFile, unsigned int maxRedir, bool *httpOk)
|
||||||
|
{
|
||||||
|
QFileInfo output(outFile);
|
||||||
|
output.setCaching(false);
|
||||||
|
if(httpOk) *httpOk = false;
|
||||||
|
|
||||||
|
if(output.exists())
|
||||||
|
{
|
||||||
|
QFile::remove(output.canonicalFilePath());
|
||||||
|
if(output.exists())
|
||||||
|
{
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
QProcess process;
|
||||||
|
lamexp_init_process(process, output.absolutePath());
|
||||||
|
|
||||||
|
QStringList args;
|
||||||
|
args << "--no-cache" << "--no-dns-cache" << QString().sprintf("--max-redirect=%u", maxRedir);
|
||||||
|
args << QString("--referer=%1://%2/").arg(QUrl(url).scheme(), QUrl(url).host()) << "-U" << USER_AGENT_STR;
|
||||||
|
args << "-O" << output.fileName() << url;
|
||||||
|
|
||||||
|
QEventLoop loop;
|
||||||
|
connect(&process, SIGNAL(error(QProcess::ProcessError)), &loop, SLOT(quit()));
|
||||||
|
connect(&process, SIGNAL(finished(int,QProcess::ExitStatus)), &loop, SLOT(quit()));
|
||||||
|
connect(&process, SIGNAL(readyRead()), &loop, SLOT(quit()));
|
||||||
|
|
||||||
|
QTimer timer;
|
||||||
|
timer.setSingleShot(true);
|
||||||
|
timer.setInterval(25000);
|
||||||
|
connect(&timer, SIGNAL(timeout()), &loop, SLOT(quit()));
|
||||||
|
|
||||||
|
const QRegExp httpResponseOK("200 OK$");
|
||||||
|
|
||||||
|
process.start(m_binaryWGet, args);
|
||||||
|
|
||||||
|
if(!process.waitForStarted())
|
||||||
|
{
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
timer.start();
|
||||||
|
|
||||||
|
while(process.state() == QProcess::Running)
|
||||||
|
{
|
||||||
|
loop.exec();
|
||||||
|
bool bTimeOut = (!timer.isActive());
|
||||||
|
while(process.canReadLine())
|
||||||
|
{
|
||||||
|
QString line = QString::fromLatin1(process.readLine()).simplified();
|
||||||
|
if(line.contains(httpResponseOK))
|
||||||
|
{
|
||||||
|
line.append(" [OK]");
|
||||||
|
if(httpOk) *httpOk = true;
|
||||||
|
}
|
||||||
|
log(line);
|
||||||
|
}
|
||||||
|
if(bTimeOut)
|
||||||
|
{
|
||||||
|
qWarning("WGet process timed out <-- killing!");
|
||||||
|
process.kill();
|
||||||
|
process.waitForFinished();
|
||||||
|
log("!!! TIMEOUT !!!");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
timer.stop();
|
||||||
|
timer.disconnect(&timer, SIGNAL(timeout()), &loop, SLOT(quit()));
|
||||||
|
|
||||||
|
log(QString().sprintf("Exited with code %d", process.exitCode()));
|
||||||
|
return (process.exitCode() == 0) && output.exists() && output.isFile();
|
||||||
|
}
|
||||||
|
|
||||||
|
bool UpdateCheckThread::checkSignature(const QString &file, const QString &signature)
|
||||||
|
{
|
||||||
|
if(QFileInfo(file).absolutePath().compare(QFileInfo(signature).absolutePath(), Qt::CaseInsensitive) != 0)
|
||||||
|
{
|
||||||
|
qWarning("CheckSignature: File and signature should be in same folder!");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
if(QFileInfo(file).absolutePath().compare(QFileInfo(m_binaryKeys).absolutePath(), Qt::CaseInsensitive) != 0)
|
||||||
|
{
|
||||||
|
qWarning("CheckSignature: File and keyring should be in same folder!");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
QProcess process;
|
||||||
|
lamexp_init_process(process, QFileInfo(file).absolutePath());
|
||||||
|
|
||||||
|
QEventLoop loop;
|
||||||
|
connect(&process, SIGNAL(error(QProcess::ProcessError)), &loop, SLOT(quit()));
|
||||||
|
connect(&process, SIGNAL(finished(int,QProcess::ExitStatus)), &loop, SLOT(quit()));
|
||||||
|
connect(&process, SIGNAL(readyRead()), &loop, SLOT(quit()));
|
||||||
|
|
||||||
|
process.start(m_binaryGnuPG, QStringList() << "--homedir" << "." << "--keyring" << QFileInfo(m_binaryKeys).fileName() << QFileInfo(signature).fileName() << QFileInfo(file).fileName());
|
||||||
|
|
||||||
|
if(!process.waitForStarted())
|
||||||
|
{
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
while(process.state() == QProcess::Running)
|
||||||
|
{
|
||||||
|
loop.exec();
|
||||||
|
while(process.canReadLine())
|
||||||
|
{
|
||||||
|
log(QString::fromLatin1(process.readLine()).simplified());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
log(QString().sprintf("Exited with code %d", process.exitCode()));
|
||||||
|
return (process.exitCode() == 0);
|
||||||
|
}
|
||||||
|
|
||||||
|
bool UpdateCheckThread::parseVersionInfo(const QString &file, UpdateInfo *updateInfo)
|
||||||
|
{
|
||||||
|
QRegExp value("^(\\w+)=(.+)$");
|
||||||
|
QRegExp section("^\\[(.+)\\]$");
|
||||||
|
|
||||||
|
QDate updateInfoDate;
|
||||||
|
updateInfo->resetInfo();
|
||||||
|
|
||||||
|
QFile data(file);
|
||||||
|
if(!data.open(QIODevice::ReadOnly))
|
||||||
|
{
|
||||||
|
qWarning("Cannot open update info file for reading!");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
bool inHeader = false;
|
||||||
|
bool inSection = false;
|
||||||
|
|
||||||
|
while(!data.atEnd())
|
||||||
|
{
|
||||||
|
QString line = QString::fromLatin1(data.readLine()).trimmed();
|
||||||
|
if(section.indexIn(line) >= 0)
|
||||||
|
{
|
||||||
|
log(QString("Sec: [%1]").arg(section.cap(1)));
|
||||||
|
inSection = (section.cap(1).compare(section_id, Qt::CaseInsensitive) == 0);
|
||||||
|
inHeader = (section.cap(1).compare(header_id, Qt::CaseInsensitive) == 0);
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
if(inSection && (value.indexIn(line) >= 0))
|
||||||
|
{
|
||||||
|
log(QString("Val: '%1' ==> '%2").arg(value.cap(1), value.cap(2)));
|
||||||
|
if(value.cap(1).compare("BuildNo", Qt::CaseInsensitive) == 0)
|
||||||
|
{
|
||||||
|
bool ok = false;
|
||||||
|
unsigned int temp = value.cap(2).toUInt(&ok);
|
||||||
|
if(ok) updateInfo->m_buildNo = temp;
|
||||||
|
}
|
||||||
|
else if(value.cap(1).compare("BuildDate", Qt::CaseInsensitive) == 0)
|
||||||
|
{
|
||||||
|
QDate temp = QDate::fromString(value.cap(2).trimmed(), Qt::ISODate);
|
||||||
|
if(temp.isValid()) updateInfo->m_buildDate = temp;
|
||||||
|
}
|
||||||
|
else if(value.cap(1).compare("DownloadSite", Qt::CaseInsensitive) == 0)
|
||||||
|
{
|
||||||
|
updateInfo->m_downloadSite = value.cap(2).trimmed();
|
||||||
|
}
|
||||||
|
else if(value.cap(1).compare("DownloadAddress", Qt::CaseInsensitive) == 0)
|
||||||
|
{
|
||||||
|
updateInfo->m_downloadAddress = value.cap(2).trimmed();
|
||||||
|
}
|
||||||
|
else if(value.cap(1).compare("DownloadFilename", Qt::CaseInsensitive) == 0)
|
||||||
|
{
|
||||||
|
updateInfo->m_downloadFilename = value.cap(2).trimmed();
|
||||||
|
}
|
||||||
|
else if(value.cap(1).compare("DownloadFilecode", Qt::CaseInsensitive) == 0)
|
||||||
|
{
|
||||||
|
updateInfo->m_downloadFilecode = value.cap(2).trimmed();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if(inHeader && (value.indexIn(line) >= 0))
|
||||||
|
{
|
||||||
|
log(QString("Val: '%1' ==> '%2").arg(value.cap(1), value.cap(2)));
|
||||||
|
if(value.cap(1).compare("TimestampCreated", Qt::CaseInsensitive) == 0)
|
||||||
|
{
|
||||||
|
QDate temp = QDate::fromString(value.cap(2).trimmed(), Qt::ISODate);
|
||||||
|
if(temp.isValid()) updateInfoDate = temp;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if(!updateInfoDate.isValid())
|
||||||
|
{
|
||||||
|
updateInfo->resetInfo();
|
||||||
|
log("WARNING: Version info timestamp is missing!");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
else if(updateInfoDate.addMonths(VERSION_INFO_EXPIRES_MONTHS) < lamexp_current_date_safe())
|
||||||
|
{
|
||||||
|
updateInfo->resetInfo();
|
||||||
|
log(QString::fromLatin1("WARNING: This version info has expired at %1!").arg(updateInfoDate.addMonths(VERSION_INFO_EXPIRES_MONTHS).toString(Qt::ISODate)));
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
else if(lamexp_current_date_safe() < updateInfoDate)
|
||||||
|
{
|
||||||
|
log("Version info is from the future, take care!");
|
||||||
|
qWarning("Version info is from the future, take care!");
|
||||||
|
}
|
||||||
|
|
||||||
|
bool complete = true;
|
||||||
|
|
||||||
|
if(!(updateInfo->m_buildNo > 0)) complete = false;
|
||||||
|
if(!(updateInfo->m_buildDate.year() >= 2010)) complete = false;
|
||||||
|
if(updateInfo->m_downloadSite.isEmpty()) complete = false;
|
||||||
|
if(updateInfo->m_downloadAddress.isEmpty()) complete = false;
|
||||||
|
if(updateInfo->m_downloadFilename.isEmpty()) complete = false;
|
||||||
|
if(updateInfo->m_downloadFilecode.isEmpty()) complete = false;
|
||||||
|
|
||||||
|
if(!complete)
|
||||||
|
{
|
||||||
|
log("WARNING: Version info is incomplete!");
|
||||||
|
}
|
||||||
|
|
||||||
|
return complete;
|
||||||
|
}
|
||||||
|
|
||||||
|
////////////////////////////////////////////////////////////
|
||||||
|
// SLOTS
|
||||||
|
////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
/*NONE*/
|
||||||
|
|
||||||
|
////////////////////////////////////////////////////////////
|
||||||
|
// EVENTS
|
||||||
|
////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
/*NONE*/
|
108
src/Thread_CheckUpdate.h
Normal file
108
src/Thread_CheckUpdate.h
Normal file
@ -0,0 +1,108 @@
|
|||||||
|
///////////////////////////////////////////////////////////////////////////////
|
||||||
|
// LameXP - Audio Encoder Front-End
|
||||||
|
// Copyright (C) 2004-2013 LoRd_MuldeR <MuldeR2@GMX.de>
|
||||||
|
//
|
||||||
|
// This program is free software; you can redistribute it and/or modify
|
||||||
|
// it under the terms of the GNU General Public License as published by
|
||||||
|
// the Free Software Foundation; either version 2 of the License, or
|
||||||
|
// (at your option) any later version, but always including the *additional*
|
||||||
|
// restrictions defined in the "License.txt" file.
|
||||||
|
//
|
||||||
|
// This program is distributed in the hope that it will be useful,
|
||||||
|
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
// GNU General Public License for more details.
|
||||||
|
//
|
||||||
|
// You should have received a copy of the GNU General Public License along
|
||||||
|
// with this program; if not, write to the Free Software Foundation, Inc.,
|
||||||
|
// 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||||
|
//
|
||||||
|
// http://www.gnu.org/licenses/gpl-2.0.txt
|
||||||
|
///////////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
#pragma once
|
||||||
|
|
||||||
|
#include <QThread>
|
||||||
|
#include <QDate>
|
||||||
|
|
||||||
|
///////////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
class UpdateInfo
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
UpdateInfo(void);
|
||||||
|
void resetInfo(void);
|
||||||
|
|
||||||
|
unsigned int m_buildNo;
|
||||||
|
QDate m_buildDate;
|
||||||
|
QString m_downloadSite;
|
||||||
|
QString m_downloadAddress;
|
||||||
|
QString m_downloadFilename;
|
||||||
|
QString m_downloadFilecode;
|
||||||
|
};
|
||||||
|
|
||||||
|
///////////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
class UpdateCheckThread : public QThread
|
||||||
|
{
|
||||||
|
Q_OBJECT
|
||||||
|
|
||||||
|
public:
|
||||||
|
enum
|
||||||
|
{
|
||||||
|
UpdateStatus_NotStartedYet = 0,
|
||||||
|
UpdateStatus_CheckingConnection = 1,
|
||||||
|
UpdateStatus_FetchingUpdates = 2,
|
||||||
|
UpdateStatus_CompletedUpdateAvailable = 3,
|
||||||
|
UpdateStatus_CompletedNoUpdates = 4,
|
||||||
|
UpdateStatus_CompletedNewVersionOlder = 5,
|
||||||
|
UpdateStatus_ErrorNoConnection = 6,
|
||||||
|
UpdateStatus_ErrorConnectionTestFailed = 7,
|
||||||
|
UpdateStatus_ErrorFetchUpdateInfo = 8
|
||||||
|
}
|
||||||
|
update_status_t;
|
||||||
|
|
||||||
|
UpdateCheckThread(const bool betaUpdates, const bool testMode = false);
|
||||||
|
~UpdateCheckThread(void);
|
||||||
|
|
||||||
|
const int getUpdateStatus(void) const { return m_status; }
|
||||||
|
const bool getSuccess(void) const { return m_success; };
|
||||||
|
const int getMaximumProgress(void) const { return m_maxProgress; };
|
||||||
|
const int getCurrentProgress(void) const { return m_progress; };
|
||||||
|
const UpdateInfo *getUpdateInfo(void) const { return m_updateInfo; }
|
||||||
|
|
||||||
|
protected:
|
||||||
|
void run(void);
|
||||||
|
void checkForUpdates(void);
|
||||||
|
void testKnownHosts(void);
|
||||||
|
|
||||||
|
signals:
|
||||||
|
void statusChanged(const int status);
|
||||||
|
void progressChanged(const int progress);
|
||||||
|
void messageLogged(const QString &text);
|
||||||
|
|
||||||
|
private:
|
||||||
|
const int m_maxProgress;
|
||||||
|
UpdateInfo *const m_updateInfo;
|
||||||
|
|
||||||
|
const bool m_betaUpdates;
|
||||||
|
const bool m_testMode;
|
||||||
|
|
||||||
|
const QString m_binaryWGet;
|
||||||
|
const QString m_binaryGnuPG;
|
||||||
|
const QString m_binaryKeys;
|
||||||
|
|
||||||
|
volatile bool m_success;
|
||||||
|
|
||||||
|
int m_status;
|
||||||
|
int m_progress;
|
||||||
|
|
||||||
|
inline void setStatus(const int status);
|
||||||
|
inline void setProgress(const int progress);
|
||||||
|
inline void log(const QString &str1, const QString &str2 = QString(), const QString &str3 = QString(), const QString &str4 = QString());
|
||||||
|
|
||||||
|
bool getFile(const QString &url, const QString &outFile, unsigned int maxRedir = 5, bool *httpOk = NULL);
|
||||||
|
bool tryUpdateMirror(UpdateInfo *updateInfo, const QString &url);
|
||||||
|
bool checkSignature(const QString &file, const QString &signature);
|
||||||
|
bool parseVersionInfo(const QString &file, UpdateInfo *updateInfo);
|
||||||
|
};
|
Loading…
Reference in New Issue
Block a user