+ ProjectNode GetObjectFileNode(const char * filePath, const char * objectFileExt)
+ {
+ ProjectNode node = null;
+ char ext[MAX_EXTENSION];
+ GetExtension(filePath, ext);
+ if(ext[0])
+ {
+ IntermediateFileType type = IntermediateFileType::FromExtension(ext);
+ if(type)
+ {
+ char fileName[MAX_FILENAME];
+ GetLastDirectory(filePath, fileName);
+ if(fileName[0])
+ {
+ DotMain dotMain = DotMain::FromFileName(fileName);
+ node = FindNodeByObjectFileName(fileName, type, dotMain, null, objectFileExt);
+ }
+ }
+ }
+ return node;
+ }
+
+ bool GetAbsoluteFromRelativePath(const char * relativePath, char * absolutePath, const char * objectFileExt)
+ {
+ ProjectNode node = topNode.FindWithPath(relativePath, false);
+ if(!node)
+ node = GetObjectFileNode(relativePath, objectFileExt);
+ if(node)
+ {
+ strcpy(absolutePath, node.project.topNode.path);
+ PathCat(absolutePath, relativePath);
+ MakeSlashPath(absolutePath);
+ }
+ return node != null;
+ }
+