Redo paging, small fixes

This should solve some of the problems @mohit was seeing. The page listener has somewhat of a side-effect to rerequest and get the function name back in the dialog.