- Added columns width saving to torrent addition dialog

- Fixed column width saving in torrent properties
- Code Cleanup
This commit is contained in:
Christophe Dumez 2009-11-11 14:19:44 +00:00
parent 5d09f89a0f
commit 743d54a745
3 changed files with 27 additions and 6 deletions

View file

@ -65,7 +65,6 @@ PropertiesWidget::PropertiesWidget(QWidget *parent, TransferListWidget *transfer
// Set Properties list model
PropListModel = new TorrentFilesModel();
filesList->setModel(PropListModel);
filesList->hideColumn(INDEX);
PropDelegate = new PropListDelegate(0);
filesList->setItemDelegate(PropDelegate);
@ -217,7 +216,7 @@ void PropertiesWidget::saveSettings() {
QSettings settings(QString::fromUtf8("qBittorrent"), QString::fromUtf8("qBittorrent"));
settings.setValue("TorrentProperties/Visible", state==VISIBLE);
QVariantList contentColsWidths;
for(int i=0; i<PropListModel->columnCount()-1; ++i) {
for(int i=0; i<PropListModel->columnCount(); ++i) {
contentColsWidths.append(filesList->columnWidth(i));
}
settings.setValue(QString::fromUtf8("TorrentProperties/filesColsWidth"), contentColsWidths);