diff editor.js @ 23:068d63627b16

Populate in scope symbol buttons when clicking on a symbol in the source
author Mike Pavone <pavone@retrodev.com>
date Mon, 26 Mar 2012 21:29:03 -0700
parents a5ef5af3df0f
children 4d87c38404d6
line wrap: on
line diff
--- a/editor.js	Mon Mar 26 00:06:13 2012 -0700
+++ b/editor.js	Mon Mar 26 21:29:03 2012 -0700
@@ -93,8 +93,12 @@
 };
 
 symbol.prototype.toHTML = function(node) {
+	var astNode = this;
 	node.appendChild(newEl('span', {
 		className: 'symbol',
-		textContent: this.name
+		textContent: this.name,
+		onclick: function() {
+			return mainModule.symbolClick(this, astNode);
+		}
 	}));
 }