Developer forums (C::B DEVELOPMENT STRICTLY!) > CodeCompletion redesign
try to solve the "typedef" problem.
pingf:
typedef struct tagOFNA {
DWORD lStructSize;
HWND hwndOwner;
HINSTANCE hInstance;
LPCSTR lpstrFilter;
LPSTR lpstrCustomFilter;
DWORD nMaxCustFilter;
DWORD nFilterIndex;
LPSTR lpstrFile;
DWORD nMaxFile;
LPSTR lpstrFileTitle;
DWORD nMaxFileTitle;
LPCSTR lpstrInitialDir;
LPCSTR lpstrTitle;
DWORD Flags;
WORD nFileOffset;
WORD nFileExtension;
LPCSTR lpstrDefExt;
LPARAM lCustData;
LPOFNHOOKPROC lpfnHook;
LPCSTR lpTemplateName;
#ifdef _MAC
LPEDITMENU lpEditInfo;
LPCSTR lpstrPrompt;
#endif
} OPENFILENAMEA, *LPOPENFILENAMEA;
.......
.......
typedef OPENFILENAMEA OPENFILENAME;
.......
.......
vc+visual assist find it correctley!
for more , you can search the msdn.
pingf:
still ,
CB can not find the OPENFILENAME automatically,
but if this struct is defined by me,
it works correctly!
MortenMacFly:
--- Quote from: pingf on March 27, 2009, 03:24:29 pm ---CB can not find the OPENFILENAME automatically,
--- End quote ---
Check your project settings related to CC and add the folders as needed.
ollydbg:
A little test source.
--- Code: ---typedef class Ancestor{
public:
int m_aaaa;
int m_bbbb;
} Parent, pPointer;
int main()
{
Parent obj;
obj. //can't works
return 0;
}
--- End code ---
At this time, CC can't works. I just add ,pPointer after Parent. It is not due to the path setting, but caused by the CC's parser.
Another issue:
--- Code: ---typedef OPENFILENAMEA OPENFILENAME;
--- End code ---
The statement above will not regard OPENFILENAME as a derived class from OPENFILENAMEA, so, when you write.
--- Code: ---OPENFILENAME obj;
obj. //CC can't work here
--- End code ---
This was my opinion after reading the current CC's related sources.
Navigation
[0] Message Index
[*] Previous page
Go to full version