SPAS 3.0 Forums: General

You have been banned from this forum. If you have any questions, please contact the Administrator.

Sign in or create an account

You are logged in as:

Error when building project in Flash Builder

Page : 1

Reply New topic
Author Message
Community Member
Join Date: 2012-07-14
Posts: 21
Post date 02-08-2013, 05:36
#1
Hi Pascal

I am back working on the project using FlashAPI and I wanted to profile my project using Adobe scout. So that means I need to be able to build it in Flash Builder. I normally use Flash Develop and dont have any problems. But when I tried to compile my project in Flash Builder, I get 6 errors all in one function.
initTarget() in UIObject.

$target = $parent = super;

spas_internal::lafDTO.width = $width = super.width;
spas_internal::lafDTO.height = $height = super.height;
super.scaleX = super.scaleY = 1;

'=' is not allowed here UIObject.as for the $parent = super, and the rest of the bolded super.

I am doing something wrong here?

bob
It appears not to like the "super" in this context.




Administrator
Join Date: 2008-12-01
Location: French Riviera
Posts: 47
Post date 02-08-2013, 08:34
#2
Hi Robert,
This line is quite strange:
$target = $parent = super;
All of the errors probably come from the use of the super statement there.
I'll have a look on it.
Does Adobe Scout need the ASC 2 compiler to work with ?

Creator of SPAS 3.0
Community Member
Join Date: 2012-07-14
Posts: 21
Post date 02-08-2013, 16:40
#3
Haven't even got to scout yet. These 6 errors are keeping me from getting a successful build that I can then use in scout. The errors are in Flash Builder 4.7.

And one more warning I did not mention. in UIObject.addEventListener
case UIOEvent.INITIALIZED :
if (_isInitialized = true) dispatchUIOEvent(UIOEvent.INITIALIZED);
break;


tells me assignment within conditional. I am assuming that should be
if (_isInitialized == true), not =

bob

Administrator
Join Date: 2008-12-01
Location: French Riviera
Posts: 47
Post date 02-09-2013, 11:21
#4
Robert,
Some of these errors occur because you are using the ASC2 compiler. SPAS 3.0 migration has been planned to be released only after the new Item Renderers APIs will be available.
Anyway, the piece of code _isInitialized = true is a nasty bug; thx a lot for submitting.
I've fixed the target initialization errors. This part has been designed to enable the use of SPAS UIObjects as Flash IDE runtime components.
But the fact is that you won't be able to use the SPAS API with the new ASC2 compiler at this time. Some sections, such as the return statements placed in the middle of a function code, have to be redesigned. It is the same for some boolean auto-casted parts, and so on...

Creator of SPAS 3.0
Community Member
Join Date: 2012-07-14
Posts: 21
Post date 02-09-2013, 16:52
#5
I missed the implications of the ASC 2 compiler the first time. For profiling I can probably just remove the GUI from the system.

Over the years I have worked hard on developing this habit.
for comparisons I always put the const or unchangeable value to the left

if ( true == initialized )
rather then
if ( initialized == true )

the former has saved me countless hours.

Community Member
Join Date: 2012-07-14
Posts: 21
Post date 02-10-2013, 18:22
#6
Hi Pascal

One more thought on the ACS2.0 Issue. I was planning on building and deploying the app on mobile devices. For now the GUI is not an issue since I wont really use a GUI for the mobile apps. But it seems like its a killer issue for me moving forward. Unless you have a work around for ASC 2.0.
FYI The only errors I ran into in your code where the few I pointed out in the first message. If those were fixed would things work in FlashBuilder 4.7 and ASC 2.0?

bob

Administrator
Join Date: 2008-12-01
Location: French Riviera
Posts: 47
Post date 02-12-2013, 15:14
#7
Hi Bob,

SPAS wont work in FlashBuilder 4.7 and ASC 2.0 indeed.
Actually, some parts of the API are not compatible with the new ASC2 specifications.
I need some time to chech the entire API.

The next step in SPAS development is to finish the Mobile API. At that moment, the whole framework will be compatible with the ASC2 compiler.

Pascal

Creator of SPAS 3.0

Page : 1