Improve lists columns state saving

This commit is contained in:
Christophe Dumez 2011-03-13 10:09:31 +00:00
commit 596737ba2f
7 changed files with 49 additions and 68 deletions

View file

@ -65,6 +65,10 @@ using namespace libtorrent;
TransferListWidget::TransferListWidget(QWidget *parent, MainWindow *main_window, QBtSession *_BTSession):
QTreeView(parent), BTSession(_BTSession), main_window(main_window) {
// Load settings
loadSettings();
// Create and apply delegate
listDelegate = new TransferListDelegate(this);
setItemDelegate(listDelegate);
@ -120,9 +124,6 @@ TransferListWidget::TransferListWidget(QWidget *parent, MainWindow *main_window,
connect(this, SIGNAL(customContextMenuRequested(const QPoint&)), this, SLOT(displayListMenu(const QPoint&)));
header()->setContextMenuPolicy(Qt::CustomContextMenu);
connect(header(), SIGNAL(customContextMenuRequested(const QPoint&)), this, SLOT(displayDLHoSMenu(const QPoint&)));
// Load settings
loadSettings();
}
TransferListWidget::~TransferListWidget() {