1
0
mirror of https://github.com/sehugg/8bitworkshop.git synced 2024-11-25 18:33:11 +00:00

fixed unit test

This commit is contained in:
Steven Hugg 2019-02-22 11:43:07 -05:00
parent af0e3ed064
commit 3c911b8869
2 changed files with 4 additions and 4 deletions

View File

@ -293,9 +293,9 @@ export class CodeProject {
this.listings = data.listings;
for (var lstname in this.listings) {
var lst = this.listings[lstname];
if (lst.lines && lst.text)
if (lst.lines)
lst.sourcefile = new SourceFile(lst.lines, lst.text);
if (lst.asmlines && lst.text)
if (lst.asmlines)
lst.assemblyfile = new SourceFile(lst.asmlines, lst.text);
}
}

View File

@ -173,8 +173,8 @@ function refreshWindowList() {
if (listings) {
for (var lstfn in listings) {
var lst = listings[lstfn];
// TODO: add assembly listings? (lines, macrolines, sourcefile)
if (lst.assemblyfile || lst.sourcefile) {
// add listing if source/assembly file exists and has text
if ((lst.assemblyfile && lst.assemblyfile.text) || (lst.sourcefile && lst.sourcefile.text)) {
addWindowItem(lstfn, getFilenameForPath(lstfn), (path) => {
return new Views.ListingView(path);
});