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

Using code templates in Flash Builder

Guide ,
Aug 08, 2011 Aug 08, 2011

Copy link to clipboard

Copied

Hi, all;

I know how to change most of the templates so that they go from the default "uncuddled" brackets to "cuddled"

i.e.

public function notCuddled():void

{

     //TODO

}

vs.

public function cuddled():void {

     //yay! no wasted space

}

However, I have not found the template used for the constructor for a generated Class, so I get:

package my.package {

     public class MyLovelyCuddledClass {

          public function MyLovelyCuddledClass()

          {//wasted line that I have to manually fix

          }

     }

}

I love the new productivity enhamcements in FB 4.5, and they are so great that little nitpicks like this stand out.  Can anyone tell me where I can find the template that is used for this, so I can code to the fullest potential of the tool?

TIA;

Amy

Views

746

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
Guest
Aug 08, 2011 Aug 08, 2011

Copy link to clipboard

Copied

Hi Amy,

You can customize 'New class' generation under Preferences->Editors->Flash

Builder->FileTemplates->Action Script->New ActionScript class.

Currently there are no template variables available constructors. But you

can customize it as following,

$

{

${import_declaration}

$ {

public function ${class_name}() {

}

}

}

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
Guide ,
Aug 09, 2011 Aug 09, 2011

Copy link to clipboard

Copied

LATEST

Thanks, I'll try that

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