grabber offset storage fixes

This commit is contained in:
Andrew Dolgov 2008-05-20 05:08:36 +01:00
parent d16a515917
commit 0fb6ae042f
2 changed files with 8 additions and 6 deletions

View File

@ -478,7 +478,8 @@ function mouse_move_handler(e) {
client_y = window.event.clientY; client_y = window.event.clientY;
client_x = window.event.clientX; client_x = window.event.clientX;
} else if (e) { } else if (e) {
client_x = e.screenX;
client_y = e.screenY;
} }
if (mouse_is_down) { if (mouse_is_down) {

View File

@ -359,7 +359,7 @@ function init() {
function resize_headlines(delta_x, delta_y) { function resize_headlines(delta_x, delta_y) {
debug("resize_headlines: " + hor_offset + ":" + ver_offset); debug("resize_headlines: " + delta_x + ":" + delta_y);
var h_frame = document.getElementById("headlines-frame"); var h_frame = document.getElementById("headlines-frame");
var c_frame = document.getElementById("content-frame"); var c_frame = document.getElementById("content-frame");
@ -450,7 +450,6 @@ function init_second_stage() {
delCookie("ttrss_vf_test"); delCookie("ttrss_vf_test");
// document.onresize = resize_headlines; // document.onresize = resize_headlines;
resize_headlines();
var toolbar = document.forms["main_toolbar_form"]; var toolbar = document.forms["main_toolbar_form"];
@ -466,10 +465,12 @@ function init_second_stage() {
loading_set_progress(60); loading_set_progress(60);
ver_offset = getCookie("ttrss_offset_ver"); ver_offset = parseInt(getCookie("ttrss_offset_ver"));
hor_offset = parseInt(getCookie("ttrss_offset_hor"));
if (!ver_offset || ver_offset == undefined || ver_offset == 'undefined') ver_offset = 0; debug("offsets from cookies [x:y]: " + hor_offset + ":" + ver_offset);
if (!hor_offset || hor_offset == undefined || hor_offset == 'undefined') hor_offset = 0;
resize_headlines();
} catch (e) { } catch (e) {
exception_error("init_second_stage", e); exception_error("init_second_stage", e);