Make 'TorrentPersistentData' similar to 'Preferences' class.

This commit is contained in:
sledgehammer999 2015-01-27 17:28:21 +02:00
parent 70985480d6
commit eeee24a0b3
11 changed files with 235 additions and 223 deletions

View file

@ -63,6 +63,7 @@
#include "preferences.h"
#include "trackerlist.h"
#include "peerlistwidget.h"
#include "torrentpersistentdata.h"
#include "transferlistfilterswidget.h"
#include "propertieswidget.h"
#include "statusbar.h"
@ -505,6 +506,7 @@ void MainWindow::shutdownCleanUp()
delete switchRSSShortcut;
delete toolbarMenu;
IconProvider::drop();
TorrentPersistentData::drop();
Preferences::drop();
Logger::drop();
qDebug("Finished GUI destruction");
@ -667,7 +669,7 @@ void MainWindow::balloonClicked()
// called when a torrent has finished
void MainWindow::finishedTorrent(const QTorrentHandle& h) const
{
if (TorrentPersistentData::instance().isSeed(h.hash()))
if (TorrentPersistentData::instance()->isSeed(h.hash()))
showNotificationBaloon(tr("Download completion"), tr("%1 has finished downloading.", "e.g: xxx.avi has finished downloading.").arg(h.name()));
}