Permalink
Browse files

Fix UI bugs

  • Loading branch information...
1 parent 96fa356 commit 1d746b24359c707f811d1dd8035980ee35e22d62 @syg committed Sep 6, 2011
Showing with 7 additions and 8 deletions.
  1. +6 −7 data/app.js
  2. +1 −1 data/inferscraper.js
View
@@ -16,9 +16,10 @@ function initializeWithSpew(spew) {
el.removeAttr("style");
el.addClass("clickableTypeset");
el.click(clickSourceTypeset);
- var kids = el.find("span");
- kids.addClass("clickableTypeset");
- kids.click(clickSourceTypeset);
+ }
+
+ function doNothing(e) {
+ e.stopPropagation();
}
/* |el| is the element to show the bubble around. */
@@ -47,9 +48,7 @@ function initializeWithSpew(spew) {
el.css({ position: "relative", "z-index": 1000 });
el.removeClass("clickableTypeset");
el.unbind("click");
- var kids = el.find("span");
- kids.removeClass("clickableTypeset");
- kids.unbind("click");
+ el.click(doNothing);
}
function toggleClickable(el, klass, f) {
@@ -112,7 +111,7 @@ function initializeWithSpew(spew) {
el.html("");
if (path) {
/* We are sure #typeset is in the source text. */
- displayId = "typeset";
+ displayId = $("#typeset > h3").html();
for (var i = 0; i < path.length; i++) {
id = path[i].source;
/*
View
@@ -169,7 +169,7 @@ var InferScraper = (function () {
break;
case RESOLVE:
- if (addQueue.length === 1) {
+ if (addQueue.length) {
add = addQueue.pop();
var constraint = this.constraints[op.constraint];
if (!constraint)

0 comments on commit 1d746b2

Please sign in to comment.