Update rbox.js

more flexible rbox, also taking scroll into account