Force opening in fg when opening a JS-window.

Fixes #174.