mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2026-09-12 04:45:42 +00:00
Get rid of the wikivocabulary object
This commit is contained in:
@@ -20,11 +20,15 @@ var WidgetRenderer = function(renderTree,renderContext,parseTreeNode) {
|
||||
this.renderTree = renderTree;
|
||||
this.renderContext = renderContext;
|
||||
this.parseTreeNode = parseTreeNode;
|
||||
// Widget classes
|
||||
if(!this.widgetClasses) {
|
||||
WidgetRenderer.prototype.widgetClasses = $tw.modules.createClassesFromModules("widget",null,$tw.WidgetBase);
|
||||
}
|
||||
// Compute our attributes
|
||||
this.attributes = {};
|
||||
this.computeAttributes();
|
||||
// Create the widget object
|
||||
var WidgetClass = this.renderTree.parser.vocabulary.widgetClasses[this.parseTreeNode.tag];
|
||||
var WidgetClass = this.widgetClasses[this.parseTreeNode.tag];
|
||||
if(WidgetClass) {
|
||||
this.widget = new WidgetClass();
|
||||
this.widget.init(this);
|
||||
|
||||
Reference in New Issue
Block a user