mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Merge m-c to s-c.
This commit is contained in:
commit
085d71296a
@ -52,10 +52,17 @@ const nsIPropertyElement = Components.interfaces.nsIPropertyElement;
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// OS detect
|
||||
const MAC = (navigator.platform.indexOf("Mac") != -1)? true : false;
|
||||
const LINUX = (navigator.platform.indexOf("Linux") != -1)? true : false;
|
||||
const SOLARIS = (navigator.platform.indexOf("SunOS") != -1)? true : false;
|
||||
const WIN = (navigator.platform.indexOf("Win") != -1)? true : false;
|
||||
|
||||
const MAC = (navigator.platform.indexOf("Mac") != -1);
|
||||
const LINUX = (navigator.platform.indexOf("Linux") != -1);
|
||||
const SOLARIS = (navigator.platform.indexOf("SunOS") != -1);
|
||||
const WIN = (navigator.platform.indexOf("Win") != -1);
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// Application detect
|
||||
// Firefox is assumed by default.
|
||||
|
||||
const SEAMONKEY = navigator.userAgent.match(/ SeaMonkey\//);
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// Accessible general
|
||||
|
@ -382,6 +382,12 @@
|
||||
var gInitQueue = null;
|
||||
function initTests()
|
||||
{
|
||||
if (SEAMONKEY) {
|
||||
todo(false, "Skipping this test on SeaMonkey ftb. (Bug 718237)");
|
||||
SimpleTest.finish();
|
||||
return;
|
||||
}
|
||||
|
||||
// register 'test-a11y-search' autocomplete search
|
||||
initAutoComplete([ "hello", "hi" ],
|
||||
[ "Beep beep'm beep beep yeah", "Baby you can drive my car" ]);
|
||||
|
@ -52,7 +52,7 @@
|
||||
};
|
||||
|
||||
// SeaMonkey and Firefox tabbrowser UIs differ.
|
||||
if ("restoreTab" in tabBrowser) {
|
||||
if (SEAMONKEY) {
|
||||
SimpleTest.ok(true, "Testing SeaMonkey tabbrowser UI.");
|
||||
|
||||
tabsAccTree.children.splice(0, 0,
|
||||
|
@ -37,21 +37,6 @@ XPCOMUtils.defineLazyServiceGetter(Services, 'fm', function(){
|
||||
.getService(Ci.nsFocusManager);
|
||||
});
|
||||
|
||||
|
||||
// In order to use http:// scheme instead of file:// scheme
|
||||
// (that is much more restricted) the following code kick-off
|
||||
// a local http server listening on http://127.0.0.1:7777 and
|
||||
// http://localhost:7777.
|
||||
function startupHttpd(baseDir, port) {
|
||||
const httpdURL = 'chrome://browser/content/httpd.js';
|
||||
let httpd = {};
|
||||
Services.scriptloader.loadSubScript(httpdURL, httpd);
|
||||
let server = new httpd.nsHttpServer();
|
||||
server.registerDirectory('/', new LocalFile(baseDir));
|
||||
server.registerContentType('appcache', 'text/cache-manifest');
|
||||
server.start(port);
|
||||
}
|
||||
|
||||
// FIXME Bug 707625
|
||||
// until we have a proper security model, add some rights to
|
||||
// the pre-installed web applications
|
||||
@ -70,7 +55,6 @@ function addPermissions(urls) {
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
var shell = {
|
||||
// FIXME/bug 678695: this should be a system setting
|
||||
preferredScreenBrightness: 1.0,
|
||||
@ -121,17 +105,7 @@ var shell = {
|
||||
|
||||
let fileScheme = 'file://';
|
||||
if (homeURL.substring(0, fileScheme.length) == fileScheme) {
|
||||
homeURL = homeURL.replace(fileScheme, '');
|
||||
|
||||
let baseDir = homeURL.split('/');
|
||||
baseDir.pop();
|
||||
baseDir = baseDir.join('/');
|
||||
|
||||
const SERVER_PORT = 6666;
|
||||
startupHttpd(baseDir, SERVER_PORT);
|
||||
|
||||
let baseHost = 'http://localhost';
|
||||
homeURL = homeURL.replace(baseDir, baseHost + ':' + SERVER_PORT);
|
||||
homeURL = 'http://localhost:7777' + homeURL.replace(fileScheme, '');
|
||||
}
|
||||
addPermissions([homeURL]);
|
||||
} catch (e) {
|
||||
@ -139,12 +113,12 @@ var shell = {
|
||||
return alert(msg);
|
||||
}
|
||||
|
||||
// Load webapi+apps.js as a frame script
|
||||
// Load webapi.js as a frame script
|
||||
let frameScriptUrl = 'chrome://browser/content/webapi.js';
|
||||
try {
|
||||
messageManager.loadFrameScript(frameScriptUrl, true);
|
||||
} catch (e) {
|
||||
dump('Error when loading ' + frameScriptUrl + ' as a frame script: ' + e + '\n');
|
||||
dump('Error loading ' + frameScriptUrl + ' as a frame script: ' + e + '\n');
|
||||
}
|
||||
|
||||
let browser = this.contentBrowser;
|
||||
|
@ -140,9 +140,9 @@ static PRLogModuleInfo* gJSDiagnostics;
|
||||
|
||||
// The amount of time we wait between a request to CC (after GC ran)
|
||||
// and doing the actual CC.
|
||||
#define NS_CC_DELAY 5000 // ms
|
||||
#define NS_CC_DELAY 6000 // ms
|
||||
|
||||
#define NS_CC_SKIPPABLE_DELAY 250 // ms
|
||||
#define NS_CC_SKIPPABLE_DELAY 400 // ms
|
||||
|
||||
#define NS_CC_FORCED (5 * 60 * PR_USEC_PER_SEC) // 5 min
|
||||
|
||||
|
@ -275,7 +275,7 @@ GonkCameraInputStream::Init(nsACString& aContentType, nsCaptureParams* aParams)
|
||||
mHeight = aParams->height;
|
||||
mCamera = aParams->camera;
|
||||
|
||||
PRUint32 maxNumCameras = 2;//getNumberOfCameras();
|
||||
PRUint32 maxNumCameras = getNumberOfCameras();
|
||||
|
||||
if (maxNumCameras == 0)
|
||||
return NS_ERROR_FAILURE;
|
||||
|
Loading…
Reference in New Issue
Block a user