1 Reply Latest reply on Jun 22, 2010 7:31 AM by Flex harUI

    Custom component issue


      Custom component issue

      According to customer requirements, we want to get such an effect in the development of custom components:
      Drag and drop custom components to the Flex builder work area, it can generate more than the default properties, not just generate "x", "y" attribute.

      【Details are as follows】
      We design a custom panel "CustomPanel.mxml" in the project development, then drag it into the workspace in the Flex builder development environment.
      View the source code found that it can only generate "x", "y" attribute in default. That is:
      <ns2:CustomPanel x="105" y="74">

      How can we do that when drag the 'custom component' into Flex builder workspace,  we can generate "layout" attribute in addition to "x", "y" attributes?
      That is:
      <ns2:CustomPanel x="105" y="74" layout="absolute">

      The following code will be generated when the "panel component comes with Flex builder environment" is dragged into workspace.
      <mx:Panel x="121" y="134" width="250" height="200" layout="absolute">

      How it is done?