From c222791f5569d2aabcdd6245ce2dc4792e2b725a Mon Sep 17 00:00:00 2001 From: adun Date: Sat, 2 Feb 2019 14:44:22 +0800 Subject: [PATCH] Fix the build error and runtime coredump in Windows backend Change-Id: I3957ac493d1ae7aed1fd765280fc22c414bb268d --- dali-toolkit/internal/layouting/flex-layout-impl.cpp | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) mode change 100644 => 100755 dali-toolkit/internal/layouting/flex-layout-impl.cpp diff --git a/dali-toolkit/internal/layouting/flex-layout-impl.cpp b/dali-toolkit/internal/layouting/flex-layout-impl.cpp old mode 100644 new mode 100755 index 65b46c1..0090ec8 --- a/dali-toolkit/internal/layouting/flex-layout-impl.cpp +++ b/dali-toolkit/internal/layouting/flex-layout-impl.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2018 Samsung Electronics Co., Ltd. + * Copyright (c) 2019 Samsung Electronics Co., Ltd. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -335,10 +335,11 @@ YGSize FlexLayout::OnChildMeasure( YGNodeRef node, LayoutLength measuredWidth = childLayout->GetMeasuredWidth() - padding.end - padding.start; LayoutLength measuredHeight = childLayout->GetMeasuredHeight() - padding.bottom - padding.top; - return YGSize{ - .width = measuredWidth.AsDecimal(), - .height = measuredHeight.AsDecimal(), - }; + // Create struct instance first and manually set params to support all compiler versions + YGSize ygSize; + ygSize.width = measuredWidth.AsDecimal(); + ygSize.height = measuredHeight.AsDecimal(); + return ygSize; } void FlexLayout::SetChildrenStyle() -- 2.7.4