Add existence checks for scrolling functions since they are missing on Firefox. Closes GH-1