You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@flex.apache.org by ah...@apache.org on 2015/08/17 07:30:12 UTC
[09/12] git commit: [flex-asjs] [refs/heads/develop] - off by one
off by one
Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/b60d1d85
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/b60d1d85
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/b60d1d85
Branch: refs/heads/develop
Commit: b60d1d8582492c908e849055ad0e9227a3360e56
Parents: 95cb5df
Author: Alex Harui <ah...@apache.org>
Authored: Thu Aug 13 23:53:04 2015 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Thu Aug 13 23:53:04 2015 -0700
----------------------------------------------------------------------
.../html/beads/layouts/OneFlexibleChildHorizontalLayout.as | 3 +--
.../flex/html/beads/layouts/OneFlexibleChildVerticalLayout.as | 6 +++---
2 files changed, 4 insertions(+), 5 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/b60d1d85/frameworks/projects/HTML/asjs/src/org/apache/flex/html/beads/layouts/OneFlexibleChildHorizontalLayout.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/HTML/asjs/src/org/apache/flex/html/beads/layouts/OneFlexibleChildHorizontalLayout.as b/frameworks/projects/HTML/asjs/src/org/apache/flex/html/beads/layouts/OneFlexibleChildHorizontalLayout.as
index bacf28a..d992d6b 100644
--- a/frameworks/projects/HTML/asjs/src/org/apache/flex/html/beads/layouts/OneFlexibleChildHorizontalLayout.as
+++ b/frameworks/projects/HTML/asjs/src/org/apache/flex/html/beads/layouts/OneFlexibleChildHorizontalLayout.as
@@ -244,7 +244,6 @@ package org.apache.flex.html.beads.layouts
mb = CSSUtils.getTopValue(marginBottom, margin, hh);
mr = CSSUtils.getRightValue(marginRight, margin, ww);
ml = CSSUtils.getLeftValue(marginLeft, margin, ww);
- child.y = mt;
if (child is ILayoutChild)
{
ilc = child as ILayoutChild;
@@ -302,7 +301,7 @@ package org.apache.flex.html.beads.layouts
}
else
{
- child.y = h - bottom - mb - child.height;
+ child.y = h - bottom - mb - child.height - 1; // some browsers don't like going to the edge
ySet = true;
}
}
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/b60d1d85/frameworks/projects/HTML/asjs/src/org/apache/flex/html/beads/layouts/OneFlexibleChildVerticalLayout.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/HTML/asjs/src/org/apache/flex/html/beads/layouts/OneFlexibleChildVerticalLayout.as b/frameworks/projects/HTML/asjs/src/org/apache/flex/html/beads/layouts/OneFlexibleChildVerticalLayout.as
index f8805f5..73f0f3a 100644
--- a/frameworks/projects/HTML/asjs/src/org/apache/flex/html/beads/layouts/OneFlexibleChildVerticalLayout.as
+++ b/frameworks/projects/HTML/asjs/src/org/apache/flex/html/beads/layouts/OneFlexibleChildVerticalLayout.as
@@ -239,7 +239,6 @@ package org.apache.flex.html.beads.layouts
if (isNaN(mr))
mr = 0;
}
- child.x = ml;
if (child is ILayoutChild)
{
ilc = child as ILayoutChild;
@@ -419,7 +418,8 @@ package org.apache.flex.html.beads.layouts
}
else
{
- child.x = ml;
+ if (isNaN(right))
+ child.x = ml;
ww -= ml;
}
if (!isNaN(right))
@@ -435,7 +435,7 @@ package org.apache.flex.html.beads.layouts
}
}
else
- child.x = w - right - mr - child.width;
+ child.x = w - right - mr - child.width - 1; // some browsers don't like going all the way to the edge
}
if (ilc)
{