Applied javascript_debugging_WIP_v.0.6.diff by Yves.