diff --git a/src/ContactsWidget.cpp b/src/ContactsWidget.cpp index b535e3c..c43a4b6 100644 --- a/src/ContactsWidget.cpp +++ b/src/ContactsWidget.cpp @@ -24,8 +24,8 @@ ContactsWidget::ContactsWidget(QSharedPointer ctx, QWidget *parent) ui->contacts->setModel(m_proxyModel); ui->contacts->setSortingEnabled(true); - ui->contacts->header()->setSectionResizeMode(AddressBookModel::Address, QHeaderView::Stretch); - ui->contacts->header()->setSectionResizeMode(AddressBookModel::Description, QHeaderView::ResizeToContents); + ui->contacts->header()->setSectionResizeMode(AddressBookModel::Address, QHeaderView::ResizeToContents); + ui->contacts->header()->setSectionResizeMode(AddressBookModel::Description, QHeaderView::Stretch); ui->contacts->header()->setMinimumSectionSize(200); // header context menu diff --git a/src/model/AddressBookModel.h b/src/model/AddressBookModel.h index 7157c6d..0257bcb 100644 --- a/src/model/AddressBookModel.h +++ b/src/model/AddressBookModel.h @@ -16,8 +16,8 @@ class AddressBookModel : public QAbstractTableModel public: enum ModelColumn { - Address = 0, - Description, + Description = 0, + Address, COUNT };