Fix IPC on Windows by making SendMessage() call return immediately

This commit is contained in:
Simon Kornblith 2011-07-03 03:07:01 +00:00
parent 5710fbc530
commit 67c81db102

View file

@ -338,11 +338,12 @@ ZoteroCommandLineHandler.prototype = {
}
// handler for Windows IPC commands
var param = cmdLine.handleFlagWithParam("ZoteroIPC", false);
if(param) {
var ipcParam = cmdLine.handleFlagWithParam("ZoteroIPC", false);
if(ipcParam) {
// Don't open a new window
cmdLine.preventDefault = true;
this.Zotero.IPC.parsePipeInput(param);
var Zotero = this.Zotero;
Zotero.setTimeout(function() { Zotero.IPC.parsePipeInput(ipcParam) }, 0);
}
// special handler for "zotero" URIs at the command line to prevent them from opening a new