dlgTextEntry_Keyboard: rename to TouchTextEntry
[xcsoar.git] / src / NMEA / MoreData.hpp
blob839c3ffe2923b9777565ce740b69ae50b903664a
1 /*
2 Copyright_License {
4 XCSoar Glide Computer - http://www.xcsoar.org/
5 Copyright (C) 2000-2013 The XCSoar Project
6 A detailed list of copyright holders can be found in the file "AUTHORS".
8 This program is free software; you can redistribute it and/or
9 modify it under the terms of the GNU General Public License
10 as published by the Free Software Foundation; either version 2
11 of the License, or (at your option) any later version.
13 This program is distributed in the hope that it will be useful,
14 but WITHOUT ANY WARRANTY; without even the implied warranty of
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 GNU General Public License for more details.
18 You should have received a copy of the GNU General Public License
19 along with this program; if not, write to the Free Software
20 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
24 #ifndef XCSOAR_MORE_DATA_HPP
25 #define XCSOAR_MORE_DATA_HPP
27 #include "NMEA/Info.hpp"
29 #include <type_traits>
31 /**
32 * A wrapper for NMEA_INFO which adds a few attributes that are cheap
33 * to calculate. They are managed by #BasicComputer inside
34 * #MergeThread.
36 struct MoreData : public NMEAInfo {
37 /** Altitude used for navigation (GPS or Baro) */
38 fixed nav_altitude;
40 /** Energy height excess to slow to best glide speed */
41 fixed energy_height;
43 /** Nav Altitude + Energy height (m) */
44 fixed TE_altitude;
46 /** GPS-based vario */
47 fixed gps_vario;
48 /** GPS-based vario including energy height */
49 fixed gps_vario_TE;
51 Validity gps_vario_available;
53 /**
54 * Current vertical speed (total energy). This is set to
55 * TotalEnergyVario if available, and falls back to GPSVario. It is
56 * maintained by DeviceBlackboard::Vario().
58 fixed brutto_vario;
60 Validity brutto_vario_available;
62 void Reset();
64 bool NavAltitudeAvailable() const {
65 return baro_altitude_available || gps_altitude_available;
69 static_assert(std::is_trivial<MoreData>::value, "type is not trivial");
71 #endif