aharui commented on issue #529: Compile time issue on accessing a file into 
script Block
URL: https://github.com/apache/royale-asjs/issues/529#issuecomment-546424114
 
 
   I'm not sure what "one inside abc and one outside abc" means.  In the 
example you linked to, there are only two source files:
   
   ```
   src\main\royale\HelloWorld.mxml (starting with mx:Application)
   src\main\royale\abc\ControlsExample.mxml (starting with mx:TitleWindow)
   ```
   
   The code in HelloWorld.mxml references `abc.ControlsExample`.
   
   The build script compiles the ControlsExample, but it is not a Application 
or Module, so I don't understand why it is being compiled.  The compiling 
overwrites some of the files output during the HelloWorld compile causing 
HelloWorld to fail.
   
   If you just compile the HelloWorld (compile-shell), it runs just fine as 
expected.
   
   I'm confused as to what your goal is.  If your goal is to have a Module 
called abc.ControlsExample, then HelloWorld should not be directly referencing 
abc.ControlsExample.  If your goal is to use abc.ControlsExample as an 
MXMLComponent then there is no need to compile ControlsExample.
   
   If the question is how to have an MXML class in a package, then the main tag 
in ControlsExample should be mx:Application or mx:Module, and when you compile 
it, you want to specify the `-source-path=src/main/royale` but specify the main 
file as `src/main/royale/abc/ControlsExample.mxml`.  Then the main module class 
will be `abc.ControlsExample`.
    

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to