block status bar when image hovering
This commit is contained in:
parent
a09049472c
commit
268c5f592b
@ -2194,21 +2194,32 @@
|
|||||||
},
|
},
|
||||||
cb: {
|
cb: {
|
||||||
node: function(root) {
|
node: function(root) {
|
||||||
var thumb;
|
var a, thumb;
|
||||||
if (!(thumb = $('img[md5]', root))) {
|
if (!(thumb = $('img[md5]', root))) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
a = thumb.parentNode;
|
||||||
|
a.setAttribute('data-href', a.href);
|
||||||
|
a.removeAttribute('href');
|
||||||
$.bind(thumb, 'mouseover', imageHover.cb.mouseover);
|
$.bind(thumb, 'mouseover', imageHover.cb.mouseover);
|
||||||
$.bind(thumb, 'mousemove', ui.hover);
|
$.bind(thumb, 'mousemove', ui.hover);
|
||||||
return $.bind(thumb, 'mouseout', ui.hoverend);
|
$.bind(thumb, 'mouseout', ui.hoverend);
|
||||||
|
return $.bind(thumb, 'mouseout', imageHover.cb.mouseout);
|
||||||
},
|
},
|
||||||
mouseover: function(e) {
|
mouseover: function(e) {
|
||||||
var el;
|
var a, el;
|
||||||
|
a = this.parentNode;
|
||||||
|
a.href = a.dataset.href;
|
||||||
el = $('#iHover');
|
el = $('#iHover');
|
||||||
el.src = null;
|
el.src = null;
|
||||||
el.src = this.parentNode.href;
|
el.src = this.parentNode.href;
|
||||||
ui.el = el;
|
ui.el = el;
|
||||||
return $.show(el);
|
return $.show(el);
|
||||||
|
},
|
||||||
|
mouseout: function(e) {
|
||||||
|
var a;
|
||||||
|
a = this.parentNode;
|
||||||
|
return a.removeAttribute('href');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|||||||
@ -1681,15 +1681,24 @@ imageHover =
|
|||||||
cb:
|
cb:
|
||||||
node: (root) ->
|
node: (root) ->
|
||||||
return unless thumb = $ 'img[md5]', root
|
return unless thumb = $ 'img[md5]', root
|
||||||
|
a = thumb.parentNode
|
||||||
|
a.setAttribute 'data-href', a.href
|
||||||
|
a.removeAttribute 'href'
|
||||||
$.bind thumb, 'mouseover', imageHover.cb.mouseover
|
$.bind thumb, 'mouseover', imageHover.cb.mouseover
|
||||||
$.bind thumb, 'mousemove', ui.hover
|
$.bind thumb, 'mousemove', ui.hover
|
||||||
$.bind thumb, 'mouseout', ui.hoverend
|
$.bind thumb, 'mouseout', ui.hoverend
|
||||||
|
$.bind thumb, 'mouseout', imageHover.cb.mouseout
|
||||||
mouseover: (e) ->
|
mouseover: (e) ->
|
||||||
|
a = @parentNode
|
||||||
|
a.href = a.dataset.href
|
||||||
el = $ '#iHover'
|
el = $ '#iHover'
|
||||||
el.src = null
|
el.src = null
|
||||||
el.src = @parentNode.href
|
el.src = @parentNode.href
|
||||||
ui.el = el
|
ui.el = el
|
||||||
$.show el
|
$.show el
|
||||||
|
mouseout: (e) ->
|
||||||
|
a = @parentNode
|
||||||
|
a.removeAttribute 'href'
|
||||||
|
|
||||||
imgPreloading =
|
imgPreloading =
|
||||||
init: ->
|
init: ->
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user