Add XPCOM clearTimeout() and remove Zotero.wait()
Properly emulate setTimeout() with support for cancelling timers.
This commit is contained in:
parent
a285e97815
commit
6907af86fd
2 changed files with 31 additions and 69 deletions
|
@ -178,7 +178,11 @@ ZoteroContext.prototype = {
|
|||
* Convenience method to replicate window.setTimeout()
|
||||
**/
|
||||
"setTimeout":function setTimeout(func, ms){
|
||||
this.Zotero.setTimeout(func, ms);
|
||||
return this.Zotero.setTimeout(func, ms);
|
||||
},
|
||||
|
||||
"clearTimeout":function setTimeout(id) {
|
||||
this.Zotero.clearTimeout(id);
|
||||
},
|
||||
|
||||
/**
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue