Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 405fddd2 authored by Peng Xu's avatar Peng Xu
Browse files

Clarify sensor NDK struct has to be backward compatible

Bug: 35842870
Test: compiles
Change-Id: I7ee89f88d09b2204b61cfd090a29c80a064191e9
Merged-In: I7ee89f88d09b2204b61cfd090a29c80a064191e9
parent 480e3ff5
Loading
Loading
Loading
Loading
+2 −2
Original line number Original line Diff line number Diff line
@@ -197,7 +197,7 @@ enum {
 * A sensor event.
 * A sensor event.
 */
 */


/* NOTE: Must match hardware/sensors.h */
/* NOTE: changes to these structs have to be backward compatible */
typedef struct ASensorVector {
typedef struct ASensorVector {
    union {
    union {
        float v[3];
        float v[3];
@@ -259,7 +259,7 @@ typedef struct {
    };
    };
} AAdditionalInfoEvent;
} AAdditionalInfoEvent;


/* NOTE: Must match hardware/sensors.h */
/* NOTE: changes to this struct has to be backward compatible */
typedef struct ASensorEvent {
typedef struct ASensorEvent {
    int32_t version; /* sizeof(struct ASensorEvent) */
    int32_t version; /* sizeof(struct ASensorEvent) */
    int32_t sensor;
    int32_t sensor;