mirror of
https://github.com/d47081/qBittorrent.git
synced 2025-01-23 21:14:33 +00:00
Merge pull request #4849 from Chocobo1/run_ext_slash
Save "Run external program" input as is. Closes #4830.
This commit is contained in:
commit
96c2947283
@ -1127,12 +1127,12 @@ void Preferences::setAutoRunEnabled(bool enabled)
|
|||||||
|
|
||||||
QString Preferences::getAutoRunProgram() const
|
QString Preferences::getAutoRunProgram() const
|
||||||
{
|
{
|
||||||
return Utils::Fs::fromNativePath(value("AutoRun/program").toString());
|
return value("AutoRun/program").toString();
|
||||||
}
|
}
|
||||||
|
|
||||||
void Preferences::setAutoRunProgram(const QString &program)
|
void Preferences::setAutoRunProgram(const QString &program)
|
||||||
{
|
{
|
||||||
setValue("AutoRun/program", Utils::Fs::fromNativePath(program));
|
setValue("AutoRun/program", program);
|
||||||
}
|
}
|
||||||
|
|
||||||
bool Preferences::shutdownWhenDownloadsComplete() const
|
bool Preferences::shutdownWhenDownloadsComplete() const
|
||||||
|
@ -199,17 +199,19 @@ options_imp::options_imp(QWidget *parent)
|
|||||||
connect(autoRunBox, SIGNAL(toggled(bool)), this, SLOT(enableApplyButton()));
|
connect(autoRunBox, SIGNAL(toggled(bool)), this, SLOT(enableApplyButton()));
|
||||||
connect(autoRun_txt, SIGNAL(textChanged(QString)), this, SLOT(enableApplyButton()));
|
connect(autoRun_txt, SIGNAL(textChanged(QString)), this, SLOT(enableApplyButton()));
|
||||||
|
|
||||||
autoRun_param->setText(QString::fromUtf8("%1\n %2\n %3\n %4\n %5\n %6\n %7\n %8\n %9\n %10")
|
const QString autoRunStr = QString::fromUtf8("%1\n %2\n %3\n %4\n %5\n %6\n %7\n %8\n %9\n %10\n%11")
|
||||||
.arg(tr("Supported parameters (case sensitive):"))
|
.arg(tr("Supported parameters (case sensitive):"))
|
||||||
.arg(tr("%N: Torrent name"))
|
.arg(tr("%N: Torrent name"))
|
||||||
.arg(tr("%L: Category"))
|
.arg(tr("%L: Label"))
|
||||||
.arg(tr("%F: Content path (same as root path for multifile torrent)"))
|
.arg(tr("%F: Content path (same as root path for multifile torrent)"))
|
||||||
.arg(tr("%R: Root path (first torrent subdirectory path)"))
|
.arg(tr("%R: Root path (first torrent subdirectory path)"))
|
||||||
.arg(tr("%D: Save path"))
|
.arg(tr("%D: Save path"))
|
||||||
.arg(tr("%C: Number of files"))
|
.arg(tr("%C: Number of files"))
|
||||||
.arg(tr("%Z: Torrent size (bytes)"))
|
.arg(tr("%Z: Torrent size (bytes)"))
|
||||||
.arg(tr("%T: Current tracker"))
|
.arg(tr("%T: Current tracker"))
|
||||||
.arg(tr("%I: Info hash")));
|
.arg(tr("%I: Info hash"))
|
||||||
|
.arg(tr("Tip: Encapsulate parameter with quotation marks to avoid text being cut off at whitespace (e.g., \"%N\")"));
|
||||||
|
autoRun_param->setText(autoRunStr);
|
||||||
|
|
||||||
// Connection tab
|
// Connection tab
|
||||||
connect(spinPort, SIGNAL(valueChanged(QString)), this, SLOT(enableApplyButton()));
|
connect(spinPort, SIGNAL(valueChanged(QString)), this, SLOT(enableApplyButton()));
|
||||||
|
Loading…
x
Reference in New Issue
Block a user