Flex 布局:对单个状态进行的更改
我正在 Flex Builder 中修改 Flex 应用程序的布局。 我没有意识到我所做的改变是针对特定状态的。 我的申请中大约有 6-7 个州。 现在,我需要对所有这些状态进行这些更改。 我该怎么做? 到目前为止,在一种状态下有多行这样的:
<mx:SetProperty target="{accno}" name="x" value="116"/>
<mx:SetProperty target="{accno}" name="y" value="826"/>
<mx:SetProperty target="{phone}" name="x" value="116"/>
<mx:SetProperty target="{phone}" name="y" value="866"/>
I was modifying the layout of a Flex application in Flex Builder. What I didn't realize was that the changes I made, were made for a particular state. There are around 6-7 states in my application. Now, I need those changes to be made to all of those states. How do I do it? As of now there are multiple lines like this in one state :
<mx:SetProperty target="{accno}" name="x" value="116"/>
<mx:SetProperty target="{accno}" name="y" value="826"/>
<mx:SetProperty target="{phone}" name="x" value="116"/>
<mx:SetProperty target="{phone}" name="y" value="866"/>
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
如果位置是相对的,您可以在绑定中使用数学。 为什么不绑定 x & y 在 accno 和phone 上输入变量,并计算相对位置?
那行得通吗? 然后,您的页面上只需要一个 accno_x 和 accno_y 变量。 您也可以只制作手机的 x & y 相对于 accno:
If the positions are relative, you can use math in your bindings. Why don't you bind x & y on accno and phone to variables, and do math for the relative position?
Would that work? Then you just need an accno_x and accno_y variable on your page. You can also just make phone's x & y relative to accno: