У меня проблема с подключением к моему приложению Flex, точно меню (на основе mx.controls.Menu и flexlib.controls.ScrollableMenu).mx.controls.Menu не отображается должным образом при построении flexmojos-maven-plugin
Когда я создаю свое приложение с помощью меню FlashBuilder. Смотрите скриншот:
Но когда я построить его мавена использованием flexmojos-Sonatype-плагин меню нарушается (это не оказанными надлежащим образом в соответствии с labelField собственности и не улавливает любые события, как мыши) , Смотрите скриншот:
Мой .actionScriptProperties файл:
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<actionScriptProperties analytics="false" mainApplicationPath="ats.mxml" projectUUID="802474ea-5e3c-4d2c-bdaa-8c263c0828f4" version="6">
<compiler additionalCompilerArguments="-locale en_US" autoRSLOrdering="false" copyDependentFiles="true" flexSDK="Flex 3.3" fteInMXComponents="false" generateAccessible="true" htmlExpressInstall="true" htmlGenerate="true" htmlHistoryManagement="true" htmlPlayerVersionCheck="true" includeNetmonSwc="false" outputFolderLocation="D:/flex" outputFolderPath="bin-debug" rootURL="http://localhost:8080/flex/" sourceFolderPath="src/main/flex" strict="true" targetPlayerVersion="0.0.0" useApolloConfig="false" useDebugRSLSwfs="true" verifyDigests="true" warn="true">
<compilerSourcePath />
<libraryPath defaultLinkType="1">
<libraryPathEntry kind="3" linkType="1" path="d:/apps/.m2/repo/com/adobe/flex/framework/automation/3.3.0.4852/automation-3.3.0.4852.swc" useDefaultLinkType="true"/>
<libraryPathEntry kind="3" linkType="1" path="d:/apps/.m2/repo/com/adobe/flex/framework/automation_agent/3.3.0.4852/automation_agent-3.3.0.4852.swc" useDefaultLinkType="true"/>
<libraryPathEntry kind="3" linkType="1" path="d:/apps/.m2/repo/com/adobe/flex/framework/automation_dmv/3.3.0.4852/automation_dmv-3.3.0.4852.swc" useDefaultLinkType="true"/>
<libraryPathEntry kind="3" linkType="1" path="d:/apps/.m2/repo/com/adobe/flex/framework/automation_flashflexkit/3.3.0.4852/automation_flashflexkit-3.3.0.4852.swc" useDefaultLinkType="true"/>
<libraryPathEntry kind="3" linkType="1" path="d:/apps/.m2/repo/com/adobe/flex/framework/automation_agent/3.3.0.4852/automation_agent-3.3.0.4852-en_US.rb.swc" useDefaultLinkType="true"/>
<libraryPathEntry kind="3" linkType="1" path="d:/apps/.m2/repo/com/adobe/flex/framework/automation/3.3.0.4852/automation-3.3.0.4852-en_US.rb.swc" useDefaultLinkType="true"/>
<libraryPathEntry kind="3" linkType="1" path="d:/apps/.m2/repo/com/adobe/flexunit/flexunit/0.90/flexunit-0.90.swc" useDefaultLinkType="true"/>
<libraryPathEntry kind="3" linkType="1" path="d:/apps/.m2/repo/com/adobe/flex/framework/as3corelib/0.92.1/as3corelib-0.92.1.swc" useDefaultLinkType="true"/>
<libraryPathEntry kind="3" linkType="1" path="d:/apps/.m2/repo/com/google/code/flexlib/flexlib/2.6-M3/flexlib-2.6-M3.swc" useDefaultLinkType="true"/>
<libraryPathEntry kind="4" path="">
<modifiedEntries>
<libraryPathEntry kind="3" linkType="1" path="${PROJECT_FRAMEWORKS}/libs/framework.swc" useDefaultLinkType="true"/>
</modifiedEntries>
<excludedEntries>
<libraryPathEntry kind="3" linkType="1" path="${PROJECT_FRAMEWORKS}/libs/qtp.swc" useDefaultLinkType="false"/>
<libraryPathEntry kind="3" linkType="1" path="${PROJECT_FRAMEWORKS}/libs/automation.swc" useDefaultLinkType="false"/>
<libraryPathEntry kind="3" linkType="1" path="${PROJECT_FRAMEWORKS}/libs/automation_dmv.swc" useDefaultLinkType="false"/>
<libraryPathEntry kind="3" linkType="1" path="${PROJECT_FRAMEWORKS}/libs/automation_agent.swc" useDefaultLinkType="false"/>
</excludedEntries>
</libraryPathEntry>
</libraryPath>
<sourceAttachmentPath>
<sourceAttachmentPathEntry kind="3" linkType="1" path="${PROJECT_FRAMEWORKS}/libs/flex.swc" sourcepath="${PROJECT_FRAMEWORKS}/source" useDefaultLinkType="false"/>
</sourceAttachmentPath>
</compiler>
<applications>
<application path="myApp.mxml"/>
</applications>
<modules/>
<buildCSSFiles/>
</actionScriptProperties>
Мой эффективный файл POM:
<?xml version="1.0" encoding="UTF-8"?>
<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd" xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<modelVersion>4.0.0</modelVersion>
<groupId>org.application.myApp</groupId>
<artifactId>myApp</artifactId>
<version>trunk-SNAPSHOT</version>
<packaging>swf</packaging>
<dependencyManagement>
<dependencies>
<dependency>
<groupId>com.google.code.flexlib</groupId>
<artifactId>flexlib</artifactId>
<version>2.6-M3</version>
<type>swc</type>
</dependency>
</dependencies>
</dependencyManagement>
<dependencies>
<dependency>
<groupId>com.google.code.flexlib</groupId>
<artifactId>flexlib</artifactId>
<type>swc</type>
</dependency>
<dependency>
<groupId>com.adobe.flex.framework</groupId>
<artifactId>flex-framework</artifactId>
<version>3.3.0.4852</version>
<type>pom</type>
<scope>compile</scope>
<exclusions>
<exclusion>
<artifactId>playerglobal</artifactId>
<groupId>com.adobe.flex.framework</groupId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>com.adobe.flex.framework</groupId>
<artifactId>playerglobal</artifactId>
<version>3.3.0.4852</version>
<type>swc</type>
<classifier>10</classifier>
<scope>compile</scope>
</dependency>
<dependency>
<groupId>com.adobe.flexunit</groupId>
<artifactId>flexunit</artifactId>
<version>0.90</version>
<type>swc</type>
<scope>compile</scope>
</dependency>
<dependency>
<groupId>com.adobe.flex.framework</groupId>
<artifactId>as3corelib</artifactId>
<version>0.92.1</version>
<type>swc</type>
<scope>compile</scope>
</dependency>
<dependency>
<groupId>com.adobe.flex.framework</groupId>
<artifactId>datavisualization</artifactId>
<version>3.3.0.4852</version>
<type>swc</type>
<scope>compile</scope>
</dependency>
</dependencies>
<build>
<extensions>
<extension>
<groupId>org.apache.maven.wagon</groupId>
<artifactId>wagon-http-lightweight</artifactId>
<version>1.0</version>
</extension>
</extensions>
<pluginManagement>
<plugins>
<plugin>
<artifactId>maven-antrun-plugin</artifactId>
<version>1.3</version>
</plugin>
<plugin>
<artifactId>maven-assembly-plugin</artifactId>
<version>2.2-beta-5</version>
</plugin>
<plugin>
<artifactId>maven-dependency-plugin</artifactId>
<version>2.1</version>
</plugin>
<plugin>
<artifactId>maven-release-plugin</artifactId>
<version>2.0</version>
</plugin>
<plugin>
<groupId>org.sonatype.flexmojos</groupId>
<artifactId>flexmojos-maven-plugin</artifactId>
<version>4.0-RC2</version>
<extensions>true</extensions>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>sources</goal>
</goals>
<configuration>
<actionscriptFileEncoding>UTF-8</actionscriptFileEncoding>
<licenses>
<flexbuilder3>...</flexbuilder3>
</licenses>
<targetPlayer>10.2.0</targetPlayer>
<accessible>true</accessible>
<headlessServer>true</headlessServer>
<localesCompiled>
<locale>en_US</locale>
</localesCompiled>
<verboseStacktraces>true</verboseStacktraces>
<compilerWarnings>
<assignmentWithinConditional>true</assignmentWithinConditional>
<constructorReturnsValue>true</constructorReturnsValue>
<duplicateArgumentNames>true</duplicateArgumentNames>
<duplicateVariableDef>true</duplicateVariableDef>
<noConstructor>true</noConstructor>
</compilerWarnings>
<generateHtmlWrapper>false</generateHtmlWrapper>
<enableM2e>false</enableM2e>
</configuration>
</execution>
<execution>
<id>swf-optimization</id>
<goals>
<goal>optimize-swf</goal>
</goals>
<configuration>
<attachOriginalArtifact>false</attachOriginalArtifact>
<reduce>false</reduce>
<reduceMergeABC>false</reduceMergeABC>
<reduceMergeCF>false</reduceMergeCF>
<reduceSortCPool>false</reduceSortCPool>
<strip>false</strip>
<actionscriptFileEncoding>UTF-8</actionscriptFileEncoding>
<licenses>
<flexbuilder3>...</flexbuilder3>
</licenses>
<targetPlayer>10.2.0</targetPlayer>
<accessible>true</accessible>
<headlessServer>true</headlessServer>
<localesCompiled>
<locale>en_US</locale>
</localesCompiled>
<verboseStacktraces>true</verboseStacktraces>
<compilerWarnings>
<assignmentWithinConditional>true</assignmentWithinConditional>
<constructorReturnsValue>true</constructorReturnsValue>
<duplicateArgumentNames>true</duplicateArgumentNames>
<duplicateVariableDef>true</duplicateVariableDef>
<noConstructor>true</noConstructor>
</compilerWarnings>
<generateHtmlWrapper>false</generateHtmlWrapper>
<enableM2e>false</enableM2e>
</configuration>
</execution>
</executions>
<dependencies>
<dependency>
<groupId>com.adobe.flex</groupId>
<artifactId>license</artifactId>
<version>3</version>
<scope>compile</scope>
</dependency>
<dependency>
<groupId>org.sonatype.flexmojos</groupId>
<artifactId>flexmojos-flex3-compatibility-layer</artifactId>
<version>4.0-RC2</version>
<scope>compile</scope>
</dependency>
<dependency>
<groupId>com.adobe.flex</groupId>
<artifactId>compiler</artifactId>
<version>3.3.0.4852</version>
<type>pom</type>
<scope>compile</scope>
</dependency>
<dependency>
<groupId>com.adobe.flex</groupId>
<artifactId>adt</artifactId>
<version>3.3.0.4852</version>
<scope>compile</scope>
</dependency>
</dependencies>
<configuration>
<actionscriptFileEncoding>UTF-8</actionscriptFileEncoding>
<licenses>
<flexbuilder3>...</flexbuilder3>
</licenses>
<targetPlayer>10.2.0</targetPlayer>
<accessible>true</accessible>
<headlessServer>true</headlessServer>
<localesCompiled>
<locale>en_US</locale>
</localesCompiled>
<verboseStacktraces>true</verboseStacktraces>
<compilerWarnings>
<assignmentWithinConditional>true</assignmentWithinConditional>
<constructorReturnsValue>true</constructorReturnsValue>
<duplicateArgumentNames>true</duplicateArgumentNames>
<duplicateVariableDef>true</duplicateVariableDef>
<noConstructor>true</noConstructor>
</compilerWarnings>
<generateHtmlWrapper>false</generateHtmlWrapper>
<enableM2e>false</enableM2e>
</configuration>
</plugin>
<plugin>
<artifactId>maven-deploy-plugin</artifactId>
<version>2.5</version>
</plugin>
<plugin>
<artifactId>maven-clean-plugin</artifactId>
<version>2.4.1</version>
</plugin>
</plugins>
</pluginManagement>
<plugins>
<plugin>
<artifactId>maven-release-plugin</artifactId>
<version>2.0</version>
<configuration>
<allowTimestampedSnapshots>true</allowTimestampedSnapshots>
</configuration>
</plugin>
<plugin>
<groupId>org.sonatype.flexmojos</groupId>
<artifactId>flexmojos-maven-plugin</artifactId>
<version>4.0-RC2</version>
<extensions>true</extensions>
<executions>
<execution>
<id>default-compile-swf</id>
<phase>compile</phase>
<goals>
<goal>compile-swf</goal>
</goals>
<configuration>
<sourceFile>myApp.mxml</sourceFile>
<ignoreVersionIssues>true</ignoreVersionIssues>
<skipTests>true</skipTests>
<compilerWarnings>
<warn-no-constructor>false</warn-no-constructor>
<show-binding-warnings>false</show-binding-warnings>
<warn-duplicate-variable-def>false</warn-duplicate-variable-def>
<assignmentWithinConditional>true</assignmentWithinConditional>
<constructorReturnsValue>true</constructorReturnsValue>
<duplicateArgumentNames>true</duplicateArgumentNames>
<duplicateVariableDef>true</duplicateVariableDef>
<noConstructor>true</noConstructor>
</compilerWarnings>
<actionscriptFileEncoding>UTF-8</actionscriptFileEncoding>
<licenses>
<flexbuilder3>...</flexbuilder3>
</licenses>
<targetPlayer>10.2.0</targetPlayer>
<accessible>true</accessible>
<headlessServer>true</headlessServer>
<localesCompiled>
<locale>en_US</locale>
</localesCompiled>
<verboseStacktraces>true</verboseStacktraces>
<generateHtmlWrapper>false</generateHtmlWrapper>
<enableM2e>false</enableM2e>
</configuration>
</execution>
<execution>
<phase>package</phase>
<goals>
<goal>sources</goal>
</goals>
<configuration>
<sourceFile>myApp.mxml</sourceFile>
<ignoreVersionIssues>true</ignoreVersionIssues>
<skipTests>true</skipTests>
<compilerWarnings>
<warn-no-constructor>false</warn-no-constructor>
<show-binding-warnings>false</show-binding-warnings>
<warn-duplicate-variable-def>false</warn-duplicate-variable-def>
<assignmentWithinConditional>true</assignmentWithinConditional>
<constructorReturnsValue>true</constructorReturnsValue>
<duplicateArgumentNames>true</duplicateArgumentNames>
<duplicateVariableDef>true</duplicateVariableDef>
<noConstructor>true</noConstructor>
</compilerWarnings>
<actionscriptFileEncoding>UTF-8</actionscriptFileEncoding>
<licenses>
<flexbuilder3>...</flexbuilder3>
</licenses>
<targetPlayer>10.2.0</targetPlayer>
<accessible>true</accessible>
<headlessServer>true</headlessServer>
<localesCompiled>
<locale>en_US</locale>
</localesCompiled>
<verboseStacktraces>true</verboseStacktraces>
<generateHtmlWrapper>false</generateHtmlWrapper>
<enableM2e>false</enableM2e>
</configuration>
</execution>
<execution>
<id>swf-optimization</id>
<goals>
<goal>optimize-swf</goal>
</goals>
<configuration>
<attachOriginalArtifact>false</attachOriginalArtifact>
<reduce>false</reduce>
<reduceMergeABC>false</reduceMergeABC>
<reduceMergeCF>false</reduceMergeCF>
<reduceSortCPool>false</reduceSortCPool>
<strip>false</strip>
<sourceFile>myApp.mxml</sourceFile>
<ignoreVersionIssues>true</ignoreVersionIssues>
<skipTests>true</skipTests>
<compilerWarnings>
<warn-no-constructor>false</warn-no-constructor>
<show-binding-warnings>false</show-binding-warnings>
<warn-duplicate-variable-def>false</warn-duplicate-variable-def>
<assignmentWithinConditional>true</assignmentWithinConditional>
<constructorReturnsValue>true</constructorReturnsValue>
<duplicateArgumentNames>true</duplicateArgumentNames>
<duplicateVariableDef>true</duplicateVariableDef>
<noConstructor>true</noConstructor>
</compilerWarnings>
<actionscriptFileEncoding>UTF-8</actionscriptFileEncoding>
<licenses>
<flexbuilder3>...</flexbuilder3>
</licenses>
<targetPlayer>10.2.0</targetPlayer>
<accessible>true</accessible>
<headlessServer>true</headlessServer>
<localesCompiled>
<locale>en_US</locale>
</localesCompiled>
<verboseStacktraces>true</verboseStacktraces>
<generateHtmlWrapper>false</generateHtmlWrapper>
<enableM2e>false</enableM2e>
</configuration>
</execution>
</executions>
<dependencies>
<dependency>
<groupId>com.adobe.flex</groupId>
<artifactId>license</artifactId>
<version>3</version>
<scope>compile</scope>
</dependency>
<dependency>
<groupId>org.sonatype.flexmojos</groupId>
<artifactId>flexmojos-flex3-compatibility-layer</artifactId>
<version>4.0-RC2</version>
<scope>compile</scope>
</dependency>
<dependency>
<groupId>com.adobe.flex</groupId>
<artifactId>compiler</artifactId>
<version>3.3.0.4852</version>
<type>pom</type>
<scope>compile</scope>
</dependency>
<dependency>
<groupId>com.adobe.flex</groupId>
<artifactId>adt</artifactId>
<version>3.3.0.4852</version>
<scope>compile</scope>
</dependency>
</dependencies>
<configuration>
<sourceFile>ats.mxml</sourceFile>
<ignoreVersionIssues>true</ignoreVersionIssues>
<skipTests>true</skipTests>
<compilerWarnings>
<warn-no-constructor>false</warn-no-constructor>
<show-binding-warnings>false</show-binding-warnings>
<warn-duplicate-variable-def>false</warn-duplicate-variable-def>
<assignmentWithinConditional>true</assignmentWithinConditional>
<constructorReturnsValue>true</constructorReturnsValue>
<duplicateArgumentNames>true</duplicateArgumentNames>
<duplicateVariableDef>true</duplicateVariableDef>
<noConstructor>true</noConstructor>
</compilerWarnings>
<actionscriptFileEncoding>UTF-8</actionscriptFileEncoding>
<licenses>
<flexbuilder3>...</flexbuilder3>
</licenses>
<targetPlayer>10.2.0</targetPlayer>
<accessible>true</accessible>
<headlessServer>true</headlessServer>
<localesCompiled>
<locale>en_US</locale>
</localesCompiled>
<verboseStacktraces>true</verboseStacktraces>
<generateHtmlWrapper>false</generateHtmlWrapper>
<enableM2e>false</enableM2e>
</configuration>
</plugin>
<plugin>
<artifactId>maven-clean-plugin</artifactId>
<version>2.4.1</version>
<executions>
<execution>
<id>default-clean</id>
<phase>clean</phase>
<goals>
<goal>clean</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<artifactId>maven-resources-plugin</artifactId>
<executions>
<execution>
<id>default-resources</id>
<phase>process-resources</phase>
<goals>
<goal>resources</goal>
</goals>
</execution>
<execution>
<id>default-testResources</id>
<phase>process-test-resources</phase>
<goals>
<goal>testResources</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<artifactId>maven-install-plugin</artifactId>
<executions>
<execution>
<id>default-install</id>
<phase>install</phase>
<goals>
<goal>install</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<artifactId>maven-deploy-plugin</artifactId>
<version>2.5</version>
<executions>
<execution>
<id>default-deploy</id>
<phase>deploy</phase>
<goals>
<goal>deploy</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>
Я нашел с помощью MonsterDebugger, что во время выполнения программы меню объекта, и он создается MenuItemRenderers ,
Я использую Flex SDK 3.3, FlashBuilder 4, Maven 3.0.5, flexmojos-maven-plugin 4.0-RC2. Вы знаете, в чем разница между созданием моего приложения FlashBuilder и Maven? Спасибо за любой ответ.
Вы использовали 'стыковку report' для изучения различий между вашими двумя строит? – Brian
И вы используете действительно действительно старую версию flexmojos. Самый последний для Adobe Flex является curretnly 6.0.1 (но с измененным идентификатором группы: net.flexmojos.oss), а для Apache Flex - 7.0.1 –
Вы используете безумно старую версию Flex и Flexmojos, и вы дублируя довольно много конфигурации, так как вам нужно только настроить плагин в разделе pluginManagement или в разделе плагина (у вас в настоящее время есть все два раза). Я бы порекомендовал взглянуть на «modulename-config.xml», созданный в целевом каталоге FlexMojos (в 6.x и 7.x он создан автоматически) и параметр командной строки «-dump-config» для FlashBuilder , Если вы сравните созданные конфигурации, вы должны выяснить, что происходит довольно быстро. –