I have made the style change and noInheritAttribute change requested in pull #433.

This commit is contained in:
Davide P. Cervone 2013-05-01 15:42:46 -04:00
parent a7d9bf314b
commit e724a2559c
2 changed files with 7 additions and 5 deletions

View File

@ -56,6 +56,11 @@
"background-color":"white", opacity:0, filter:"alpha(opacity=0)" "background-color":"white", opacity:0, filter:"alpha(opacity=0)"
}, },
"#MathJax_ZoomFrame": {
position:"relative", display:"inline-block",
height:0, width:0
},
"#MathJax_ZoomEventTrap": { "#MathJax_ZoomEventTrap": {
position:"absolute", left:0, top:0, "z-index":302, position:"absolute", left:0, top:0, "z-index":302,
display:"inline-block", border:0, padding:0, margin:0, display:"inline-block", border:0, padding:0, margin:0,
@ -135,10 +140,7 @@
var Mw = Math.floor(.85*document.body.clientWidth), var Mw = Math.floor(.85*document.body.clientWidth),
Mh = Math.floor(.85*Math.max(document.body.clientHeight,document.documentElement.clientHeight)); Mh = Math.floor(.85*Math.max(document.body.clientHeight,document.documentElement.clientHeight));
var div = HTML.Element( var div = HTML.Element(
"span",{ "span",{id:"MathJax_ZoomFrame"},[
style: {position:"relative", display:"inline-block", height:0, width:0},
id:"MathJax_ZoomFrame"
},[
["span",{id:"MathJax_ZoomOverlay", onmousedown:this.Remove}], ["span",{id:"MathJax_ZoomOverlay", onmousedown:this.Remove}],
["span",{ ["span",{
id:"MathJax_Zoom", onclick:this.Remove, id:"MathJax_Zoom", onclick:this.Remove,

View File

@ -283,7 +283,7 @@ MathJax.ElementJax.mml.Augment({
var obj = this.inherit; var root = obj; var obj = this.inherit; var root = obj;
while (obj) { while (obj) {
var value = obj[name]; if (value == null && obj.attr) {value = obj.attr[name]} var value = obj[name]; if (value == null && obj.attr) {value = obj.attr[name]}
if (value != null && !obj.noInheritAttribute[name]) { if (value != null && obj.noInheritAttribute && !obj.noInheritAttribute[name]) {
var noInherit = obj.noInherit[this.type]; var noInherit = obj.noInherit[this.type];
if (!(noInherit && noInherit[name])) {return value} if (!(noInherit && noInherit[name])) {return value}
} }