Enroute Flight Navigation
A navigation app for VFR pilots
PlatformAdaptor_Android.h
1/***************************************************************************
2 * Copyright (C) 2019-2024 by Stefan Kebekus *
3 * stefan.kebekus@gmail.com *
4 * *
5 * This program is free software; you can redistribute it and/or modify *
6 * it under the terms of the GNU General Public License as published by *
7 * the Free Software Foundation; either version 3 of the License, or *
8 * (at your option) any later version. *
9 * *
10 * This program is distributed in the hope that it will be useful, *
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of *
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
13 * GNU General Public License for more details. *
14 * *
15 * You should have received a copy of the GNU General Public License *
16 * along with this program; if not, write to the *
17 * Free Software Foundation, Inc., *
18 * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
19 ***************************************************************************/
20
21#pragma once
22
23#include <QObject>
24#include <QTimer>
25#include <QtGlobal>
26
27#include "platform/PlatformAdaptor_Abstract.h"
28
29namespace Platform {
30
32
33
35{
36 Q_OBJECT
37 QML_ELEMENT
38 QML_SINGLETON
39
40public:
45 explicit PlatformAdaptor(QObject *parent = nullptr);
46
47 ~PlatformAdaptor() override = default;
48
49
50 //
51 // Methods
52 //
53
58 QString currentSSID() override;
59
61 void disableScreenSaver() override;
62
67 void lockWifi(bool lock) override;
68
73 void openSatView(const QGeoCoordinate& coordinate) override;
74
79 QString systemInfo() override;
80
82 void vibrateBrief() override;
83
85 void vibrateLong() override;
86
88 void onGUISetupCompleted() override;
89
90
91protected:
93 void deferredInitialization() override;
94
95private:
96 Q_DISABLE_COPY_MOVE(PlatformAdaptor)
97
98 bool splashScreenHidden {false};
99};
100
101} // namespace Platform
Interface to platform-specific functionality.
void onGUISetupCompleted() override
Implements a pure virtual method from PlatformAdaptor_Abstract.
void deferredInitialization() override
Re-implements a virtual method from PlatformAdaptor_Abstract.
void vibrateLong() override
Implements a pure virtual method from PlatformAdaptor_Abstract.
PlatformAdaptor(QObject *parent=nullptr)
Standard constructor.
QString systemInfo() override
Information about the system, in HTML format.
void openSatView(const QGeoCoordinate &coordinate) override
Re-implements a virtual method from PlatformAdaptor_Abstract.
void disableScreenSaver() override
Implements a pure virtual method from PlatformAdaptor_Abstract.
void lockWifi(bool lock) override
Implements s pure virtual method from PlatformAdaptor_Abstract.
QString currentSSID() override
Implements a pure virtual method from PlatformAdaptor_Abstract.
void vibrateBrief() override
Implements a pure virtual method from PlatformAdaptor_Abstract.