mirror of
https://github.com/wickedest/Mergely.git
synced 2026-03-20 09:38:39 +08:00
Fixes sidebar click.
This commit is contained in:
@@ -1411,12 +1411,12 @@ jQuery.extend(Mgly.mergely.prototype, {
|
|||||||
ctx_rhs.fillRect(1.5, rfrom, 4.5, rto);
|
ctx_rhs.fillRect(1.5, rfrom, 4.5, rto);
|
||||||
|
|
||||||
ex.clhs.click(function (ev) {
|
ex.clhs.click(function (ev) {
|
||||||
var y = ev.pageY - ex.lhs_xyoffset.top - (to / 2);
|
var y = ev.pageY - ex.lhs_xyoffset.top - (lto / 2);
|
||||||
var sto = Math.max(0, (y / mcanvas_lhs.height) * ex.lhs_scroller.get(0).scrollHeight);
|
var sto = Math.max(0, (y / mcanvas_lhs.height) * ex.lhs_scroller.get(0).scrollHeight);
|
||||||
ex.lhs_scroller.scrollTop(sto);
|
ex.lhs_scroller.scrollTop(sto);
|
||||||
});
|
});
|
||||||
ex.crhs.click(function (ev) {
|
ex.crhs.click(function (ev) {
|
||||||
var y = ev.pageY - ex.rhs_xyoffset.top - (to / 2);
|
var y = ev.pageY - ex.rhs_xyoffset.top - (rto / 2);
|
||||||
var sto = Math.max(0, (y / mcanvas_rhs.height) * ex.rhs_scroller.get(0).scrollHeight);
|
var sto = Math.max(0, (y / mcanvas_rhs.height) * ex.rhs_scroller.get(0).scrollHeight);
|
||||||
ex.rhs_scroller.scrollTop(sto);
|
ex.rhs_scroller.scrollTop(sto);
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user