summaryrefslogtreecommitdiffstats
path: root/desktop-widgets/tab-widgets/TabDiveEquipment.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'desktop-widgets/tab-widgets/TabDiveEquipment.cpp')
-rw-r--r--desktop-widgets/tab-widgets/TabDiveEquipment.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/desktop-widgets/tab-widgets/TabDiveEquipment.cpp b/desktop-widgets/tab-widgets/TabDiveEquipment.cpp
index 1ea57e703..cb7182e02 100644
--- a/desktop-widgets/tab-widgets/TabDiveEquipment.cpp
+++ b/desktop-widgets/tab-widgets/TabDiveEquipment.cpp
@@ -33,8 +33,10 @@ TabDiveEquipment::TabDiveEquipment(QWidget *parent) : TabBase(parent),
ui.weights->setModel(weightModel);
connect(&diveListNotifier, &DiveListNotifier::divesChanged, this, &TabDiveEquipment::divesChanged);
- connect(ui.cylinders->view(), &QTableView::clicked, this, &TabDiveEquipment::editCylinderWidget);
- connect(ui.weights->view(), &QTableView::clicked, this, &TabDiveEquipment::editWeightWidget);
+ connect(ui.cylinders, &TableView::itemClicked, cylindersModel, &CylindersModel::remove);
+ connect(ui.cylinders, &TableView::itemClicked, this, &TabDiveEquipment::editCylinderWidget);
+ connect(ui.weights, &TableView::itemClicked, weightModel, &WeightModel::remove);
+ connect(ui.weights, &TableView::itemClicked, this, &TabDiveEquipment::editWeightWidget);
// Current display of things on Gnome3 looks like shit, so
// let's fix that.