fix warning regarding nested anonymus union

This commit is contained in:
sub.mohanty@samsung.com 2019-07-04 21:49:58 +09:00 committed by Subhransu
parent 36eae75a5a
commit 4d61e8fd01
2 changed files with 16 additions and 12 deletions

View File

@ -47,13 +47,15 @@ public:
VGradient::Mode mMode; VGradient::Mode mMode;
VGradientStops mStops; VGradientStops mStops;
float mAlpha{1.0}; float mAlpha{1.0};
struct Linear{
float x1, y1, x2, y2;
};
struct Radial{
float cx, cy, fx, fy, cradius, fradius;
};
union { union {
struct { Linear linear;
float x1, y1, x2, y2; Radial radial;
} linear;
struct {
float cx, cy, fx, fy, cradius, fradius;
} radial;
}; };
VMatrix mMatrix; VMatrix mMatrix;
}; };

View File

@ -103,13 +103,15 @@ private:
struct VGradientData { struct VGradientData {
VGradient::Spread mSpread; VGradient::Spread mSpread;
struct Linear{
float x1, y1, x2, y2;
};
struct Radial{
float cx, cy, fx, fy, cradius, fradius;
};
union { union {
struct { Linear linear;
float x1, y1, x2, y2; Radial radial;
} linear;
struct {
float cx, cy, fx, fy, cradius, fradius;
} radial;
}; };
const uint32_t *mColorTable; const uint32_t *mColorTable;
bool mColorTableAlpha; bool mColorTableAlpha;