msie-related code cleanup
This commit is contained in:
parent
569720c589
commit
f74cfded6f
6 changed files with 19 additions and 80 deletions
10
functions.js
10
functions.js
|
@ -11,10 +11,6 @@ Array.prototype.remove = function(s) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function is_msie() {
|
|
||||||
return navigator.userAgent.match("MSIE");
|
|
||||||
}
|
|
||||||
|
|
||||||
function is_opera() {
|
function is_opera() {
|
||||||
return window.opera;
|
return window.opera;
|
||||||
}
|
}
|
||||||
|
@ -28,7 +24,9 @@ function exception_error(location, e, silent) {
|
||||||
msg = "Exception: " + e.name + ", " + e.message +
|
msg = "Exception: " + e.name + ", " + e.message +
|
||||||
"\nFunction: " + location + "()" +
|
"\nFunction: " + location + "()" +
|
||||||
"\nLocation: " + base_fname + ":" + e.lineNumber;
|
"\nLocation: " + base_fname + ":" + e.lineNumber;
|
||||||
|
|
||||||
|
} else if (e.description) {
|
||||||
|
msg = "Exception: " + e.description + "\nFunction: " + location + "()";
|
||||||
} else {
|
} else {
|
||||||
msg = "Exception: " + e + "\nFunction: " + location + "()";
|
msg = "Exception: " + e + "\nFunction: " + location + "()";
|
||||||
}
|
}
|
||||||
|
@ -534,7 +532,7 @@ function parse_counters(reply, scheduled_call) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (has_img && feed_img && !is_msie()) {
|
if (has_img && feed_img) {
|
||||||
if (!feed_img.src.match(id + ".ico")) {
|
if (!feed_img.src.match(id + ".ico")) {
|
||||||
feed_img.src = getInitParam("icons_location") + "/" + id + ".ico";
|
feed_img.src = getInitParam("icons_location") + "/" + id + ".ico";
|
||||||
}
|
}
|
||||||
|
|
21
ie6.css
21
ie6.css
|
@ -1,21 +0,0 @@
|
||||||
#infoBoxTitle {
|
|
||||||
display : none;
|
|
||||||
}
|
|
||||||
|
|
||||||
#headlinesContainer {
|
|
||||||
width: expression(((parseInt(document.getElementById("headlines-frame").clientWidth)-2)+'px'));
|
|
||||||
}
|
|
||||||
|
|
||||||
#headlinesInnerContainer {
|
|
||||||
position : normal;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.headlines_normal {
|
|
||||||
overflow : auto;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.headlines_cdm {
|
|
||||||
overflow : auto;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
8
ie7.css
8
ie7.css
|
@ -1,8 +0,0 @@
|
||||||
/* div.prefsTabSelected {
|
|
||||||
bottom : 1px;
|
|
||||||
} */
|
|
||||||
|
|
||||||
table.headlinesList {
|
|
||||||
width: expression(((parseInt(document.getElementById("headlinesInnerContainer").clientWidth)-0)+'px'));
|
|
||||||
}
|
|
||||||
|
|
|
@ -46,15 +46,6 @@
|
||||||
<script type="text/javascript" src="functions.js?<?php echo $dt_add ?>"></script>
|
<script type="text/javascript" src="functions.js?<?php echo $dt_add ?>"></script>
|
||||||
<script type="text/javascript" src="prefs.js?<?php echo $dt_add ?>"></script>
|
<script type="text/javascript" src="prefs.js?<?php echo $dt_add ?>"></script>
|
||||||
|
|
||||||
<!--[if lt IE 7]>
|
|
||||||
<script type="text/javascript" src="pngfix.js"></script>
|
|
||||||
<link rel="stylesheet" type="text/css" href="ie6.css">
|
|
||||||
<![endif]-->
|
|
||||||
|
|
||||||
<!--[if IE 7]>
|
|
||||||
<link rel="stylesheet" type="text/css" href="ie7.css">
|
|
||||||
<![endif]-->
|
|
||||||
|
|
||||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
|
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
|
||||||
|
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
|
|
42
tt-rss.js
42
tt-rss.js
|
@ -383,7 +383,7 @@ function resize_headlines(delta_x, delta_y) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
debug("resize_headlines: HOR-mode");
|
debug("resize_headlines: HOR-mode: " + hor_offset);
|
||||||
|
|
||||||
c_frame.style.width = (400 + hor_offset) + "px";
|
c_frame.style.width = (400 + hor_offset) + "px";
|
||||||
h_frame.style.right = c_frame.offsetWidth - 1 + "px";
|
h_frame.style.right = c_frame.offsetWidth - 1 + "px";
|
||||||
|
@ -401,37 +401,20 @@ function resize_headlines(delta_x, delta_y) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
debug("resize_headlines: VER-mode");
|
debug("resize_headlines: VER-mode: " + ver_offset);
|
||||||
|
|
||||||
if (!is_msie()) {
|
h_frame.style.height = (300 - ver_offset) + "px";
|
||||||
h_frame.style.height = (300 - ver_offset) + "px";
|
|
||||||
|
|
||||||
c_frame.style.top = (h_frame.offsetTop + h_frame.offsetHeight + 1) + "px";
|
c_frame.style.top = (h_frame.offsetTop + h_frame.offsetHeight + 1) + "px";
|
||||||
h_frame.style.height = h_frame.offsetHeight + "px";
|
h_frame.style.height = h_frame.offsetHeight + "px";
|
||||||
|
|
||||||
var theme_c = 0;
|
var theme_c = 0;
|
||||||
|
|
||||||
if (getInitParam("theme") == "graycube") theme_c = 1;
|
if (getInitParam("theme") == "graycube") theme_c = 1;
|
||||||
|
|
||||||
resize_grab.style.top = (h_frame.offsetTop + h_frame.offsetHeight -
|
resize_grab.style.top = (h_frame.offsetTop + h_frame.offsetHeight -
|
||||||
4 - theme_c) + "px";
|
4 - theme_c) + "px";
|
||||||
resize_grab.style.display = "block";
|
resize_grab.style.display = "block";
|
||||||
|
|
||||||
} else {
|
|
||||||
h_frame.style.height = document.documentElement.clientHeight * 0.3 + "px";
|
|
||||||
c_frame.style.top = h_frame.offsetTop + h_frame.offsetHeight + 1 + "px";
|
|
||||||
|
|
||||||
var c_bottom = document.documentElement.clientHeight;
|
|
||||||
|
|
||||||
if (f_frame) {
|
|
||||||
c_bottom = f_frame.offsetTop;
|
|
||||||
}
|
|
||||||
|
|
||||||
c_frame.style.height = c_bottom - (h_frame.offsetTop +
|
|
||||||
h_frame.offsetHeight + 1) + "px";
|
|
||||||
h_frame.style.height = h_frame.offsetHeight + "px";
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -472,6 +455,11 @@ function init_second_stage() {
|
||||||
ver_offset = parseInt(getCookie("ttrss_offset_ver"));
|
ver_offset = parseInt(getCookie("ttrss_offset_ver"));
|
||||||
hor_offset = parseInt(getCookie("ttrss_offset_hor"));
|
hor_offset = parseInt(getCookie("ttrss_offset_hor"));
|
||||||
|
|
||||||
|
/* fuck IE */
|
||||||
|
|
||||||
|
if (isNaN(hor_offset)) hor_offset = 0;
|
||||||
|
if (isNaN(ver_offset)) ver_offset = 0;
|
||||||
|
|
||||||
debug("offsets from cookies [x:y]: " + hor_offset + ":" + ver_offset);
|
debug("offsets from cookies [x:y]: " + hor_offset + ":" + ver_offset);
|
||||||
|
|
||||||
resize_headlines();
|
resize_headlines();
|
||||||
|
|
|
@ -37,15 +37,6 @@
|
||||||
<link rel="stylesheet" type="text/css" href="<?php echo $user_css_url ?>"/>
|
<link rel="stylesheet" type="text/css" href="<?php echo $user_css_url ?>"/>
|
||||||
<?php } ?>
|
<?php } ?>
|
||||||
|
|
||||||
<!--[if lt IE 7]>
|
|
||||||
<script type="text/javascript" src="pngfix.js"></script>
|
|
||||||
<link rel="stylesheet" type="text/css" href="ie6.css">
|
|
||||||
<![endif]-->
|
|
||||||
|
|
||||||
<!--[if IE 7]>
|
|
||||||
<link rel="stylesheet" type="text/css" href="ie7.css">
|
|
||||||
<![endif]-->
|
|
||||||
|
|
||||||
<link rel="shortcut icon" type="image/png" href="images/favicon.png">
|
<link rel="shortcut icon" type="image/png" href="images/favicon.png">
|
||||||
|
|
||||||
<script type="text/javascript" src="prototype.js"></script>
|
<script type="text/javascript" src="prototype.js"></script>
|
||||||
|
|
Loading…
Reference in a new issue