Check if currentWidget is None in tabbed_browser.on_mode_left.

Fixes #186.