Commit 18b1221d authored by Kjetil Thuen's avatar Kjetil Thuen

Allways register click handlers

parent 1b5ef985
......@@ -167,7 +167,7 @@
};
var registerEventHandlers = function() {
var registerWindowEventHandlers = function() {
$(window).bind('scrollstart', function(){
if (scrollListenersEnabled) {
scrollInProgress = true;
......@@ -189,15 +189,9 @@
}
});
peekedList.children("li").click(function() {
setSelectedElement($(this).get(), true);
});
$(window).resize(function() {
debounce(resetGeometry, 500, false)();
});
handlersRegistered = true;
};
$.fn.listEntryInfo = function(options) {
......@@ -253,9 +247,14 @@
centerOfHeadline = $('#' + settings.sightScopeId).offset().top - $(window).scrollTop() + ($('#' + settings.sightScopeId).height() / 2);
if (!handlersRegistered) {
registerEventHandlers();
registerWindowEventHandlers();
}
peekedList.children("li").click(function() {
setSelectedElement($(this).get(), true);
});
resetGeometry();
return this;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment