svg_loader: initialize member data in default.

static analizyer bothers us due to this.
we'd rather initialize members for free of them.

Change-Id: I6dd76427b0fe2f9ff09034fe3ab11080a8d72a2e
This commit is contained in:
Hermet Park 2020-08-13 19:08:34 +09:00
parent 0b95e55e2f
commit 9ce44de970
2 changed files with 2 additions and 7 deletions

View file

@ -373,7 +373,6 @@ unique_ptr<Scene> SvgSceneBuilder::build(SvgNode* node)
viewBox.w = node->node.doc.vw;
viewBox.h = node->node.doc.vh;
preserveAspect = node->node.doc.preserveAspect;
staticViewBox = true;
return _sceneBuildHelper(node, viewBox.x, viewBox.y, viewBox.w, viewBox.h, 255);
}

View file

@ -32,12 +32,8 @@ private:
struct {
int x, y;
uint32_t w, h;
} viewBox;
int ref;
uint32_t w, h; //Default size
bool staticViewBox;
bool preserveAspect; //Used in SVG
bool shareable;
} viewBox = {0, 0, 0, 0};
bool preserveAspect = false;
public:
SvgSceneBuilder();