mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Merge b2g-inbound to m-c
This commit is contained in:
commit
f8bb8da7ea
@ -19,7 +19,7 @@
|
||||
<copyfile dest="Makefile" src="core/root.mk"/>
|
||||
</project>
|
||||
<project name="fake-dalvik" path="dalvik" remote="b2g" revision="ca1f327d5acc198bb4be62fa51db2c039032c9ce"/>
|
||||
<project name="gaia.git" path="gaia" remote="mozillaorg" revision="40abb245b1e61df67757ba3747e2f73202e5182b"/>
|
||||
<project name="gaia.git" path="gaia" remote="mozillaorg" revision="ef66efa34ed8a559c8998bde688fae88eb943a7a"/>
|
||||
<project name="gonk-misc" path="gonk-misc" remote="b2g" revision="996b5c6a2fd2b8a0124c0eab80eb72a4daece7bc"/>
|
||||
<project name="rilproxy" path="rilproxy" remote="b2g" revision="827214fcf38d6569aeb5c6d6f31cb296d1f09272"/>
|
||||
<project name="platform_hardware_ril" path="hardware/ril" remote="b2g" revision="ca283b9db2b151d465cfd2e19346cf58fe89e413"/>
|
||||
|
@ -17,7 +17,7 @@
|
||||
</project>
|
||||
<project name="rilproxy" path="rilproxy" remote="b2g" revision="827214fcf38d6569aeb5c6d6f31cb296d1f09272"/>
|
||||
<project name="fake-libdvm" path="dalvik" remote="b2g" revision="d50ae982b19f42f0b66d08b9eb306be81687869f"/>
|
||||
<project name="gaia" path="gaia" remote="mozillaorg" revision="40abb245b1e61df67757ba3747e2f73202e5182b"/>
|
||||
<project name="gaia" path="gaia" remote="mozillaorg" revision="ef66efa34ed8a559c8998bde688fae88eb943a7a"/>
|
||||
<project name="gonk-misc" path="gonk-misc" remote="b2g" revision="996b5c6a2fd2b8a0124c0eab80eb72a4daece7bc"/>
|
||||
<project name="moztt" path="external/moztt" remote="b2g" revision="ce95d372e6d285725b96490afdaaf489ad8f9ca9"/>
|
||||
<project name="apitrace" path="external/apitrace" remote="apitrace" revision="8a4baf82a131a7853cf7e7f9cf74253927b2f355"/>
|
||||
|
@ -15,7 +15,7 @@
|
||||
<project name="platform_build" path="build" remote="b2g" revision="65fba428f8d76336b33ddd9e15900357953600ba">
|
||||
<copyfile dest="Makefile" src="core/root.mk"/>
|
||||
</project>
|
||||
<project name="gaia" path="gaia" remote="mozillaorg" revision="40abb245b1e61df67757ba3747e2f73202e5182b"/>
|
||||
<project name="gaia" path="gaia" remote="mozillaorg" revision="ef66efa34ed8a559c8998bde688fae88eb943a7a"/>
|
||||
<project name="fake-libdvm" path="dalvik" remote="b2g" revision="d50ae982b19f42f0b66d08b9eb306be81687869f"/>
|
||||
<project name="gonk-misc" path="gonk-misc" remote="b2g" revision="996b5c6a2fd2b8a0124c0eab80eb72a4daece7bc"/>
|
||||
<project name="moztt" path="external/moztt" remote="b2g" revision="ce95d372e6d285725b96490afdaaf489ad8f9ca9"/>
|
||||
|
@ -19,7 +19,7 @@
|
||||
<copyfile dest="Makefile" src="core/root.mk"/>
|
||||
</project>
|
||||
<project name="fake-dalvik" path="dalvik" remote="b2g" revision="ca1f327d5acc198bb4be62fa51db2c039032c9ce"/>
|
||||
<project name="gaia.git" path="gaia" remote="mozillaorg" revision="40abb245b1e61df67757ba3747e2f73202e5182b"/>
|
||||
<project name="gaia.git" path="gaia" remote="mozillaorg" revision="ef66efa34ed8a559c8998bde688fae88eb943a7a"/>
|
||||
<project name="gonk-misc" path="gonk-misc" remote="b2g" revision="996b5c6a2fd2b8a0124c0eab80eb72a4daece7bc"/>
|
||||
<project name="rilproxy" path="rilproxy" remote="b2g" revision="827214fcf38d6569aeb5c6d6f31cb296d1f09272"/>
|
||||
<project name="platform_hardware_ril" path="hardware/ril" remote="b2g" revision="ca283b9db2b151d465cfd2e19346cf58fe89e413"/>
|
||||
|
@ -18,7 +18,7 @@
|
||||
<project name="rilproxy" path="rilproxy" remote="b2g" revision="827214fcf38d6569aeb5c6d6f31cb296d1f09272"/>
|
||||
<project name="librecovery" path="librecovery" remote="b2g" revision="891e5069c0ad330d8191bf8c7b879c814258c89f"/>
|
||||
<project name="fake-libdvm" path="dalvik" remote="b2g" revision="d50ae982b19f42f0b66d08b9eb306be81687869f"/>
|
||||
<project name="gaia" path="gaia" remote="mozillaorg" revision="40abb245b1e61df67757ba3747e2f73202e5182b"/>
|
||||
<project name="gaia" path="gaia" remote="mozillaorg" revision="ef66efa34ed8a559c8998bde688fae88eb943a7a"/>
|
||||
<project name="gonk-misc" path="gonk-misc" remote="b2g" revision="996b5c6a2fd2b8a0124c0eab80eb72a4daece7bc"/>
|
||||
<project name="moztt" path="external/moztt" remote="b2g" revision="ce95d372e6d285725b96490afdaaf489ad8f9ca9"/>
|
||||
<project name="apitrace" path="external/apitrace" remote="apitrace" revision="8a4baf82a131a7853cf7e7f9cf74253927b2f355"/>
|
||||
|
@ -4,6 +4,6 @@
|
||||
"remote": "",
|
||||
"branch": ""
|
||||
},
|
||||
"revision": "54d21654d085dfc74541b847ccbcc105caa8856a",
|
||||
"revision": "21652299e03788cc0a8481cdab94718ac7b42dda",
|
||||
"repo_path": "/integration/gaia-central"
|
||||
}
|
||||
|
@ -17,7 +17,7 @@
|
||||
<copyfile dest="Makefile" src="core/root.mk"/>
|
||||
</project>
|
||||
<project name="fake-dalvik" path="dalvik" remote="b2g" revision="ca1f327d5acc198bb4be62fa51db2c039032c9ce"/>
|
||||
<project name="gaia.git" path="gaia" remote="mozillaorg" revision="40abb245b1e61df67757ba3747e2f73202e5182b"/>
|
||||
<project name="gaia.git" path="gaia" remote="mozillaorg" revision="ef66efa34ed8a559c8998bde688fae88eb943a7a"/>
|
||||
<project name="gonk-misc" path="gonk-misc" remote="b2g" revision="996b5c6a2fd2b8a0124c0eab80eb72a4daece7bc"/>
|
||||
<project name="rilproxy" path="rilproxy" remote="b2g" revision="827214fcf38d6569aeb5c6d6f31cb296d1f09272"/>
|
||||
<project name="librecovery" path="librecovery" remote="b2g" revision="891e5069c0ad330d8191bf8c7b879c814258c89f"/>
|
||||
|
@ -15,7 +15,7 @@
|
||||
<copyfile dest="Makefile" src="core/root.mk"/>
|
||||
</project>
|
||||
<project name="fake-dalvik" path="dalvik" remote="b2g" revision="ca1f327d5acc198bb4be62fa51db2c039032c9ce"/>
|
||||
<project name="gaia.git" path="gaia" remote="mozillaorg" revision="40abb245b1e61df67757ba3747e2f73202e5182b"/>
|
||||
<project name="gaia.git" path="gaia" remote="mozillaorg" revision="ef66efa34ed8a559c8998bde688fae88eb943a7a"/>
|
||||
<project name="gonk-misc" path="gonk-misc" remote="b2g" revision="996b5c6a2fd2b8a0124c0eab80eb72a4daece7bc"/>
|
||||
<project name="rilproxy" path="rilproxy" remote="b2g" revision="827214fcf38d6569aeb5c6d6f31cb296d1f09272"/>
|
||||
<project name="librecovery" path="librecovery" remote="b2g" revision="891e5069c0ad330d8191bf8c7b879c814258c89f"/>
|
||||
|
@ -19,7 +19,7 @@
|
||||
<copyfile dest="Makefile" src="core/root.mk"/>
|
||||
</project>
|
||||
<project name="fake-dalvik" path="dalvik" remote="b2g" revision="ca1f327d5acc198bb4be62fa51db2c039032c9ce"/>
|
||||
<project name="gaia.git" path="gaia" remote="mozillaorg" revision="40abb245b1e61df67757ba3747e2f73202e5182b"/>
|
||||
<project name="gaia.git" path="gaia" remote="mozillaorg" revision="ef66efa34ed8a559c8998bde688fae88eb943a7a"/>
|
||||
<project name="gonk-misc" path="gonk-misc" remote="b2g" revision="996b5c6a2fd2b8a0124c0eab80eb72a4daece7bc"/>
|
||||
<project name="rilproxy" path="rilproxy" remote="b2g" revision="827214fcf38d6569aeb5c6d6f31cb296d1f09272"/>
|
||||
<project name="librecovery" path="librecovery" remote="b2g" revision="891e5069c0ad330d8191bf8c7b879c814258c89f"/>
|
||||
|
@ -17,7 +17,7 @@
|
||||
<copyfile dest="Makefile" src="core/root.mk"/>
|
||||
</project>
|
||||
<project name="fake-dalvik" path="dalvik" remote="b2g" revision="ca1f327d5acc198bb4be62fa51db2c039032c9ce"/>
|
||||
<project name="gaia.git" path="gaia" remote="mozillaorg" revision="40abb245b1e61df67757ba3747e2f73202e5182b"/>
|
||||
<project name="gaia.git" path="gaia" remote="mozillaorg" revision="ef66efa34ed8a559c8998bde688fae88eb943a7a"/>
|
||||
<project name="gonk-misc" path="gonk-misc" remote="b2g" revision="996b5c6a2fd2b8a0124c0eab80eb72a4daece7bc"/>
|
||||
<project name="rilproxy" path="rilproxy" remote="b2g" revision="827214fcf38d6569aeb5c6d6f31cb296d1f09272"/>
|
||||
<project name="librecovery" path="librecovery" remote="b2g" revision="891e5069c0ad330d8191bf8c7b879c814258c89f"/>
|
||||
|
@ -17,7 +17,7 @@
|
||||
</project>
|
||||
<project name="rilproxy" path="rilproxy" remote="b2g" revision="827214fcf38d6569aeb5c6d6f31cb296d1f09272"/>
|
||||
<project name="fake-libdvm" path="dalvik" remote="b2g" revision="d50ae982b19f42f0b66d08b9eb306be81687869f"/>
|
||||
<project name="gaia" path="gaia" remote="mozillaorg" revision="40abb245b1e61df67757ba3747e2f73202e5182b"/>
|
||||
<project name="gaia" path="gaia" remote="mozillaorg" revision="ef66efa34ed8a559c8998bde688fae88eb943a7a"/>
|
||||
<project name="gonk-misc" path="gonk-misc" remote="b2g" revision="996b5c6a2fd2b8a0124c0eab80eb72a4daece7bc"/>
|
||||
<project name="moztt" path="external/moztt" remote="b2g" revision="ce95d372e6d285725b96490afdaaf489ad8f9ca9"/>
|
||||
<project name="apitrace" path="external/apitrace" remote="apitrace" revision="8a4baf82a131a7853cf7e7f9cf74253927b2f355"/>
|
||||
|
@ -17,7 +17,7 @@
|
||||
<copyfile dest="Makefile" src="core/root.mk"/>
|
||||
</project>
|
||||
<project name="fake-dalvik" path="dalvik" remote="b2g" revision="ca1f327d5acc198bb4be62fa51db2c039032c9ce"/>
|
||||
<project name="gaia.git" path="gaia" remote="mozillaorg" revision="40abb245b1e61df67757ba3747e2f73202e5182b"/>
|
||||
<project name="gaia.git" path="gaia" remote="mozillaorg" revision="ef66efa34ed8a559c8998bde688fae88eb943a7a"/>
|
||||
<project name="gonk-misc" path="gonk-misc" remote="b2g" revision="996b5c6a2fd2b8a0124c0eab80eb72a4daece7bc"/>
|
||||
<project name="rilproxy" path="rilproxy" remote="b2g" revision="827214fcf38d6569aeb5c6d6f31cb296d1f09272"/>
|
||||
<project name="librecovery" path="librecovery" remote="b2g" revision="891e5069c0ad330d8191bf8c7b879c814258c89f"/>
|
||||
|
@ -1534,12 +1534,12 @@ int64_t FileMediaResource::Tell()
|
||||
NS_ASSERTION(!NS_IsMainThread(), "Don't call on main thread");
|
||||
|
||||
MutexAutoLock lock(mLock);
|
||||
if (!mSeekable)
|
||||
return 0;
|
||||
EnsureSizeInitialized();
|
||||
|
||||
int64_t offset = 0;
|
||||
mSeekable->Tell(&offset);
|
||||
// Return mSize as offset (end of stream) in case of error
|
||||
if (!mSeekable || NS_FAILED(mSeekable->Tell(&offset)))
|
||||
return mSize;
|
||||
return offset;
|
||||
}
|
||||
|
||||
|
@ -17,6 +17,9 @@ Cu.import("resource://gre/modules/DownloadsIPC.jsm");
|
||||
XPCOMUtils.defineLazyServiceGetter(this, "cpmm",
|
||||
"@mozilla.org/childprocessmessagemanager;1",
|
||||
"nsIMessageSender");
|
||||
XPCOMUtils.defineLazyServiceGetter(this, "volumeService",
|
||||
"@mozilla.org/telephony/volume-service;1",
|
||||
"nsIVolumeService");
|
||||
|
||||
function debug(aStr) {
|
||||
#ifdef MOZ_DEBUG
|
||||
@ -207,6 +210,8 @@ function DOMDownloadImpl() {
|
||||
this.currentBytes = 0;
|
||||
this.url = null;
|
||||
this.path = null;
|
||||
this.storageName = null;
|
||||
this.storagePath = null;
|
||||
this.contentType = null;
|
||||
|
||||
/* fields that require getters/setters */
|
||||
@ -308,17 +313,47 @@ DOMDownloadImpl.prototype = {
|
||||
return;
|
||||
}
|
||||
|
||||
let props = ["totalBytes", "currentBytes", "url", "path", "state",
|
||||
"contentType", "startTime"];
|
||||
let props = ["totalBytes", "currentBytes", "url", "path", "storageName",
|
||||
"storagePath", "state", "contentType", "startTime"];
|
||||
let changed = false;
|
||||
let changedProps = {};
|
||||
|
||||
props.forEach((prop) => {
|
||||
if (aDownload[prop] && (aDownload[prop] != this[prop])) {
|
||||
this[prop] = aDownload[prop];
|
||||
changed = true;
|
||||
changedProps[prop] = changed = true;
|
||||
}
|
||||
});
|
||||
|
||||
// When the path changes, we should update the storage name and
|
||||
// storage path used for our downloaded file in case our download
|
||||
// was re-targetted to a different storage and/or filename.
|
||||
if (changedProps["path"]) {
|
||||
let storages = this._window.navigator.getDeviceStorages("sdcard");
|
||||
let preferredStorageName;
|
||||
// Use the first one or the default storage. Just like jsdownloads picks
|
||||
// the default / preferred download directory.
|
||||
storages.forEach((aStorage) => {
|
||||
if (aStorage.default || !preferredStorageName) {
|
||||
preferredStorageName = aStorage.storageName;
|
||||
}
|
||||
});
|
||||
// Now get the path for this storage area.
|
||||
let volume;
|
||||
if (preferredStorageName) {
|
||||
let volume = volumeService.getVolumeByName(preferredStorageName);
|
||||
if (volume) {
|
||||
// Finally, create the relative path of the file that can be used
|
||||
// later on to retrieve the file via DeviceStorage. Our path
|
||||
// needs to omit the starting '/'.
|
||||
this.storageName = preferredStorageName;
|
||||
this.storagePath =
|
||||
this.path.substring(this.path.indexOf(volume.mountPoint) +
|
||||
volume.mountPoint.length + 1);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (aDownload.error) {
|
||||
//
|
||||
// When we get a generic error failure back from the js downloads api
|
||||
|
@ -54,10 +54,17 @@ interface DOMDownload : EventTarget {
|
||||
// The url of the resource.
|
||||
readonly attribute DOMString url;
|
||||
|
||||
// The path in local storage where the file will end up once the download
|
||||
// The full path in local storage where the file will end up once the download
|
||||
// is complete.
|
||||
readonly attribute DOMString path;
|
||||
|
||||
// The DeviceStorage volume name on which the file is being downloaded.
|
||||
readonly attribute DOMString storageName;
|
||||
|
||||
// The DeviceStorage path on the volume with 'storageName' of the file being
|
||||
// downloaded.
|
||||
readonly attribute DOMString storagePath;
|
||||
|
||||
// The state of the download.
|
||||
readonly attribute DownloadState state;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user