diff options
author | Thomas Preud'homme <robotux@celest.fr> | 2017-11-24 23:24:09 +0000 |
---|---|---|
committer | Thomas Preud'homme <robotux@celest.fr> | 2017-11-24 23:24:09 +0000 |
commit | b3c8bdcc0d1e4b2ab298847a7902b6d60410a5bc (patch) | |
tree | 8fce8a51adfb245db8ab2a76831661780c0c713e /plugins-alternative/Themes/Clean | |
parent | e297dbd8052ef4e66f069e2dd1865ae7fa8af28e (diff) |
New upstream version 1.2.3.6
Diffstat (limited to 'plugins-alternative/Themes/Clean')
38 files changed, 673 insertions, 550 deletions
diff --git a/plugins-alternative/Themes/Clean/Languages/ar/translation.ts b/plugins-alternative/Themes/Clean/Languages/ar/translation.ts index 81df74e..54104e3 100644 --- a/plugins-alternative/Themes/Clean/Languages/ar/translation.ts +++ b/plugins-alternative/Themes/Clean/Languages/ar/translation.ts @@ -4,7 +4,7 @@ <context> <name>InterfacePlugin</name> <message> - <location filename="../../interface.cpp" line="145"/> + <location filename="../../interface.cpp" line="142"/> <source>%1/%2 files, %3/%4</source> <translation type="unfinished"></translation> </message> @@ -18,7 +18,7 @@ </message> <message> <location filename="../../interface.ui" line="44"/> - <source>In wait</source> + <source>Waiting</source> <translation type="unfinished"></translation> </message> <message> diff --git a/plugins-alternative/Themes/Clean/Languages/de/translation.ts b/plugins-alternative/Themes/Clean/Languages/de/translation.ts index 7ea1972..0a833ee 100644 --- a/plugins-alternative/Themes/Clean/Languages/de/translation.ts +++ b/plugins-alternative/Themes/Clean/Languages/de/translation.ts @@ -4,9 +4,9 @@ <context> <name>InterfacePlugin</name> <message> - <location filename="../../interface.cpp" line="145"/> + <location filename="../../interface.cpp" line="142"/> <source>%1/%2 files, %3/%4</source> - <translation>%1/%2 dateien, %3/%4</translation> + <translation>%1/%2 Dateien, %3/%4</translation> </message> </context> <context> @@ -18,8 +18,8 @@ </message> <message> <location filename="../../interface.ui" line="44"/> - <source>In wait</source> - <translation>auf der Lauer</translation> + <source>Waiting</source> + <translation>Warten</translation> </message> <message> <location filename="../../interface.ui" line="78"/> @@ -34,22 +34,22 @@ <message> <location filename="../../interface.ui" line="96"/> <source>Move file(s)</source> - <translation>Bewegen Sie Datei (en)</translation> + <translation>Datei (en) verschieben</translation> </message> <message> <location filename="../../interface.ui" line="105"/> <source>Move folder</source> - <translation>bewegen Sie Ordner</translation> + <translation>Ordner verschieben</translation> </message> <message> <location filename="../../interface.ui" line="114"/> <source>Copy file(s)</source> - <translation>Kopieren Sie die Datei (en)</translation> + <translation>Datei (en) kopieren</translation> </message> <message> <location filename="../../interface.ui" line="123"/> <source>Copy folder</source> - <translation>kopieren Sie das Verzeichnis</translation> + <translation>Ordner kopieren</translation> </message> </context> </TS> diff --git a/plugins-alternative/Themes/Clean/Languages/el/translation.ts b/plugins-alternative/Themes/Clean/Languages/el/translation.ts index 81df74e..54104e3 100644 --- a/plugins-alternative/Themes/Clean/Languages/el/translation.ts +++ b/plugins-alternative/Themes/Clean/Languages/el/translation.ts @@ -4,7 +4,7 @@ <context> <name>InterfacePlugin</name> <message> - <location filename="../../interface.cpp" line="145"/> + <location filename="../../interface.cpp" line="142"/> <source>%1/%2 files, %3/%4</source> <translation type="unfinished"></translation> </message> @@ -18,7 +18,7 @@ </message> <message> <location filename="../../interface.ui" line="44"/> - <source>In wait</source> + <source>Waiting</source> <translation type="unfinished"></translation> </message> <message> diff --git a/plugins-alternative/Themes/Clean/Languages/en/translation.ts b/plugins-alternative/Themes/Clean/Languages/en/translation.ts new file mode 100644 index 0000000..d13892c --- /dev/null +++ b/plugins-alternative/Themes/Clean/Languages/en/translation.ts @@ -0,0 +1,55 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.0" language="en"> +<context> + <name>InterfacePlugin</name> + <message> + <location filename="../../interface.cpp" line="142"/> + <source>%1/%2 files, %3/%4</source> + <translation type="unfinished"></translation> + </message> +</context> +<context> + <name>interface</name> + <message> + <location filename="../../interface.ui" line="32"/> + <source>Action:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../../interface.ui" line="44"/> + <source>Waiting</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../../interface.ui" line="78"/> + <source>Add file</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../../interface.ui" line="87"/> + <source>Add folder</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../../interface.ui" line="96"/> + <source>Move file(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../../interface.ui" line="105"/> + <source>Move folder</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../../interface.ui" line="114"/> + <source>Copy file(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../../interface.ui" line="123"/> + <source>Copy folder</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/plugins-alternative/Themes/Clean/Languages/es/translation.ts b/plugins-alternative/Themes/Clean/Languages/es/translation.ts index 70b8246..8c54e8a 100644 --- a/plugins-alternative/Themes/Clean/Languages/es/translation.ts +++ b/plugins-alternative/Themes/Clean/Languages/es/translation.ts @@ -4,7 +4,7 @@ <context> <name>InterfacePlugin</name> <message> - <location filename="../../interface.cpp" line="145"/> + <location filename="../../interface.cpp" line="142"/> <source>%1/%2 files, %3/%4</source> <translation>%1/%2 archivos, %3/%4</translation> </message> @@ -17,9 +17,13 @@ <translation>Acción:</translation> </message> <message> - <location filename="../../interface.ui" line="44"/> <source>In wait</source> - <translation>En espera</translation> + <translation type="obsolete">En espera</translation> + </message> + <message> + <location filename="../../interface.ui" line="44"/> + <source>Waiting</source> + <translation type="unfinished"></translation> </message> <message> <location filename="../../interface.ui" line="78"/> diff --git a/plugins-alternative/Themes/Clean/Languages/fr/translation.ts b/plugins-alternative/Themes/Clean/Languages/fr/translation.ts index 51fd57f..bdc0621 100644 --- a/plugins-alternative/Themes/Clean/Languages/fr/translation.ts +++ b/plugins-alternative/Themes/Clean/Languages/fr/translation.ts @@ -4,7 +4,7 @@ <context> <name>InterfacePlugin</name> <message> - <location filename="../../interface.cpp" line="145"/> + <location filename="../../interface.cpp" line="142"/> <source>%1/%2 files, %3/%4</source> <translation>%1/%2 fichiers, %3/%4</translation> </message> @@ -17,9 +17,8 @@ <translation>Action:</translation> </message> <message> - <location filename="../../interface.ui" line="44"/> <source>In wait</source> - <translation>En attente</translation> + <translation type="obsolete">En attente</translation> </message> <message> <location filename="../../interface.ui" line="96"/> @@ -47,6 +46,11 @@ <translation>Ajouter un dossier</translation> </message> <message> + <location filename="../../interface.ui" line="44"/> + <source>Waiting</source> + <translation type="unfinished"></translation> + </message> + <message> <location filename="../../interface.ui" line="78"/> <source>Add file</source> <translation>Ajout de fichier</translation> diff --git a/plugins-alternative/Themes/Clean/Languages/hi/translation.ts b/plugins-alternative/Themes/Clean/Languages/hi/translation.ts index 81df74e..54104e3 100644 --- a/plugins-alternative/Themes/Clean/Languages/hi/translation.ts +++ b/plugins-alternative/Themes/Clean/Languages/hi/translation.ts @@ -4,7 +4,7 @@ <context> <name>InterfacePlugin</name> <message> - <location filename="../../interface.cpp" line="145"/> + <location filename="../../interface.cpp" line="142"/> <source>%1/%2 files, %3/%4</source> <translation type="unfinished"></translation> </message> @@ -18,7 +18,7 @@ </message> <message> <location filename="../../interface.ui" line="44"/> - <source>In wait</source> + <source>Waiting</source> <translation type="unfinished"></translation> </message> <message> diff --git a/plugins-alternative/Themes/Clean/Languages/hu/translation.ts b/plugins-alternative/Themes/Clean/Languages/hu/translation.ts new file mode 100644 index 0000000..e5a3bcc --- /dev/null +++ b/plugins-alternative/Themes/Clean/Languages/hu/translation.ts @@ -0,0 +1,55 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.0" language="hu"> +<context> + <name>InterfacePlugin</name> + <message> + <location filename="../../interface.cpp" line="142"/> + <source>%1/%2 files, %3/%4</source> + <translation>%1/%2 fájl, %3/%4</translation> + </message> +</context> +<context> + <name>interface</name> + <message> + <location filename="../../interface.ui" line="32"/> + <source>Action:</source> + <translation>Művelet:</translation> + </message> + <message> + <location filename="../../interface.ui" line="44"/> + <source>Waiting</source> + <translation>Várakozás</translation> + </message> + <message> + <location filename="../../interface.ui" line="78"/> + <source>Add file</source> + <translation>Fájl hozzáadása</translation> + </message> + <message> + <location filename="../../interface.ui" line="87"/> + <source>Add folder</source> + <translation>Mappa hozzáadása</translation> + </message> + <message> + <location filename="../../interface.ui" line="96"/> + <source>Move file(s)</source> + <translation>Fájl(ok) mozgatása</translation> + </message> + <message> + <location filename="../../interface.ui" line="105"/> + <source>Move folder</source> + <translation>Mappa mozgatása</translation> + </message> + <message> + <location filename="../../interface.ui" line="114"/> + <source>Copy file(s)</source> + <translation>Fájl(ok) másolása</translation> + </message> + <message> + <location filename="../../interface.ui" line="123"/> + <source>Copy folder</source> + <translation>Mappa másolása</translation> + </message> +</context> +</TS> diff --git a/plugins-alternative/Themes/Clean/Languages/id/translation.ts b/plugins-alternative/Themes/Clean/Languages/id/translation.ts index 81df74e..54104e3 100644 --- a/plugins-alternative/Themes/Clean/Languages/id/translation.ts +++ b/plugins-alternative/Themes/Clean/Languages/id/translation.ts @@ -4,7 +4,7 @@ <context> <name>InterfacePlugin</name> <message> - <location filename="../../interface.cpp" line="145"/> + <location filename="../../interface.cpp" line="142"/> <source>%1/%2 files, %3/%4</source> <translation type="unfinished"></translation> </message> @@ -18,7 +18,7 @@ </message> <message> <location filename="../../interface.ui" line="44"/> - <source>In wait</source> + <source>Waiting</source> <translation type="unfinished"></translation> </message> <message> diff --git a/plugins-alternative/Themes/Clean/Languages/it/translation.ts b/plugins-alternative/Themes/Clean/Languages/it/translation.ts index b44bd5f..b94ac7b 100644 --- a/plugins-alternative/Themes/Clean/Languages/it/translation.ts +++ b/plugins-alternative/Themes/Clean/Languages/it/translation.ts @@ -4,9 +4,9 @@ <context> <name>InterfacePlugin</name> <message> - <location filename="../../interface.cpp" line="145"/> + <location filename="../../interface.cpp" line="142"/> <source>%1/%2 files, %3/%4</source> - <translation></translation> + <translation>%1/%2 file, %3/%4</translation> </message> </context> <context> @@ -17,9 +17,13 @@ <translation>Azione:</translation> </message> <message> - <location filename="../../interface.ui" line="44"/> <source>In wait</source> - <translation>In attesa</translation> + <translation type="obsolete">In attesa</translation> + </message> + <message> + <location filename="../../interface.ui" line="44"/> + <source>Waiting</source> + <translation type="unfinished"></translation> </message> <message> <location filename="../../interface.ui" line="78"/> @@ -34,22 +38,22 @@ <message> <location filename="../../interface.ui" line="96"/> <source>Move file(s)</source> - <translation>Spostare file(s)</translation> + <translation>Sposta file</translation> </message> <message> <location filename="../../interface.ui" line="105"/> <source>Move folder</source> - <translation>Spostare la cartella</translation> + <translation>Sposta la cartella</translation> </message> <message> <location filename="../../interface.ui" line="114"/> <source>Copy file(s)</source> - <translation>Copiare il file (s)</translation> + <translation>Copia file</translation> </message> <message> <location filename="../../interface.ui" line="123"/> <source>Copy folder</source> - <translation>Copia la cartella</translation> + <translation>Copia cartella</translation> </message> </context> </TS> diff --git a/plugins-alternative/Themes/Clean/Languages/ja/translation.ts b/plugins-alternative/Themes/Clean/Languages/ja/translation.ts index 81df74e..54104e3 100644 --- a/plugins-alternative/Themes/Clean/Languages/ja/translation.ts +++ b/plugins-alternative/Themes/Clean/Languages/ja/translation.ts @@ -4,7 +4,7 @@ <context> <name>InterfacePlugin</name> <message> - <location filename="../../interface.cpp" line="145"/> + <location filename="../../interface.cpp" line="142"/> <source>%1/%2 files, %3/%4</source> <translation type="unfinished"></translation> </message> @@ -18,7 +18,7 @@ </message> <message> <location filename="../../interface.ui" line="44"/> - <source>In wait</source> + <source>Waiting</source> <translation type="unfinished"></translation> </message> <message> diff --git a/plugins-alternative/Themes/Clean/Languages/ko/translation.ts b/plugins-alternative/Themes/Clean/Languages/ko/translation.ts index 41627de..95d2138 100644 --- a/plugins-alternative/Themes/Clean/Languages/ko/translation.ts +++ b/plugins-alternative/Themes/Clean/Languages/ko/translation.ts @@ -4,7 +4,7 @@ <context> <name>InterfacePlugin</name> <message> - <location filename="../../interface.cpp" line="+145"/> + <location filename="../../interface.cpp" line="+142"/> <source>%1/%2 files, %3/%4</source> <translation type="unfinished">%1/%2 파일, %3/%4</translation> </message> @@ -17,9 +17,13 @@ <translation type="unfinished">실행:</translation> </message> <message> - <location line="+12"/> <source>In wait</source> - <translation type="unfinished">대기중</translation> + <translation type="obsolete">대기중</translation> + </message> + <message> + <location line="+12"/> + <source>Waiting</source> + <translation type="unfinished"></translation> </message> <message> <location line="+34"/> diff --git a/plugins-alternative/Themes/Clean/Languages/nl/translation.ts b/plugins-alternative/Themes/Clean/Languages/nl/translation.ts index 81df74e..54104e3 100644 --- a/plugins-alternative/Themes/Clean/Languages/nl/translation.ts +++ b/plugins-alternative/Themes/Clean/Languages/nl/translation.ts @@ -4,7 +4,7 @@ <context> <name>InterfacePlugin</name> <message> - <location filename="../../interface.cpp" line="145"/> + <location filename="../../interface.cpp" line="142"/> <source>%1/%2 files, %3/%4</source> <translation type="unfinished"></translation> </message> @@ -18,7 +18,7 @@ </message> <message> <location filename="../../interface.ui" line="44"/> - <source>In wait</source> + <source>Waiting</source> <translation type="unfinished"></translation> </message> <message> diff --git a/plugins-alternative/Themes/Clean/Languages/no/translation.ts b/plugins-alternative/Themes/Clean/Languages/no/translation.ts index 81df74e..54104e3 100644 --- a/plugins-alternative/Themes/Clean/Languages/no/translation.ts +++ b/plugins-alternative/Themes/Clean/Languages/no/translation.ts @@ -4,7 +4,7 @@ <context> <name>InterfacePlugin</name> <message> - <location filename="../../interface.cpp" line="145"/> + <location filename="../../interface.cpp" line="142"/> <source>%1/%2 files, %3/%4</source> <translation type="unfinished"></translation> </message> @@ -18,7 +18,7 @@ </message> <message> <location filename="../../interface.ui" line="44"/> - <source>In wait</source> + <source>Waiting</source> <translation type="unfinished"></translation> </message> <message> diff --git a/plugins-alternative/Themes/Clean/Languages/pl/translation.ts b/plugins-alternative/Themes/Clean/Languages/pl/translation.ts index 81df74e..54104e3 100644 --- a/plugins-alternative/Themes/Clean/Languages/pl/translation.ts +++ b/plugins-alternative/Themes/Clean/Languages/pl/translation.ts @@ -4,7 +4,7 @@ <context> <name>InterfacePlugin</name> <message> - <location filename="../../interface.cpp" line="145"/> + <location filename="../../interface.cpp" line="142"/> <source>%1/%2 files, %3/%4</source> <translation type="unfinished"></translation> </message> @@ -18,7 +18,7 @@ </message> <message> <location filename="../../interface.ui" line="44"/> - <source>In wait</source> + <source>Waiting</source> <translation type="unfinished"></translation> </message> <message> diff --git a/plugins-alternative/Themes/Clean/Languages/ru/translation.ts b/plugins-alternative/Themes/Clean/Languages/ru/translation.ts index 5f83874..36798e7 100644 --- a/plugins-alternative/Themes/Clean/Languages/ru/translation.ts +++ b/plugins-alternative/Themes/Clean/Languages/ru/translation.ts @@ -4,7 +4,7 @@ <context> <name>InterfacePlugin</name> <message> - <location filename="../../interface.cpp" line="145"/> + <location filename="../../interface.cpp" line="142"/> <source>%1/%2 files, %3/%4</source> <translation>%1/%2 файлы, %3/%4</translation> </message> @@ -17,9 +17,13 @@ <translation>Действие:</translation> </message> <message> - <location filename="../../interface.ui" line="44"/> <source>In wait</source> - <translation>В ожидании</translation> + <translation type="obsolete">В ожидании</translation> + </message> + <message> + <location filename="../../interface.ui" line="44"/> + <source>Waiting</source> + <translation type="unfinished"></translation> </message> <message> <location filename="../../interface.ui" line="78"/> diff --git a/plugins-alternative/Themes/Clean/Languages/th/translation.ts b/plugins-alternative/Themes/Clean/Languages/th/translation.ts index 81df74e..54104e3 100644 --- a/plugins-alternative/Themes/Clean/Languages/th/translation.ts +++ b/plugins-alternative/Themes/Clean/Languages/th/translation.ts @@ -4,7 +4,7 @@ <context> <name>InterfacePlugin</name> <message> - <location filename="../../interface.cpp" line="145"/> + <location filename="../../interface.cpp" line="142"/> <source>%1/%2 files, %3/%4</source> <translation type="unfinished"></translation> </message> @@ -18,7 +18,7 @@ </message> <message> <location filename="../../interface.ui" line="44"/> - <source>In wait</source> + <source>Waiting</source> <translation type="unfinished"></translation> </message> <message> diff --git a/plugins-alternative/Themes/Clean/Languages/tr/translation.ts b/plugins-alternative/Themes/Clean/Languages/tr/translation.ts index 81df74e..54104e3 100644 --- a/plugins-alternative/Themes/Clean/Languages/tr/translation.ts +++ b/plugins-alternative/Themes/Clean/Languages/tr/translation.ts @@ -4,7 +4,7 @@ <context> <name>InterfacePlugin</name> <message> - <location filename="../../interface.cpp" line="145"/> + <location filename="../../interface.cpp" line="142"/> <source>%1/%2 files, %3/%4</source> <translation type="unfinished"></translation> </message> @@ -18,7 +18,7 @@ </message> <message> <location filename="../../interface.ui" line="44"/> - <source>In wait</source> + <source>Waiting</source> <translation type="unfinished"></translation> </message> <message> diff --git a/plugins-alternative/Themes/Clean/Languages/zh/translation.ts b/plugins-alternative/Themes/Clean/Languages/zh/translation.ts index 81df74e..54104e3 100644 --- a/plugins-alternative/Themes/Clean/Languages/zh/translation.ts +++ b/plugins-alternative/Themes/Clean/Languages/zh/translation.ts @@ -4,7 +4,7 @@ <context> <name>InterfacePlugin</name> <message> - <location filename="../../interface.cpp" line="145"/> + <location filename="../../interface.cpp" line="142"/> <source>%1/%2 files, %3/%4</source> <translation type="unfinished"></translation> </message> @@ -18,7 +18,7 @@ </message> <message> <location filename="../../interface.ui" line="44"/> - <source>In wait</source> + <source>Waiting</source> <translation type="unfinished"></translation> </message> <message> diff --git a/plugins-alternative/Themes/Clean/documentation.dox b/plugins-alternative/Themes/Clean/documentation.dox index 56e5331..3f7bc88 100755..100644 --- a/plugins-alternative/Themes/Clean/documentation.dox +++ b/plugins-alternative/Themes/Clean/documentation.dox @@ -11,12 +11,12 @@ \section mainpage_overview Overview It's interface to have minimal interface for Ultracopier.\n - More informations on <a href="http://ultracopier-wiki.first-world.info/">the wiki of ultracopier</a>. Is part of Ultracopier 0.3 project as alternative plugin. + More informations on <a href="http://ultracopier-wiki.first-world.info/">the wiki of ultracopier</a>. Is part of Ultracopier project as alternative plugin. \section mainpage_platforms Platforms - This plugin might be usable in all environments where you find Qt 4.\n - To be compatible with the official Ultracopier plugins, you need compil it with Gcc, Qt4.8, and same env as Ultracopier have been compiled, see the documentation. + Ultracopier might be usable in all environments where you find Qt 5.\n + Ultracopier requires Qt 5.0 or newer. Tested on Qt 5.0. \section mainpage_downloads Downloads diff --git a/plugins-alternative/Themes/Clean/factory.cpp b/plugins-alternative/Themes/Clean/factory.cpp index 2b8d109..6acbe3a 100644 --- a/plugins-alternative/Themes/Clean/factory.cpp +++ b/plugins-alternative/Themes/Clean/factory.cpp @@ -1,70 +1,65 @@ /** \file factory.cpp \brief Define the factory core \author alpha_one_x86 -\version 0.3 -\date 2010 */ - -#include <QtCore> +*/ #include "factory.h" -PluginInterface_Themes * Factory::getInstance() +PluginInterface_Themes * ThemesFactory::getInstance() { - PluginInterface_Themes * newInterface=new InterfacePlugin(facilityEngine); - connect(this,SIGNAL(reloadLanguage()),newInterface,SLOT(newLanguageLoaded())); - return newInterface; + InterfacePlugin * newInterface=new InterfacePlugin(facilityEngine); + connect(this,&ThemesFactory::reloadLanguage,newInterface,&InterfacePlugin::newLanguageLoaded); + return newInterface; } -void Factory::setResources(OptionInterface * options,const QString &writePath,const QString &pluginPath,FacilityInterface * facilityEngine,bool portableVersion) +void ThemesFactory::setResources(OptionInterface * options, const QString &writePath, const QString &pluginPath, FacilityInterface * facilityInterface, const bool &portableVersion) { - Q_UNUSED(options) - Q_UNUSED(writePath) - Q_UNUSED(pluginPath) - this->facilityEngine=facilityEngine; - Q_UNUSED(portableVersion) + Q_UNUSED(options) + Q_UNUSED(writePath) + Q_UNUSED(pluginPath) + this->facilityEngine=facilityInterface; + Q_UNUSED(portableVersion) } -QWidget * Factory::options() +QWidget * ThemesFactory::options() { - return NULL; + return NULL; } -QIcon Factory::getIcon(const QString &fileName) +QIcon ThemesFactory::getIcon(const QString &fileName) const { - if(fileName=="SystemTrayIcon/exit.png") - { - QIcon tempIcon=QIcon::fromTheme("application-exit"); - if(!tempIcon.isNull()) - return tempIcon; - } - if(fileName=="SystemTrayIcon/add.png") - { - QIcon tempIcon=QIcon::fromTheme("list-add"); - if(!tempIcon.isNull()) - return tempIcon; - } - if(fileName=="SystemTrayIcon/informations.png") - { - QIcon tempIcon=QIcon::fromTheme("help-about"); - if(!tempIcon.isNull()) - return tempIcon; - } - if(fileName=="SystemTrayIcon/options.png") - { - QIcon tempIcon=QIcon::fromTheme("applications-system"); - if(!tempIcon.isNull()) - return tempIcon; - } - return QIcon(":/resources/"+fileName); + if(fileName=="SystemTrayIcon/exit.png") + { + QIcon tempIcon=QIcon::fromTheme("application-exit"); + if(!tempIcon.isNull()) + return tempIcon; + } + if(fileName=="SystemTrayIcon/add.png") + { + QIcon tempIcon=QIcon::fromTheme("list-add"); + if(!tempIcon.isNull()) + return tempIcon; + } + if(fileName=="SystemTrayIcon/informations.png") + { + QIcon tempIcon=QIcon::fromTheme("help-about"); + if(!tempIcon.isNull()) + return tempIcon; + } + if(fileName=="SystemTrayIcon/options.png") + { + QIcon tempIcon=QIcon::fromTheme("applications-system"); + if(!tempIcon.isNull()) + return tempIcon; + } + return QIcon(":/Themes/Clean/resources/"+fileName); } -void Factory::resetOptions() +void ThemesFactory::resetOptions() { } -void Factory::newLanguageLoaded() +void ThemesFactory::newLanguageLoaded() { - emit reloadLanguage(); + emit reloadLanguage(); } - -Q_EXPORT_PLUGIN2(interface, Factory); diff --git a/plugins-alternative/Themes/Clean/factory.h b/plugins-alternative/Themes/Clean/factory.h index 2a9c0ef..f9b1ee2 100644 --- a/plugins-alternative/Themes/Clean/factory.h +++ b/plugins-alternative/Themes/Clean/factory.h @@ -1,8 +1,7 @@ /** \file factory.h \brief Define the factory, to create instance of the interface \author alpha_one_x86 -\version 0.3 -\date 2010 */ +\licence GPL3, see the file COPYING */ #ifndef FACTORY_H #define FACTORY_H @@ -14,26 +13,27 @@ #include "../../../interface/PluginInterface_Themes.h" /// \brief Define the factory, to create instance of the interface -class Factory : public PluginInterface_ThemesFactory +class ThemesFactory : public PluginInterface_ThemesFactory { - Q_OBJECT - Q_INTERFACES(PluginInterface_ThemesFactory) - public: - /// \brief to return the instance of the copy engine - PluginInterface_Themes * getInstance(); - /// \brief set the resources, to store options, to have facilityInterface - void setResources(OptionInterface * optionsEngine,const QString &writePath,const QString &pluginPath,FacilityInterface * facilityEngine,bool portableVersion); - /// \brief to get the default options widget - QWidget * options(); - /// \brief to get a resource icon - QIcon getIcon(const QString &fileName); - signals: - void reloadLanguage(); - public slots: - void resetOptions(); - void newLanguageLoaded(); - private: - FacilityInterface * facilityEngine; + Q_OBJECT + Q_PLUGIN_METADATA(IID "first-world.info.ultracopier.PluginInterface.ThemesFactory/1.0.1.0" FILE "plugin.json") + Q_INTERFACES(PluginInterface_ThemesFactory) + public: + /// \brief to return the instance of the copy engine + PluginInterface_Themes * getInstance(); + /// \brief set the resources, to store options, to have facilityInterface + void setResources(OptionInterface * options,const QString &writePath,const QString &pluginPath,FacilityInterface * facilityInterface,const bool &portableVersion); + /// \brief to get the default options widget + QWidget * options(); + /// \brief to get a resource icon + QIcon getIcon(const QString &fileName) const; + signals: + void reloadLanguage(); + public slots: + void resetOptions(); + void newLanguageLoaded(); + private: + FacilityInterface * facilityEngine; }; #endif // FACTORY_H diff --git a/plugins-alternative/Themes/Clean/informations.xml b/plugins-alternative/Themes/Clean/informations.xml index 8e076a4..3b49a98 100644 --- a/plugins-alternative/Themes/Clean/informations.xml +++ b/plugins-alternative/Themes/Clean/informations.xml @@ -17,11 +17,10 @@ <description xml:lang="en"><![CDATA[Clean style for Ultracopier]]></description> <description xml:lang="fr"><![CDATA[Style Clean pour Ultracopier]]></description> <!-- Version of this release of this plugin, need be like that's: A.B.C.D, where A, B, C and D is number --> - <version>0.3.1.0</version> + <version>1.2.3.6</version> <!-- This internal name should never change, because it is used to detect when a particular plugin is updated. It must comprise only lower case ASCII characters (a-z), numerical digits (0-9), "-", "." or "_", and it must be be unique within the category. And have size lower than 64 char. --> <name>Clean</name> <!-- Dependency checking. This is used to check when a plugin may not be compatible with an updated version of either Ultracopier or another plugin. This example only checks Ultracopier. --> <dependencies><![CDATA[ - >=ultracopier-0.3.1.0 ]]></dependencies> </package>
\ No newline at end of file diff --git a/plugins-alternative/Themes/Clean/interface.cpp b/plugins-alternative/Themes/Clean/interface.cpp index 6d6c4b1..3f2cd2a 100644 --- a/plugins-alternative/Themes/Clean/interface.cpp +++ b/plugins-alternative/Themes/Clean/interface.cpp @@ -1,99 +1,96 @@ /** \file interface.cpp \brief Define the interface core \author alpha_one_x86 -\version 0.3 -\date 2010 */ - -#include <QtCore> +*/ #include "interface.h" #include "ui_interface.h" InterfacePlugin::InterfacePlugin(FacilityInterface * facilityEngine) : - ui(new Ui::interface()) -{ - ui->setupUi(this); - currentFile = 0; - totalFile = 0; - currentSize = 0; - totalSize = 0; - modeIsForced = false; - haveStarted = false; - this->facilityEngine = facilityEngine; - this->show(); - menu=new QMenu(this); - ui->toolButton->setMenu(menu); - updateModeAndType(); - - connect(ui->actionAddFile,SIGNAL(triggered()),this,SLOT(forcedModeAddFile())); - connect(ui->actionAddFileToCopy,SIGNAL(triggered()),this,SLOT(forcedModeAddFileToCopy())); - connect(ui->actionAddFileToMove,SIGNAL(triggered()),this,SLOT(forcedModeAddFileToMove())); - connect(ui->actionAddFolderToCopy,SIGNAL(triggered()),this,SLOT(forcedModeAddFolderToCopy())); - connect(ui->actionAddFolderToMove,SIGNAL(triggered()),this,SLOT(forcedModeAddFolderToMove())); - connect(ui->actionAddFolder,SIGNAL(triggered()),this,SLOT(forcedModeAddFolder())); + ui(new Ui::interface()) +{ + ui->setupUi(this); + currentFile = 0; + totalFile = 0; + currentSize = 0; + totalSize = 0; + modeIsForced = false; + haveStarted = false; + this->facilityEngine = facilityEngine; + menu=new QMenu(this); + ui->toolButton->setMenu(menu); + updateModeAndType(); + + connect(ui->actionAddFile,&QAction::triggered,this,&InterfacePlugin::forcedModeAddFile); + connect(ui->actionAddFileToCopy,&QAction::triggered,this,&InterfacePlugin::forcedModeAddFileToCopy); + connect(ui->actionAddFileToMove,&QAction::triggered,this,&InterfacePlugin::forcedModeAddFileToMove); + connect(ui->actionAddFolderToCopy,&QAction::triggered,this,&InterfacePlugin::forcedModeAddFolderToCopy); + connect(ui->actionAddFolderToMove,&QAction::triggered,this,&InterfacePlugin::forcedModeAddFolderToMove); + connect(ui->actionAddFolder,&QAction::triggered,this,&InterfacePlugin::forcedModeAddFolder); + show(); } InterfacePlugin::~InterfacePlugin() { - delete menu; + delete menu; } void InterfacePlugin::forcedModeAddFile() { - emit userAddFile(mode); + emit userAddFile(mode); } void InterfacePlugin::forcedModeAddFolder() { - emit userAddFolder(mode); + emit userAddFolder(mode); } void InterfacePlugin::forcedModeAddFileToCopy() { - emit userAddFile(Copy); + emit userAddFile(Ultracopier::Copy); } void InterfacePlugin::forcedModeAddFolderToCopy() { - emit userAddFolder(Copy); + emit userAddFolder(Ultracopier::Copy); } void InterfacePlugin::forcedModeAddFileToMove() { - emit userAddFile(Move); + emit userAddFile(Ultracopier::Move); } void InterfacePlugin::forcedModeAddFolderToMove() { - emit userAddFolder(Move); + emit userAddFolder(Ultracopier::Move); } void InterfacePlugin::updateModeAndType() { - menu->clear(); - if(modeIsForced) - { - menu->addAction(ui->actionAddFile); - if(type==FileAndFolder) - menu->addAction(ui->actionAddFolder); - } - else - { - menu->addAction(ui->actionAddFileToCopy); - menu->addAction(ui->actionAddFileToMove); - if(type==FileAndFolder) - { - menu->addAction(ui->actionAddFolderToCopy); - menu->addAction(ui->actionAddFolderToMove); - } - } + menu->clear(); + if(modeIsForced) + { + menu->addAction(ui->actionAddFile); + if(type==Ultracopier::FileAndFolder) + menu->addAction(ui->actionAddFolder); + } + else + { + menu->addAction(ui->actionAddFileToCopy); + menu->addAction(ui->actionAddFileToMove); + if(type==Ultracopier::FileAndFolder) + { + menu->addAction(ui->actionAddFolderToCopy); + menu->addAction(ui->actionAddFolderToMove); + } + } } void InterfacePlugin::closeEvent(QCloseEvent *event) { - event->ignore(); - this->hide(); - emit cancel(); + event->ignore(); + this->hide(); + emit cancel(); } void InterfacePlugin::detectedSpeed(const quint64 &speed) @@ -106,162 +103,170 @@ QWidget * InterfacePlugin::getOptionsEngineWidget() return NULL; } -void InterfacePlugin::getOptionsEngineEnabled(bool isEnabled) +void InterfacePlugin::getOptionsEngineEnabled(const bool &isEnabled) { Q_UNUSED(isEnabled) } -void InterfacePlugin::setCopyType(CopyType type) +void InterfacePlugin::setCopyType(const Ultracopier::CopyType &type) { - this->type=type; - updateModeAndType(); + this->type=type; + updateModeAndType(); } -void InterfacePlugin::forceCopyMode(CopyMode mode) +void InterfacePlugin::forceCopyMode(const Ultracopier::CopyMode &mode) { - modeIsForced=true; - this->mode=mode; - updateModeAndType(); + modeIsForced=true; + this->mode=mode; + updateModeAndType(); } void InterfacePlugin::updateTitle() { - QString actionString; - switch(action) - { - case Listing: - actionString=facilityEngine->translateText("Listing"); - break; - case Copying: - actionString=facilityEngine->translateText("Copying"); - break; - case CopyingAndListing: - actionString=facilityEngine->translateText("Listing and copying"); - break; - case Idle: - actionString="Ultracopier"; - break; - } - this->setWindowTitle(actionString+" - "+tr("%1/%2 files, %3/%4").arg(currentFile).arg(totalFile).arg(currentSize).arg(totalSize)); -} - -void InterfacePlugin::actionInProgess(EngineActionInProgress action) -{ - this->action=action; - switch(action) - { - case Copying: - case CopyingAndListing: - ui->progressBar->setMaximum(65535); - ui->progressBar->setMinimum(0); - break; - case Listing: - ui->progressBar->setMaximum(0); - ui->progressBar->setMinimum(0); - break; - case Idle: - if(haveStarted) - emit cancel(); - break; - default: - break; - } - switch(action) - { - case Copying: - case CopyingAndListing: - haveStarted=true; - break; - default: - break; - } -} - -void InterfacePlugin::newTransferStart(const ItemOfCopyList &item) -{ - ui->text->setText(item.sourceFullPath); + QString actionString; + switch(action) + { + case Ultracopier::Listing: + actionString=facilityEngine->translateText("Listing"); + break; + case Ultracopier::Copying: + actionString=facilityEngine->translateText("Copying"); + break; + case Ultracopier::CopyingAndListing: + actionString=facilityEngine->translateText("Listing and copying"); + break; + case Ultracopier::Idle: + actionString="Ultracopier"; + break; + } + this->setWindowTitle(actionString+" - "+tr("%1/%2 files, %3/%4").arg(currentFile).arg(totalFile).arg(currentSize).arg(totalSize)); +} + +void InterfacePlugin::actionInProgess(const Ultracopier::EngineActionInProgress &action) +{ + this->action=action; + switch(action) + { + case Ultracopier::Copying: + case Ultracopier::CopyingAndListing: + ui->progressBar->setMaximum(65535); + ui->progressBar->setMinimum(0); + break; + case Ultracopier::Listing: + ui->progressBar->setMaximum(0); + ui->progressBar->setMinimum(0); + break; + case Ultracopier::Idle: + if(haveStarted) + emit cancel(); + break; + default: + break; + } + switch(action) + { + case Ultracopier::Copying: + case Ultracopier::CopyingAndListing: + haveStarted=true; + break; + default: + break; + } +} + +void InterfacePlugin::newTransferStart(const Ultracopier::ItemOfCopyList &item) +{ + ui->text->setText(item.sourceFullPath); } void InterfacePlugin::newTransferStop(const quint64 &id) { - Q_UNUSED(id) + Q_UNUSED(id) } void InterfacePlugin::newFolderListing(const QString &path) { - if(action==Listing) - ui->text->setText(path); + if(action==Ultracopier::Listing) + ui->text->setText(path); } void InterfacePlugin::remainingTime(const int &remainingSeconds) { - Q_UNUSED(remainingSeconds) + Q_UNUSED(remainingSeconds) } void InterfacePlugin::newCollisionAction(const QString &action) { - Q_UNUSED(action) + Q_UNUSED(action) } void InterfacePlugin::newErrorAction(const QString &action) { - Q_UNUSED(action) + Q_UNUSED(action) } void InterfacePlugin::errorDetected() { } -void InterfacePlugin::setTransferListOperation(TransferListOperation transferListOperation) +/// \brief new error +void InterfacePlugin::errorToRetry(const QString &source,const QString &destination,const QString &error) +{ + Q_UNUSED(source); + Q_UNUSED(destination); + Q_UNUSED(error); +} + +void InterfacePlugin::setTransferListOperation(const Ultracopier::TransferListOperation &transferListOperation) { - Q_UNUSED(transferListOperation) + Q_UNUSED(transferListOperation) } //speed limitation bool InterfacePlugin::setSpeedLimitation(const qint64 &speedLimitation) { - Q_UNUSED(speedLimitation) + Q_UNUSED(speedLimitation) return false; } //get information about the copy void InterfacePlugin::setGeneralProgression(const quint64 ¤t,const quint64 &total) { - ui->progressBar->setValue(((double)current/total)*65535); + ui->progressBar->setValue(((double)current/total)*65535); } void InterfacePlugin::setCollisionAction(const QList<QPair<QString,QString> > &list) { - Q_UNUSED(list) + Q_UNUSED(list) } void InterfacePlugin::setErrorAction(const QList<QPair<QString,QString> > &list) { - Q_UNUSED(list) + Q_UNUSED(list) } //edit the transfer list -void InterfacePlugin::getActionOnList(const QList<returnActionOnCopyList> &returnActions) +void InterfacePlugin::getActionOnList(const QList<Ultracopier::ReturnActionOnCopyList> &returnActions) { - Q_UNUSED(returnActions) + Q_UNUSED(returnActions) } void InterfacePlugin::haveExternalOrder() { - ui->toolButton->hide(); + ui->toolButton->hide(); } -void InterfacePlugin::isInPause(bool isInPause) +void InterfacePlugin::isInPause(const bool &isInPause) { - //resume in auto the pause - if(isInPause) - emit resume(); + //resume in auto the pause + if(isInPause) + emit resume(); } void InterfacePlugin::newLanguageLoaded() { - ui->retranslateUi(this); - updateTitle(); + ui->retranslateUi(this); + updateTitle(); } /* @@ -269,147 +274,153 @@ void InterfacePlugin::newLanguageLoaded() Return[1]: totalSize Return[2]: currentFile */ -void InterfacePlugin::synchronizeItems(const QList<returnActionOnCopyList>& returnActions) -{ - loop_size=returnActions.size(); - index_for_loop=0; - while(index_for_loop<loop_size) - { - const returnActionOnCopyList& action=returnActions.at(index_for_loop); - switch(action.type) - { - case AddingItem: - { - totalFile++; - totalSize+=action.addAction.size; - } - break; - case RemoveItem: - currentFile++; - break; - case PreOperation: - { - ItemOfCopyListWithMoreInformations tempItem; - tempItem.currentProgression=0; - tempItem.generalData=action.addAction; - totalFile+=action.addAction.size; - InternalRunningOperation << tempItem; - } - break; - case Transfer: - { - sub_index_for_loop=0; - sub_loop_size=InternalRunningOperation.size(); - while(sub_index_for_loop<sub_loop_size) - { - if(InternalRunningOperation.at(sub_index_for_loop).generalData.id==action.addAction.id) - { - InternalRunningOperation[sub_index_for_loop].actionType=action.type; - break; - } - sub_index_for_loop++; - } - } - break; - case PostOperation: - { - sub_index_for_loop=0; - sub_loop_size=InternalRunningOperation.size(); - while(sub_index_for_loop<sub_loop_size) - { - if(InternalRunningOperation.at(sub_index_for_loop).generalData.id==action.addAction.id) - { - InternalRunningOperation.removeAt(sub_index_for_loop); - break; - } - sub_index_for_loop++; - } - } - break; - case CustomOperation: - { - bool custom_with_progression=(action.addAction.size==1); - sub_index_for_loop=0; - sub_loop_size=InternalRunningOperation.size(); - while(sub_index_for_loop<sub_loop_size) - { - if(InternalRunningOperation.at(sub_index_for_loop).generalData.id==action.addAction.id) - { - InternalRunningOperation[sub_index_for_loop].actionType=action.type; - InternalRunningOperation[sub_index_for_loop].custom_with_progression=custom_with_progression; - InternalRunningOperation[sub_index_for_loop].currentProgression=0; - break; - } - sub_index_for_loop++; - } - } - break; - default: - //unknow code, ignore it - break; - } - index_for_loop++; - } -} - -void InterfacePlugin::setFileProgression(const QList<ProgressionItem> &progressionList) -{ - loop_size=InternalRunningOperation.size(); - sub_loop_size=progressionList.size(); - index_for_loop=0; - while(index_for_loop<loop_size) - { - sub_index_for_loop=0; - while(sub_index_for_loop<sub_loop_size) - { - if(progressionList.at(sub_index_for_loop).id==InternalRunningOperation.at(index_for_loop).generalData.id) - { - InternalRunningOperation[index_for_loop].generalData.size=progressionList.at(sub_index_for_loop).total; - InternalRunningOperation[index_for_loop].currentProgression=progressionList.at(sub_index_for_loop).current; - break; - } - sub_index_for_loop++; - } - index_for_loop++; - } +void InterfacePlugin::synchronizeItems(const QList<Ultracopier::ReturnActionOnCopyList>& returnActions) +{ + loop_size=returnActions.size(); + index_for_loop=0; + while(index_for_loop<loop_size) + { + const Ultracopier::ReturnActionOnCopyList& action=returnActions.at(index_for_loop); + switch(action.type) + { + case Ultracopier::AddingItem: + { + totalFile++; + totalSize+=action.addAction.size; + } + break; + case Ultracopier::RemoveItem: + currentFile++; + break; + case Ultracopier::PreOperation: + { + ItemOfCopyListWithMoreInformations tempItem; + tempItem.currentProgression=0; + tempItem.generalData=action.addAction; + currentSize+=action.addAction.size; + InternalRunningOperation << tempItem; + } + break; + case Ultracopier::Transfer: + { + sub_index_for_loop=0; + sub_loop_size=InternalRunningOperation.size(); + while(sub_index_for_loop<sub_loop_size) + { + if(InternalRunningOperation.at(sub_index_for_loop).generalData.id==action.addAction.id) + { + InternalRunningOperation[sub_index_for_loop].actionType=action.type; + break; + } + sub_index_for_loop++; + } + } + break; + case Ultracopier::PostOperation: + { + sub_index_for_loop=0; + sub_loop_size=InternalRunningOperation.size(); + while(sub_index_for_loop<sub_loop_size) + { + if(InternalRunningOperation.at(sub_index_for_loop).generalData.id==action.addAction.id) + { + InternalRunningOperation.removeAt(sub_index_for_loop); + break; + } + sub_index_for_loop++; + } + } + break; + case Ultracopier::CustomOperation: + { + bool custom_with_progression=(action.addAction.size==1); + sub_index_for_loop=0; + sub_loop_size=InternalRunningOperation.size(); + while(sub_index_for_loop<sub_loop_size) + { + if(InternalRunningOperation.at(sub_index_for_loop).generalData.id==action.addAction.id) + { + InternalRunningOperation[sub_index_for_loop].actionType=action.type; + InternalRunningOperation[sub_index_for_loop].custom_with_progression=custom_with_progression; + InternalRunningOperation[sub_index_for_loop].currentProgression=0; + break; + } + sub_index_for_loop++; + } + } + break; + default: + //unknow code, ignore it + break; + } + index_for_loop++; + } +} + +/** \brief support speed limitation */ +void InterfacePlugin::setSupportSpeedLimitation(const bool &supportSpeedLimitationBool) +{ + Q_UNUSED(supportSpeedLimitationBool); +} + +void InterfacePlugin::setFileProgression(const QList<Ultracopier::ProgressionItem> &progressionList) +{ + loop_size=InternalRunningOperation.size(); + sub_loop_size=progressionList.size(); + index_for_loop=0; + while(index_for_loop<loop_size) + { + sub_index_for_loop=0; + while(sub_index_for_loop<sub_loop_size) + { + if(progressionList.at(sub_index_for_loop).id==InternalRunningOperation.at(index_for_loop).generalData.id) + { + InternalRunningOperation[index_for_loop].generalData.size=progressionList.at(sub_index_for_loop).total; + InternalRunningOperation[index_for_loop].currentProgression=(progressionList.at(sub_index_for_loop).currentRead+progressionList.at(sub_index_for_loop).currentWrite)/2; + break; + } + sub_index_for_loop++; + } + index_for_loop++; + } } InterfacePlugin::currentTransfertItem InterfacePlugin::getCurrentTransfertItem() { - currentTransfertItem returnItem; - returnItem.haveItem=InternalRunningOperation.size()>0; - if(returnItem.haveItem) - { - const ItemOfCopyListWithMoreInformations &itemTransfer=InternalRunningOperation.first(); - returnItem.from=itemTransfer.generalData.sourceFullPath; - returnItem.to=itemTransfer.generalData.destinationFullPath; - returnItem.current_file=itemTransfer.generalData.destinationFileName+", "+facilityEngine->sizeToString(itemTransfer.generalData.size); - switch(itemTransfer.actionType) - { - case CustomOperation: - if(!itemTransfer.custom_with_progression) - returnItem.progressBar_file=0; - else - { - if(itemTransfer.generalData.size>0) - returnItem.progressBar_file=((double)itemTransfer.currentProgression/itemTransfer.generalData.size)*65535; - else - returnItem.progressBar_file=0; - } - break; - case Transfer: - if(itemTransfer.generalData.size>0) - returnItem.progressBar_file=((double)itemTransfer.currentProgression/itemTransfer.generalData.size)*65535; - else - returnItem.progressBar_file=0; - break; - case PostOperation: - returnItem.progressBar_file=65535; - break; - default: - returnItem.progressBar_file=0; - } - } - return returnItem; + currentTransfertItem returnItem; + returnItem.haveItem=InternalRunningOperation.size()>0; + if(returnItem.haveItem) + { + const ItemOfCopyListWithMoreInformations &itemTransfer=InternalRunningOperation.first(); + returnItem.from=itemTransfer.generalData.sourceFullPath; + returnItem.to=itemTransfer.generalData.destinationFullPath; + returnItem.current_file=itemTransfer.generalData.destinationFileName+", "+facilityEngine->sizeToString(itemTransfer.generalData.size); + switch(itemTransfer.actionType) + { + case Ultracopier::CustomOperation: + if(!itemTransfer.custom_with_progression) + returnItem.progressBar_file=0; + else + { + if(itemTransfer.generalData.size>0) + returnItem.progressBar_file=((double)itemTransfer.currentProgression/itemTransfer.generalData.size)*65535; + else + returnItem.progressBar_file=0; + } + break; + case Ultracopier::Transfer: + if(itemTransfer.generalData.size>0) + returnItem.progressBar_file=((double)itemTransfer.currentProgression/itemTransfer.generalData.size)*65535; + else + returnItem.progressBar_file=0; + break; + case Ultracopier::PostOperation: + returnItem.progressBar_file=65535; + break; + default: + returnItem.progressBar_file=0; + } + } + return returnItem; } diff --git a/plugins-alternative/Themes/Clean/interface.h b/plugins-alternative/Themes/Clean/interface.h index b7ab57f..e5b5c36 100644 --- a/plugins-alternative/Themes/Clean/interface.h +++ b/plugins-alternative/Themes/Clean/interface.h @@ -1,8 +1,7 @@ /** \file interface.h \brief Define the interface \author alpha_one_x86 -\version 0.3 -\date 2010 */ +\licence GPL3, see the file COPYING */ #ifndef INTERFACE_TEST_H #define INTERFACE_TEST_H @@ -15,145 +14,128 @@ #include "../../../interface/PluginInterface_Themes.h" namespace Ui { - class interface; + class interface; } /// \brief Define the interface class InterfacePlugin : public PluginInterface_Themes { - Q_OBJECT + Q_OBJECT public slots: - //send information about the copy - /// \brief to set the action in progress - void actionInProgess(EngineActionInProgress); - /// \brief new transfer have started - void newTransferStart(const ItemOfCopyList &item); - /** \brief one transfer have been stopped - * is stopped, example: because error have occurred, and try later, don't remove the item! */ - void newTransferStop(const quint64 &id); - /// \brief the new folder is listing - void newFolderListing(const QString &path); - /** \brief show the detected speed - * in byte per seconds */ - void detectedSpeed(const quint64 &speed); - /** \brief show the remaining time - * time in seconds */ - void remainingTime(const int &remainingSeconds); - /// \brief set the current collision action - void newCollisionAction(const QString &action); - /// \brief set the current error action - void newErrorAction(const QString &action); - /// \brief set one error is detected - void errorDetected(); - //speed limitation - /** \brief the max speed used - * in byte per seconds, -1 if not able, 0 if disabled */ - bool setSpeedLimitation(const qint64 &speedLimitation); - //set the translate - void newLanguageLoaded(); - void synchronizeItems(const QList<returnActionOnCopyList>& returnActions); + //send information about the copy + /// \brief to set the action in progress + void actionInProgess(const Ultracopier::EngineActionInProgress&); + /// \brief new transfer have started + void newTransferStart(const Ultracopier::ItemOfCopyList &item); + /** \brief one transfer have been stopped + * is stopped, example: because error have occurred, and try later, don't remove the item! */ + void newTransferStop(const quint64 &id); + /// \brief the new folder is listing + void newFolderListing(const QString &path); + /** \brief show the detected speed + * in byte per seconds */ + void detectedSpeed(const quint64 &speed); + /** \brief show the remaining time + * time in seconds */ + void remainingTime(const int &remainingSeconds); + /// \brief set the current collision action + void newCollisionAction(const QString &action); + /// \brief set the current error action + void newErrorAction(const QString &action); + /// \brief set one error is detected + void errorDetected(); + /// \brief new error + void errorToRetry(const QString &source,const QString &destination,const QString &error); + //speed limitation + /** \brief the max speed used + * in byte per seconds, -1 if not able, 0 if disabled */ + bool setSpeedLimitation(const qint64 &speedLimitation); + //set the translate + void newLanguageLoaded(); + void synchronizeItems(const QList<Ultracopier::ReturnActionOnCopyList>& returnActions); + /** \brief support speed limitation */ + void setSupportSpeedLimitation(const bool &supportSpeedLimitationBool); public: - /// \brief the transfer item with progression - struct ItemOfCopyListWithMoreInformations - { - quint64 currentProgression; - ItemOfCopyList generalData; - ActionTypeCopyList actionType; - bool custom_with_progression; - }; - /// \brief returned first transfer item - struct currentTransfertItem - { - quint64 id; - bool haveItem; - QString from; - QString to; - QString current_file; - int progressBar_file; - }; - /// \brief get the widget for the copy engine - QWidget * getOptionsEngineWidget(); - /// \brief to set if the copy engine is found - void getOptionsEngineEnabled(bool isEnabled); - /// \brief get action on the transfer list (add/move/remove) - void getActionOnList(const QList<returnActionOnCopyList> &returnActions); - //get information about the copy - /// \brief show the general progression - void setGeneralProgression(const quint64 ¤t,const quint64 &total); - /// \brief show the file progression - void setFileProgression(const QList<ProgressionItem> &progressionList); - /// \brief set collision action - void setCollisionAction(const QList<QPair<QString,QString> > &); - /// \brief set error action - void setErrorAction(const QList<QPair<QString,QString> > &); - /// \brief set the copyType -> file or folder - void setCopyType(CopyType); - /// \brief set the copyMove -> copy or move, to force in copy or move, else support both - void forceCopyMode(CopyMode); - /// \brief set if transfer list is exportable/importable - void setTransferListOperation(TransferListOperation transferListOperation); - /** \brief set if the order is external (like file manager copy) - * to notify the interface, which can hide add folder/filer button */ - void haveExternalOrder(); - /// \brief set if is in pause - void isInPause(bool); + /// \brief the transfer item with progression + struct ItemOfCopyListWithMoreInformations + { + quint64 currentProgression; + Ultracopier::ItemOfCopyList generalData; + Ultracopier::ActionTypeCopyList actionType; + bool custom_with_progression; + }; + /// \brief returned first transfer item + struct currentTransfertItem + { + quint64 id; + bool haveItem; + QString from; + QString to; + QString current_file; + int progressBar_file; + }; + /// \brief get the widget for the copy engine + QWidget * getOptionsEngineWidget(); + /// \brief to set if the copy engine is found + void getOptionsEngineEnabled(const bool &isEnabled); + /// \brief get action on the transfer list (add/move/remove) + void getActionOnList(const QList<Ultracopier::ReturnActionOnCopyList> &returnActions); + //get information about the copy + /// \brief show the general progression + void setGeneralProgression(const quint64 ¤t,const quint64 &total); + /// \brief show the file progression + void setFileProgression(const QList<Ultracopier::ProgressionItem> &progressionList); + /// \brief set collision action + void setCollisionAction(const QList<QPair<QString,QString> > &); + /// \brief set error action + void setErrorAction(const QList<QPair<QString,QString> > &); + /// \brief set the copyType -> file or folder + void setCopyType(const Ultracopier::CopyType&); + /// \brief set the copyMove -> copy or move, to force in copy or move, else support both + void forceCopyMode(const Ultracopier::CopyMode &); + /// \brief set if transfer list is exportable/importable + void setTransferListOperation(const Ultracopier::TransferListOperation &transferListOperation); + /** \brief set if the order is external (like file manager copy) + * to notify the interface, which can hide add folder/filer button */ + void haveExternalOrder(); + /// \brief set if is in pause + void isInPause(const bool &); signals: - #ifdef ULTRACOPIER_PLUGIN_DEBUG - /// \brief To debug source - void debugInformation(DebugLevel level,QString fonction,QString text,QString file,int ligne); - #endif - //set the transfer list - void removeItems(QList<int> ids); - void moveItemsOnTop(QList<int> ids); - void moveItemsUp(QList<int> ids); - void moveItemsDown(QList<int> ids); - void moveItemsOnBottom(QList<int> ids); - void exportTransferList(); - void importTransferList(); - //user ask ask to add folder (add it with interface ask source/destination) - void userAddFolder(CopyMode); - void userAddFile(CopyMode); - void urlDropped(QList<QUrl> urls); - //action on the copy - void pause(); - void resume(); - void skip(quint64 id); - void cancel(); - //edit the action - void sendCollisionAction(QString action); - void sendErrorAction(QString action); - void newSpeedLimitation(qint64); + #ifdef ULTRACOPIER_PLUGIN_DEBUG + /// \brief To debug source + void debugInformation(const DebugLevel &level,const QString &fonction,const QString &text,const QString &file,const int &ligne); + #endif public: - //constructor and destructor - InterfacePlugin(FacilityInterface * facilityEngine); - ~InterfacePlugin(); + //constructor and destructor + InterfacePlugin(FacilityInterface * facilityEngine); + ~InterfacePlugin(); private: - Ui::interface *ui; - quint64 currentFile; - quint64 totalFile; - quint64 currentSize; - quint64 totalSize; - void updateTitle(); - QMenu *menu; - EngineActionInProgress action; - void closeEvent(QCloseEvent *event); - void updateModeAndType(); - bool modeIsForced; - CopyType type; - CopyMode mode; - bool haveStarted; - QList<ItemOfCopyListWithMoreInformations> InternalRunningOperation; - int loop_size,index_for_loop; - int sub_loop_size,sub_index_for_loop; - currentTransfertItem getCurrentTransfertItem(); - FacilityInterface * facilityEngine; + Ui::interface *ui; + quint64 currentFile; + quint64 totalFile; + quint64 currentSize; + quint64 totalSize; + void updateTitle(); + QMenu *menu; + Ultracopier::EngineActionInProgress action; + void closeEvent(QCloseEvent *event); + void updateModeAndType(); + bool modeIsForced; + Ultracopier::CopyType type; + Ultracopier::CopyMode mode; + bool haveStarted; + QList<ItemOfCopyListWithMoreInformations> InternalRunningOperation; + int loop_size,index_for_loop; + int sub_loop_size,sub_index_for_loop; + currentTransfertItem getCurrentTransfertItem(); + FacilityInterface * facilityEngine; private slots: - void forcedModeAddFile(); - void forcedModeAddFolder(); - void forcedModeAddFileToCopy(); - void forcedModeAddFolderToCopy(); - void forcedModeAddFileToMove(); - void forcedModeAddFolderToMove(); + void forcedModeAddFile(); + void forcedModeAddFolder(); + void forcedModeAddFileToCopy(); + void forcedModeAddFolderToCopy(); + void forcedModeAddFileToMove(); + void forcedModeAddFolderToMove(); }; #endif // INTERFACE_TEST_H diff --git a/plugins-alternative/Themes/Clean/interface.pro b/plugins-alternative/Themes/Clean/interface.pro index 20fd1dd..eb124c9 100644 --- a/plugins-alternative/Themes/Clean/interface.pro +++ b/plugins-alternative/Themes/Clean/interface.pro @@ -1,31 +1,36 @@ +CONFIG += c++11 +QMAKE_CXXFLAGS+="-std=c++0x -Wall -Wextra" +mac:QMAKE_CXXFLAGS+="-stdlib=libc++" + +QT += widgets TEMPLATE = lib CONFIG += plugin HEADERS = interface.h \ - interface/PluginInterface_Themes.h \ - StructEnumDefinition.h \ + StructEnumDefinition.h \ factory.h \ ../../../interface/PluginInterface_Themes.h SOURCES = interface.cpp \ factory.cpp TARGET = $$qtLibraryTarget(interface) -TRANSLATIONS += Languages/fr/translation.ts \ - Languages/ar/translation.ts \ - Languages/zh/translation.ts \ - Languages/es/translation.ts \ +TRANSLATIONS += Languages/ar/translation.ts \ Languages/de/translation.ts \ Languages/el/translation.ts \ + Languages/en/translation.ts \ + Languages/es/translation.ts \ + Languages/fr/translation.ts \ + Languages/hi/translation.ts \ + Languages/hu/translation.ts \ + Languages/id/translation.ts \ Languages/it/translation.ts \ Languages/ja/translation.ts \ - Languages/id/translation.ts \ + Languages/ko/translation.ts \ + Languages/nl/translation.ts \ + Languages/no/translation.ts \ Languages/pl/translation.ts \ Languages/ru/translation.ts \ - Languages/tr/translation.ts \ Languages/th/translation.ts \ - Languages/hi/translation.ts \ - Languages/nl/translation.ts \ - Languages/no/translation.ts \ - Languages/pt/translation.ts \ - Languages/ko/translation.ts + Languages/tr/translation.ts \ + Languages/zh/translation.ts FORMS += \ interface.ui diff --git a/plugins-alternative/Themes/Clean/interface.ui b/plugins-alternative/Themes/Clean/interface.ui index 1ac0e4a..f178af7 100644 --- a/plugins-alternative/Themes/Clean/interface.ui +++ b/plugins-alternative/Themes/Clean/interface.ui @@ -41,7 +41,7 @@ </font> </property> <property name="text"> - <string>In wait</string> + <string>Waiting</string> </property> </widget> </item> @@ -72,7 +72,7 @@ <action name="actionAddFile"> <property name="icon"> <iconset> - <normaloff>:/resources/add.png</normaloff>:/resources/add.png</iconset> + <normaloff>:/Themes/Clean/resources/add.png</normaloff>:/Themes/Clean/resources/add.png</iconset> </property> <property name="text"> <string>Add file</string> @@ -81,7 +81,7 @@ <action name="actionAddFolder"> <property name="icon"> <iconset> - <normaloff>:/resources/add.png</normaloff>:/resources/add.png</iconset> + <normaloff>:/Themes/Clean/resources/add.png</normaloff>:/Themes/Clean/resources/add.png</iconset> </property> <property name="text"> <string>Add folder</string> @@ -90,7 +90,7 @@ <action name="actionAddFileToMove"> <property name="icon"> <iconset> - <normaloff>:/resources/add.png</normaloff>:/resources/add.png</iconset> + <normaloff>:/Themes/Clean/resources/add.png</normaloff>:/Themes/Clean/resources/add.png</iconset> </property> <property name="text"> <string>Move file(s)</string> @@ -99,7 +99,7 @@ <action name="actionAddFolderToMove"> <property name="icon"> <iconset> - <normaloff>:/resources/add.png</normaloff>:/resources/add.png</iconset> + <normaloff>:/Themes/Clean/resources/add.png</normaloff>:/Themes/Clean/resources/add.png</iconset> </property> <property name="text"> <string>Move folder</string> @@ -108,7 +108,7 @@ <action name="actionAddFileToCopy"> <property name="icon"> <iconset> - <normaloff>:/resources/add.png</normaloff>:/resources/add.png</iconset> + <normaloff>:/Themes/Clean/resources/add.png</normaloff>:/Themes/Clean/resources/add.png</iconset> </property> <property name="text"> <string>Copy file(s)</string> @@ -117,7 +117,7 @@ <action name="actionAddFolderToCopy"> <property name="icon"> <iconset> - <normaloff>:/resources/add.png</normaloff>:/resources/add.png</iconset> + <normaloff>:/Themes/Clean/resources/add.png</normaloff>:/Themes/Clean/resources/add.png</iconset> </property> <property name="text"> <string>Copy folder</string> diff --git a/plugins-alternative/Themes/Clean/plugin.json b/plugins-alternative/Themes/Clean/plugin.json new file mode 100644 index 0000000..9e26dfe --- /dev/null +++ b/plugins-alternative/Themes/Clean/plugin.json @@ -0,0 +1 @@ +{}
\ No newline at end of file diff --git a/plugins-alternative/Themes/Clean/resources.qrc b/plugins-alternative/Themes/Clean/resources.qrc index 67c550f..40533c4 100644 --- a/plugins-alternative/Themes/Clean/resources.qrc +++ b/plugins-alternative/Themes/Clean/resources.qrc @@ -1,5 +1,5 @@ <RCC> - <qresource prefix="/"> + <qresource prefix="/Themes/Clean"> <file>resources/SystemTrayIcon/informations.png</file> </qresource> </RCC> diff --git a/plugins-alternative/Themes/Clean/resources/SystemTrayIcon/informations.png b/plugins-alternative/Themes/Clean/resources/SystemTrayIcon/informations.png Binary files differindex e1eb797..5b7b255 100644 --- a/plugins-alternative/Themes/Clean/resources/SystemTrayIcon/informations.png +++ b/plugins-alternative/Themes/Clean/resources/SystemTrayIcon/informations.png diff --git a/plugins-alternative/Themes/Clean/resources/SystemTrayIcon/systray_Caught_Unix.png b/plugins-alternative/Themes/Clean/resources/SystemTrayIcon/systray_Caught_Unix.png Binary files differindex a81e70d..6f5d1cf 100644 --- a/plugins-alternative/Themes/Clean/resources/SystemTrayIcon/systray_Caught_Unix.png +++ b/plugins-alternative/Themes/Clean/resources/SystemTrayIcon/systray_Caught_Unix.png diff --git a/plugins-alternative/Themes/Clean/resources/SystemTrayIcon/systray_Caught_Windows.png b/plugins-alternative/Themes/Clean/resources/SystemTrayIcon/systray_Caught_Windows.png Binary files differindex 8072aea..5464856 100644 --- a/plugins-alternative/Themes/Clean/resources/SystemTrayIcon/systray_Caught_Windows.png +++ b/plugins-alternative/Themes/Clean/resources/SystemTrayIcon/systray_Caught_Windows.png diff --git a/plugins-alternative/Themes/Clean/resources/SystemTrayIcon/systray_Semiuncaught_Unix.png b/plugins-alternative/Themes/Clean/resources/SystemTrayIcon/systray_Semiuncaught_Unix.png Binary files differindex f40ea82..3961215 100644 --- a/plugins-alternative/Themes/Clean/resources/SystemTrayIcon/systray_Semiuncaught_Unix.png +++ b/plugins-alternative/Themes/Clean/resources/SystemTrayIcon/systray_Semiuncaught_Unix.png diff --git a/plugins-alternative/Themes/Clean/resources/SystemTrayIcon/systray_Semiuncaught_Windows.png b/plugins-alternative/Themes/Clean/resources/SystemTrayIcon/systray_Semiuncaught_Windows.png Binary files differindex 8d673e4..45d6315 100644 --- a/plugins-alternative/Themes/Clean/resources/SystemTrayIcon/systray_Semiuncaught_Windows.png +++ b/plugins-alternative/Themes/Clean/resources/SystemTrayIcon/systray_Semiuncaught_Windows.png diff --git a/plugins-alternative/Themes/Clean/resources/SystemTrayIcon/systray_Uncaught_Unix.png b/plugins-alternative/Themes/Clean/resources/SystemTrayIcon/systray_Uncaught_Unix.png Binary files differindex 9ce4779..ac4299a 100644 --- a/plugins-alternative/Themes/Clean/resources/SystemTrayIcon/systray_Uncaught_Unix.png +++ b/plugins-alternative/Themes/Clean/resources/SystemTrayIcon/systray_Uncaught_Unix.png diff --git a/plugins-alternative/Themes/Clean/resources/SystemTrayIcon/systray_Uncaught_Windows.png b/plugins-alternative/Themes/Clean/resources/SystemTrayIcon/systray_Uncaught_Windows.png Binary files differindex d0fca1b..6e6bae7 100644 --- a/plugins-alternative/Themes/Clean/resources/SystemTrayIcon/systray_Uncaught_Windows.png +++ b/plugins-alternative/Themes/Clean/resources/SystemTrayIcon/systray_Uncaught_Windows.png diff --git a/plugins-alternative/Themes/Clean/resources_unix.qrc b/plugins-alternative/Themes/Clean/resources_unix.qrc index ae3894b..847cc1c 100644 --- a/plugins-alternative/Themes/Clean/resources_unix.qrc +++ b/plugins-alternative/Themes/Clean/resources_unix.qrc @@ -1,6 +1,6 @@ <RCC> - <qresource prefix="/"> - <file>resources/SystemTrayIcon/systray_Caught_Unix.png</file> + <qresource prefix="/Themes/Clean"> + <file>resources/SystemTrayIcon/systray_Caught_Unix.png</file> <file>resources/SystemTrayIcon/systray_Semiuncaught_Unix.png</file> <file>resources/SystemTrayIcon/systray_Uncaught_Unix.png</file> </qresource> diff --git a/plugins-alternative/Themes/Clean/resources_windows.qrc b/plugins-alternative/Themes/Clean/resources_windows.qrc index 99829b3..7d8bbe1 100644 --- a/plugins-alternative/Themes/Clean/resources_windows.qrc +++ b/plugins-alternative/Themes/Clean/resources_windows.qrc @@ -1,5 +1,5 @@ <RCC> - <qresource prefix="/"> + <qresource prefix="/Themes/Clean"> <file>resources/SystemTrayIcon/systray_Caught_Windows.png</file> <file>resources/SystemTrayIcon/systray_Semiuncaught_Windows.png</file> <file>resources/SystemTrayIcon/systray_Uncaught_Windows.png</file> |