diff --git a/Changelog b/Changelog index baf552391..1a351ee75 100644 --- a/Changelog +++ b/Changelog @@ -34,6 +34,7 @@ - FEATURE: Support for bitcomet padding files (libtorrent >= v0.15 only) - FEATURE: Option to skip file checking and start seeding immediately in torrent addition dialog (Stephanos Antaris) (libtorrent >= v0.15 only) - WEB UI: Removed Web UI to match new qBittorrent UI + - WEB UI: Added internationalization support - COSMETIC: Merged download / upload lists - COSMETIC: Torrents can be filtered based on their status - COSMETIC: Torrent properties are now displayed in main window diff --git a/src/httpconnection.cpp b/src/httpconnection.cpp index 0b3bde469..bf49d7d84 100644 --- a/src/httpconnection.cpp +++ b/src/httpconnection.cpp @@ -102,12 +102,12 @@ void HttpConnection::write() } QString HttpConnection::translateDocument(QString data) { - std::string contexts[] = {"TransferListFiltersWidget", "TransferListWidget", "PropertiesWidget", "GUI", "MainWindow", "HttpServer"}; + std::string contexts[] = {"TransferListFiltersWidget", "TransferListWidget", "PropertiesWidget", "GUI", "MainWindow", "HttpServer", "confirmDeletionDlg"}; int i=0; bool found = false; do { found = false; - QRegExp regex("_\\(([\\w\\s]+)\\)"); + QRegExp regex("_\\(([\\w\\s?!]+)\\)"); i = regex.indexIn(data, i); if(i >= 0) { qDebug("Found translatable string: %s", regex.cap(1).toUtf8().data()); @@ -117,7 +117,7 @@ QString HttpConnection::translateDocument(QString data) { do { translation = qApp->translate(contexts[context_index].c_str(), word.toLocal8Bit().data(), 0, QCoreApplication::UnicodeUTF8, 1); ++context_index; - }while(translation == word && context_index < 6); + }while(translation == word && context_index < 7); qDebug("Translation is %s", translation.toUtf8().data()); data = data.replace(i, regex.matchedLength(), translation); i += translation.length(); @@ -185,7 +185,7 @@ void HttpConnection::respond() ext.clear(); QByteArray data = file.readAll(); // Translate the page - if(ext == "html") { + if(ext == "html" || ext == "js") { data = translateDocument(QString::fromUtf8(data.data())).toUtf8(); } generator.setStatusLine(200, "OK"); diff --git a/src/httpserver.cpp b/src/httpserver.cpp index f10d2e5bf..9892a1a0a 100644 --- a/src/httpserver.cpp +++ b/src/httpserver.cpp @@ -67,6 +67,7 @@ HttpServer::HttpServer(Bittorrent *_BTSession, int msec, QObject* parent) : QTcp a = tr("Torrent files were correctly added to download list."); a = tr("Point to torrent file"); a = tr("Download"); + a = tr("Are you sure you want to delete the selected torrents from the transfer list and hard disk?"); } HttpServer::~HttpServer() diff --git a/src/lang/qbittorrent_bg.ts b/src/lang/qbittorrent_bg.ts index a1027de88..2dca5757d 100644 --- a/src/lang/qbittorrent_bg.ts +++ b/src/lang/qbittorrent_bg.ts @@ -2839,6 +2839,11 @@ Are you sure you want to quit qBittorrent? Download Свали + + + Are you sure you want to delete the selected torrents from the transfer list and hard disk? + + MainWindow diff --git a/src/lang/qbittorrent_ca.ts b/src/lang/qbittorrent_ca.ts index fe211a198..db4b7f349 100644 --- a/src/lang/qbittorrent_ca.ts +++ b/src/lang/qbittorrent_ca.ts @@ -2315,6 +2315,11 @@ Are you sure you want to quit qBittorrent? Download Descàrrega + + + Are you sure you want to delete the selected torrents from the transfer list and hard disk? + + MainWindow diff --git a/src/lang/qbittorrent_cs.ts b/src/lang/qbittorrent_cs.ts index 9207d7be2..1e71796c3 100644 --- a/src/lang/qbittorrent_cs.ts +++ b/src/lang/qbittorrent_cs.ts @@ -1904,6 +1904,11 @@ Are you sure you want to quit qBittorrent? Download Stáhnout + + + Are you sure you want to delete the selected torrents from the transfer list and hard disk? + + MainWindow diff --git a/src/lang/qbittorrent_da.ts b/src/lang/qbittorrent_da.ts index f98c237ae..583d27e7a 100644 --- a/src/lang/qbittorrent_da.ts +++ b/src/lang/qbittorrent_da.ts @@ -2042,6 +2042,11 @@ Are you sure you want to quit qBittorrent? Download + + + Are you sure you want to delete the selected torrents from the transfer list and hard disk? + + MainWindow diff --git a/src/lang/qbittorrent_de.ts b/src/lang/qbittorrent_de.ts index 914d2bd97..c899a7cc5 100644 --- a/src/lang/qbittorrent_de.ts +++ b/src/lang/qbittorrent_de.ts @@ -2806,6 +2806,11 @@ Are you sure you want to quit qBittorrent? Download Lade + + + Are you sure you want to delete the selected torrents from the transfer list and hard disk? + + MainWindow diff --git a/src/lang/qbittorrent_el.ts b/src/lang/qbittorrent_el.ts index 00d138fcf..f1310bd6b 100644 --- a/src/lang/qbittorrent_el.ts +++ b/src/lang/qbittorrent_el.ts @@ -2908,6 +2908,11 @@ Are you sure you want to quit qBittorrent? Download Κατέβασμα + + + Are you sure you want to delete the selected torrents from the transfer list and hard disk? + + MainWindow diff --git a/src/lang/qbittorrent_en.ts b/src/lang/qbittorrent_en.ts index 0e0e290e0..f7ebca1a3 100644 --- a/src/lang/qbittorrent_en.ts +++ b/src/lang/qbittorrent_en.ts @@ -1357,6 +1357,11 @@ Are you sure you want to quit qBittorrent? Download + + + Are you sure you want to delete the selected torrents from the transfer list and hard disk? + + MainWindow diff --git a/src/lang/qbittorrent_es.ts b/src/lang/qbittorrent_es.ts index aaea00ce5..def67732c 100644 --- a/src/lang/qbittorrent_es.ts +++ b/src/lang/qbittorrent_es.ts @@ -2749,6 +2749,11 @@ Are you sure you want to quit qBittorrent? Download Descargar + + + Are you sure you want to delete the selected torrents from the transfer list and hard disk? + + MainWindow diff --git a/src/lang/qbittorrent_fi.ts b/src/lang/qbittorrent_fi.ts index a3fac8bc0..2258895c0 100644 --- a/src/lang/qbittorrent_fi.ts +++ b/src/lang/qbittorrent_fi.ts @@ -2489,6 +2489,11 @@ Are you sure you want to quit qBittorrent? Download Lataa + + + Are you sure you want to delete the selected torrents from the transfer list and hard disk? + + MainWindow diff --git a/src/lang/qbittorrent_fr.qm b/src/lang/qbittorrent_fr.qm index 0b9b7e3d1..ab1681573 100644 Binary files a/src/lang/qbittorrent_fr.qm and b/src/lang/qbittorrent_fr.qm differ diff --git a/src/lang/qbittorrent_fr.ts b/src/lang/qbittorrent_fr.ts index a639f8a8c..a1275f099 100644 --- a/src/lang/qbittorrent_fr.ts +++ b/src/lang/qbittorrent_fr.ts @@ -2984,6 +2984,11 @@ Etes-vous certain de vouloir quitter qBittorrent ? Download Télécharger + + + Are you sure you want to delete the selected torrents from the transfer list and hard disk? + Etes-vous certain de vouloir supprimer les torrents sélectionnés de la liste et du disque dur ? + MainWindow diff --git a/src/lang/qbittorrent_hu.ts b/src/lang/qbittorrent_hu.ts index e3663f65d..471199f50 100644 --- a/src/lang/qbittorrent_hu.ts +++ b/src/lang/qbittorrent_hu.ts @@ -2334,6 +2334,11 @@ Are you sure you want to quit qBittorrent? Download Letöltés + + + Are you sure you want to delete the selected torrents from the transfer list and hard disk? + + MainWindow diff --git a/src/lang/qbittorrent_it.ts b/src/lang/qbittorrent_it.ts index 890603487..d79fbbe90 100644 --- a/src/lang/qbittorrent_it.ts +++ b/src/lang/qbittorrent_it.ts @@ -2661,6 +2661,11 @@ Are you sure you want to quit qBittorrent? Download Download + + + Are you sure you want to delete the selected torrents from the transfer list and hard disk? + + MainWindow diff --git a/src/lang/qbittorrent_ja.ts b/src/lang/qbittorrent_ja.ts index 05bba301e..861c16355 100644 --- a/src/lang/qbittorrent_ja.ts +++ b/src/lang/qbittorrent_ja.ts @@ -2264,6 +2264,11 @@ qBittorrent を終了してもよろしいですか? Download ダウンロード + + + Are you sure you want to delete the selected torrents from the transfer list and hard disk? + + MainWindow diff --git a/src/lang/qbittorrent_ko.ts b/src/lang/qbittorrent_ko.ts index 1cf778f1f..f455ea5bc 100644 --- a/src/lang/qbittorrent_ko.ts +++ b/src/lang/qbittorrent_ko.ts @@ -2831,6 +2831,11 @@ Are you sure you want to quit qBittorrent? Download 다운로드 + + + Are you sure you want to delete the selected torrents from the transfer list and hard disk? + + MainWindow diff --git a/src/lang/qbittorrent_nb.ts b/src/lang/qbittorrent_nb.ts index edb49b348..52c35b3fa 100644 --- a/src/lang/qbittorrent_nb.ts +++ b/src/lang/qbittorrent_nb.ts @@ -2244,6 +2244,11 @@ Are you sure you want to quit qBittorrent? Download Last ned + + + Are you sure you want to delete the selected torrents from the transfer list and hard disk? + + MainWindow diff --git a/src/lang/qbittorrent_nl.ts b/src/lang/qbittorrent_nl.ts index dd08d5dd9..ba1311ce0 100644 --- a/src/lang/qbittorrent_nl.ts +++ b/src/lang/qbittorrent_nl.ts @@ -2504,6 +2504,10 @@ Are you sure you want to quit qBittorrent? Point to torrent file + + Are you sure you want to delete the selected torrents from the transfer list and hard disk? + + MainWindow diff --git a/src/lang/qbittorrent_pl.ts b/src/lang/qbittorrent_pl.ts index 53a6da1a4..c5dc8d806 100644 --- a/src/lang/qbittorrent_pl.ts +++ b/src/lang/qbittorrent_pl.ts @@ -2526,6 +2526,10 @@ Are you sure you want to quit qBittorrent? Point to torrent file + + Are you sure you want to delete the selected torrents from the transfer list and hard disk? + + MainWindow diff --git a/src/lang/qbittorrent_pt.ts b/src/lang/qbittorrent_pt.ts index bac1dc392..e1cdf8586 100644 --- a/src/lang/qbittorrent_pt.ts +++ b/src/lang/qbittorrent_pt.ts @@ -2433,6 +2433,10 @@ Are you sure you want to quit qBittorrent? Point to torrent file + + Are you sure you want to delete the selected torrents from the transfer list and hard disk? + + MainWindow diff --git a/src/lang/qbittorrent_pt_BR.ts b/src/lang/qbittorrent_pt_BR.ts index bac1dc392..e1cdf8586 100644 --- a/src/lang/qbittorrent_pt_BR.ts +++ b/src/lang/qbittorrent_pt_BR.ts @@ -2433,6 +2433,10 @@ Are you sure you want to quit qBittorrent? Point to torrent file + + Are you sure you want to delete the selected torrents from the transfer list and hard disk? + + MainWindow diff --git a/src/lang/qbittorrent_ro.ts b/src/lang/qbittorrent_ro.ts index f6e40df52..ef37aeaf5 100644 --- a/src/lang/qbittorrent_ro.ts +++ b/src/lang/qbittorrent_ro.ts @@ -2360,6 +2360,10 @@ Are you sure you want to quit qBittorrent? Point to torrent file + + Are you sure you want to delete the selected torrents from the transfer list and hard disk? + + MainWindow diff --git a/src/lang/qbittorrent_ru.ts b/src/lang/qbittorrent_ru.ts index af2ad8099..83c11294e 100644 --- a/src/lang/qbittorrent_ru.ts +++ b/src/lang/qbittorrent_ru.ts @@ -2521,6 +2521,10 @@ Are you sure you want to quit qBittorrent? Point to torrent file + + Are you sure you want to delete the selected torrents from the transfer list and hard disk? + + MainWindow diff --git a/src/lang/qbittorrent_sk.ts b/src/lang/qbittorrent_sk.ts index 845e83d15..8c3c6aa15 100644 --- a/src/lang/qbittorrent_sk.ts +++ b/src/lang/qbittorrent_sk.ts @@ -2446,6 +2446,10 @@ Are you sure you want to quit qBittorrent? Point to torrent file + + Are you sure you want to delete the selected torrents from the transfer list and hard disk? + + MainWindow diff --git a/src/lang/qbittorrent_sv.ts b/src/lang/qbittorrent_sv.ts index 88f3f02c8..3188c4f68 100644 --- a/src/lang/qbittorrent_sv.ts +++ b/src/lang/qbittorrent_sv.ts @@ -1495,6 +1495,10 @@ Are you sure you want to quit qBittorrent? Point to torrent file + + Are you sure you want to delete the selected torrents from the transfer list and hard disk? + + MainWindow diff --git a/src/lang/qbittorrent_tr.ts b/src/lang/qbittorrent_tr.ts index 19367f7fd..5f795f19d 100644 --- a/src/lang/qbittorrent_tr.ts +++ b/src/lang/qbittorrent_tr.ts @@ -2506,6 +2506,10 @@ Are you sure you want to quit qBittorrent? Point to torrent file + + Are you sure you want to delete the selected torrents from the transfer list and hard disk? + + MainWindow diff --git a/src/lang/qbittorrent_uk.ts b/src/lang/qbittorrent_uk.ts index 21fd9e672..90de85dc3 100644 --- a/src/lang/qbittorrent_uk.ts +++ b/src/lang/qbittorrent_uk.ts @@ -2380,6 +2380,10 @@ Are you sure you want to quit qBittorrent? Point to torrent file + + Are you sure you want to delete the selected torrents from the transfer list and hard disk? + + MainWindow diff --git a/src/lang/qbittorrent_zh.ts b/src/lang/qbittorrent_zh.ts index ecfe41009..b114c5035 100644 --- a/src/lang/qbittorrent_zh.ts +++ b/src/lang/qbittorrent_zh.ts @@ -2641,6 +2641,10 @@ Are you sure you want to quit qBittorrent? Point to torrent file + + Are you sure you want to delete the selected torrents from the transfer list and hard disk? + + MainWindow diff --git a/src/lang/qbittorrent_zh_TW.ts b/src/lang/qbittorrent_zh_TW.ts index 8fe3b5666..0047b7c65 100644 --- a/src/lang/qbittorrent_zh_TW.ts +++ b/src/lang/qbittorrent_zh_TW.ts @@ -1590,6 +1590,10 @@ Are you sure you want to quit qBittorrent? Point to torrent file + + Are you sure you want to delete the selected torrents from the transfer list and hard disk? + + MainWindow diff --git a/src/webui/scripts/mocha-init.js b/src/webui/scripts/mocha-init.js index 9ba863b0f..faccb7fd8 100644 --- a/src/webui/scripts/mocha-init.js +++ b/src/webui/scripts/mocha-init.js @@ -64,7 +64,7 @@ initializeWindows = function(){ addClickEvent('delete', function(e){ new Event(e).stop(); var h = myTable.selectedIds(); - if(h.length && confirm('Are you sure you want to delete the selected item in download list?')) { + if(h.length && confirm('_(Are you sure you want to delete the selected torrents from the transfer list?)')) { h.each(function(item, index){ new Request({url: '/command/delete', method: 'post', data: {hash: item}}).send(); }); @@ -76,7 +76,7 @@ initializeWindows = function(){ addClickEvent('deletePerm', function(e){ new Event(e).stop(); var h = myTable.selectedIds(); - if(h.length && confirm('Are you sure you want to delete from hard drive the selected item in download list?')) { + if(h.length && confirm('_(Are you sure you want to delete the selected torrents from the transfer list and hard disk?)')) { h.each(function(item, index){ new Request({url: '/command/deletePerm', method: 'post', data: {hash: item}}).send(); });