mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-15 06:15:43 +00:00
Bug 1230847 - Use increasing value as id for runEmulatorCmd and runEmulatorShell. r=ato
--HG-- extra : commitid : 5Sl2Yge4LNO extra : rebase_source : 57a16f6ee3e2fae4177f137263546d5e0f6c5cba extra : amend_source : f3de7188493a5ef64c2e7ff96cad0e7abf9bba9a
This commit is contained in:
parent
0501ee71ad
commit
31a7f4d9c9
@ -1903,23 +1903,26 @@ function getAppCacheStatus(msg) {
|
||||
}
|
||||
|
||||
// emulator callbacks
|
||||
var _emu_cb_id = 0;
|
||||
var _emu_cbs = {};
|
||||
|
||||
function runEmulatorCmd(cmd, callback) {
|
||||
logger.info("listener runEmulatorCmd cmd=" + cmd);
|
||||
if (callback) {
|
||||
_emu_cbs[asyncTestCommandId] = callback;
|
||||
_emu_cbs[_emu_cb_id] = callback;
|
||||
}
|
||||
sendAsyncMessage("Marionette:runEmulatorCmd",
|
||||
{command: cmd, id: asyncTestCommandId});
|
||||
{command: cmd, id: _emu_cb_id});
|
||||
_emu_cb_id += 1;
|
||||
}
|
||||
|
||||
function runEmulatorShell(args, callback) {
|
||||
if (callback) {
|
||||
_emu_cbs[asyncTestCommandId] = callback;
|
||||
_emu_cbs[_emu_cb_id] = callback;
|
||||
}
|
||||
sendAsyncMessage("Marionette:runEmulatorShell",
|
||||
{arguments: args, id: asyncTestCommandId});
|
||||
{arguments: args, id: _emu_cb_id});
|
||||
_emu_cb_id += 1;
|
||||
}
|
||||
|
||||
function emulatorCmdResult(msg) {
|
||||
|
Loading…
Reference in New Issue
Block a user