mirror of
https://github.com/subsurface/subsurface.git
synced 2024-12-03 15:43:09 +00:00
mobile/divelist: connect click on trip to toggle MobileListModel
Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
parent
edeaf7fa57
commit
730fd26814
3 changed files with 3 additions and 2 deletions
|
@ -50,7 +50,7 @@ Kirigami.ScrollablePage {
|
||||||
if (isTrip) {
|
if (isTrip) {
|
||||||
manager.appendTextToLog("clicked on trip " + tripTitle)
|
manager.appendTextToLog("clicked on trip " + tripTitle)
|
||||||
// toggle expand (backend to deal with unexpand other trip)
|
// toggle expand (backend to deal with unexpand other trip)
|
||||||
manager.toggle(model.row);
|
diveModel.toggle(model.row);
|
||||||
} else {
|
} else {
|
||||||
manager.appendTextToLog("clicked on dive")
|
manager.appendTextToLog("clicked on dive")
|
||||||
if (detailsWindow.state === "view") {
|
if (detailsWindow.state === "view") {
|
||||||
|
|
|
@ -24,6 +24,7 @@
|
||||||
#include "qt-models/completionmodels.h"
|
#include "qt-models/completionmodels.h"
|
||||||
#include "qt-models/messagehandlermodel.h"
|
#include "qt-models/messagehandlermodel.h"
|
||||||
#include "qt-models/tankinfomodel.h"
|
#include "qt-models/tankinfomodel.h"
|
||||||
|
#include "qt-models/mobilelistmodel.h"
|
||||||
#include "core/device.h"
|
#include "core/device.h"
|
||||||
#include "core/errorhelper.h"
|
#include "core/errorhelper.h"
|
||||||
#include "core/file.h"
|
#include "core/file.h"
|
||||||
|
|
|
@ -49,7 +49,7 @@ public:
|
||||||
void resetModel();
|
void resetModel();
|
||||||
void expand(int row);
|
void expand(int row);
|
||||||
void unexpand();
|
void unexpand();
|
||||||
void toggle(int row);
|
Q_INVOKABLE void toggle(int row);
|
||||||
Q_PROPERTY(int shown READ shown NOTIFY shownChanged);
|
Q_PROPERTY(int shown READ shown NOTIFY shownChanged);
|
||||||
signals:
|
signals:
|
||||||
void shownChanged();
|
void shownChanged();
|
||||||
|
|
Loading…
Reference in a new issue