Flash Builder 4 suddenly stops doing auto-complete

2019-06-25 22:51发布

A project we've been working on for weeks in Flash Builder suddenly has stopped being navigable: all the nice features of Flash Builder like auto-completion, jump to definition, even search for References are only partially working -- they work for some classes but not for others. I've tried restarting Flash Builder, closing and opening the project, re-creating the project, but this bad situation persists. Moreover, it happened at about the same time for 2 other developers on the same project, each with a somewhat different configuration. It seems perhaps we have exceeded some internal limit of FlashBuilder, yet our project is not even that large yet. I'm not sure where I can look to troubleshoot this.

8条回答
爱情/是我丢掉的垃圾
2楼-- · 2019-06-25 23:15

Right click on a class and select 'refresh' fixed this issue for me :)

I also noticed it opens a weird second class where code hinting is not working when you click on a hyperlink to that class from a different class. If you double click the 'Class.as' file in the documents tree then it works fine. Very strange

查看更多
看我几分像从前
3楼-- · 2019-06-25 23:19

Usually an Eclipse shut down and relaunch solves the problem for me. But, here are a few other things to try:

  1. Since this has happened across three work stations, on a discrete set of classes, have you looked for a weird, or non-standard syntax bug? I'm sure I have seen situations where something will not cause a compiler error, but do cause code hinting to break. I'd look for things like single quotes inside of double quotes or ASDocs that aren't properly terminated. [It does seem wildly inconsistent, though, so it is a bit of a stab in the dark].
  2. Try cleaning the work space. When you launch Flash Builder (or Eclipse) use the '-clean' argument. I do this in a Windows shortcut; I'm not sure how to do it on a Mac
  3. Try re-creating the component in question. Slowly copy code over in chunks until you find out what breaks the code hinting.
查看更多
在下西门庆
4楼-- · 2019-06-25 23:19

I got significant improvement by turning of 'Enable Design Mode'

查看更多
放荡不羁爱自由
5楼-- · 2019-06-25 23:23

This happened when I added a model declaration to the MXML application. When I commented this out auto complete worked again.

<fx:Model id="testTextFlow">
    <flow:TextFlow version='3.0.0' xmlns:flow='http://ns.adobe.com/textLayout/2008' fontSize='11' 
        textIndent='10' paragraphSpaceBefore='6' paddingTop='8' paddingLeft='8' paddingRight='8'>
        <flow:p paragraphSpaceBefore='inherit' clearFloats='start'>
        <flow:img source="http://imgs.xkcd.com/comics/trapped.png" width="600" height="300" float="right"/>
        <flow:span>Bacon ipsum. Permanent link to this comic: http://xkcd.com/876/ Image URL (for hotlinking/embedding): http://imgs.xkcd.com/comics/trapped.png</flow:span>
        <flow:TextFlow version='3.0.0' xmlns:flow='http://ns.adobe.com/textLayout/2008' fontSize='15'>  
        <flow:p paragraphSpaceBefore='inherit' >Here is an embedded text flow.</flow:p>
        </flow:TextFlow>
        </flow:p>
    </flow:TextFlow>
</fx:Model>
查看更多
We Are One
6楼-- · 2019-06-25 23:36

This is a common problem in eclipse (aka Flash Builder).

Try increasing the available memory for it's "type caching" (I forget the specific term). You can do this by editing the FlashBuilder.ini in your flex home to look something like this:

-vmargs
-Xms64m
-Xmx1024m
-XX:MaxPermSize=1024m
-XX:PermSize=64m

(snipped out the irrelevant options)

You may also need to completely delete your workspace cache and recreate it. I haven't had this problem since I increased the max memory limit.

You probably don't need more then 512m on the max size, but I am working with a particularly large project with a lot of open library dependencies...

查看更多
仙女界的扛把子
7楼-- · 2019-06-25 23:37

Removing then re-adding the project seemed to fix this for me.

查看更多
登录 后发表回答