TextInput without a width isn't stretchy. It seems to have a default width
Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/8377006c Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/8377006c Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/8377006c Branch: refs/heads/develop Commit: 8377006c39efc7e453693997a78d398f5ebaab5f Parents: 9ab3b56 Author: Alex Harui <[email protected]> Authored: Thu Apr 27 23:58:03 2017 -0700 Committer: Alex Harui <[email protected]> Committed: Thu Apr 27 23:58:03 2017 -0700 ---------------------------------------------------------------------- .../src/main/flex/org/apache/flex/html/beads/TextInputView.as | 2 ++ 1 file changed, 2 insertions(+) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/8377006c/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TextInputView.as ---------------------------------------------------------------------- diff --git a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TextInputView.as b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TextInputView.as index a6f1438..be59056 100644 --- a/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TextInputView.as +++ b/frameworks/projects/Basic/src/main/flex/org/apache/flex/html/beads/TextInputView.as @@ -84,6 +84,8 @@ package org.apache.flex.html.beads h = textField.textHeight; textField.text = s; ilc.setWidth(w + uiMetrics.left + uiMetrics.right, true); + // TextInput doesn't stretch if no width like divs do + ilc.explicitWidth = ilc.width; } if (ilc.isHeightSizedToContent()) {
