forked from osmocom/wireshark
From Thomas ERSFELD (GSoC13) Qtshark : Columns in the packet list table are not updated when you add one on preference menu
svn path=/trunk/; revision=50818
This commit is contained in:
parent
681c9e7160
commit
6cff72548d
|
@ -970,6 +970,7 @@ void MainWindow::recreatePacketList()
|
|||
col_cleanup(&cfile.cinfo);
|
||||
build_column_format_array(&cfile.cinfo, prefs.num_cols, FALSE);
|
||||
|
||||
packet_list_->updateAll();
|
||||
packet_list_->hide();
|
||||
packet_list_->show();
|
||||
|
||||
|
|
|
@ -511,6 +511,8 @@ void PacketList::updateAll() {
|
|||
if (cap_file_->edt && cap_file_->edt->tree) {
|
||||
proto_tree_->fillProtocolTree(cap_file_->edt->tree);
|
||||
}
|
||||
|
||||
packet_list_model_->resetColumns();
|
||||
}
|
||||
|
||||
void PacketList::clear() {
|
||||
|
|
|
@ -101,6 +101,12 @@ void PacketListModel::clear() {
|
|||
endResetModel();
|
||||
}
|
||||
|
||||
void PacketListModel::resetColumns()
|
||||
{
|
||||
beginResetModel();
|
||||
endResetModel();
|
||||
}
|
||||
|
||||
int PacketListModel::rowCount(const QModelIndex &parent) const
|
||||
{
|
||||
if (!cap_file_) return 0;
|
||||
|
|
|
@ -62,6 +62,7 @@ public:
|
|||
gint appendPacket(frame_data *fdata);
|
||||
frame_data *getRowFdata(int row);
|
||||
int visibleIndexOf(frame_data *fdata) const;
|
||||
void resetColumns();
|
||||
|
||||
signals:
|
||||
|
||||
|
|
Loading…
Reference in New Issue