Disable sigint handler by default and add an isMainThread() function

r=jhanssen
Add flags to EventLoop and kill setMainEventLoop