[ticket/13059] Add core event to generate_page_link()

Add core event to generate_page_link() to allow overriding/modifying pagination URLs.
Event request: http://area51.phpbb.com/phpBB/viewtopic.php?f=111&t=45905

<a href="http://area51.phpbb.com/phpBB/viewtopic.php?f=111&t=45905">PHPBB3-13059</a>.
I'll try to fix the class as it can be required for other tests too in the future.