Skip to main content
Participant
July 2, 2008
Question

Extend the use case of includeInLayout

  • July 2, 2008
  • 3 replies
  • 552 views
Let's focus on the case of VBox. When component.includeInLayout=false, the component is placed at the position of the previously placed component in the VBox. Hence, even though component.includeInLayout==false, the position of the component is changed. However, I sometimes want to place e.g. a Button at an arbitrary position within a VBox. But this is not possible because the position gets overridden by the VBox.

So why is the position of the component.includeInLayout==false just not touched? For example, change line 272 of mx.containers.utilityClasses.BoxLayout in 3.0.2.2095 from
for (i = 0; i < n; i++)
{
obj = IUIComponent(target.getChildAt(i));
left = (w - obj.width) * horizontalAlign + paddingLeft;
obj.move(Math.floor(left), Math.floor(top));
if (obj.includeInLayout)
top += obj.height + gap;
}

to something like

for (i = 0; i < n; i++)
{
obj = IUIComponent(target.getChildAt(i));
if (obj.includeInLayout)
{
left = (w - obj.width) * horizontalAlign + paddingLeft;
obj.move(Math.floor(left), Math.floor(top));
top += obj.height + gap;
}
}

Marc
This topic has been closed for replies.

3 replies

_MarcS_Author
Participant
July 14, 2008
Ohm, I'd have a look at the svn code but it regularly fails since the beginning:
Error: REPORT request failed on '/svn/opensource/!svn/vcc/default'
Error: REPORT of '/svn/opensource/!svn/vcc/default': Could not read chunk delimiter: connection was closed by server (http://opensource.adobe.com)

I got 6500 files so far (including svn stuff) but there are still more to download... Currently, I get the error after downloading 8 to 22MB of data without any complete file transmitted.

I've never had an issue with checkouts from other repositories. The only difference I currently see is the huge size of some files in your rep. Do you know of any issues about that?
matt_chotin
Inspiring
July 7, 2008
Though Gordon pointed out to me that given this will be a behavior change we probably should do the work in the Flex 4 line and put compatibility logic around it (you can see compatibility checks elsewhere in the code).<br /><br />Matt<br /><br /><br />On 7/7/08 4:39 PM, "Matt Chotin" <member@adobeforums.com> wrote:<br /><br />A new message was posted by Matt Chotin in<br /><br />Developers --<br /> Extend the use case of includeInLayout<br /><br />Hi Marc,<br /><br />I think you're probably right. Can you file a bug and maybe submit a patch for this?<br /><br />Matt<br /><br /><br />On 7/2/08 1:12 AM, "MarcS" <member@adobeforums.com> wrote:<br /><br />A new discussion was started by MarcS in<br /><br />Developers --<br /> Extend the use case of includeInLayout<br /><br />Let's focus on the case of VBox. When component.includeInLayout=false, the component is placed at the position of the previously placed component in the VBox. Hence, even though component.includeInLayout==false, the position of the component is changed. However, I sometimes want to place e.g. a Button at an arbitrary position within a VBox. But this is not possible because the position gets overridden by the VBox.<br /><br />So why is the position of the component.includeInLayout==false just not touched? For example, change line 272 of mx.containers.utilityClasses.BoxLayout in 3.0.2.2095 from<br />for (i = 0; i < n; i++) { obj = IUIComponent(target.getChildAt(i)); left = (w - obj.width) * horizontalAlign + paddingLeft; obj.move(Math.floor(left), Math.floor(top)); if (obj.includeInLayout) top += obj.height + gap; }<br /><br />to something like<br /><br />for (i = 0; i < n; i++) { obj = IUIComponent(target.getChildAt(i)); if (obj.includeInLayout) { left = (w - obj.width) * horizontalAlign + paddingLeft; obj.move(Math.floor(left), Math.floor(top)); top += obj.height + gap; } }<br /><br />Marc<br /><br />________________________________<br />View/reply at Extend the use case of includeInLayout <a href=http://www.adobeforums.com/webx?13@@.59b5b0c3><br />Replies by email are OK.<br />Use the unsubscribe <a href=http://www.adobeforums.com/webx?280@@.59b5b0c3!folder=.3c060fa3> form to cancel your email subscription.<br /><br /><br /><br /><br />------------------------------------------------------<br />View/reply at <a href=http://www.adobeforums.com/webx?13@@.59b5b0c3/0><br />Replies by email are OK.<br />Use the unsubscribe form at <a href=http://www.adobeforums.com/webx?280@@.59b5b0c3!folder=.3c060fa3> to cancel your email subscription.
matt_chotin
Inspiring
July 7, 2008
Hi Marc,<br /><br />I think you're probably right. Can you file a bug and maybe submit a patch for this?<br /><br />Matt<br /><br /><br />On 7/2/08 1:12 AM, "MarcS" <member@adobeforums.com> wrote:<br /><br />A new discussion was started by MarcS in<br /><br />Developers --<br /> Extend the use case of includeInLayout<br /><br />Let's focus on the case of VBox. When component.includeInLayout=false, the component is placed at the position of the previously placed component in the VBox. Hence, even though component.includeInLayout==false, the position of the component is changed. However, I sometimes want to place e.g. a Button at an arbitrary position within a VBox. But this is not possible because the position gets overridden by the VBox.<br /><br />So why is the position of the component.includeInLayout==false just not touched? For example, change line 272 of mx.containers.utilityClasses.BoxLayout in 3.0.2.2095 from<br />for (i = 0; i < n; i++) { obj = IUIComponent(target.getChildAt(i)); left = (w - obj.width) * horizontalAlign + paddingLeft; obj.move(Math.floor(left), Math.floor(top)); if (obj.includeInLayout) top += obj.height + gap; }<br /><br />to something like<br /><br />for (i = 0; i < n; i++) { obj = IUIComponent(target.getChildAt(i)); if (obj.includeInLayout) { left = (w - obj.width) * horizontalAlign + paddingLeft; obj.move(Math.floor(left), Math.floor(top)); top += obj.height + gap; } }<br /><br />Marc<br /><br />________________________________<br />View/reply at Extend the use case of includeInLayout <a href=http://www.adobeforums.com/webx?13@@.59b5b0c3><br />Replies by email are OK.<br />Use the unsubscribe <a href=http://www.adobeforums.com/webx?280@@.59b5b0c3!folder=.3c060fa3> form to cancel your email subscription.