mirror of
https://github.com/d47081/qBittorrent.git
synced 2025-01-26 22:44:36 +00:00
Add missing QTreeWidget::dropEvent to d'n'd atempt occuring in same location.
Remove 'Overwrite attempt' dialog as obsolete. Now moving item, e.g. from folder to same folder, will just make it the last child of the folder.
This commit is contained in:
parent
4f667c6e7d
commit
116fa8936a
@ -205,7 +205,7 @@ void FeedListWidget::dropEvent(QDropEvent *event) {
|
|||||||
foreach (QTreeWidgetItem *src_item, src_items) {
|
foreach (QTreeWidgetItem *src_item, src_items) {
|
||||||
RssFilePtr file = getRSSItem(src_item);
|
RssFilePtr file = getRSSItem(src_item);
|
||||||
if (dest_folder->hasChild(file->id())) {
|
if (dest_folder->hasChild(file->id())) {
|
||||||
emit overwriteAttempt(file->id());
|
QTreeWidget::dropEvent(event);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -71,7 +71,6 @@ public slots:
|
|||||||
|
|
||||||
signals:
|
signals:
|
||||||
void foldersAltered(const QList<QTreeWidgetItem*> &folders);
|
void foldersAltered(const QList<QTreeWidgetItem*> &folders);
|
||||||
void overwriteAttempt(const QString &filename);
|
|
||||||
|
|
||||||
private slots:
|
private slots:
|
||||||
void updateCurrentFeed(QTreeWidgetItem* new_item);
|
void updateCurrentFeed(QTreeWidgetItem* new_item);
|
||||||
|
@ -168,13 +168,6 @@ void RSSImp::askNewFolder()
|
|||||||
m_rssManager->saveStreamList();
|
m_rssManager->saveStreamList();
|
||||||
}
|
}
|
||||||
|
|
||||||
void RSSImp::displayOverwriteError(const QString& filename)
|
|
||||||
{
|
|
||||||
QMessageBox::warning(this, tr("Overwrite attempt"),
|
|
||||||
tr("You cannot overwrite %1 item.", "You cannot overwrite myFolder item.").arg(filename),
|
|
||||||
QMessageBox::Ok);
|
|
||||||
}
|
|
||||||
|
|
||||||
// add a stream by a button
|
// add a stream by a button
|
||||||
void RSSImp::on_newFeedButton_clicked()
|
void RSSImp::on_newFeedButton_clicked()
|
||||||
{
|
{
|
||||||
@ -717,7 +710,6 @@ RSSImp::RSSImp(QWidget *parent) :
|
|||||||
|
|
||||||
connect(m_feedList, SIGNAL(currentItemChanged(QTreeWidgetItem*,QTreeWidgetItem*)), this, SLOT(populateArticleList(QTreeWidgetItem*)));
|
connect(m_feedList, SIGNAL(currentItemChanged(QTreeWidgetItem*,QTreeWidgetItem*)), this, SLOT(populateArticleList(QTreeWidgetItem*)));
|
||||||
connect(m_feedList, SIGNAL(foldersAltered(QList<QTreeWidgetItem*>)), this, SLOT(updateItemsInfos(QList<QTreeWidgetItem*>)));
|
connect(m_feedList, SIGNAL(foldersAltered(QList<QTreeWidgetItem*>)), this, SLOT(updateItemsInfos(QList<QTreeWidgetItem*>)));
|
||||||
connect(m_feedList, SIGNAL(overwriteAttempt(QString)), this, SLOT(displayOverwriteError(QString)));
|
|
||||||
|
|
||||||
connect(listArticles, SIGNAL(itemSelectionChanged()), this, SLOT(refreshTextBrowser()));
|
connect(listArticles, SIGNAL(itemSelectionChanged()), this, SLOT(refreshTextBrowser()));
|
||||||
connect(listArticles, SIGNAL(itemDoubleClicked(QListWidgetItem *)), this, SLOT(downloadSelectedTorrents()));
|
connect(listArticles, SIGNAL(itemDoubleClicked(QListWidgetItem *)), this, SLOT(downloadSelectedTorrents()));
|
||||||
|
@ -79,7 +79,6 @@ private slots:
|
|||||||
void askNewFolder();
|
void askNewFolder();
|
||||||
void saveFoldersOpenState();
|
void saveFoldersOpenState();
|
||||||
void loadFoldersOpenState();
|
void loadFoldersOpenState();
|
||||||
void displayOverwriteError(const QString &filename);
|
|
||||||
void on_actionManage_cookies_triggered();
|
void on_actionManage_cookies_triggered();
|
||||||
void on_settingsButton_clicked();
|
void on_settingsButton_clicked();
|
||||||
void on_rssDownloaderBtn_clicked();
|
void on_rssDownloaderBtn_clicked();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user