aboutsummaryrefslogtreecommitdiffstats
path: root/ui/qt/main_window_slots.cpp
diff options
context:
space:
mode:
authorRoland Knall <rknall@gmail.com>2016-10-01 08:54:57 +0200
committerRoland Knall <rknall@gmail.com>2016-10-01 13:18:51 +0000
commit99097dd3c65358a525e40767cc1501c4116c3a4d (patch)
tree1ad9637554aebded5ff4bf8a400a6c3fc2ed4b4e /ui/qt/main_window_slots.cpp
parentb6ad91520fd602710f5afe4a4eb8787a6bca22d4 (diff)
Interface List: Change display to view/model
This changes the underlying model of the main interface tree. Because of that, we can resort to a view/model approach, enlisting the global interfaces list as only data source. The interface list works identical to the old list, but allows for filtering of the displayed interfaces by type. Only types, which are present and whose interfaces are not hidden, are being displayed for selection. Change-Id: If8475b227daa026dc0ad3d25bc7fe050d5bf2ac3 Reviewed-on: https://code.wireshark.org/review/17940 Reviewed-by: Roland Knall <rknall@gmail.com>
Diffstat (limited to 'ui/qt/main_window_slots.cpp')
-rw-r--r--ui/qt/main_window_slots.cpp15
1 files changed, 5 insertions, 10 deletions
diff --git a/ui/qt/main_window_slots.cpp b/ui/qt/main_window_slots.cpp
index f10e997bc4..8b0b31df95 100644
--- a/ui/qt/main_window_slots.cpp
+++ b/ui/qt/main_window_slots.cpp
@@ -3642,18 +3642,13 @@ void MainWindow::on_actionCaptureOptions_triggered()
connect(capture_interfaces_dialog_, SIGNAL(stopCapture()), this, SLOT(stopCapture()));
connect(capture_interfaces_dialog_, SIGNAL(getPoints(int,PointList*)),
- this->main_welcome_->getInterfaceTree(), SLOT(getPoints(int,PointList*)));
- // Changes in interface selections or capture filters should be propagated
- // to the main welcome screen where they will be applied to the global
- // capture options.
- connect(capture_interfaces_dialog_, SIGNAL(interfaceListChanged()),
- this->main_welcome_->getInterfaceTree(), SLOT(interfaceListChanged()));
+ this->main_welcome_->getInterfaceFrame(), SLOT(getPoints(int,PointList*)));
connect(capture_interfaces_dialog_, SIGNAL(interfacesChanged()),
this->main_welcome_, SLOT(interfaceSelected()));
connect(capture_interfaces_dialog_, SIGNAL(interfacesChanged()),
- this->main_welcome_->getInterfaceTree(), SLOT(updateSelectedInterfaces()));
- connect(capture_interfaces_dialog_, SIGNAL(interfacesChanged()),
- this->main_welcome_->getInterfaceTree(), SLOT(updateToolTips()));
+ this->main_welcome_->getInterfaceFrame(), SLOT(updateSelectedInterfaces()));
+ connect(capture_interfaces_dialog_, SIGNAL(interfaceListChanged()),
+ this->main_welcome_->getInterfaceFrame(), SLOT(interfaceListChanged()));
connect(capture_interfaces_dialog_, SIGNAL(captureFilterTextEdited(QString)),
this->main_welcome_, SLOT(setCaptureFilterText(QString)));
@@ -3716,7 +3711,7 @@ void MainWindow::extcap_options_finished(int result)
if (result == QDialog::Accepted) {
startCapture();
}
- this->main_welcome_->getInterfaceTree()->interfaceListChanged();
+ this->main_welcome_->getInterfaceFrame()->interfaceListChanged();
}
void MainWindow::showExtcapOptionsDialog(QString &device_name)