diff --git a/demo/keyboard_shortcuts.html b/demo/keyboard_shortcuts.html
new file mode 100644
index 00000000..4a579d37
--- /dev/null
+++ b/demo/keyboard_shortcuts.html
@@ -0,0 +1,46 @@
+
+
+
+
+
+ Editor
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/demo/kitchen-sink/demo.js b/demo/kitchen-sink/demo.js
index d51134df..e624541a 100644
--- a/demo/kitchen-sink/demo.js
+++ b/demo/kitchen-sink/demo.js
@@ -33,7 +33,8 @@ define(function(require, exports, module) {
"use strict";
require("ace/lib/fixoldbrowsers");
-require("ace/config").init();
+var config = require("ace/config");
+config.init();
var env = {};
var dom = require("ace/lib/dom");
@@ -151,6 +152,15 @@ env.editor.commands.addCommands([{
editor.cmdLine.setValue(r + "")
},
readOnly: true
+}, {
+ name: "showKeyboardShortcuts",
+ bindKey: {win: "Ctrl-Alt-h", mac: "Command-Alt-h"},
+ exec: function(editor) {
+ config.loadModule("ace/ext/keybinding_menu", function(module) {
+ module.init(editor);
+ editor.showKeyboardShortcuts()
+ })
+ }
}]);
diff --git a/demo/modelist.html b/demo/modelist.html
index da46acf6..99b02e8a 100644
--- a/demo/modelist.html
+++ b/demo/modelist.html
@@ -21,24 +21,10 @@
-var editor = ace.edit("editor");
-editor.setTheme("ace/theme/twilight");
-(function () {
- var modelist = ace.require('ace/ext/modelist');
- // the file path could come from an xmlhttp request, a drop event,
- // or any other scriptable file loading process.
- // Extensions could consume the modelist and use it to dynamically
- // set the editor mode. Webmasters could use it in their scripts
- // for site specific purposes as well.
- var filePath = 'blahblah/weee/some.js';
- var mode = modelist.getModeFromPath(filePath).mode;
- console.log(mode);
- editor.getSession().setMode(mode);
-}());
-
+
-
-
+
+
+