diff --git a/src/webui/abstractwebapplication.cpp b/src/webui/abstractwebapplication.cpp index c0e42bf0a..263fdc9b5 100644 --- a/src/webui/abstractwebapplication.cpp +++ b/src/webui/abstractwebapplication.cpp @@ -245,7 +245,7 @@ void AbstractWebApplication::translateDocument(QString& data) "options_imp", "Preferences", "TrackersAdditionDlg", "ScanFoldersModel", "PropTabBar", "TorrentModel", "downloadFromURL", "MainWindow", "misc", "StatusBar", "AboutDlg", "about", "PeerListWidget", "StatusFiltersWidget", - "CategoryFiltersList", "TransferListDelegate" + "CategoryFiltersList", "TransferListDelegate", "AddNewTorrentDialog" }; const size_t context_count = sizeof(contexts) / sizeof(contexts[0]); int i = 0; diff --git a/src/webui/webapplication.cpp b/src/webui/webapplication.cpp index 26e188c6d..ea274a13c 100644 --- a/src/webui/webapplication.cpp +++ b/src/webui/webapplication.cpp @@ -367,6 +367,8 @@ void WebApplication::action_command_download() CHECK_URI(0); QString urls = request().posts["urls"]; QStringList list = urls.split('\n'); + bool skipChecking = request().posts["skip_checking"] == "true"; + bool addPaused = request().posts["paused"] == "true"; QString savepath = request().posts["savepath"]; QString category = request().posts["category"]; QString cookie = request().posts["cookie"]; @@ -390,6 +392,11 @@ void WebApplication::action_command_download() category = category.trimmed(); BitTorrent::AddTorrentParams params; + + // TODO: Check if destination actually exists + params.skipChecking = skipChecking; + + params.addPaused = addPaused; params.savePath = savepath; params.category = category; @@ -406,6 +413,8 @@ void WebApplication::action_command_upload() { qDebug() << Q_FUNC_INFO; CHECK_URI(0); + bool skipChecking = request().posts["skip_checking"] == "true"; + bool addPaused = request().posts["paused"] == "true"; QString savepath = request().posts["savepath"]; QString category = request().posts["category"]; @@ -423,6 +432,11 @@ void WebApplication::action_command_upload() } else { BitTorrent::AddTorrentParams params; + + // TODO: Check if destination actually exists + params.skipChecking = skipChecking; + + params.addPaused = addPaused; params.savePath = savepath; params.category = category; if (!BitTorrent::Session::instance()->addTorrent(torrentInfo, params)) { diff --git a/src/webui/www/public/download.html b/src/webui/www/public/download.html index a5c612e02..e030b6e70 100644 --- a/src/webui/www/public/download.html +++ b/src/webui/www/public/download.html @@ -29,6 +29,15 @@ +