Make global.setImmediate work in browser process

This commit is contained in:
Cheng Zhao 2015-09-14 16:34:58 +08:00
parent d2e52fb6bb
commit 9d366e6c5c

View file

@ -45,6 +45,8 @@ if process.type is 'browser'
# recalculate the timeout in browser process.
global.setTimeout = wrapWithActivateUvLoop timers.setTimeout
global.setInterval = wrapWithActivateUvLoop timers.setInterval
global.setImmediate = wrapWithActivateUvLoop timers.setImmediate
global.clearImmediate = wrapWithActivateUvLoop timers.clearImmediate
else
# There are no setImmediate under renderer process by default, so we need to
# manually setup them here.