Fixed #8710 - Position: collision: "flip" doesn't work for my: "right top", at: "right bottom" (in some situations)

Bug #8719

Reverted this commit: https://github.com/jquery/jquery-ui/commit/7f808b2047725cd8fde51a948cb4e5f5946c82e1

The intention of the commit is unclear.. I added unit tests to show that the code before that commit already did what it aimed to fix.

http://bugs.jqueryui.com/ticket/8710