2

I'm using Eclipse in linux. I have created a project using Cocos2D. It's a Java project, but im opening cpp and headers files to write native code.

Each time, i compile the native code with ./build_native.sh

I will like to know if eclipse could be configure to autocomplete functions in native code.

Example:

CCDirector::sharedDirector()->

Must show the options like getWinSize().

Some ideas? Thanks in advance.

vgonisanz
  • 11,831
  • 13
  • 78
  • 130

2 Answers2

3

I can't answer to the specifics of your question but in general I had this problem in C/C++ with iostream and STL libs. Even though everything would compile fine it wasn't supporting auto-complete. I ended up digging down into the supplied libraries to the root that held each .h file collection and added those to the directories path. Then I rebuilt the index and then auto-complete started working. So if cocos2d stores .h files in more than one location add each folder.

Tod
  • 8,192
  • 5
  • 52
  • 93
2

Have you installed the CDT? That give Eclipse C/C++ capabilities similar to what it already has for Java.

E-Riz
  • 31,431
  • 9
  • 97
  • 134
  • Yes, i have CDT main features installed, and CDT Optional features. I can create c++ projects and compile it – vgonisanz Apr 08 '12 at 07:53