0 Replies Latest reply on Aug 27, 2009 3:43 AM by ravindra.kumar

    Creating custom html-wrapper from ANT build

    ravindra.kumar

      Hi,

       

      I have been using flex from last six month. I am facing problem while creating html-wrapper. As per my requirement, my application need to run on all the browser. But whenever I use to run application on firefox, there is some focus related problem. For that I need to set wmode='opaque' and

      <

       

      body scroll="no" onLoad="window.document.${application}.focus();">. But I am unable to find out how to set this property in html-wrapper through ant build.

       

      currently I am using following and script to build my flex application.

       

       

       

       

       

       

       

       

       

       

       

       

       

       

       

       

       

       

       

       

      <!-- compile flex source code -->

       

       

      <target name="compile.flex" description="Compile the Flex source code" unless="eclipse.running"

      >

       

       

      <taskdef resource="flexTasks.tasks" classpath="${flex.home}/ant/lib/flexTasks.jar"

      />

       

       

      <echo level="info">Compiling flex mxml

      </echo>

       

       

      <property name="FLEX_HOME" value="${flex.home}"

      />

       

       

      <mxmlc file="${basedir}/src/main/flex/main.mxml" output="${exploded.dir}/${project.name}.swf" actionscript-file-encoding="UTF-8" incremental="true" services="${basedir}/src/main/resources/services-config.xml" context-root="/${project.name}"

      >

       

       

      <source-path path-element="${basedir}/src/main/resources/messages/{locale}"

      />

       

       

       

      <!-- Get default compiler options. -->

       

       

      <load-config filename="${flex.home}/frameworks/flex-config.xml"

      />

       

       

       

      <!-- List of path elements that form the roots of ActionScript class hierarchies. -->

       

       

      <!--<source-path path-element="${view.dir}/flex/assets" />-->

       

       

       

      <compiler.library-path dir="${flex.lib.dir}" append="true"

      >

       

       

      <include name="*"

      />

       

       

      </compiler.library-path>

       

       

      </mxmlc>

       

       

      <echo level="info">Generating html

      </echo>

       

       

      <html-wrapper title="${project.name}" file="${project.name}.html" application="app" swf="${project.name}" version-major="9" version-minor="0" version-revision="0" width="100%" height="100%" history="true" template="client-side-detection" output="${exploded.dir}"

      />

       

       

      </target>

       

       

      I have also tried to edit respective index.template.html file in flex SDK, but that also doesn't work. Please suggest what shoud I do?

       

      Thanks and Regards,

      Ravindar kumar