var prevPos
$('body').on('mousedown', function (evt) {
$(this).on('mousemove', drag)
prevPos = {x:evt.clientX, y:evt.clientY}
}).on('mouseup mouseout', function() {
$(this).off('mousemove', drag)
})
function drag(evt) {
window.scrollBy(prevPos.x - evt.clientX, prevPos.y - evt.clientY) // вся магия здесь
prevPos = {x:evt.clientX, y:evt.clientY}
}