Corrects keys and focusing on popup boxes.
This commit is contained in:
parent
94b0d7d1ee
commit
516874b50c
|
@ -29,7 +29,13 @@
|
|||
|
||||
var STIXURL = "http://www.stixfonts.org/";
|
||||
var MENU = MathJax.Menu;
|
||||
var FALSE, KEY;
|
||||
HUB.Register.StartupHook("MathEvents Ready",function () {
|
||||
FALSE = MathJax.Extension.MathEvents.Event.False;
|
||||
KEY = MathJax.Extension.MathEvents.Event.KEY;
|
||||
});
|
||||
|
||||
|
||||
var CONFIG = HUB.CombineConfig("HelpDialog",{
|
||||
|
||||
styles: {
|
||||
|
@ -104,7 +110,7 @@
|
|||
id: "MathJax_Help", tabIndex: 0, onkeydown: HELP.Keydown
|
||||
},LOCALE._("HelpDialog",[
|
||||
["b",{style:{fontSize:"120%"}},[["Help","MathJax Help"]]],
|
||||
["div",{id: "MathJax_HelpContent"},[
|
||||
["div",{id: "MathJax_HelpContent", tabIndex: 0},[
|
||||
["p",{},[["MathJax",
|
||||
"*MathJax* is a JavaScript library that allows page authors to include " +
|
||||
"mathematics within their web pages. As a reader, you don't need to do " +
|
||||
|
@ -173,8 +179,9 @@
|
|||
HELP.Keydown = function(event) {
|
||||
if (event.keyCode === KEY.ESCAPE ||
|
||||
(this.id === 'MathJax_HelpClose' &&
|
||||
(event.keyCode === KEY.SPACE || event.keyCode === KEY.Return))) {
|
||||
(event.keyCode === KEY.SPACE || event.keyCode === KEY.RETURN))) {
|
||||
HELP.Remove(event);
|
||||
FALSE(event);
|
||||
}
|
||||
},
|
||||
|
||||
|
|
|
@ -1026,7 +1026,7 @@
|
|||
display:"inline-block", "text-align":"left", "font-size":"80%",
|
||||
"max-height":"20em", overflow:"auto",
|
||||
"background-color":"#E4E4E4", padding:".4em .6em", border:"1px inset"
|
||||
}},jax],["br"],["br"],
|
||||
}, tabIndex: 0},jax],["br"],["br"],
|
||||
["a",{href:"http://www.mathjax.org/"},["www.mathjax.org"]],
|
||||
["span",{className:"MathJax_MenuClose",id:"MathJax_AboutClose",
|
||||
onclick:MENU.About.Remove,
|
||||
|
@ -1053,8 +1053,9 @@
|
|||
MENU.About.Keydown = function(event) {
|
||||
if (event.keyCode === KEY.ESCAPE ||
|
||||
(this.id === 'MathJax_AboutClose' &&
|
||||
(event.keyCode === KEY.SPACE || event.keyCode === KEY.Return))) {
|
||||
(event.keyCode === KEY.SPACE || event.keyCode === KEY.RETURN))) {
|
||||
MENU.About.Remove(event);
|
||||
FALSE(event);
|
||||
}
|
||||
},
|
||||
MENU.About.GetJax = function (jax,JAX,type,noTypeCheck) {
|
||||
|
|
Loading…
Reference in New Issue
Block a user