Moved browser-specific code to separate adapter.