make code independent from open-browser

The open-browser plugin is still used but there is also some original code to
compensate for its absence.  There are still some FIXME markers in the code
to improve the tests for different operating systems.