• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

components on class (.as) files

Community Beginner ,
May 01, 2015 May 01, 2015

Copy link to clipboard

Copied

flash CC on W7. To use 'import fl.controls.Button' on a fla file, I first drag a Button from Library to Screen. How do I use 'import fl.controls.Button' on a class (.as) file where the library is not available?

TOPICS
ActionScript

Views

610

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Community Expert , May 01, 2015 May 01, 2015

No. If you are using Button symbols in your library you draw out all the states using Flash Pro. If you simply create the Button programattically, then you draw out all the states via code.

Votes

Translate

Translate
Community Expert ,
May 01, 2015 May 01, 2015

Copy link to clipboard

Copied

You'd have to programmatically draw your own assets for the button. There is an example here:

Button - Adobe ActionScript® 3 (AS3 Flash) API Reference

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
May 01, 2015 May 01, 2015

Copy link to clipboard

Copied

 

I have a class (.as) file with an ‘import fl.contros.Button’ line. Do you mean that each fla file that includes this class must have a Button component on its library?

 

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
May 01, 2015 May 01, 2015

Copy link to clipboard

Copied

LATEST

No. If you are using Button symbols in your library you draw out all the states using Flash Pro. If you simply create the Button programattically, then you draw out all the states via code.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines