mirror of https://github.com/aria2/aria2
Add "hide" to --download-result option
parent
3c637fa3d5
commit
aa863fa4d1
|
@ -315,7 +315,8 @@ error_code::Value MultiUrlRequestInfo::getResult()
|
||||||
if (!serverStatOf.empty()) {
|
if (!serverStatOf.empty()) {
|
||||||
e_->getRequestGroupMan()->saveServerStat(serverStatOf);
|
e_->getRequestGroupMan()->saveServerStat(serverStatOf);
|
||||||
}
|
}
|
||||||
if (!option_->getAsBool(PREF_QUIET)) {
|
if (!option_->getAsBool(PREF_QUIET) &&
|
||||||
|
option_->get(PREF_DOWNLOAD_RESULT) != A2_V_HIDE) {
|
||||||
e_->getRequestGroupMan()->showDownloadResults(
|
e_->getRequestGroupMan()->showDownloadResults(
|
||||||
*global::cout(), option_->get(PREF_DOWNLOAD_RESULT) == A2_V_FULL);
|
*global::cout(), option_->get(PREF_DOWNLOAD_RESULT) == A2_V_FULL);
|
||||||
global::cout()->flush();
|
global::cout()->flush();
|
||||||
|
|
|
@ -235,9 +235,9 @@ std::vector<OptionHandler*> OptionHandlerFactory::createOptionHandlers()
|
||||||
handlers.push_back(op);
|
handlers.push_back(op);
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
OptionHandler* op(
|
OptionHandler* op(new ParameterOptionHandler(
|
||||||
new ParameterOptionHandler(PREF_DOWNLOAD_RESULT, TEXT_DOWNLOAD_RESULT,
|
PREF_DOWNLOAD_RESULT, TEXT_DOWNLOAD_RESULT, A2_V_DEFAULT,
|
||||||
A2_V_DEFAULT, {A2_V_DEFAULT, A2_V_FULL}));
|
{A2_V_DEFAULT, A2_V_FULL, A2_V_HIDE}));
|
||||||
op->addTag(TAG_ADVANCED);
|
op->addTag(TAG_ADVANCED);
|
||||||
op->setChangeGlobalOption(true);
|
op->setChangeGlobalOption(true);
|
||||||
handlers.push_back(op);
|
handlers.push_back(op);
|
||||||
|
|
|
@ -121,6 +121,7 @@ const std::string V_NONE("none");
|
||||||
const std::string V_MEM("mem");
|
const std::string V_MEM("mem");
|
||||||
const std::string V_ALL("all");
|
const std::string V_ALL("all");
|
||||||
const std::string A2_V_FULL("full");
|
const std::string A2_V_FULL("full");
|
||||||
|
const std::string A2_V_HIDE("hide");
|
||||||
const std::string A2_V_GEOM("geom");
|
const std::string A2_V_GEOM("geom");
|
||||||
const std::string V_PREALLOC("prealloc");
|
const std::string V_PREALLOC("prealloc");
|
||||||
const std::string V_FALLOC("falloc");
|
const std::string V_FALLOC("falloc");
|
||||||
|
@ -336,7 +337,7 @@ PrefPtr PREF_STREAM_PIECE_SELECTOR = makePref("stream-piece-selector");
|
||||||
PrefPtr PREF_TRUNCATE_CONSOLE_READOUT = makePref("truncate-console-readout");
|
PrefPtr PREF_TRUNCATE_CONSOLE_READOUT = makePref("truncate-console-readout");
|
||||||
// value: true | false
|
// value: true | false
|
||||||
PrefPtr PREF_PAUSE = makePref("pause");
|
PrefPtr PREF_PAUSE = makePref("pause");
|
||||||
// value: default | full
|
// value: default | full | hide
|
||||||
PrefPtr PREF_DOWNLOAD_RESULT = makePref("download-result");
|
PrefPtr PREF_DOWNLOAD_RESULT = makePref("download-result");
|
||||||
// value: true | false
|
// value: true | false
|
||||||
PrefPtr PREF_HASH_CHECK_ONLY = makePref("hash-check-only");
|
PrefPtr PREF_HASH_CHECK_ONLY = makePref("hash-check-only");
|
||||||
|
|
|
@ -78,6 +78,7 @@ extern const std::string V_NONE;
|
||||||
extern const std::string V_MEM;
|
extern const std::string V_MEM;
|
||||||
extern const std::string V_ALL;
|
extern const std::string V_ALL;
|
||||||
extern const std::string A2_V_FULL;
|
extern const std::string A2_V_FULL;
|
||||||
|
extern const std::string A2_V_HIDE;
|
||||||
extern const std::string A2_V_GEOM;
|
extern const std::string A2_V_GEOM;
|
||||||
extern const std::string V_PREALLOC;
|
extern const std::string V_PREALLOC;
|
||||||
extern const std::string V_FALLOC;
|
extern const std::string V_FALLOC;
|
||||||
|
@ -289,7 +290,7 @@ extern PrefPtr PREF_STREAM_PIECE_SELECTOR;
|
||||||
extern PrefPtr PREF_TRUNCATE_CONSOLE_READOUT;
|
extern PrefPtr PREF_TRUNCATE_CONSOLE_READOUT;
|
||||||
// value: true | false
|
// value: true | false
|
||||||
extern PrefPtr PREF_PAUSE;
|
extern PrefPtr PREF_PAUSE;
|
||||||
// value: default | full
|
// value: default | full | hide
|
||||||
extern PrefPtr PREF_DOWNLOAD_RESULT;
|
extern PrefPtr PREF_DOWNLOAD_RESULT;
|
||||||
// value: true | false
|
// value: true | false
|
||||||
extern PrefPtr PREF_HASH_CHECK_ONLY;
|
extern PrefPtr PREF_HASH_CHECK_ONLY;
|
||||||
|
|
|
@ -882,7 +882,8 @@
|
||||||
" download speed, percentage of progress and\n" \
|
" download speed, percentage of progress and\n" \
|
||||||
" path/URI. The percentage of progress and\n" \
|
" path/URI. The percentage of progress and\n" \
|
||||||
" path/URI are printed for each requested file in\n" \
|
" path/URI are printed for each requested file in\n" \
|
||||||
" each row.")
|
" each row.\n" \
|
||||||
|
" If OPT is 'hide', \"Download Result\" is hidden.")
|
||||||
#define TEXT_HASH_CHECK_ONLY \
|
#define TEXT_HASH_CHECK_ONLY \
|
||||||
_(" --hash-check-only[=true|false] If true is given, after hash check using\n" \
|
_(" --hash-check-only[=true|false] If true is given, after hash check using\n" \
|
||||||
" --check-integrity option, abort download whether\n" \
|
" --check-integrity option, abort download whether\n" \
|
||||||
|
|
Loading…
Reference in New Issue