Fixed disconnecting wrong signal callback on webview after main loop exited. Also set pointer to main loop to NULL after unref.