Permalink
Browse files

Downcase the sh_lang variable.

* Allows us to use @@@ javascript
* Change the execute to take this into account.
  • Loading branch information...
1 parent 6d1d7e8 commit 399590d5f95c969449010f216053c81af9f41514 @andersjanmyr andersjanmyr committed Mar 20, 2011
Showing with 4 additions and 4 deletions.
  1. +1 −1 example/two/slidesA.md
  2. +1 −1 lib/showoff.rb
  3. +2 −2 public/js/showoff.js
View
@@ -22,7 +22,7 @@
# Executable JavaScript #
- @@@ javaScript
+ @@@ javascript
result = 3 + 3;
!SLIDE
View
@@ -162,7 +162,7 @@ def update_commandline_code(slide)
lines = out.split("\n")
if lines.first[0, 3] == '@@@'
lang = lines.shift.gsub('@@@', '').strip
- pre.set_attribute('class', 'sh_' + lang)
+ pre.set_attribute('class', 'sh_' + lang.downcase)
code.content = lines.join("\n")
end
end
View
@@ -320,7 +320,7 @@ function keyDown(event)
gotoSlidenum = 0;
} else {
debug('executeCode');
- executeCode.call($('.sh_javaScript code:visible'));
+ executeCode.call($('.sh_javascript code:visible'));
}
}
@@ -465,7 +465,7 @@ function executeCode () {
setTimeout(function() { codeDiv.removeClass("executing");}, 250 );
if (result != null) print(result);
}
-$('.sh_javaScript code').live("click", executeCode);
+$('.sh_javascript code').live("click", executeCode);
/********************

0 comments on commit 399590d

Please sign in to comment.