mirror of
https://github.com/d47081/qBittorrent.git
synced 2025-01-23 13:04:23 +00:00
commit
4ca1a2d5aa
@ -153,10 +153,10 @@ QVariant ScanFoldersModel::headerData(int section, Qt::Orientation orientation,
|
|||||||
|
|
||||||
switch (section) {
|
switch (section) {
|
||||||
case WATCH:
|
case WATCH:
|
||||||
title = tr("Watched Folder");
|
title = tr("Monitored Folder");
|
||||||
break;
|
break;
|
||||||
case DOWNLOAD:
|
case DOWNLOAD:
|
||||||
title = tr("Save Files to");
|
title = tr("Override Save Location");
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1248,7 +1248,7 @@
|
|||||||
<item>
|
<item>
|
||||||
<widget class="QPushButton" name="addScanFolderButton">
|
<widget class="QPushButton" name="addScanFolderButton">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>Add folder...</string>
|
<string>Add entry</string>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
@ -1258,7 +1258,7 @@
|
|||||||
<bool>false</bool>
|
<bool>false</bool>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>Remove folder</string>
|
<string>Remove entry</string>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
|
@ -1317,7 +1317,7 @@ void options_imp::on_addScanFolderButton_clicked()
|
|||||||
const QString dir = QFileDialog::getExistingDirectory(this, tr("Add directory to scan"),
|
const QString dir = QFileDialog::getExistingDirectory(this, tr("Add directory to scan"),
|
||||||
Utils::Fs::toNativePath(Utils::Fs::folderName(pref->getScanDirsLastPath())));
|
Utils::Fs::toNativePath(Utils::Fs::folderName(pref->getScanDirsLastPath())));
|
||||||
if (!dir.isEmpty()) {
|
if (!dir.isEmpty()) {
|
||||||
const ScanFoldersModel::PathStatus status = ScanFoldersModel::instance()->addPath(dir, ScanFoldersModel::DOWNLOAD_IN_WATCH_FOLDER, QString(), false);
|
const ScanFoldersModel::PathStatus status = ScanFoldersModel::instance()->addPath(dir, ScanFoldersModel::DEFAULT_LOCATION, QString(), false);
|
||||||
QString error;
|
QString error;
|
||||||
switch (status) {
|
switch (status) {
|
||||||
case ScanFoldersModel::AlreadyInList:
|
case ScanFoldersModel::AlreadyInList:
|
||||||
|
@ -126,7 +126,7 @@ PeerListWidget::PeerListWidget(PropertiesWidget *parent)
|
|||||||
connect(header(), SIGNAL(sectionClicked(int)), SLOT(handleSortColumnChanged(int)));
|
connect(header(), SIGNAL(sectionClicked(int)), SLOT(handleSortColumnChanged(int)));
|
||||||
handleSortColumnChanged(header()->sortIndicatorSection());
|
handleSortColumnChanged(header()->sortIndicatorSection());
|
||||||
m_copyHotkey = new QShortcut(QKeySequence(Qt::ControlModifier + Qt::Key_C), this, SLOT(copySelectedPeers()), 0, Qt::WidgetShortcut);
|
m_copyHotkey = new QShortcut(QKeySequence(Qt::ControlModifier + Qt::Key_C), this, SLOT(copySelectedPeers()), 0, Qt::WidgetShortcut);
|
||||||
|
|
||||||
#ifdef QBT_USES_QT5
|
#ifdef QBT_USES_QT5
|
||||||
// This hack fixes reordering of first column with Qt5.
|
// This hack fixes reordering of first column with Qt5.
|
||||||
// https://github.com/qtproject/qtbase/commit/e0fc088c0c8bc61dbcaf5928b24986cd61a22777
|
// https://github.com/qtproject/qtbase/commit/e0fc088c0c8bc61dbcaf5928b24986cd61a22777
|
||||||
@ -236,7 +236,7 @@ void PeerListWidget::showPeerListMenu(const QPoint&)
|
|||||||
QAction *banAct = 0;
|
QAction *banAct = 0;
|
||||||
QAction *copyPeerAct = 0;
|
QAction *copyPeerAct = 0;
|
||||||
if (!selectionModel()->selectedRows().isEmpty()) {
|
if (!selectionModel()->selectedRows().isEmpty()) {
|
||||||
copyPeerAct = menu.addAction(GuiIconProvider::instance()->getIcon("edit-copy"), tr("Copy selected"));
|
copyPeerAct = menu.addAction(GuiIconProvider::instance()->getIcon("edit-copy"), tr("Copy IP:port"));
|
||||||
menu.addSeparator();
|
menu.addSeparator();
|
||||||
banAct = menu.addAction(GuiIconProvider::instance()->getIcon("user-group-delete"), tr("Ban peer permanently"));
|
banAct = menu.addAction(GuiIconProvider::instance()->getIcon("user-group-delete"), tr("Ban peer permanently"));
|
||||||
emptyMenu = false;
|
emptyMenu = false;
|
||||||
|
@ -63,8 +63,8 @@ QWidget *ScanFoldersDelegate::createEditor(QWidget *parent, const QStyleOptionVi
|
|||||||
QComboBox* editor = new QComboBox(parent);
|
QComboBox* editor = new QComboBox(parent);
|
||||||
|
|
||||||
editor->setFocusPolicy(Qt::StrongFocus);
|
editor->setFocusPolicy(Qt::StrongFocus);
|
||||||
editor->addItem(tr("Watch Folder"));
|
editor->addItem(tr("Same as monitored folder"));
|
||||||
editor->addItem(tr("Default Folder"));
|
editor->addItem(tr("Default save location"));
|
||||||
editor->addItem(tr("Browse..."));
|
editor->addItem(tr("Browse..."));
|
||||||
if (index.data(Qt::UserRole).toInt() == ScanFoldersModel::CUSTOM_LOCATION) {
|
if (index.data(Qt::UserRole).toInt() == ScanFoldersModel::CUSTOM_LOCATION) {
|
||||||
editor->insertSeparator(3);
|
editor->insertSeparator(3);
|
||||||
@ -99,7 +99,7 @@ void ScanFoldersDelegate::setModelData(QWidget *editor, QAbstractItemModel *mode
|
|||||||
model->setData(
|
model->setData(
|
||||||
index,
|
index,
|
||||||
QFileDialog::getExistingDirectory(
|
QFileDialog::getExistingDirectory(
|
||||||
0, tr("Choose save path"),
|
0, tr("Select save location"),
|
||||||
index.data(Qt::UserRole).toInt() == ScanFoldersModel::CUSTOM_LOCATION ?
|
index.data(Qt::UserRole).toInt() == ScanFoldersModel::CUSTOM_LOCATION ?
|
||||||
index.data().toString() :
|
index.data().toString() :
|
||||||
BitTorrent::Session::instance()->defaultSavePath()),
|
BitTorrent::Session::instance()->defaultSavePath()),
|
||||||
|
Loading…
x
Reference in New Issue
Block a user