Lines 43-48
Link Here
|
43 |
import org.eclipse.cdt.core.CCorePlugin; |
43 |
import org.eclipse.cdt.core.CCorePlugin; |
44 |
import org.eclipse.cdt.core.model.CModelException; |
44 |
import org.eclipse.cdt.core.model.CModelException; |
45 |
import org.eclipse.cdt.core.model.ICElement; |
45 |
import org.eclipse.cdt.core.model.ICElement; |
|
|
46 |
import org.eclipse.cdt.core.parser.ExtendedScannerInfo; |
47 |
import org.eclipse.cdt.core.parser.IExtendedScannerInfo; |
46 |
import org.eclipse.cdt.core.parser.IScannerInfo; |
48 |
import org.eclipse.cdt.core.parser.IScannerInfo; |
47 |
import org.eclipse.cdt.core.parser.IScannerInfoProvider; |
49 |
import org.eclipse.cdt.core.parser.IScannerInfoProvider; |
48 |
import org.eclipse.cdt.ui.CUIPlugin; |
50 |
import org.eclipse.cdt.ui.CUIPlugin; |
Lines 95-106
Link Here
|
95 |
info = provider.getScannerInformation(proj); |
97 |
info = provider.getScannerInformation(proj); |
96 |
} |
98 |
} |
97 |
if (info != null) { |
99 |
if (info != null) { |
|
|
100 |
// search in system includes |
98 |
String[] includePaths = info.getIncludePaths(); |
101 |
String[] includePaths = info.getIncludePaths(); |
99 |
findFile(includePaths, includeName, filesFound); |
102 |
findFile(includePaths, includeName, filesFound); |
100 |
} |
103 |
} |
101 |
if (filesFound.size() == 0) { |
104 |
if (filesFound.size() == 0) { |
102 |
// Fall back and search the project |
105 |
// search in local includes |
103 |
findFile(proj, new Path(includeName), filesFound); |
106 |
if (info != null) { |
|
|
107 |
IExtendedScannerInfo scanInfo = new ExtendedScannerInfo(info); |
108 |
String[] localIncludePaths = scanInfo.getLocalIncludePath(); |
109 |
findFile(localIncludePaths, includeName, filesFound); |
110 |
} |
111 |
|
112 |
if (filesFound.size() == 0) { |
113 |
// Fall back and search the project |
114 |
findFile(proj, new Path(includeName), filesFound); |
115 |
} |
104 |
} |
116 |
} |
105 |
} |
117 |
} |
106 |
} |
118 |
} |