Fix issue with Android source not displaying

VSCode 1.9 prioritises srcref over path - we now set the ref to 0 if a source path is set.
This commit is contained in:
adelphes
2017-02-02 19:18:54 +00:00
parent 214a48b1e1
commit b60ef65803

View File

@@ -802,7 +802,7 @@ class AndroidDebugSession extends DebugSession {
const srcpath = pkginfo ? path.join(pkginfo.package_path,sourcefile)
: this._android_sources_path ? srcInfo.filepath
: null;
const src = new Source(sourcefile, srcpath, srcRefId);
const src = new Source(sourcefile, srcpath, srcpath ? 0 : srcRefId);
pkginfo && (highest_known_source=i);
stack.push(new StackFrame(stack_frame_id, name, src, linenum, 0));
}