Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[cdt-dev] Refreshing include paths programmatically

Hi all,

I have written an IProjectMacroSupplier that looks up values for macros
stored with known IDs as persistent properties in the project. I allow
users to enter initial values for these macros in my new project wizard.
The values of these macros are used to construct include paths. 

However, when a project is created with these macros, the include paths
cannot be found as the macros are not resolved to the values that the
user has given in the wizard. If I open up the project properties,
navigate to the project macros and press OK (without changing anything)
then the macros resolve and the include paths can be found.

Because the values are persistent properties of the project, they cannot
be set until after the project has been created, so I set them in an
operationClass of the page in which the values are set. I believe that
what is happening is that the project is being created with the
IProjectMacroSupplier unable to see the values - when I later set the
values, the project does not refresh its include paths. This is not
surprising, as there is no way that the project could 'know' that my
having set persistent properties on it changes the behaviour of its
IProjectMacroSupplier.

I have tried various means of making the project refresh (including the
obvious 'refreshLocal') but this seems not to work. From web searching
and looking at source it seems that a PathEntryManager is responsible
for looking after the include paths, but I cannot find any way to make
this refresh the paths. Any suggestions would be greatly appreciated.

Regards,

Bernie Ogden
Product Engineering Group
ARM Ltd

-- 
IMPORTANT NOTICE: The contents of this email and any attachments are confidential and may also be privileged. If you are not the intended recipient, please notify the sender immediately and do not disclose the contents to any other person, use it for any purpose, or store or copy the information in any medium.  Thank you.




Back to the top