Cosmetics
[opentx.git] / companion / src / firmwares / curvereference.h
blobff5571bb5f5790582a4aef9339935121d5434f60
1 /*
2 * Copyright (C) OpenTX
4 * Based on code named
5 * th9x - http://code.google.com/p/th9x
6 * er9x - http://code.google.com/p/er9x
7 * gruvin9x - http://code.google.com/p/gruvin9x
9 * License GPLv2: http://www.gnu.org/licenses/gpl-2.0.html
11 * This program is free software; you can redistribute it and/or modify
12 * it under the terms of the GNU General Public License version 2 as
13 * published by the Free Software Foundation.
15 * This program is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 * GNU General Public License for more details.
21 #ifndef CURVEREFERENCE_H
22 #define CURVEREFERENCE_H
24 #include <QtCore>
26 class ModelData;
28 class CurveReference {
29 Q_DECLARE_TR_FUNCTIONS(CurveReference)
31 public:
32 enum CurveRefType {
33 CURVE_REF_DIFF,
34 CURVE_REF_EXPO,
35 CURVE_REF_FUNC,
36 CURVE_REF_CUSTOM
39 CurveReference() { clear(); }
41 CurveReference(CurveRefType type, int value):
42 type(type),
43 value(value)
47 void clear() { memset(this, 0, sizeof(CurveReference)); }
49 CurveRefType type;
50 int value;
52 QString toString(const ModelData * model = NULL, bool verbose = true) const;
55 #endif // CURVEREFERENCE_H