Merge pull request #1457 from ether/fix-IE8-error

fixes IE8 error by only redifining if firefox
This commit is contained in:
John McLear 2013-02-06 15:43:18 -08:00
commit a9436f290a
2 changed files with 18 additions and 7 deletions

View file

@ -156,10 +156,15 @@ function Ace2Inner(){
// Ugly hack for Firefox 18
// get the timeout and interval methods from the parent iframe
setTimeout = parent.setTimeout;
clearTimeout = parent.clearTimeout;
setInterval = parent.setInterval;
clearInterval = parent.clearInterval;
// This hack breaks IE8
try{
setTimeout = parent.setTimeout;
clearTimeout = parent.clearTimeout;
setInterval = parent.setInterval;
clearInterval = parent.clearInterval;
}catch(err){
// IE8 can panic here.
}
var textFace = 'monospace';
var textSize = 12;

View file

@ -64,7 +64,8 @@
box-shadow: 0px 1px 8px rgba(0,0,0,0.3);
}
#inner {
width: 300px;
position:relative;
max-width: 300px;
margin: 0 auto;
}
#button {
@ -100,6 +101,10 @@
text-shadow: 0 1px 1px #fff;
margin: 16px auto 0;
}
#padname{
height:38px;
max-width:280px;
}
form {
height: 38px;
background: #fff;
@ -115,7 +120,8 @@
border-radius: 3px;
box-sizing: border-box;
-moz-box-sizing: border-box;
padding: 0 45px 0 10px;
line-height:36px; /* IE8 hack */
padding: 0px 45px 0 10px;
*padding: 0; /* IE7 hack */
width: 100%;
height: 100%;
@ -125,7 +131,7 @@
}
button[type="submit"] {
position: absolute;
right: 0;
left:253px;
width: 45px;
height: 38px;
}