1
0
mirror of https://github.com/Jermolene/TiddlyWiki5 synced 2025-12-03 15:28:05 +00:00

Switch the story list over to using the new list field

This commit is contained in:
Jeremy Ruston
2013-08-07 17:54:27 +01:00
parent 6a6e7454d7
commit 83ea953a1d
4 changed files with 9 additions and 12 deletions

View File

@@ -51,19 +51,14 @@ NavigatorWidget.prototype.refreshInDom = function(changedAttributes,changedTiddl
};
NavigatorWidget.prototype.getStoryList = function() {
var text = this.renderer.renderTree.wiki.getTextReference(this.storyTitle,"");
if(text && text.length > 0) {
this.storyList = text.split("\n");
} else {
this.storyList = [];
}
this.storyList = this.renderer.renderTree.wiki.getTiddlerList(this.storyTitle);
};
NavigatorWidget.prototype.saveStoryList = function() {
var storyTiddler = this.renderer.renderTree.wiki.getTiddler(this.storyTitle);
this.renderer.renderTree.wiki.addTiddler(new $tw.Tiddler({
title: this.storyTitle
},storyTiddler,{text: this.storyList.join("\n")}));
},storyTiddler,{list: this.storyList}));
};
NavigatorWidget.prototype.findTitleInStory = function(title,defaultIndex) {