Added TO column to message inbox
This commit is contained in:
parent
f0ceb0f7f4
commit
8186348abe
@ -100,6 +100,12 @@ void MessageWindow::populateMessages(QList<QPair<int, Message> > msgs){
|
|||||||
fromItem->setTextAlignment(Qt::AlignHCenter|Qt::AlignVCenter);
|
fromItem->setTextAlignment(Qt::AlignHCenter|Qt::AlignVCenter);
|
||||||
ui->messageTableWidget->setItem(row, col++, fromItem);
|
ui->messageTableWidget->setItem(row, col++, fromItem);
|
||||||
|
|
||||||
|
auto to = params.value("TO").toString();
|
||||||
|
auto toItem = new QTableWidgetItem(to);
|
||||||
|
toItem->setData(Qt::UserRole, to);
|
||||||
|
toItem->setTextAlignment(Qt::AlignHCenter|Qt::AlignVCenter);
|
||||||
|
ui->messageTableWidget->setItem(row, col++, toItem);
|
||||||
|
|
||||||
auto text = params.value("TEXT").toString();
|
auto text = params.value("TEXT").toString();
|
||||||
auto textItem = new QTableWidgetItem(text);
|
auto textItem = new QTableWidgetItem(text);
|
||||||
textItem->setData(Qt::UserRole, text);
|
textItem->setData(Qt::UserRole, text);
|
||||||
@ -112,6 +118,7 @@ void MessageWindow::populateMessages(QList<QPair<int, Message> > msgs){
|
|||||||
ui->messageTableWidget->resizeColumnToContents(2);
|
ui->messageTableWidget->resizeColumnToContents(2);
|
||||||
ui->messageTableWidget->resizeColumnToContents(3);
|
ui->messageTableWidget->resizeColumnToContents(3);
|
||||||
ui->messageTableWidget->resizeColumnToContents(4);
|
ui->messageTableWidget->resizeColumnToContents(4);
|
||||||
|
ui->messageTableWidget->resizeColumnToContents(5);
|
||||||
}
|
}
|
||||||
ui->messageTableWidget->setUpdatesEnabled(true);
|
ui->messageTableWidget->setUpdatesEnabled(true);
|
||||||
|
|
||||||
|
@ -137,6 +137,11 @@
|
|||||||
<string>From</string>
|
<string>From</string>
|
||||||
</property>
|
</property>
|
||||||
</column>
|
</column>
|
||||||
|
<column>
|
||||||
|
<property name="text">
|
||||||
|
<string>To</string>
|
||||||
|
</property>
|
||||||
|
</column>
|
||||||
<column>
|
<column>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>Message</string>
|
<string>Message</string>
|
||||||
|
Loading…
Reference in New Issue
Block a user