mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2025-02-08 23:20:03 +00:00
Fix scrollable widget not to crash on the server
This commit is contained in:
parent
945ad6792f
commit
79d643775d
@ -20,6 +20,7 @@ var ScrollableWidget = function(parseTreeNode,options) {
|
|||||||
this.addEventListeners([
|
this.addEventListeners([
|
||||||
{type: "tw-scroll", handler: "handleScrollEvent"}
|
{type: "tw-scroll", handler: "handleScrollEvent"}
|
||||||
]);
|
]);
|
||||||
|
if($tw.browser) {
|
||||||
this.requestAnimationFrame = window.requestAnimationFrame ||
|
this.requestAnimationFrame = window.requestAnimationFrame ||
|
||||||
window.webkitRequestAnimationFrame ||
|
window.webkitRequestAnimationFrame ||
|
||||||
window.mozRequestAnimationFrame ||
|
window.mozRequestAnimationFrame ||
|
||||||
@ -34,6 +35,7 @@ var ScrollableWidget = function(parseTreeNode,options) {
|
|||||||
function(id) {
|
function(id) {
|
||||||
window.clearTimeout(id);
|
window.clearTimeout(id);
|
||||||
};
|
};
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
Loading…
x
Reference in New Issue
Block a user