Publish Vulpes Preview 15 sources for desktop, Android and Tundra
Share Gaia assets and adapters, keep private profiles and development documents local, and update both public READMEs.
This commit is contained in:
parent
93e3a48004
commit
b38dea0597
25901 changed files with 9982925 additions and 369 deletions
33
gaia/apps/settings/test/marionette/mocks/mock_navigator_moz_bluetooth.js
Executable file
33
gaia/apps/settings/test/marionette/mocks/mock_navigator_moz_bluetooth.js
Executable file
|
|
@ -0,0 +1,33 @@
|
|||
/*global Components, Services */
|
||||
'use strict';
|
||||
|
||||
var Cu = Components.utils;
|
||||
Cu.import('resource://gre/modules/Services.jsm');
|
||||
|
||||
Services.obs.addObserver(function(document) {
|
||||
if (!document || !document.location) {
|
||||
return;
|
||||
}
|
||||
|
||||
var window = document.defaultView;
|
||||
var _bluetooth = {
|
||||
isConnected: function() { return false; },
|
||||
getDefaultAdapter: function() { return new window.Object(); },
|
||||
addEventListener: function() {},
|
||||
enabled: false,
|
||||
onenabled: null,
|
||||
ondisabled: null,
|
||||
onadapteradded: null
|
||||
};
|
||||
|
||||
Object.defineProperty(window.wrappedJSObject.navigator, 'mozBluetooth', {
|
||||
configurable: false,
|
||||
writable: false,
|
||||
value: Cu.cloneInto(
|
||||
_bluetooth,
|
||||
window,
|
||||
{cloneFunctions: true}
|
||||
)
|
||||
});
|
||||
|
||||
}, 'document-element-inserted', false);
|
||||
|
|
@ -0,0 +1,21 @@
|
|||
/*global Components, Services */
|
||||
'use strict';
|
||||
|
||||
Components.utils.import('resource://gre/modules/Services.jsm');
|
||||
|
||||
Services.obs.addObserver(function(document) {
|
||||
if (!document || !document.location) {
|
||||
return;
|
||||
}
|
||||
|
||||
var window = document.defaultView.wrappedJSObject;
|
||||
var _mobileConnections = new document.defaultView.Array({});
|
||||
|
||||
Object.defineProperty(window.navigator, 'mozMobileConnections', {
|
||||
configurable: false,
|
||||
get: function() {
|
||||
return _mobileConnections;
|
||||
}
|
||||
});
|
||||
|
||||
}, 'document-element-inserted', false);
|
||||
|
|
@ -0,0 +1,21 @@
|
|||
/*global Components, Services */
|
||||
'use strict';
|
||||
|
||||
Components.utils.import('resource://gre/modules/Services.jsm');
|
||||
|
||||
Services.obs.addObserver(function(document) {
|
||||
if (!document || !document.location) {
|
||||
return;
|
||||
}
|
||||
|
||||
var window = document.defaultView.wrappedJSObject;
|
||||
var _mobileConnections = new document.defaultView.Array({}, {});
|
||||
|
||||
Object.defineProperty(window.navigator, 'mozMobileConnections', {
|
||||
configurable: false,
|
||||
get: function() {
|
||||
return _mobileConnections;
|
||||
}
|
||||
});
|
||||
|
||||
}, 'document-element-inserted', false);
|
||||
19
gaia/apps/settings/test/marionette/mocks/mock_navigator_moz_telephony.js
Executable file
19
gaia/apps/settings/test/marionette/mocks/mock_navigator_moz_telephony.js
Executable file
|
|
@ -0,0 +1,19 @@
|
|||
/*global Components, Services */
|
||||
'use strict';
|
||||
|
||||
Components.utils.import('resource://gre/modules/Services.jsm');
|
||||
|
||||
Services.obs.addObserver(function(document) {
|
||||
if (!document || !document.location) {
|
||||
return;
|
||||
}
|
||||
|
||||
var window = document.defaultView.wrappedJSObject;
|
||||
Object.defineProperty(window.navigator, 'mozTelephony', {
|
||||
configurable: false,
|
||||
get: function() {
|
||||
return {};
|
||||
}
|
||||
});
|
||||
|
||||
}, 'document-element-inserted', false);
|
||||
23
gaia/apps/settings/test/marionette/mocks/mock_navigator_moz_wifi_manager.js
Executable file
23
gaia/apps/settings/test/marionette/mocks/mock_navigator_moz_wifi_manager.js
Executable file
|
|
@ -0,0 +1,23 @@
|
|||
/*global Components, Services */
|
||||
'use strict';
|
||||
|
||||
var Cu = Components.utils;
|
||||
Cu.import('resource://gre/modules/Services.jsm');
|
||||
|
||||
Services.obs.addObserver(function(document) {
|
||||
if (!document || !document.location) {
|
||||
return;
|
||||
}
|
||||
|
||||
var window = document.defaultView;
|
||||
Object.defineProperty(window.wrappedJSObject.navigator, 'mozWifiManager', {
|
||||
configurable: false,
|
||||
writable: false,
|
||||
value: Cu.cloneInto(
|
||||
{enabled: false},
|
||||
window,
|
||||
{cloneFunctions: true}
|
||||
)
|
||||
});
|
||||
|
||||
}, 'document-element-inserted', false);
|
||||
Loading…
Reference in a new issue