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 2017/06/08 07:05:13 UTC
[1/6] git commit: [flex-asjs] [refs/heads/release0.8.0] - don't need
this. The y of the children are factored into the size
Repository: flex-asjs
Updated Branches:
refs/heads/release0.8.0 8dc27279a -> 908477e67
don't need this. The y of the children are factored into the size
Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/c55a2380
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/c55a2380
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/c55a2380
Branch: refs/heads/release0.8.0
Commit: c55a2380841f856a4063e7ed2e479d215252e246
Parents: e30a129
Author: Alex Harui <ah...@apache.org>
Authored: Wed Jun 7 23:21:46 2017 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Wed Jun 7 23:23:05 2017 -0700
----------------------------------------------------------------------
.../src/main/flex/org/apache/flex/html/beads/PanelView.as | 7 -------
1 file changed, 7 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/c55a2380/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/PanelView.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/PanelView.as b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/PanelView.as
index d3ff5cb..c2bb227 100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/PanelView.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/PanelView.as
@@ -265,12 +265,5 @@ package org.apache.flex.html.beads
performLayout(event);
}
- COMPILE::SWF
- override protected function calculateContentSize():Size
- {
- var size:Size = super.calculateContentSize();
- size.height += titleBar.height;
- return size;
- }
}
}
[2/6] git commit: [flex-asjs] [refs/heads/release0.8.0] - fix border
CSS
Posted by ah...@apache.org.
fix border CSS
Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/e30a1296
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/e30a1296
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/e30a1296
Branch: refs/heads/release0.8.0
Commit: e30a129621da6b4e089c91693ff9b728ec2438a3
Parents: 5ebb2ae
Author: Alex Harui <ah...@apache.org>
Authored: Wed Jun 7 22:47:56 2017 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Wed Jun 7 23:23:05 2017 -0700
----------------------------------------------------------------------
frameworks/projects/Basic/src/main/resources/defaults.css | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/e30a1296/frameworks/projects/Basic/src/main/resources/defaults.css
----------------------------------------------------------------------
diff --git a/frameworks/projects/Basic/src/main/resources/defaults.css b/frameworks/projects/Basic/src/main/resources/defaults.css
index 026c933..e236e38 100644
--- a/frameworks/projects/Basic/src/main/resources/defaults.css
+++ b/frameworks/projects/Basic/src/main/resources/defaults.css
@@ -425,7 +425,7 @@ Panel
IPanelLayout: ClassReference("org.apache.flex.html.beads.layouts.VerticalFlexLayout");
background-color: #FFFFFF;
- border: solid 1px #333333
+ border: 1px solid #333333
}
PanelWithControlBar
@@ -435,12 +435,12 @@ PanelWithControlBar
IPanelLayout: ClassReference("org.apache.flex.html.beads.layouts.VerticalFlexLayout");
background-color: #FFFFFF;
- border: solid 1px #333333;
+ border: 1px solid #333333;
}
Panel .TitleBar
{
- border-bottom: solid 1px #333333;
+ border-bottom: 1px solid #333333;
}
.PanelContent
@@ -662,7 +662,7 @@ global
IMeasurementBead: ClassReference("org.apache.flex.html.beads.ControlBarMeasurementBead");
IBackgroundBead: ClassReference("org.apache.flex.html.beads.SolidBackgroundBead");
IBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead");
- border: solid 1px #333333;
+ border: 1px solid #333333;
}
ComboBoxList {
@@ -903,7 +903,7 @@ global
{
IBorderBead: ClassReference("org.apache.flex.html.beads.SingleLineBorderBead");
IBackgroundBead: ClassReference("org.apache.flex.html.beads.SolidBackgroundBead");
- border: solid 1px #333333;
+ border: 1px solid #333333;
}
ToggleTextButton
[4/6] git commit: [flex-asjs] [refs/heads/release0.8.0] - parent the
titlebar and content area sooner so their children can calculate size
correctly
Posted by ah...@apache.org.
parent the titlebar and content area sooner so their children can calculate size correctly
Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/93e26655
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/93e26655
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/93e26655
Branch: refs/heads/release0.8.0
Commit: 93e266557f8992b504c76a7058d9da650b4da06a
Parents: 531c9e1
Author: Alex Harui <ah...@apache.org>
Authored: Wed Jun 7 22:46:31 2017 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Wed Jun 7 23:23:05 2017 -0700
----------------------------------------------------------------------
.../org/apache/flex/html/beads/PanelView.as | 22 +++++++++++++-------
1 file changed, 15 insertions(+), 7 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/93e26655/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/PanelView.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/PanelView.as b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/PanelView.as
index da34924..d3ff5cb 100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/PanelView.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/PanelView.as
@@ -158,6 +158,9 @@ package org.apache.flex.html.beads
// any changes to values in the Panel's model that correspond values in the TitleBar will
// be picked up automatically by the TitleBar.
titleBar.model = host.model;
+ if (titleBar.parent == null) {
+ (_strand as Panel).$addElement(titleBar);
+ }
if (!_contentArea) {
_contentArea = new Container();
@@ -209,6 +212,10 @@ package org.apache.flex.html.beads
_contentArea.addBead(viewportBead);
}
+ if (contentArea.parent == null) {
+ (_strand as Panel).$addElement(contentArea as IChild);
+ }
+
// Now give the Panel its own layout
layoutBead = new VerticalFlexLayout();
value.addBead(layoutBead);
@@ -237,13 +244,6 @@ package org.apache.flex.html.beads
override protected function completeSetup():void
{
- if (titleBar.parent == null) {
- (_strand as Panel).$addElement(titleBar);
- }
- if (contentArea.parent == null) {
- (_strand as Panel).$addElement(contentArea as IChild);
- }
-
super.completeSetup();
performLayout(null);
@@ -264,5 +264,13 @@ package org.apache.flex.html.beads
_contentArea.dispatchEvent(new Event("layoutNeeded"));
performLayout(event);
}
+
+ COMPILE::SWF
+ override protected function calculateContentSize():Size
+ {
+ var size:Size = super.calculateContentSize();
+ size.height += titleBar.height;
+ return size;
+ }
}
}
[3/6] git commit: [flex-asjs] [refs/heads/release0.8.0] - when sized
to content, have to take content size and add in padding and borders again
Posted by ah...@apache.org.
when sized to content, have to take content size and add in padding and borders again
Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/531c9e14
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/531c9e14
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/531c9e14
Branch: refs/heads/release0.8.0
Commit: 531c9e1417e547e90dfb6ffa1f605d9e55da6631
Parents: 8dc2727
Author: Alex Harui <ah...@apache.org>
Authored: Wed Jun 7 22:45:54 2017 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Wed Jun 7 23:23:05 2017 -0700
----------------------------------------------------------------------
.../src/main/flex/org/apache/flex/html/beads/GroupView.as | 9 +++++++++
1 file changed, 9 insertions(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/531c9e14/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/GroupView.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/GroupView.as b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/GroupView.as
index 2a982c2..2921b65 100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/GroupView.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/GroupView.as
@@ -268,6 +268,15 @@ package org.apache.flex.html.beads
{
var host:UIBase = _strand as UIBase;
var contentSize:Size = calculateContentSize();
+ var border:org.apache.flex.geom.Rectangle = CSSContainerUtils.getBorderMetrics(this._strand);
+ contentSize.width += border.left + border.right;
+ contentSize.height += border.top + border.bottom;
+ var padding:org.apache.flex.geom.Rectangle = CSSContainerUtils.getPaddingMetrics(this._strand);
+ // add padding.left since it wasn't considered in contentSize,
+ // and add border.right so the border can be drawn in that column of pixels
+ contentSize.width += padding.left + border.right;
+ contentSize.height += padding.top + border.top;
+
if (host.isWidthSizedToContent() && host.isHeightSizedToContent()) {
host.setWidthAndHeight(contentSize.width, contentSize.height, true);
[5/6] git commit: [flex-asjs] [refs/heads/release0.8.0] - handle
sizedToContent by growing to content instead of shrinking things
Posted by ah...@apache.org.
handle sizedToContent by growing to content instead of shrinking things
Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/5ebb2aeb
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/5ebb2aeb
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/5ebb2aeb
Branch: refs/heads/release0.8.0
Commit: 5ebb2aebcfd09d5b91cccc6c088dc4b79b9fb2c1
Parents: 93e2665
Author: Alex Harui <ah...@apache.org>
Authored: Wed Jun 7 22:47:27 2017 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Wed Jun 7 23:23:05 2017 -0700
----------------------------------------------------------------------
.../flex/html/beads/layouts/VerticalFlexLayout.as | 14 +++++++++++---
1 file changed, 11 insertions(+), 3 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/5ebb2aeb/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalFlexLayout.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalFlexLayout.as b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalFlexLayout.as
index 0b845b5..4d86f14 100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalFlexLayout.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/layouts/VerticalFlexLayout.as
@@ -128,8 +128,16 @@ package org.apache.flex.html.beads.layouts
// adjust the host's usable size by the metrics. If hostSizedToContent, then the
// resulting adjusted value may be less than zero.
- hostWidth -= paddingMetrics.left + paddingMetrics.right + borderMetrics.left + borderMetrics.right;
- hostHeight -= paddingMetrics.top + paddingMetrics.bottom + borderMetrics.top + borderMetrics.bottom;
+ var extra:Number = paddingMetrics.left + paddingMetrics.right + borderMetrics.left + borderMetrics.right;
+ if (hostWidthSizedToContent)
+ hostWidth += extra;
+ else
+ hostWidth -= extra;
+ extra = paddingMetrics.top + paddingMetrics.bottom + borderMetrics.top + borderMetrics.bottom;
+ if (hostHeightSizedToContent)
+ hostHeight += extra;
+ else
+ hostHeight -= extra;
var remainingHeight:Number = hostHeight;
@@ -194,7 +202,7 @@ package org.apache.flex.html.beads.layouts
useWidth = (data.width < 0 ? hostWidth : data.width);
var setHeight:Boolean = true;
- if (data.height != 0) {
+ if (data.height != 0 && !hostHeightSizedToContent) {
if (data.grow > 0 && growCount > 0) {
useHeight = remainingHeight / growCount;
setHeight = false;
[6/6] git commit: [flex-asjs] [refs/heads/release0.8.0] - fix when we
force sizing
Posted by ah...@apache.org.
fix when we force sizing
Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/908477e6
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/908477e6
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/908477e6
Branch: refs/heads/release0.8.0
Commit: 908477e67ff9ed7ae5898123ef9ff43baf0a1e2f
Parents: c55a238
Author: Alex Harui <ah...@apache.org>
Authored: Wed Jun 7 23:22:26 2017 -0700
Committer: Alex Harui <ah...@apache.org>
Committed: Wed Jun 7 23:27:16 2017 -0700
----------------------------------------------------------------------
.../src/main/flex/org/apache/flex/html/beads/NumericStepperView.as | 2 --
1 file changed, 2 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/908477e6/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/NumericStepperView.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/NumericStepperView.as b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/NumericStepperView.as
index 4c7e6ba..9d08d56 100644
--- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/NumericStepperView.as
+++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/NumericStepperView.as
@@ -82,8 +82,6 @@ package org.apache.flex.html.beads
input = new TextInput();
input.className = "NumericStepperInput";
input.typeNames = "NumericStepperInput";
- input.width = 100;
- input.height = 22;
IParent(value).addElement(input);
COMPILE::JS
{