зеркало из https://github.com/mozilla/gecko-dev.git
Backed out changeset 2483596f62ef (bug 1245064)
This commit is contained in:
Родитель
f06c52d3e1
Коммит
b685a90a5e
|
@ -451,14 +451,19 @@ GeckoDriver.prototype.registerBrowser = function(id, be) {
|
|||
|
||||
this.curBrowser.elementManager.seenItems[reg.id] =
|
||||
Cu.getWeakReference(listenerWindow);
|
||||
let flags = {
|
||||
B2G: (this.appName == "B2G"),
|
||||
raisesAccessibilityExceptions:
|
||||
this.sessionCapabilities.raisesAccessibilityExceptions
|
||||
};
|
||||
if (nullPrevious && (this.curBrowser.curFrameId !== null)) {
|
||||
this.sendAsync("newSession", this.sessionCapabilities, this.newSessionCommandId);
|
||||
this.sendAsync("newSession", flags, this.newSessionCommandId);
|
||||
if (this.curBrowser.isNewSession) {
|
||||
this.newSessionCommandId = null;
|
||||
}
|
||||
}
|
||||
|
||||
return [reg, mainContent, this.sessionCapabilities];
|
||||
return [reg, mainContent, flags];
|
||||
};
|
||||
|
||||
GeckoDriver.prototype.registerPromise = function() {
|
||||
|
@ -2893,7 +2898,12 @@ GeckoDriver.prototype.receiveMessage = function(message) {
|
|||
// If remoteness gets updated we need to call newSession. In the case
|
||||
// of desktop this just sets up a small amount of state that doesn't
|
||||
// change over the course of a session.
|
||||
this.sendAsync("newSession", this.sessionCapabilities);
|
||||
let newSessionValues = {
|
||||
B2G: (this.appName == "B2G"),
|
||||
raisesAccessibilityExceptions:
|
||||
this.sessionCapabilities.raisesAccessibilityExceptions
|
||||
};
|
||||
this.sendAsync("newSession", newSessionValues);
|
||||
this.curBrowser.flushPendingCommands();
|
||||
}
|
||||
break;
|
||||
|
|
|
@ -109,7 +109,7 @@ function registerSelf() {
|
|||
if (register[0]) {
|
||||
let {id, remotenessChange} = register[0][0];
|
||||
capabilities = register[0][2];
|
||||
isB2G = capabilities.platformName == "B2G";
|
||||
isB2G = capabilities.B2G;
|
||||
listenerId = id;
|
||||
if (typeof id != "undefined") {
|
||||
// check if we're the main process
|
||||
|
@ -300,7 +300,7 @@ function waitForReady() {
|
|||
*/
|
||||
function newSession(msg) {
|
||||
capabilities = msg.json;
|
||||
isB2G = capabilities.platformName == "B2G";
|
||||
isB2G = capabilities.B2G;
|
||||
resetValues();
|
||||
if (isB2G) {
|
||||
readyStateTimer.initWithCallback(waitForReady, 100, Ci.nsITimer.TYPE_ONE_SHOT);
|
||||
|
|
Загрузка…
Ссылка в новой задаче