Skip to content
This repository has been archived by the owner on Jun 3, 2021. It is now read-only.

Commit

Permalink
* [Android] Fix text height problem. (#1408)
Browse files Browse the repository at this point in the history
  • Loading branch information
YorkShen committed Aug 9, 2018
1 parent 776bc45 commit 42046b0
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions weex_core/Source/core/layout/layout.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -338,9 +338,11 @@ namespace WeexCore {
child->hypotheticalMeasure(childWidth, childHeight, stretch);
} else {
if(isSingleFlexLine(isMainAxisHorizontal(this) ? parentWidth : parentHeight)
&& !isMainAxisHorizontal(this) && child->widthMeasureMode == kUnspecified){
child->setLayoutWidth(parentWidth - sumPaddingBorderAlongAxis(this, true)
-child->mCssStyle->sumMarginOfDirection(true));
&& !isMainAxisHorizontal(this)){
if(child->widthMeasureMode == kUnspecified) {
child->setLayoutWidth(parentWidth - sumPaddingBorderAlongAxis(this, true)
- child->mCssStyle->sumMarginOfDirection(true));
}
if(child->heightMeasureMode == kUnspecified && child->widthDirty) {
child->mLayoutResult->mLayoutSize.height = NAN;
}
Expand Down

0 comments on commit 42046b0

Please sign in to comment.