mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
QML UI: don't go through manager object to open user manual
We can open URLs in the browser directly from QML. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
7e47874adb
commit
f677d482e9
3 changed files with 1 additions and 9 deletions
|
@ -205,7 +205,7 @@ Kirigami.ApplicationWindow {
|
||||||
Kirigami.Action {
|
Kirigami.Action {
|
||||||
text: "User manual"
|
text: "User manual"
|
||||||
onTriggered: {
|
onTriggered: {
|
||||||
manager.showUserManual()
|
Qt.openUrlExternally("https://subsurface-divelog.org/documentation/subsurface-mobile-user-manual/")
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
Kirigami.Action {
|
Kirigami.Action {
|
||||||
|
|
|
@ -969,13 +969,6 @@ void QMLManager::showMap(const QString& location)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#define MOBILEUSERMANUAL QUrl(QLatin1Literal("https://subsurface-divelog.org/documentation/subsurface-mobile-user-manual/"))
|
|
||||||
|
|
||||||
void QMLManager::showUserManual()
|
|
||||||
{
|
|
||||||
QDesktopServices::openUrl(MOBILEUSERMANUAL);
|
|
||||||
}
|
|
||||||
|
|
||||||
// where in the QML dive list is that dive?
|
// where in the QML dive list is that dive?
|
||||||
int QMLManager::getIndex(const QString &diveId)
|
int QMLManager::getIndex(const QString &diveId)
|
||||||
{
|
{
|
||||||
|
|
|
@ -104,7 +104,6 @@ public slots:
|
||||||
void finishSetup();
|
void finishSetup();
|
||||||
void openLocalThenRemote(QString url);
|
void openLocalThenRemote(QString url);
|
||||||
void showMap(const QString& location);
|
void showMap(const QString& location);
|
||||||
void showUserManual();
|
|
||||||
int getIndex(const QString& diveId);
|
int getIndex(const QString& diveId);
|
||||||
QString getNumber(const QString& diveId);
|
QString getNumber(const QString& diveId);
|
||||||
QString getDate(const QString& diveId);
|
QString getDate(const QString& diveId);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue