Merge m-c to inbound a=merge
authorWes Kocher <wkocher@mozilla.com>
Wed, 31 Dec 2014 17:14:50 -0800
changeset 247618 9261135074f81237a4605abe449e031ca626b2e8
parent 247617 f7dbc64435bcf9aecdd969230d5f48bb41f89dad (current diff)
parent 247605 3c296aa11c51df594590eccee16c9f639d2b5f1d (diff)
child 247619 2b1ce9e015a43cc6bba46cf0d8a98b945d63000e
push id4489
push userraliiev@mozilla.com
push dateMon, 23 Feb 2015 15:17:55 +0000
treeherdermozilla-beta@fd7c3dc24146 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmerge
milestone37.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Merge m-c to inbound a=merge
--- a/b2g/config/dolphin/sources.xml
+++ b/b2g/config/dolphin/sources.xml
@@ -10,25 +10,25 @@
   <!--original fetch url was git://codeaurora.org/-->
   <remote fetch="https://git.mozilla.org/external/caf" name="caf"/>
   <!--original fetch url was https://git.mozilla.org/releases-->
   <remote fetch="https://git.mozilla.org/releases" name="mozillaorg"/>
   <!-- B2G specific things. -->
   <project name="platform_build" path="build" remote="b2g" revision="e0c735ec89df011ea7dd435087a9045ecff9ff9e">
     <copyfile dest="Makefile" src="core/root.mk"/>
   </project>
-  <project name="gaia" path="gaia" remote="mozillaorg" revision="334532c0fcb809ac1c8bcd64a8eb9357967acf36"/>
+  <project name="gaia" path="gaia" remote="mozillaorg" revision="fce979e88240aba9f106c41b299151d3676bed99"/>
   <project name="fake-libdvm" path="dalvik" remote="b2g" revision="d50ae982b19f42f0b66d08b9eb306be81687869f"/>
   <project name="gonk-misc" path="gonk-misc" remote="b2g" revision="8aee09c106f479f36c57b2a29af72d455e359211"/>
   <project name="librecovery" path="librecovery" remote="b2g" revision="891e5069c0ad330d8191bf8c7b879c814258c89f"/>
   <project name="moztt" path="external/moztt" remote="b2g" revision="fe893bb760a3bb64375f62fdf4762a58c59df9ef"/>
   <project name="rilproxy" path="rilproxy" remote="b2g" revision="827214fcf38d6569aeb5c6d6f31cb296d1f09272"/>
   <project name="valgrind" path="external/valgrind" remote="b2g" revision="daa61633c32b9606f58799a3186395fd2bbb8d8c"/>
   <project name="vex" path="external/VEX" remote="b2g" revision="47f031c320888fe9f3e656602588565b52d43010"/>
-  <project name="apitrace" path="external/apitrace" remote="apitrace" revision="8aefd1be86268fed59946173a9f5ebabce4b8e29"/>
+  <project name="apitrace" path="external/apitrace" remote="apitrace" revision="abc4f384bc4bb9c709d4f526176ab41eff3f14fe"/>
   <!-- Stock Android things -->
   <project groups="linux" name="platform/prebuilts/gcc/linux-x86/host/i686-linux-glibc2.7-4.6" path="prebuilts/gcc/linux-x86/host/i686-linux-glibc2.7-4.6" revision="95bb5b66b3ec5769c3de8d3f25d681787418e7d2"/>
   <project groups="linux" name="platform/prebuilts/gcc/linux-x86/host/x86_64-linux-glibc2.7-4.6" path="prebuilts/gcc/linux-x86/host/x86_64-linux-glibc2.7-4.6" revision="ebdad82e61c16772f6cd47e9f11936bf6ebe9aa0"/>
   <project groups="linux,arm" name="platform/prebuilts/gcc/linux-x86/arm/arm-eabi-4.7" path="prebuilts/gcc/linux-x86/arm/arm-eabi-4.7" revision="8b880805d454664b3eed11d0f053cdeafa1ff06e"/>
   <project groups="linux,arm" name="platform/prebuilts/gcc/linux-x86/arm/arm-linux-androideabi-4.7" path="prebuilts/gcc/linux-x86/arm/arm-linux-androideabi-4.7" revision="a1e239a0bb5cd1d69680bf1075883aa9a7bf2429"/>
   <project groups="linux,x86" name="platform/prebuilts/gcc/linux-x86/x86/i686-linux-android-4.7" path="prebuilts/gcc/linux-x86/x86/i686-linux-android-4.7" revision="c7931763d41be602407ed9d71e2c0292c6597e00"/>
   <project groups="linux,x86" name="platform/prebuilts/python/linux-x86/2.7.5" path="prebuilts/python/linux-x86/2.7.5" revision="83760d213fb3bec7b4117d266fcfbf6fe2ba14ab"/>
   <project name="device/common" path="device/common" revision="6a2995683de147791e516aae2ccb31fdfbe2ad30"/>
@@ -124,17 +124,17 @@
   <project name="platform/system/security" path="system/security" revision="ee8068b9e7bfb2770635062fc9c2035be2142bd8"/>
   <project name="platform/system/vold" path="system/vold" revision="2e43efe1b30d0b98574d293059556aebd2f46454"/>
   <!--original fetch url was http://sprdsource.spreadtrum.com:8085/b2g/android-->
   <remote fetch="https://git.mozilla.org/external/sprd-aosp" name="sprd-aosp"/>
   <default remote="sprd-aosp" revision="sprdb2g_gonk4.4" sync-j="4"/>
   <!-- Stock Android things -->
   <project name="platform/external/icu4c" path="external/icu4c" revision="2bb01561780583cc37bc667f0ea79f48a122d8a2"/>
   <!-- dolphin specific things -->
-  <project name="device/sprd" path="device/sprd" revision="a229a5650aab7ff9ce47d1ca2c998ffbf6119ed7"/>
+  <project name="device/sprd" path="device/sprd" revision="de8bac99d1af4326cbd96bcb9fe76a95b7f41c8a"/>
   <project name="platform/external/wpa_supplicant_8" path="external/wpa_supplicant_8" revision="4e58336019b5cbcfd134caf55b142236cf986618"/>
   <project name="platform/frameworks/av" path="frameworks/av" revision="4387fe988e5a1001f29ce05fcfda03ed2d32137b"/>
   <project name="platform/hardware/akm" path="hardware/akm" revision="6d3be412647b0eab0adff8a2768736cf4eb68039"/>
   <project groups="invensense" name="platform/hardware/invensense" path="hardware/invensense" revision="e6d9ab28b4f4e7684f6c07874ee819c9ea0002a2"/>
   <project name="platform/hardware/ril" path="hardware/ril" revision="865ce3b4a2ba0b3a31421ca671f4d6c5595f8690"/>
   <project name="kernel/common" path="kernel" revision="6c6f012cea17fb8b3263605737816cf6663432f1"/>
   <project name="platform/system/core" path="system/core" revision="53d584d4a4b4316e4de9ee5f210d662f89b44e7e"/>
   <project name="u-boot" path="u-boot" revision="982c1fd67b89d5573317c1796cf5b0143de44e8a"/>
--- a/b2g/config/emulator-ics/sources.xml
+++ b/b2g/config/emulator-ics/sources.xml
@@ -14,23 +14,23 @@
   <!--original fetch url was git://github.com/apitrace/-->
   <remote fetch="https://git.mozilla.org/external/apitrace" name="apitrace"/>
   <default remote="caf" revision="refs/tags/android-4.0.4_r2.1" sync-j="4"/>
   <!-- Gonk specific things and forks -->
   <project name="platform_build" path="build" remote="b2g" revision="df362ace56338da8173d30d3e09e08c42c1accfa">
     <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="334532c0fcb809ac1c8bcd64a8eb9357967acf36"/>
+  <project name="gaia.git" path="gaia" remote="mozillaorg" revision="fce979e88240aba9f106c41b299151d3676bed99"/>
   <project name="gonk-misc" path="gonk-misc" remote="b2g" revision="8aee09c106f479f36c57b2a29af72d455e359211"/>
   <project name="rilproxy" path="rilproxy" remote="b2g" revision="827214fcf38d6569aeb5c6d6f31cb296d1f09272"/>
   <project name="platform_hardware_ril" path="hardware/ril" remote="b2g" revision="d5d3f93914558b6f168447b805cd799c8233e300"/>
   <project name="platform_external_qemu" path="external/qemu" remote="b2g" revision="6fa7a4936414ceb4055fd27f7a30e76790f834fb"/>
   <project name="moztt" path="external/moztt" remote="b2g" revision="fe893bb760a3bb64375f62fdf4762a58c59df9ef"/>
-  <project name="apitrace" path="external/apitrace" remote="apitrace" revision="8aefd1be86268fed59946173a9f5ebabce4b8e29"/>
+  <project name="apitrace" path="external/apitrace" remote="apitrace" revision="abc4f384bc4bb9c709d4f526176ab41eff3f14fe"/>
   <!-- Stock Android things -->
   <project name="platform/abi/cpp" path="abi/cpp" revision="dd924f92906085b831bf1cbbc7484d3c043d613c"/>
   <project name="platform/bionic" path="bionic" revision="c72b8f6359de7ed17c11ddc9dfdde3f615d188a9"/>
   <project name="platform/bootable/recovery" path="bootable/recovery" revision="425f8b5fadf5889834c5acd27d23c9e0b2129c28"/>
   <project name="device/common" path="device/common" revision="42b808b7e93d0619286ae8e59110b176b7732389"/>
   <project name="device/sample" path="device/sample" revision="237bd668d0f114d801a8d6455ef5e02cc3577587"/>
   <project name="platform_external_apriori" path="external/apriori" remote="b2g" revision="11816ad0406744f963537b23d68ed9c2afb412bd"/>
   <project name="platform/external/bluetooth/bluez" path="external/bluetooth/bluez" revision="52a1a862a8bac319652b8f82d9541ba40bfa45ce"/>
--- a/b2g/config/emulator-jb/sources.xml
+++ b/b2g/config/emulator-jb/sources.xml
@@ -12,20 +12,20 @@
   <!--original fetch url was https://git.mozilla.org/releases-->
   <remote fetch="https://git.mozilla.org/releases" name="mozillaorg"/>
   <!-- B2G specific things. -->
   <project name="platform_build" path="build" remote="b2g" revision="0e94c080bee081a50aa2097527b0b40852f9143f">
     <copyfile dest="Makefile" src="core/root.mk"/>
   </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="334532c0fcb809ac1c8bcd64a8eb9357967acf36"/>
+  <project name="gaia" path="gaia" remote="mozillaorg" revision="fce979e88240aba9f106c41b299151d3676bed99"/>
   <project name="gonk-misc" path="gonk-misc" remote="b2g" revision="8aee09c106f479f36c57b2a29af72d455e359211"/>
   <project name="moztt" path="external/moztt" remote="b2g" revision="fe893bb760a3bb64375f62fdf4762a58c59df9ef"/>
-  <project name="apitrace" path="external/apitrace" remote="apitrace" revision="8aefd1be86268fed59946173a9f5ebabce4b8e29"/>
+  <project name="apitrace" path="external/apitrace" remote="apitrace" revision="abc4f384bc4bb9c709d4f526176ab41eff3f14fe"/>
   <project name="valgrind" path="external/valgrind" remote="b2g" revision="daa61633c32b9606f58799a3186395fd2bbb8d8c"/>
   <project name="vex" path="external/VEX" remote="b2g" revision="47f031c320888fe9f3e656602588565b52d43010"/>
   <!-- Stock Android things -->
   <project groups="linux" name="platform/prebuilts/clang/linux-x86/3.1" path="prebuilts/clang/linux-x86/3.1" revision="5c45f43419d5582949284eee9cef0c43d866e03b"/>
   <project groups="linux" name="platform/prebuilts/clang/linux-x86/3.2" path="prebuilts/clang/linux-x86/3.2" revision="3748b4168e7bd8d46457d4b6786003bc6a5223ce"/>
   <project groups="linux" name="platform/prebuilts/gcc/linux-x86/host/i686-linux-glibc2.7-4.6" path="prebuilts/gcc/linux-x86/host/i686-linux-glibc2.7-4.6" revision="9025e50b9d29b3cabbbb21e1dd94d0d13121a17e"/>
   <project groups="linux" name="platform/prebuilts/gcc/linux-x86/host/x86_64-linux-glibc2.7-4.6" path="prebuilts/gcc/linux-x86/host/x86_64-linux-glibc2.7-4.6" revision="b89fda71fcd0fa0cf969310e75be3ea33e048b44"/>
   <project groups="linux,arm" name="platform/prebuilts/gcc/linux-x86/arm/arm-eabi-4.7" path="prebuilts/gcc/linux-x86/arm/arm-eabi-4.7" revision="2e7d5348f35575870b3c7e567a9a9f6d66f8d6c5"/>
--- a/b2g/config/emulator-kk/sources.xml
+++ b/b2g/config/emulator-kk/sources.xml
@@ -10,25 +10,25 @@
   <!--original fetch url was git://codeaurora.org/-->
   <remote fetch="https://git.mozilla.org/external/caf" name="caf"/>
   <!--original fetch url was https://git.mozilla.org/releases-->
   <remote fetch="https://git.mozilla.org/releases" name="mozillaorg"/>
   <!-- B2G specific things. -->
   <project name="platform_build" path="build" remote="b2g" revision="e0c735ec89df011ea7dd435087a9045ecff9ff9e">
     <copyfile dest="Makefile" src="core/root.mk"/>
   </project>
-  <project name="gaia" path="gaia" remote="mozillaorg" revision="334532c0fcb809ac1c8bcd64a8eb9357967acf36"/>
+  <project name="gaia" path="gaia" remote="mozillaorg" revision="fce979e88240aba9f106c41b299151d3676bed99"/>
   <project name="fake-libdvm" path="dalvik" remote="b2g" revision="d50ae982b19f42f0b66d08b9eb306be81687869f"/>
   <project name="gonk-misc" path="gonk-misc" remote="b2g" revision="8aee09c106f479f36c57b2a29af72d455e359211"/>
   <project name="librecovery" path="librecovery" remote="b2g" revision="891e5069c0ad330d8191bf8c7b879c814258c89f"/>
   <project name="moztt" path="external/moztt" remote="b2g" revision="fe893bb760a3bb64375f62fdf4762a58c59df9ef"/>
   <project name="rilproxy" path="rilproxy" remote="b2g" revision="827214fcf38d6569aeb5c6d6f31cb296d1f09272"/>
   <project name="valgrind" path="external/valgrind" remote="b2g" revision="daa61633c32b9606f58799a3186395fd2bbb8d8c"/>
   <project name="vex" path="external/VEX" remote="b2g" revision="47f031c320888fe9f3e656602588565b52d43010"/>
-  <project name="apitrace" path="external/apitrace" remote="apitrace" revision="8aefd1be86268fed59946173a9f5ebabce4b8e29"/>
+  <project name="apitrace" path="external/apitrace" remote="apitrace" revision="abc4f384bc4bb9c709d4f526176ab41eff3f14fe"/>
   <!-- Stock Android things -->
   <project groups="linux" name="platform/prebuilts/gcc/linux-x86/host/i686-linux-glibc2.7-4.6" path="prebuilts/gcc/linux-x86/host/i686-linux-glibc2.7-4.6" revision="f92a936f2aa97526d4593386754bdbf02db07a12"/>
   <project groups="linux" name="platform/prebuilts/gcc/linux-x86/host/x86_64-linux-glibc2.7-4.6" path="prebuilts/gcc/linux-x86/host/x86_64-linux-glibc2.7-4.6" revision="6e47ff2790f5656b5b074407829ceecf3e6188c4"/>
   <project groups="linux,arm" name="platform/prebuilts/gcc/linux-x86/arm/arm-eabi-4.7" path="prebuilts/gcc/linux-x86/arm/arm-eabi-4.7" revision="1950e4760fa14688b83cdbb5acaa1af9f82ef434"/>
   <project groups="linux,arm" name="platform/prebuilts/gcc/linux-x86/arm/arm-linux-androideabi-4.7" path="prebuilts/gcc/linux-x86/arm/arm-linux-androideabi-4.7" revision="ac6eb97a37035c09fb5ede0852f0881e9aadf9ad"/>
   <project groups="linux,x86" name="platform/prebuilts/gcc/linux-x86/x86/i686-linux-android-4.7" path="prebuilts/gcc/linux-x86/x86/i686-linux-android-4.7" revision="737f591c5f95477148d26602c7be56cbea0cdeb9"/>
   <project groups="linux,x86" name="platform/prebuilts/python/linux-x86/2.7.5" path="prebuilts/python/linux-x86/2.7.5" revision="51da9b1981be481b92a59a826d4d78dc73d0989a"/>
   <project name="device/common" path="device/common" revision="798a3664597e6041985feab9aef42e98d458bc3d"/>
--- a/b2g/config/emulator/sources.xml
+++ b/b2g/config/emulator/sources.xml
@@ -14,23 +14,23 @@
   <!--original fetch url was git://github.com/apitrace/-->
   <remote fetch="https://git.mozilla.org/external/apitrace" name="apitrace"/>
   <default remote="caf" revision="refs/tags/android-4.0.4_r2.1" sync-j="4"/>
   <!-- Gonk specific things and forks -->
   <project name="platform_build" path="build" remote="b2g" revision="df362ace56338da8173d30d3e09e08c42c1accfa">
     <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="334532c0fcb809ac1c8bcd64a8eb9357967acf36"/>
+  <project name="gaia.git" path="gaia" remote="mozillaorg" revision="fce979e88240aba9f106c41b299151d3676bed99"/>
   <project name="gonk-misc" path="gonk-misc" remote="b2g" revision="8aee09c106f479f36c57b2a29af72d455e359211"/>
   <project name="rilproxy" path="rilproxy" remote="b2g" revision="827214fcf38d6569aeb5c6d6f31cb296d1f09272"/>
   <project name="platform_hardware_ril" path="hardware/ril" remote="b2g" revision="d5d3f93914558b6f168447b805cd799c8233e300"/>
   <project name="platform_external_qemu" path="external/qemu" remote="b2g" revision="6fa7a4936414ceb4055fd27f7a30e76790f834fb"/>
   <project name="moztt" path="external/moztt" remote="b2g" revision="fe893bb760a3bb64375f62fdf4762a58c59df9ef"/>
-  <project name="apitrace" path="external/apitrace" remote="apitrace" revision="8aefd1be86268fed59946173a9f5ebabce4b8e29"/>
+  <project name="apitrace" path="external/apitrace" remote="apitrace" revision="abc4f384bc4bb9c709d4f526176ab41eff3f14fe"/>
   <!-- Stock Android things -->
   <project name="platform/abi/cpp" path="abi/cpp" revision="dd924f92906085b831bf1cbbc7484d3c043d613c"/>
   <project name="platform/bionic" path="bionic" revision="c72b8f6359de7ed17c11ddc9dfdde3f615d188a9"/>
   <project name="platform/bootable/recovery" path="bootable/recovery" revision="425f8b5fadf5889834c5acd27d23c9e0b2129c28"/>
   <project name="device/common" path="device/common" revision="42b808b7e93d0619286ae8e59110b176b7732389"/>
   <project name="device/sample" path="device/sample" revision="237bd668d0f114d801a8d6455ef5e02cc3577587"/>
   <project name="platform_external_apriori" path="external/apriori" remote="b2g" revision="11816ad0406744f963537b23d68ed9c2afb412bd"/>
   <project name="platform/external/bluetooth/bluez" path="external/bluetooth/bluez" revision="52a1a862a8bac319652b8f82d9541ba40bfa45ce"/>
--- a/b2g/config/flame-kk/sources.xml
+++ b/b2g/config/flame-kk/sources.xml
@@ -10,25 +10,25 @@
   <!--original fetch url was git://codeaurora.org/-->
   <remote fetch="https://git.mozilla.org/external/caf" name="caf"/>
   <!--original fetch url was https://git.mozilla.org/releases-->
   <remote fetch="https://git.mozilla.org/releases" name="mozillaorg"/>
   <!-- B2G specific things. -->
   <project name="platform_build" path="build" remote="b2g" revision="e0c735ec89df011ea7dd435087a9045ecff9ff9e">
     <copyfile dest="Makefile" src="core/root.mk"/>
   </project>
-  <project name="gaia" path="gaia" remote="mozillaorg" revision="334532c0fcb809ac1c8bcd64a8eb9357967acf36"/>
+  <project name="gaia" path="gaia" remote="mozillaorg" revision="fce979e88240aba9f106c41b299151d3676bed99"/>
   <project name="fake-libdvm" path="dalvik" remote="b2g" revision="d50ae982b19f42f0b66d08b9eb306be81687869f"/>
   <project name="gonk-misc" path="gonk-misc" remote="b2g" revision="8aee09c106f479f36c57b2a29af72d455e359211"/>
   <project name="librecovery" path="librecovery" remote="b2g" revision="891e5069c0ad330d8191bf8c7b879c814258c89f"/>
   <project name="moztt" path="external/moztt" remote="b2g" revision="fe893bb760a3bb64375f62fdf4762a58c59df9ef"/>
   <project name="rilproxy" path="rilproxy" remote="b2g" revision="827214fcf38d6569aeb5c6d6f31cb296d1f09272"/>
   <project name="valgrind" path="external/valgrind" remote="b2g" revision="daa61633c32b9606f58799a3186395fd2bbb8d8c"/>
   <project name="vex" path="external/VEX" remote="b2g" revision="47f031c320888fe9f3e656602588565b52d43010"/>
-  <project name="apitrace" path="external/apitrace" remote="apitrace" revision="8aefd1be86268fed59946173a9f5ebabce4b8e29"/>
+  <project name="apitrace" path="external/apitrace" remote="apitrace" revision="abc4f384bc4bb9c709d4f526176ab41eff3f14fe"/>
   <!-- Stock Android things -->
   <project groups="linux" name="platform/prebuilts/gcc/linux-x86/host/i686-linux-glibc2.7-4.6" path="prebuilts/gcc/linux-x86/host/i686-linux-glibc2.7-4.6" revision="95bb5b66b3ec5769c3de8d3f25d681787418e7d2"/>
   <project groups="linux" name="platform/prebuilts/gcc/linux-x86/host/x86_64-linux-glibc2.7-4.6" path="prebuilts/gcc/linux-x86/host/x86_64-linux-glibc2.7-4.6" revision="ebdad82e61c16772f6cd47e9f11936bf6ebe9aa0"/>
   <project groups="linux,arm" name="platform/prebuilts/gcc/linux-x86/arm/arm-eabi-4.7" path="prebuilts/gcc/linux-x86/arm/arm-eabi-4.7" revision="8b880805d454664b3eed11d0f053cdeafa1ff06e"/>
   <project groups="linux,arm" name="platform/prebuilts/gcc/linux-x86/arm/arm-linux-androideabi-4.7" path="prebuilts/gcc/linux-x86/arm/arm-linux-androideabi-4.7" revision="a1e239a0bb5cd1d69680bf1075883aa9a7bf2429"/>
   <project groups="linux,x86" name="platform/prebuilts/gcc/linux-x86/x86/i686-linux-android-4.7" path="prebuilts/gcc/linux-x86/x86/i686-linux-android-4.7" revision="c7931763d41be602407ed9d71e2c0292c6597e00"/>
   <project groups="linux,x86" name="platform/prebuilts/python/linux-x86/2.7.5" path="prebuilts/python/linux-x86/2.7.5" revision="a32003194f707f66a2d8cdb913ed1869f1926c5d"/>
   <project name="device/common" path="device/common" revision="96d4d2006c4fcb2f19a3fa47ab10cb409faa017b"/>
--- a/b2g/config/flame/sources.xml
+++ b/b2g/config/flame/sources.xml
@@ -12,20 +12,20 @@
   <!--original fetch url was https://git.mozilla.org/releases-->
   <remote fetch="https://git.mozilla.org/releases" name="mozillaorg"/>
   <!-- B2G specific things. -->
   <project name="platform_build" path="build" remote="b2g" revision="0e94c080bee081a50aa2097527b0b40852f9143f">
     <copyfile dest="Makefile" src="core/root.mk"/>
   </project>
   <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="334532c0fcb809ac1c8bcd64a8eb9357967acf36"/>
+  <project name="gaia" path="gaia" remote="mozillaorg" revision="fce979e88240aba9f106c41b299151d3676bed99"/>
   <project name="gonk-misc" path="gonk-misc" remote="b2g" revision="8aee09c106f479f36c57b2a29af72d455e359211"/>
   <project name="moztt" path="external/moztt" remote="b2g" revision="fe893bb760a3bb64375f62fdf4762a58c59df9ef"/>
-  <project name="apitrace" path="external/apitrace" remote="apitrace" revision="8aefd1be86268fed59946173a9f5ebabce4b8e29"/>
+  <project name="apitrace" path="external/apitrace" remote="apitrace" revision="abc4f384bc4bb9c709d4f526176ab41eff3f14fe"/>
   <project name="valgrind" path="external/valgrind" remote="b2g" revision="daa61633c32b9606f58799a3186395fd2bbb8d8c"/>
   <project name="vex" path="external/VEX" remote="b2g" revision="47f031c320888fe9f3e656602588565b52d43010"/>
   <!-- Stock Android things -->
   <project groups="linux" name="platform/prebuilts/clang/linux-x86/3.1" path="prebuilts/clang/linux-x86/3.1" revision="e95b4ce22c825da44d14299e1190ea39a5260bde"/>
   <project groups="linux" name="platform/prebuilts/clang/linux-x86/3.2" path="prebuilts/clang/linux-x86/3.2" revision="471afab478649078ad7c75ec6b252481a59e19b8"/>
   <project groups="linux" name="platform/prebuilts/gcc/linux-x86/host/i686-linux-glibc2.7-4.6" path="prebuilts/gcc/linux-x86/host/i686-linux-glibc2.7-4.6" revision="95bb5b66b3ec5769c3de8d3f25d681787418e7d2"/>
   <project groups="linux" name="platform/prebuilts/gcc/linux-x86/host/x86_64-linux-glibc2.7-4.6" path="prebuilts/gcc/linux-x86/host/x86_64-linux-glibc2.7-4.6" revision="ebdad82e61c16772f6cd47e9f11936bf6ebe9aa0"/>
   <project groups="linux,arm" name="platform/prebuilts/gcc/linux-x86/arm/arm-eabi-4.7" path="prebuilts/gcc/linux-x86/arm/arm-eabi-4.7" revision="8b880805d454664b3eed11d0f053cdeafa1ff06e"/>
--- a/b2g/config/gaia.json
+++ b/b2g/config/gaia.json
@@ -1,9 +1,9 @@
 {
     "git": {
         "git_revision": "", 
         "remote": "", 
         "branch": ""
     }, 
-    "revision": "8db023189f8d58a474eaf31d25cbd56b711c5567", 
+    "revision": "563db4265b0e312e0cae52479d55e55a0e6a1b5a", 
     "repo_path": "integration/gaia-central"
 }
--- a/b2g/config/hamachi/sources.xml
+++ b/b2g/config/hamachi/sources.xml
@@ -12,21 +12,21 @@
   <!--original fetch url was git://github.com/apitrace/-->
   <remote fetch="https://git.mozilla.org/external/apitrace" name="apitrace"/>
   <default remote="caf" revision="b2g/ics_strawberry" sync-j="4"/>
   <!-- Gonk specific things and forks -->
   <project name="platform_build" path="build" remote="b2g" revision="df362ace56338da8173d30d3e09e08c42c1accfa">
     <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="334532c0fcb809ac1c8bcd64a8eb9357967acf36"/>
+  <project name="gaia.git" path="gaia" remote="mozillaorg" revision="fce979e88240aba9f106c41b299151d3676bed99"/>
   <project name="gonk-misc" path="gonk-misc" remote="b2g" revision="8aee09c106f479f36c57b2a29af72d455e359211"/>
   <project name="librecovery" path="librecovery" remote="b2g" revision="891e5069c0ad330d8191bf8c7b879c814258c89f"/>
   <project name="moztt" path="external/moztt" remote="b2g" revision="fe893bb760a3bb64375f62fdf4762a58c59df9ef"/>
-  <project name="apitrace" path="external/apitrace" remote="apitrace" revision="8aefd1be86268fed59946173a9f5ebabce4b8e29"/>
+  <project name="apitrace" path="external/apitrace" remote="apitrace" revision="abc4f384bc4bb9c709d4f526176ab41eff3f14fe"/>
   <!-- Stock Android things -->
   <project name="platform/abi/cpp" path="abi/cpp" revision="6426040f1be4a844082c9769171ce7f5341a5528"/>
   <project name="platform/bionic" path="bionic" revision="d2eb6c7b6e1bc7643c17df2d9d9bcb1704d0b9ab"/>
   <project name="platform/bootable/recovery" path="bootable/recovery" revision="746bc48f34f5060f90801925dcdd964030c1ab6d"/>
   <project name="platform/development" path="development" revision="2460485184bc8535440bb63876d4e63ec1b4770c"/>
   <project name="device/common" path="device/common" revision="0dcc1e03659db33b77392529466f9eb685cdd3c7"/>
   <project name="device/sample" path="device/sample" revision="68b1cb978a20806176123b959cb05d4fa8adaea4"/>
   <project name="platform_external_apriori" path="external/apriori" remote="b2g" revision="11816ad0406744f963537b23d68ed9c2afb412bd"/>
--- a/b2g/config/helix/sources.xml
+++ b/b2g/config/helix/sources.xml
@@ -10,17 +10,17 @@
   <!--original fetch url was https://git.mozilla.org/releases-->
   <remote fetch="https://git.mozilla.org/releases" name="mozillaorg"/>
   <default remote="caf" revision="b2g/ics_strawberry" sync-j="4"/>
   <!-- Gonk specific things and forks -->
   <project name="platform_build" path="build" remote="b2g" revision="df362ace56338da8173d30d3e09e08c42c1accfa">
     <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="334532c0fcb809ac1c8bcd64a8eb9357967acf36"/>
+  <project name="gaia.git" path="gaia" remote="mozillaorg" revision="fce979e88240aba9f106c41b299151d3676bed99"/>
   <project name="gonk-misc" path="gonk-misc" remote="b2g" revision="8aee09c106f479f36c57b2a29af72d455e359211"/>
   <project name="rilproxy" path="rilproxy" remote="b2g" revision="827214fcf38d6569aeb5c6d6f31cb296d1f09272"/>
   <project name="librecovery" path="librecovery" remote="b2g" revision="891e5069c0ad330d8191bf8c7b879c814258c89f"/>
   <project name="moztt" path="external/moztt" remote="b2g" revision="fe893bb760a3bb64375f62fdf4762a58c59df9ef"/>
   <project name="gonk-patches" path="patches" remote="b2g" revision="223a2421006e8f5da33f516f6891c87cae86b0f6"/>
   <!-- Stock Android things -->
   <project name="platform/abi/cpp" path="abi/cpp" revision="6426040f1be4a844082c9769171ce7f5341a5528"/>
   <project name="platform/bionic" path="bionic" revision="d2eb6c7b6e1bc7643c17df2d9d9bcb1704d0b9ab"/>
--- a/b2g/config/nexus-4/sources.xml
+++ b/b2g/config/nexus-4/sources.xml
@@ -12,20 +12,20 @@
   <!--original fetch url was https://git.mozilla.org/releases-->
   <remote fetch="https://git.mozilla.org/releases" name="mozillaorg"/>
   <!-- B2G specific things. -->
   <project name="platform_build" path="build" remote="b2g" revision="0e94c080bee081a50aa2097527b0b40852f9143f">
     <copyfile dest="Makefile" src="core/root.mk"/>
   </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="334532c0fcb809ac1c8bcd64a8eb9357967acf36"/>
+  <project name="gaia" path="gaia" remote="mozillaorg" revision="fce979e88240aba9f106c41b299151d3676bed99"/>
   <project name="gonk-misc" path="gonk-misc" remote="b2g" revision="8aee09c106f479f36c57b2a29af72d455e359211"/>
   <project name="moztt" path="external/moztt" remote="b2g" revision="fe893bb760a3bb64375f62fdf4762a58c59df9ef"/>
-  <project name="apitrace" path="external/apitrace" remote="apitrace" revision="8aefd1be86268fed59946173a9f5ebabce4b8e29"/>
+  <project name="apitrace" path="external/apitrace" remote="apitrace" revision="abc4f384bc4bb9c709d4f526176ab41eff3f14fe"/>
   <project name="valgrind" path="external/valgrind" remote="b2g" revision="daa61633c32b9606f58799a3186395fd2bbb8d8c"/>
   <project name="vex" path="external/VEX" remote="b2g" revision="47f031c320888fe9f3e656602588565b52d43010"/>
   <!-- Stock Android things -->
   <project groups="linux" name="platform/prebuilts/clang/linux-x86/3.1" path="prebuilts/clang/linux-x86/3.1" revision="5c45f43419d5582949284eee9cef0c43d866e03b"/>
   <project groups="linux" name="platform/prebuilts/clang/linux-x86/3.2" path="prebuilts/clang/linux-x86/3.2" revision="3748b4168e7bd8d46457d4b6786003bc6a5223ce"/>
   <project groups="linux" name="platform/prebuilts/gcc/linux-x86/host/i686-linux-glibc2.7-4.6" path="prebuilts/gcc/linux-x86/host/i686-linux-glibc2.7-4.6" revision="9025e50b9d29b3cabbbb21e1dd94d0d13121a17e"/>
   <project groups="linux" name="platform/prebuilts/gcc/linux-x86/host/x86_64-linux-glibc2.7-4.6" path="prebuilts/gcc/linux-x86/host/x86_64-linux-glibc2.7-4.6" revision="b89fda71fcd0fa0cf969310e75be3ea33e048b44"/>
   <project groups="linux,arm" name="platform/prebuilts/gcc/linux-x86/arm/arm-eabi-4.7" path="prebuilts/gcc/linux-x86/arm/arm-eabi-4.7" revision="2e7d5348f35575870b3c7e567a9a9f6d66f8d6c5"/>
--- a/b2g/config/wasabi/sources.xml
+++ b/b2g/config/wasabi/sources.xml
@@ -12,22 +12,22 @@
   <!--original fetch url was git://github.com/apitrace/-->
   <remote fetch="https://git.mozilla.org/external/apitrace" name="apitrace"/>
   <default remote="caf" revision="ics_chocolate_rb4.2" sync-j="4"/>
   <!-- Gonk specific things and forks -->
   <project name="platform_build" path="build" remote="b2g" revision="df362ace56338da8173d30d3e09e08c42c1accfa">
     <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="334532c0fcb809ac1c8bcd64a8eb9357967acf36"/>
+  <project name="gaia.git" path="gaia" remote="mozillaorg" revision="fce979e88240aba9f106c41b299151d3676bed99"/>
   <project name="gonk-misc" path="gonk-misc" remote="b2g" revision="8aee09c106f479f36c57b2a29af72d455e359211"/>
   <project name="rilproxy" path="rilproxy" remote="b2g" revision="827214fcf38d6569aeb5c6d6f31cb296d1f09272"/>
   <project name="librecovery" path="librecovery" remote="b2g" revision="891e5069c0ad330d8191bf8c7b879c814258c89f"/>
   <project name="moztt" path="external/moztt" remote="b2g" revision="fe893bb760a3bb64375f62fdf4762a58c59df9ef"/>
-  <project name="apitrace" path="external/apitrace" remote="apitrace" revision="8aefd1be86268fed59946173a9f5ebabce4b8e29"/>
+  <project name="apitrace" path="external/apitrace" remote="apitrace" revision="abc4f384bc4bb9c709d4f526176ab41eff3f14fe"/>
   <project name="gonk-patches" path="patches" remote="b2g" revision="223a2421006e8f5da33f516f6891c87cae86b0f6"/>
   <!-- Stock Android things -->
   <project name="platform/abi/cpp" path="abi/cpp" revision="6426040f1be4a844082c9769171ce7f5341a5528"/>
   <project name="platform/bionic" path="bionic" revision="cd5dfce80bc3f0139a56b58aca633202ccaee7f8"/>
   <project name="platform/bootable/recovery" path="bootable/recovery" revision="e0a9ac010df3afaa47ba107192c05ac8b5516435"/>
   <project name="platform/development" path="development" revision="a384622f5fcb1d2bebb9102591ff7ae91fe8ed2d"/>
   <project name="device/common" path="device/common" revision="7c65ea240157763b8ded6154a17d3c033167afb7"/>
   <project name="device/sample" path="device/sample" revision="c328f3d4409db801628861baa8d279fb8855892f"/>
--- a/dom/icc/Assertions.cpp
+++ b/dom/icc/Assertions.cpp
@@ -89,25 +89,13 @@ ASSERT_ICC_LOCK_TYPE_EQUALITY(Fdn, CARD_
   ASSERT_EQUALITY(IccContactType, webidlState, xpidlState)
 
 ASSERT_ICC_CONTACT_TYPE_EQUALITY(Adn, CARD_CONTACT_TYPE_ADN);
 ASSERT_ICC_CONTACT_TYPE_EQUALITY(Fdn, CARD_CONTACT_TYPE_FDN);
 ASSERT_ICC_CONTACT_TYPE_EQUALITY(Sdn, CARD_CONTACT_TYPE_SDN);
 
 #undef ASSERT_ICC_CONTACT_TYPE_EQUALITY
 
-/**
- * Enum IccMvnoType
- */
-#define ASSERT_ICC_MVNO_TYPE_EQUALITY(webidlState, xpidlState) \
-  ASSERT_EQUALITY(IccMvnoType, webidlState, xpidlState)
-
-ASSERT_ICC_MVNO_TYPE_EQUALITY(Imsi, CARD_MVNO_TYPE_IMSI);
-ASSERT_ICC_MVNO_TYPE_EQUALITY(Spn, CARD_MVNO_TYPE_SPN);
-ASSERT_ICC_MVNO_TYPE_EQUALITY(Gid, CARD_MVNO_TYPE_GID);
-
-#undef ASSERT_ICC_MVNO_TYPE_EQUALITY
-
 #undef ASSERT_EQUALITY
 
 } // namespace icc
 } // namespace dom
 } // namespace mozilla
--- a/dom/icc/Icc.cpp
+++ b/dom/icc/Icc.cpp
@@ -379,28 +379,29 @@ Icc::UpdateContact(const JSContext* aCx,
     aRv.Throw(rv);
     return nullptr;
   }
 
   return request.forget().downcast<DOMRequest>();
 }
 
 already_AddRefed<DOMRequest>
-Icc::MatchMvno(IccMvnoType aMvnoType, const nsAString& aMvnoData,
+Icc::MatchMvno(const nsAString& aMvnoType,
+               const nsAString& aMvnoData,
                ErrorResult& aRv)
 {
   if (!mProvider) {
     aRv.Throw(NS_ERROR_FAILURE);
     return nullptr;
   }
 
   nsRefPtr<nsIDOMDOMRequest> request;
   nsresult rv = mProvider->MatchMvno(mClientId, GetOwner(),
-                                     static_cast<uint32_t>(aMvnoType),
-                                     aMvnoData, getter_AddRefs(request));
+                                     aMvnoType, aMvnoData,
+                                     getter_AddRefs(request));
   if (NS_FAILED(rv)) {
     aRv.Throw(rv);
     return nullptr;
   }
 
   return request.forget().downcast<DOMRequest>();
 }
 
--- a/dom/icc/Icc.h
+++ b/dom/icc/Icc.h
@@ -93,17 +93,17 @@ public:
   ReadContacts(IccContactType aContactType, ErrorResult& aRv);
 
   already_AddRefed<DOMRequest>
   UpdateContact(const JSContext* aCx, IccContactType aContactType,
                 JS::Handle<JS::Value> aContact, const nsAString& aPin2,
                 ErrorResult& aRv);
 
   already_AddRefed<DOMRequest>
-  MatchMvno(IccMvnoType aMvnoType, const nsAString& aMatchData,
+  MatchMvno(const nsAString& aMvnoType, const nsAString& aMatchData,
             ErrorResult& aRv);
 
   IMPL_EVENT_HANDLER(iccinfochange)
   IMPL_EVENT_HANDLER(cardstatechange)
   IMPL_EVENT_HANDLER(stkcommand)
   IMPL_EVENT_HANDLER(stksessionend)
 
 private:
--- a/dom/icc/interfaces/nsIIccProvider.idl
+++ b/dom/icc/interfaces/nsIIccProvider.idl
@@ -15,17 +15,17 @@ interface nsIIccListener : nsISupports
   void notifyStkSessionEnd();
   void notifyCardStateChanged();
   void notifyIccInfoChanged();
 };
 
 /**
  * XPCOM component (in the content process) that provides the ICC information.
  */
-[scriptable, uuid(c3e3c1a9-6ac4-4916-a777-7d49ffd89c46)]
+[scriptable, uuid(937213c3-f64e-4f58-b4e0-3010f219d0c3)]
 interface nsIIccProvider : nsISupports
 {
   // MUST match enum IccCardState in MozIcc.webidl!
   const unsigned long CARD_STATE_UNKNOWN = 0;
   const unsigned long CARD_STATE_READY = 1;
   const unsigned long CARD_STATE_PIN_REQUIRED = 2;
   const unsigned long CARD_STATE_PUK_REQUIRED = 3;
   const unsigned long CARD_STATE_PERMANENT_BLOCKED = 4;
@@ -80,21 +80,16 @@ interface nsIIccProvider : nsISupports
   const unsigned long CARD_LOCK_TYPE_RSPCK_PUK = 19;
   const unsigned long CARD_LOCK_TYPE_FDN = 20;
 
   // MUST match with enum IccContactType in MozIcc.webidl
   const unsigned long CARD_CONTACT_TYPE_ADN = 0;
   const unsigned long CARD_CONTACT_TYPE_FDN = 1;
   const unsigned long CARD_CONTACT_TYPE_SDN = 2;
 
-  // MUST match with enum IccMvnoType in MozIcc.webidl
-  const unsigned long CARD_MVNO_TYPE_IMSI = 0;
-  const unsigned long CARD_MVNO_TYPE_SPN = 1;
-  const unsigned long CARD_MVNO_TYPE_GID = 2;
-
   /**
    * Called when a content process registers receiving unsolicited messages from
    * RadioInterfaceLayer in the chrome process. Only a content process that has
    * the 'mobileconnection' permission is allowed to register.
    */
   void registerIccMsg(in unsigned long clientId, in nsIIccListener listener);
   void unregisterIccMsg(in unsigned long clientId, in nsIIccListener listener);
 
@@ -182,11 +177,11 @@ interface nsIIccProvider : nsISupports
                                    in nsIDOMWindow window,
                                    in long channel);
 
   /**
    * Helpers
    */
   nsIDOMDOMRequest matchMvno(in unsigned long clientId,
                              in nsIDOMWindow window,
-                             in unsigned long mvnoType,
+                             in DOMString mvnoType,
                              in DOMString mvnoData);
 };
--- a/dom/system/gonk/RadioInterfaceLayer.js
+++ b/dom/system/gonk/RadioInterfaceLayer.js
@@ -1988,38 +1988,38 @@ RadioInterface.prototype = {
       }
     }
     return true;
   },
 
   matchMvno: function(target, message) {
     if (DEBUG) this.debug("matchMvno: " + JSON.stringify(message));
 
-    if (!message || !message.mvnoData) {
+    if (!message || !message.mvnoType || !message.mvnoData) {
       message.errorMsg = RIL.GECKO_ERROR_INVALID_PARAMETER;
     }
 
     if (!message.errorMsg) {
       switch (message.mvnoType) {
-        case RIL.GECKO_CARDMVNO_TYPE_IMSI:
+        case "imsi":
           if (!this.rilContext.imsi) {
             message.errorMsg = RIL.GECKO_ERROR_GENERIC_FAILURE;
             break;
           }
           message.result = this.isImsiMatches(message.mvnoData);
           break;
-        case RIL.GECKO_CARDMVNO_TYPE_SPN:
+        case "spn":
           let spn = this.rilContext.iccInfo && this.rilContext.iccInfo.spn;
           if (!spn) {
             message.errorMsg = RIL.GECKO_ERROR_GENERIC_FAILURE;
             break;
           }
           message.result = spn == message.mvnoData;
           break;
-        case RIL.GECKO_CARDMVNO_TYPE_GID:
+        case "gid":
           this.workerMessenger.send("getGID1", null, (function(response) {
             let gid = response.gid1;
             let mvnoDataLength = message.mvnoData.length;
 
             if (!gid) {
               message.errorMsg = RIL.GECKO_ERROR_GENERIC_FAILURE;
             } else if (mvnoDataLength > gid.length) {
               message.result = false;
--- a/dom/system/gonk/ril_consts.js
+++ b/dom/system/gonk/ril_consts.js
@@ -2640,21 +2640,16 @@ GECKO_CARDLOCK_TO_SEL_CODE[GECKO_CARDLOC
 GECKO_CARDLOCK_TO_SEL_CODE[GECKO_CARDLOCK_CCK] = ICC_SEL_CODE_PH_CORP_PIN;
 GECKO_CARDLOCK_TO_SEL_CODE[GECKO_CARDLOCK_SPCK] = ICC_SEL_CODE_PH_SP_PIN;
 
 // See nsIIccProvider::CARD_CONTACT_TYPE_*
 this.GECKO_CARDCONTACT_TYPE_ADN = 0;
 this.GECKO_CARDCONTACT_TYPE_FDN = 1;
 this.GECKO_CARDCONTACT_TYPE_SDN = 2;
 
-// See nsIIccProvider::CARD_MVNO_TYPE_*
-this.GECKO_CARDMVNO_TYPE_IMSI = 0;
-this.GECKO_CARDMVNO_TYPE_SPN = 1;
-this.GECKO_CARDMVNO_TYPE_GID = 2;
-
 // See ril.h RIL_PersoSubstate
 this.PERSONSUBSTATE = {};
 PERSONSUBSTATE[CARD_PERSOSUBSTATE_UNKNOWN] = GECKO_CARDSTATE_UNKNOWN;
 PERSONSUBSTATE[CARD_PERSOSUBSTATE_IN_PROGRESS] = GECKO_CARDSTATE_PERSONALIZATION_IN_PROGRESS;
 PERSONSUBSTATE[CARD_PERSOSUBSTATE_READY] = GECKO_CARDSTATE_PERSONALIZATION_READY;
 PERSONSUBSTATE[CARD_PERSOSUBSTATE_SIM_NETWORK] = GECKO_CARDSTATE_NETWORK_LOCKED;
 PERSONSUBSTATE[CARD_PERSOSUBSTATE_SIM_NETWORK_SUBSET] = GECKO_CARDSTATE_NETWORK_SUBSET_LOCKED;
 PERSONSUBSTATE[CARD_PERSOSUBSTATE_SIM_CORPORATE] = GECKO_CARDSTATE_CORPORATE_LOCKED;
--- a/dom/webidl/MozIcc.webidl
+++ b/dom/webidl/MozIcc.webidl
@@ -77,23 +77,16 @@ enum IccLockType
 
 enum IccContactType
 {
   "adn", // Abbreviated Dialling Number.
   "fdn", // Fixed Dialling Number.
   "sdn"  // Service Dialling Number.
 };
 
-enum IccMvnoType
-{
-  "imsi",
-  "spn",
-  "gid"
-};
-
 dictionary IccUnlockCardLockOptions
 {
   required IccLockType lockType;
 
   DOMString? pin = null; // Necessary for lock types: "pin", "pin2", "nck",
                          // "nck1", "nck2", "hnck", "cck", "spck", "rcck",
                          // "rspck".
 
@@ -317,18 +310,22 @@ interface MozIcc : EventTarget
   // Integrated Circuit Card Helpers.
 
   /**
    * Verify whether the passed data (matchData) matches with some ICC's field
    * according to the mvno type (mvnoType).
    *
    * @param mvnoType
    *        Mvno type to use to compare the match data.
+   *        Currently, we only support 'imsi'.
    * @param matchData
    *        Data to be compared with ICC's field.
    *
    * @return a DOMRequest.
    *         The request's result will be a boolean indicating the matching
    *         result.
+   *
+   * TODO: change param mvnoType to WebIDL enum after Bug 864489 -
+   *       B2G RIL: use ipdl as IPC in MozIccManager
    */
   [Throws]
-  DOMRequest matchMvno(IccMvnoType mvnoType, DOMString matchData);
+  DOMRequest matchMvno(DOMString mvnoType, DOMString matchData);
 };
--- a/mobile/android/base/GeckoApp.java
+++ b/mobile/android/base/GeckoApp.java
@@ -1417,17 +1417,16 @@ public abstract class GeckoApp
                 ((SurfaceView)mCameraView).getHolder().setType(SurfaceHolder.SURFACE_TYPE_PUSH_BUFFERS);
             }
         }
 
         if (mLayerView == null) {
             LayerView layerView = (LayerView) findViewById(R.id.layer_view);
             layerView.initializeView(EventDispatcher.getInstance());
             mLayerView = layerView;
-            GeckoAppShell.setLayerView(layerView);
             GeckoAppShell.sendEventToGecko(GeckoEvent.createObjectEvent(
                 GeckoEvent.ACTION_OBJECT_LAYER_CLIENT, layerView.getLayerClientObject()));
 
             // bind the GeckoEditable instance to the new LayerView
             GeckoAppShell.notifyIMEContext(GeckoEditableListener.IME_STATE_DISABLED, "", "", "");
         }
     }
 
--- a/mobile/android/base/GeckoView.java
+++ b/mobile/android/base/GeckoView.java
@@ -117,16 +117,19 @@ public class GeckoView extends LayerView
         TypedArray a = context.obtainStyledAttributes(attrs, R.styleable.GeckoView);
         String url = a.getString(R.styleable.GeckoView_url);
         boolean doInit = a.getBoolean(R.styleable.GeckoView_doinit, true);
         a.recycle();
         init(context, url, doInit);
     }
 
     private void init(Context context, String url, boolean doInit) {
+        // Perform common initialization for Fennec/GeckoView.
+        GeckoAppShell.setLayerView(this);
+
         // TODO: Fennec currently takes care of its own initialization, so this
         // flag is a hack used in Fennec to prevent GeckoView initialization.
         // This should go away once Fennec also uses GeckoView for
         // initialization.
         if (!doInit)
             return;
 
         // If running outside of a GeckoActivity (eg, from a library project),
@@ -180,17 +183,16 @@ public class GeckoView extends LayerView
 
         initializeView(EventDispatcher.getInstance());
 
         if (GeckoThread.checkAndSetLaunchState(GeckoThread.LaunchState.Launching, GeckoThread.LaunchState.Launched)) {
             // This is the first launch, so finish initialization and go.
             GeckoProfile profile = GeckoProfile.get(context).forceCreate();
             BrowserDB.initialize(profile.getName());
 
-            GeckoAppShell.setLayerView(this);
             GeckoAppShell.sendEventToGecko(GeckoEvent.createObjectEvent(
                 GeckoEvent.ACTION_OBJECT_LAYER_CLIENT, getLayerClientObject()));
             GeckoThread.createAndStart();
         } else if(GeckoThread.checkLaunchState(GeckoThread.LaunchState.GeckoRunning)) {
             // If Gecko is already running, that means the Activity was
             // destroyed, so we need to re-attach Gecko to this GeckoView.
             connectToGecko();
         }
--- a/mobile/android/base/gfx/LayerView.java
+++ b/mobile/android/base/gfx/LayerView.java
@@ -313,17 +313,16 @@ public class LayerView extends FrameLayo
     }
 
     public void setIsRTL(boolean aIsRTL) {
         mLayerClient.setIsRTL(aIsRTL);
     }
 
     public void setInputConnectionHandler(InputConnectionHandler inputConnectionHandler) {
         mInputConnectionHandler = inputConnectionHandler;
-        mLayerClient.forceRedraw(null);
     }
 
     @Override
     public Handler getHandler() {
         if (mInputConnectionHandler != null)
             return mInputConnectionHandler.getHandler(super.getHandler());
         return super.getHandler();
     }
--- a/mobile/android/base/menu/GeckoMenu.java
+++ b/mobile/android/base/menu/GeckoMenu.java
@@ -10,16 +10,17 @@ import org.mozilla.gecko.util.ThreadUtil
 import org.mozilla.gecko.util.ThreadUtils.AssertBehavior;
 import org.mozilla.gecko.widget.GeckoActionProvider;
 
 import android.content.ComponentName;
 import android.content.Context;
 import android.content.Intent;
 import android.util.AttributeSet;
 import android.util.Log;
+import android.util.SparseArray;
 import android.view.KeyEvent;
 import android.view.LayoutInflater;
 import android.view.Menu;
 import android.view.MenuItem;
 import android.view.SubMenu;
 import android.view.View;
 import android.view.ViewGroup;
 import android.widget.AdapterView;
@@ -85,16 +86,19 @@ public class GeckoMenu extends ListView
         public void removeActionItem(View actionItem);
     }
 
     protected static final int NO_ID = 0;
 
     // List of all menu items.
     private final List<GeckoMenuItem> mItems;
 
+    // Quick lookup array used to make a fast path in findItem.
+    private final SparseArray<MenuItem> mItemsById;
+
     // Map of "always" action-items in action-bar and their views.
     private final Map<GeckoMenuItem, View> mPrimaryActionItems;
 
     // Map of "ifRoom" action-items in action-bar and their views.
     private final Map<GeckoMenuItem, View> mSecondaryActionItems;
 
     // Reference to a callback for menu events.
     private Callback mCallback;
@@ -129,16 +133,17 @@ public class GeckoMenu extends ListView
                                          LayoutParams.MATCH_PARENT));
 
         // Attach an adapter.
         mAdapter = new MenuItemsAdapter();
         setAdapter(mAdapter);
         setOnItemClickListener(this);
 
         mItems = new ArrayList<GeckoMenuItem>();
+        mItemsById = new SparseArray<MenuItem>();
         mPrimaryActionItems = new HashMap<GeckoMenuItem, View>();
         mSecondaryActionItems = new HashMap<GeckoMenuItem, View>();
 
         mPrimaryActionItemBar = (DefaultActionItemBar) LayoutInflater.from(context).inflate(R.layout.menu_action_bar, null);
         mSecondaryActionItemBar = (DefaultActionItemBar) LayoutInflater.from(context).inflate(R.layout.menu_secondary_action_bar, null);
     }
 
     private static void assertOnUiThread() {
@@ -357,25 +362,34 @@ public class GeckoMenu extends ListView
 
     private void showMenu(View viewForMenu) {
         if (mMenuPresenter != null)
             mMenuPresenter.showMenu(viewForMenu);
     }
 
     @Override
     public MenuItem findItem(int id) {
+        assertOnUiThread();
+        MenuItem quickItem = mItemsById.get(id);
+        if (quickItem != null) {
+            return quickItem;
+        }
+
         for (GeckoMenuItem menuItem : mItems) {
             if (menuItem.getItemId() == id) {
+                mItemsById.put(id, menuItem);
                 return menuItem;
             } else if (menuItem.hasSubMenu()) {
                 if (!menuItem.hasActionProvider()) {
                     SubMenu subMenu = menuItem.getSubMenu();
                     MenuItem item = subMenu.findItem(id);
-                    if (item != null)
+                    if (item != null) {
+                        mItemsById.put(id, item);
                         return item;
+                    }
                 }
             }
         }
         return null;
     }
 
     @Override
     public MenuItem getItem(int index) {
@@ -419,16 +433,19 @@ public class GeckoMenu extends ListView
 
     @Override
     public void removeItem(int id) {
         assertOnUiThread();
         GeckoMenuItem item = (GeckoMenuItem) findItem(id);
         if (item == null)
             return;
 
+        // Remove it from the cache.
+        mItemsById.remove(id);
+
         // Remove it from any sub-menu.
         for (GeckoMenuItem menuItem : mItems) {
             if (menuItem.hasSubMenu()) {
                 SubMenu subMenu = menuItem.getSubMenu();
                 if (subMenu != null && subMenu.findItem(id) != null) {
                     subMenu.removeItem(id);
                     return;
                 }
@@ -806,16 +823,17 @@ public class GeckoMenu extends ListView
 
         public void removeMenuItem(GeckoMenuItem menuItem) {
             // Remove it from the list.
             mItems.remove(menuItem);
             notifyDataSetChanged();
         }
 
         public void clear() {
+            mItemsById.clear();
             mItems.clear();
             notifyDataSetChanged();
         }
 
         public GeckoMenuItem getMenuItem(int id) {
             for (GeckoMenuItem item : mItems) {
                 if (item.getItemId() == id)
                     return item;
--- a/mobile/android/base/menu/GeckoMenuInflater.java
+++ b/mobile/android/base/menu/GeckoMenuInflater.java
@@ -151,19 +151,35 @@ public class GeckoMenuInflater extends M
         if (Versions.feature11Plus) {
             item.showAsAction = a.getInt(R.styleable.MenuItem_android_showAsAction, 0);
         }
 
         a.recycle();
     }
 
     public void setValues(ParsedItem item, MenuItem menuItem) {
+        // We are blocking any presenter updates during inflation.
+        GeckoMenuItem geckoItem = null;
+        if (menuItem instanceof GeckoMenuItem) {
+            geckoItem = (GeckoMenuItem) menuItem;
+        }
+
+        if (geckoItem != null) {
+            geckoItem.stopDispatchingChanges();
+        }
+
         menuItem.setChecked(item.checked)
                 .setVisible(item.visible)
                 .setEnabled(item.enabled)
                 .setCheckable(item.checkable)
                 .setIcon(item.iconRes);
 
         if (Versions.feature11Plus) {
             menuItem.setShowAsAction(item.showAsAction);
         }
+
+        if (geckoItem != null) {
+            // We don't need to allow presenter updates during inflation,
+            // so we use the weak form of re-enabling changes.
+            geckoItem.resumeDispatchingChanges();
+        }
     }
 }
--- a/mobile/android/base/menu/GeckoMenuItem.java
+++ b/mobile/android/base/menu/GeckoMenuItem.java
@@ -47,28 +47,62 @@ public class GeckoMenuItem implements Me
     private Drawable mIcon;
     private int mIconRes;
     private GeckoActionProvider mActionProvider;
     private GeckoSubMenu mSubMenu;
     private MenuItem.OnMenuItemClickListener mMenuItemClickListener;
     final GeckoMenu mMenu;
     OnShowAsActionChangedListener mShowAsActionChangedListener;
 
+    private volatile boolean mShouldDispatchChanges = true;
+    private volatile boolean mDidChange;
+
     public GeckoMenuItem(GeckoMenu menu, int id, int order, int titleRes) {
         mMenu = menu;
         mId = id;
         mOrder = order;
-        setTitle(titleRes);
+        mTitle = mMenu.getResources().getString(titleRes);
     }
 
     public GeckoMenuItem(GeckoMenu menu, int id, int order, CharSequence title) {
         mMenu = menu;
         mId = id;
         mOrder = order;
-        setTitle(title);
+        mTitle = title;
+    }
+
+    /**
+     * Stop dispatching item changed events to presenters until
+     * [start|resume]DispatchingItemsChanged() is called. Useful when
+     * many menu operations are going to be performed as a batch.
+     */
+    public void stopDispatchingChanges() {
+        mDidChange = false;
+        mShouldDispatchChanges = false;
+    }
+
+    /**
+     * Resume dispatching item changed events to presenters. This method
+     * will NOT call onItemChanged if any menu operations were queued.
+     * Only future menu operations will call onItemChanged. Useful for
+     * sequelching presenter updates.
+     */
+    public void resumeDispatchingChanges() {
+        mShouldDispatchChanges = true;
+    }
+
+    /**
+     * Start dispatching item changed events to presenters. This method
+     * will call onItemChanged if any menu operations were queued.
+     */
+    public void startDispatchingChanges() {
+        if (mDidChange) {
+            mMenu.onItemChanged(this);
+        }
+        mShouldDispatchChanges = true;
     }
 
     @Override
     public boolean collapseActionView() {
         return false;
     }
 
     @Override
@@ -242,53 +276,73 @@ public class GeckoMenuItem implements Me
     public MenuItem setAlphabeticShortcut(char alphaChar) {
         return this;
     }
 
     @Override
     public MenuItem setCheckable(boolean checkable) {
         if (mCheckable != checkable) {
             mCheckable = checkable;
-            mMenu.onItemChanged(this);
+            if (mShouldDispatchChanges) {
+                mMenu.onItemChanged(this);
+            } else {
+                mDidChange = true;
+            }
         }
         return this;
     }
 
     @Override
     public MenuItem setChecked(boolean checked) {
         if (mChecked != checked) {
             mChecked = checked;
-            mMenu.onItemChanged(this);
+            if (mShouldDispatchChanges) {
+                mMenu.onItemChanged(this);
+            } else {
+                mDidChange = true;
+            }
         }
         return this;
     }
 
     @Override
     public MenuItem setEnabled(boolean enabled) {
         if (mEnabled != enabled) {
             mEnabled = enabled;
-            mMenu.onItemChanged(this);
+            if (mShouldDispatchChanges) {
+                mMenu.onItemChanged(this);
+            } else {
+                mDidChange = true;
+            }
         }
         return this;
     }
 
     @Override
     public MenuItem setIcon(Drawable icon) {
         if (mIcon != icon) {
             mIcon = icon;
-            mMenu.onItemChanged(this);
+            if (mShouldDispatchChanges) {
+                mMenu.onItemChanged(this);
+            } else {
+                mDidChange = true;
+            }
         }
         return this;
     }
 
     @Override
     public MenuItem setIcon(int iconRes) {
         if (mIconRes != iconRes) {
             mIconRes = iconRes;
-            mMenu.onItemChanged(this);
+            if (mShouldDispatchChanges) {
+                mMenu.onItemChanged(this);
+            } else {
+                mDidChange = true;
+            }
         }
         return this;
     }
 
     @Override
     public MenuItem setIntent(Intent intent) {
         return this;
     }
@@ -362,17 +416,21 @@ public class GeckoMenuItem implements Me
         mSubMenu = subMenu;
         return this;
     }
 
     @Override
     public MenuItem setTitle(CharSequence title) {
         if (!TextUtils.equals(mTitle, title)) {
             mTitle = title;
-            mMenu.onItemChanged(this);
+            if (mShouldDispatchChanges) {
+                mMenu.onItemChanged(this);
+            } else {
+                mDidChange = true;
+            }
         }
         return this;
     }
 
     @Override
     public MenuItem setTitle(int title) {
         CharSequence newTitle = mMenu.getResources().getString(title);
         return setTitle(newTitle);
@@ -383,17 +441,21 @@ public class GeckoMenuItem implements Me
         mTitleCondensed = title;
         return this;
     }
 
     @Override
     public MenuItem setVisible(boolean visible) {
         if (mVisible != visible) {
             mVisible = visible;
-            mMenu.onItemChanged(this);
+            if (mShouldDispatchChanges) {
+                mMenu.onItemChanged(this);
+            } else {
+                mDidChange = true;
+            }
         }
         return this;
     }
 
     public boolean invoke() {
         if (mMenuItemClickListener != null)
             return mMenuItemClickListener.onMenuItemClick(this);
         else
--- a/mobile/android/base/moz.build
+++ b/mobile/android/base/moz.build
@@ -468,16 +468,18 @@ gbjar.sources += [
     'widget/BasicColorPicker.java',
     'widget/ButtonToast.java',
     'widget/CheckableLinearLayout.java',
     'widget/ClickableWhenDisabledEditText.java',
     'widget/DateTimePicker.java',
     'widget/Divider.java',
     'widget/DoorHanger.java',
     'widget/EllipsisTextView.java',
+    'widget/FadedMultiColorTextView.java',
+    'widget/FadedSingleColorTextView.java',
     'widget/FadedTextView.java',
     'widget/FaviconView.java',
     'widget/FloatingHintEditText.java',
     'widget/FlowLayout.java',
     'widget/GeckoActionProvider.java',
     'widget/GeckoPopupMenu.java',
     'widget/GeckoSwipeRefreshLayout.java',
     'widget/GeckoViewFlipper.java',
new file mode 100644
--- /dev/null
+++ b/mobile/android/base/resources/color/toolbar_display_layout_bg.xml
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="utf-8"?>
+
+<!-- These colors are defined from the drawables url_bar_entry_default_* -->
+<selector xmlns:android="http://schemas.android.com/apk/res/android"
+          xmlns:gecko="http://schemas.android.com/apk/res-auto">
+
+    <item gecko:state_private="true" android:color="#080A0B"/>
+
+    <item android:color="#FFFFFF"/>
+
+</selector>
--- a/mobile/android/base/resources/layout-large-v11/tab_strip_item_view.xml
+++ b/mobile/android/base/resources/layout-large-v11/tab_strip_item_view.xml
@@ -9,17 +9,17 @@
    <ImageView
         android:id="@+id/favicon"
         android:layout_width="@dimen/new_tablet_tab_strip_favicon_size"
         android:layout_height="match_parent"
         android:layout_marginRight="8dp"
         android:scaleType="centerInside"
         android:duplicateParentState="true"/>
 
-    <org.mozilla.gecko.widget.FadedTextView
+    <org.mozilla.gecko.widget.FadedSingleColorTextView
         android:id="@+id/title"
         android:layout_width="0dip"
         android:layout_height="match_parent"
         android:layout_weight="1.0"
         android:layout_marginRight="-5dp"
         android:gravity="center_vertical"
         android:textSize="14sp"
         android:ellipsize="end"
--- a/mobile/android/base/resources/layout-v11/new_tablet_tabs_item_cell.xml
+++ b/mobile/android/base/resources/layout-v11/new_tablet_tabs_item_cell.xml
@@ -16,27 +16,28 @@
     <LinearLayout android:layout_width="fill_parent"
                   android:layout_height="wrap_content"
                   android:orientation="horizontal"
                   android:duplicateParentState="true"
                   android:paddingLeft="@dimen/new_tablet_tab_highlight_stroke_width"
                   android:paddingRight="@dimen/new_tablet_tab_highlight_stroke_width"
                   android:paddingBottom="@dimen/new_tablet_tab_highlight_stroke_width">
 
-        <org.mozilla.gecko.widget.FadedTextView android:id="@+id/title"
-                                                android:layout_width="0dip"
-                                                android:layout_height="wrap_content"
-                                                android:layout_weight="1.0"
-                                                style="@style/TabLayoutItemTextAppearance"
-                                                android:textSize="14sp"
-                                                android:textColor="@color/new_tablet_tab_item_title"
-                                                android:singleLine="true"
-                                                android:duplicateParentState="true"
-                                                gecko:fadeWidth="15dp"
-                                                android:paddingRight="5dp"/>
+       <org.mozilla.gecko.widget.FadedSingleColorTextView
+               android:id="@+id/title"
+               android:layout_width="0dip"
+               android:layout_height="wrap_content"
+               android:layout_weight="1.0"
+               style="@style/TabLayoutItemTextAppearance"
+               android:textSize="14sp"
+               android:textColor="@color/new_tablet_tab_item_title"
+               android:singleLine="true"
+               android:duplicateParentState="true"
+               gecko:fadeWidth="15dp"
+               android:paddingRight="5dp"/>
 
 
         <!-- Use of baselineAlignBottom only supported from API 11+ - if this needs to work on lower API versions
              we'll need to override getBaseLine() and return image height, but we assume this won't happen -->
         <ImageButton android:id="@+id/close"
                      style="@style/TabsItemClose"
                      android:layout_width="wrap_content"
                      android:layout_height="wrap_content"
--- a/mobile/android/base/resources/layout/home_remote_tabs_group.xml
+++ b/mobile/android/base/resources/layout/home_remote_tabs_group.xml
@@ -24,17 +24,17 @@
         tools:src="@drawable/sync_mobile"/>
 
     <LinearLayout
         android:layout_width="match_parent"
         android:layout_height="wrap_content"
         android:layout_weight="1"
         android:orientation="vertical">
 
-        <org.mozilla.gecko.widget.FadedTextView
+        <org.mozilla.gecko.widget.FadedSingleColorTextView
             android:id="@+id/client"
             style="@style/Widget.TwoLinePageRow.Title"
             android:layout_width="match_parent"
             android:layout_height="wrap_content"
             gecko:fadeWidth="30dp"
             tools:text="Firefox on Nexus 5"/>
 
         <TextView
--- a/mobile/android/base/resources/layout/tab_history_item_row.xml
+++ b/mobile/android/base/resources/layout/tab_history_item_row.xml
@@ -35,17 +35,17 @@
         <ImageView android:id="@+id/tab_history_timeline_bottom"
                    android:layout_width="@dimen/tab_history_timeline_width"
                    android:layout_height="@dimen/tab_history_timeline_height"
                    android:layout_gravity="center_horizontal"
                    android:background="@color/tab_history_timeline_separator" />
 
     </LinearLayout>
 
-    <org.mozilla.gecko.widget.FadedTextView
+    <org.mozilla.gecko.widget.FadedSingleColorTextView
             android:id="@+id/tab_history_title"
             style="@style/Widget.TwoLinePageRow.Title"
             android:layout_centerVertical="true"
             android:layout_width="match_parent"
             android:layout_height="wrap_content"
             android:layout_gravity="center_vertical"
             android:paddingRight="@dimen/tab_history_title_margin_right"
             android:text="@+id/tab_history_title"
--- a/mobile/android/base/resources/layout/toolbar_display_layout.xml
+++ b/mobile/android/base/resources/layout/toolbar_display_layout.xml
@@ -20,23 +20,25 @@
                  android:layout_width="@dimen/browser_toolbar_site_security_width"
                  android:scaleType="fitCenter"
                  android:layout_marginRight="4dip"
                  android:layout_marginBottom="@dimen/site_security_bottom_margin"
                  android:src="@drawable/site_security_level"
                  android:contentDescription="@string/site_security"
                  android:visibility="gone"/>
 
-    <org.mozilla.gecko.widget.FadedTextView android:id="@+id/url_bar_title"
-                                            style="@style/UrlBar.Title"
-                                            android:layout_width="match_parent"
-                                            android:layout_height="match_parent"
-                                            android:layout_weight="1.0"
-                                            gecko:fadeWidth="40dip"
-                                            gecko:autoUpdateTheme="false"/>
+    <org.mozilla.gecko.widget.FadedMultiColorTextView
+            android:id="@+id/url_bar_title"
+            style="@style/UrlBar.Title"
+            android:layout_width="match_parent"
+            android:layout_height="match_parent"
+            android:layout_weight="1.0"
+            gecko:fadeWidth="40dip"
+            gecko:fadeBackgroundColor="@color/toolbar_display_layout_bg"
+            gecko:autoUpdateTheme="false"/>
 
     <org.mozilla.gecko.toolbar.PageActionLayout android:id="@+id/page_action_layout"
                                                 android:layout_width="wrap_content"
                                                 android:layout_height="match_parent"
                                                 android:visibility="gone"
                                                 android:orientation="horizontal"/>
 
     <ImageButton android:id="@+id/stop"
--- a/mobile/android/base/resources/layout/top_sites_grid_item_view.xml
+++ b/mobile/android/base/resources/layout/top_sites_grid_item_view.xml
@@ -7,17 +7,17 @@
        xmlns:gecko="http://schemas.android.com/apk/res-auto">
 
     <org.mozilla.gecko.home.TopSitesThumbnailView
             android:id="@+id/thumbnail"
             android:layout_width="match_parent"
             android:layout_height="wrap_content"
             android:layout_alignParentTop="true"/>
 
-    <org.mozilla.gecko.widget.FadedTextView
+    <org.mozilla.gecko.widget.FadedSingleColorTextView
             android:id="@+id/title"
             style="@style/Widget.TopSitesGridItemTitle"
             android:layout_width="match_parent"
             android:layout_height="wrap_content"
             android:layout_below="@id/thumbnail"
             android:duplicateParentState="true"
             android:drawablePadding="4dip"
             gecko:fadeWidth="20dip"/>
--- a/mobile/android/base/resources/layout/two_line_page_row.xml
+++ b/mobile/android/base/resources/layout/two_line_page_row.xml
@@ -15,17 +15,17 @@
                                           tools:background="@drawable/favicon"/>
 
     <LinearLayout android:layout_width="match_parent"
                   android:layout_height="wrap_content"
                   android:layout_gravity="center_vertical"
                   android:orientation="vertical"
                   android:paddingRight="25dp">
 
-        <org.mozilla.gecko.widget.FadedTextView
+        <org.mozilla.gecko.widget.FadedSingleColorTextView
                 android:id="@+id/title"
                 style="@style/Widget.TwoLinePageRow.Title"
                 android:layout_width="match_parent"
                 android:layout_height="wrap_content"
                 gecko:fadeWidth="30dp"
                 tools:text="This is a long test title"/>
 
         <TextView android:id="@+id/url"
--- a/mobile/android/base/resources/values/attrs.xml
+++ b/mobile/android/base/resources/values/attrs.xml
@@ -141,16 +141,22 @@
     <declare-styleable name="HomePagerTabStrip">
         <attr name="tabIndicatorColor" format="color"/>
     </declare-styleable>
 
     <declare-styleable name="FadedTextView">
         <attr name="fadeWidth" format="dimension"/>
     </declare-styleable>
 
+    <declare-styleable name="FadedMultiColorTextView">
+        <!-- The background color we should be fading over. Useful because the
+             background is full alpha and we need to copy the background underneath. -->
+        <attr name="fadeBackgroundColor" format="dimension"/>
+    </declare-styleable>
+
     <declare-styleable name="BookmarkFolderView">
         <attr name="state_open" format="boolean"/>
     </declare-styleable>
 
     <declare-styleable name="GeckoView">
         <attr name="url" format="string"/>
         <attr name="doinit" format="boolean"/>
     </declare-styleable>
--- a/mobile/android/base/tests/components/AppMenuComponent.java
+++ b/mobile/android/base/tests/components/AppMenuComponent.java
@@ -14,16 +14,17 @@ import java.util.List;
 import org.mozilla.gecko.R;
 import org.mozilla.gecko.menu.MenuItemActionBar;
 import org.mozilla.gecko.menu.MenuItemDefault;
 import org.mozilla.gecko.tests.UITestContext;
 import org.mozilla.gecko.tests.helpers.DeviceHelper;
 import org.mozilla.gecko.tests.helpers.WaitHelper;
 import org.mozilla.gecko.util.HardwareUtils;
 
+import android.text.TextUtils;
 import android.view.View;
 import android.widget.TextView;
 
 import com.jayway.android.robotium.solo.Condition;
 import com.jayway.android.robotium.solo.RobotiumUtils;
 import com.jayway.android.robotium.solo.Solo;
 
 /**
@@ -158,35 +159,35 @@ public class AppMenuComponent extends Ba
      */
     private View findAppMenuItemView(String text) {
         mSolo.waitForText(text, 1, MAX_WAITTIME_FOR_MENU_UPDATE_IN_MS);
 
         final List<View> views = mSolo.getViews();
 
         final List<MenuItemActionBar> menuItemActionBarList = RobotiumUtils.filterViews(MenuItemActionBar.class, views);
         for (MenuItemActionBar menuItem : menuItemActionBarList) {
-            if (menuItem.getContentDescription().equals(text)) {
+            if (TextUtils.equals(menuItem.getContentDescription(), text)) {
                 return menuItem;
             }
         }
 
         final List<MenuItemDefault> menuItemDefaultList = RobotiumUtils.filterViews(MenuItemDefault.class, views);
         for (MenuItemDefault menuItem : menuItemDefaultList) {
-            if (menuItem.getText().equals(text)) {
+            if (TextUtils.equals(menuItem.getText(), text)) {
                 return menuItem;
             }
         }
 
         // On Android 2.3, menu items may be instances of
         // com.android.internal.view.menu.ListMenuItemView, each with a child
         // android.widget.RelativeLayout which in turn has a child
         // TextView with the appropriate text.
         final List<TextView> textViewList = RobotiumUtils.filterViews(TextView.class, views);
         for (TextView textView : textViewList) {
-            if (textView.getText().equals(text)) {
+            if (TextUtils.equals(textView.getText(), text)) {
                 View relativeLayout = (View) textView.getParent();
                 View listMenuItemView = (View)relativeLayout.getParent();
                 return listMenuItemView;
             }
         }
         return null;
     }
 
new file mode 100644
--- /dev/null
+++ b/mobile/android/base/widget/FadedMultiColorTextView.java
@@ -0,0 +1,104 @@
+/* -*- Mode: Java; c-basic-offset: 4; tab-width: 20; indent-tabs-mode: nil; -*-
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
+
+package org.mozilla.gecko.widget;
+
+import org.mozilla.gecko.R;
+
+import android.content.Context;
+import android.content.res.ColorStateList;
+import android.content.res.TypedArray;
+import android.graphics.Canvas;
+import android.graphics.Color;
+import android.graphics.LinearGradient;
+import android.graphics.Paint;
+import android.graphics.Shader;
+import android.util.AttributeSet;
+
+/**
+ * Fades the end of the text by gecko:fadeWidth amount,
+ * if the text is too long and requires an ellipsis.
+ *
+ * This implementation is an improvement over Android's built-in fadingEdge
+ * but potentially slower than the {@link org.mozilla.gecko.widget.FadedSingleColorTextView}.
+ * It works for text of multiple colors but only one background color. It works by
+ * drawing a gradient rectangle with the background color over the text, fading it out.
+ */
+public class FadedMultiColorTextView extends FadedTextView {
+    private final ColorStateList fadeBackgroundColorList;
+
+    private final Paint fadePaint;
+    private FadedTextGradient backgroundGradient;
+
+    public FadedMultiColorTextView(Context context, AttributeSet attrs) {
+        super(context, attrs);
+
+        fadePaint = new Paint();
+
+        final TypedArray a = context.obtainStyledAttributes(attrs, R.styleable.FadedMultiColorTextView);
+        fadeBackgroundColorList =
+                a.getColorStateList(R.styleable.FadedMultiColorTextView_fadeBackgroundColor);
+        a.recycle();
+    }
+
+    @Override
+    public void onDraw(Canvas canvas) {
+        super.onDraw(canvas);
+
+        final boolean needsEllipsis = needsEllipsis();
+        if (needsEllipsis) {
+            final int right = getWidth() - getCompoundPaddingRight();
+            final float left = right - fadeWidth;
+
+            updateGradientShader(needsEllipsis, right);
+
+            final float center = getHeight() / 2;
+            final float top = center - getTextSize();
+            final float bottom = center + getTextSize();
+
+            canvas.drawRect(left, top, right, bottom, fadePaint);
+        }
+    }
+
+    private void updateGradientShader(final boolean needsEllipsis, final int gradientEndRight) {
+        final int backgroundColor =
+                fadeBackgroundColorList.getColorForState(getDrawableState(), Color.RED);
+
+        final boolean needsNewGradient = (backgroundGradient == null ||
+                                          backgroundGradient.getBackgroundColor() != backgroundColor ||
+                                          backgroundGradient.getEndRight() != gradientEndRight);
+
+        if (needsEllipsis && needsNewGradient) {
+            backgroundGradient = new FadedTextGradient(gradientEndRight, fadeWidth, backgroundColor);
+            fadePaint.setShader(backgroundGradient);
+        }
+    }
+
+    private static class FadedTextGradient extends LinearGradient {
+        private final int endRight;
+        private final int backgroundColor;
+
+        public FadedTextGradient(final int gradientEndRight, final int fadeWidth,
+                final int backgroundColor) {
+            super(gradientEndRight - fadeWidth, 0, gradientEndRight, 0,
+                  getColorWithZeroedAlpha(backgroundColor), backgroundColor, Shader.TileMode.CLAMP);
+
+            this.endRight = gradientEndRight;
+            this.backgroundColor = backgroundColor;
+        }
+
+        private static int getColorWithZeroedAlpha(final int color) {
+            return Color.argb(0, Color.red(color), Color.green(color), Color.blue(color));
+        }
+
+        public int getEndRight() {
+            return endRight;
+        }
+
+        public int getBackgroundColor() {
+            return backgroundColor;
+        }
+    }
+}
new file mode 100644
--- /dev/null
+++ b/mobile/android/base/widget/FadedSingleColorTextView.java
@@ -0,0 +1,74 @@
+/* -*- Mode: Java; c-basic-offset: 4; tab-width: 20; indent-tabs-mode: nil; -*-
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
+
+package org.mozilla.gecko.widget;
+
+import android.content.Context;
+import android.graphics.Canvas;
+import android.graphics.LinearGradient;
+import android.graphics.Shader;
+import android.util.AttributeSet;
+
+/**
+ * Fades the end of the text by gecko:fadeWidth amount,
+ * if the text is too long and requires an ellipsis.
+ *
+ * This implementation is an improvement over Android's built-in fadingEdge
+ * and the fastest of Fennec's implementations. However, it only works for
+ * text of one color. It works by applying a linear gradient directly to the text.
+ */
+public class FadedSingleColorTextView extends FadedTextView {
+    // Shader for the fading edge.
+    private FadedTextGradient mTextGradient;
+
+    public FadedSingleColorTextView(Context context, AttributeSet attrs) {
+        super(context, attrs);
+    }
+
+    private void updateGradientShader() {
+        final int color = getCurrentTextColor();
+        final int width = getAvailableWidth();
+
+        final boolean needsNewGradient = (mTextGradient == null ||
+                                          mTextGradient.getColor() != color ||
+                                          mTextGradient.getWidth() != width);
+
+        final boolean needsEllipsis = needsEllipsis();
+        if (needsEllipsis && needsNewGradient) {
+            mTextGradient = new FadedTextGradient(width, fadeWidth, color);
+        }
+
+        getPaint().setShader(needsEllipsis ? mTextGradient : null);
+    }
+
+    @Override
+    public void onDraw(Canvas canvas) {
+        updateGradientShader();
+        super.onDraw(canvas);
+    }
+
+    private static class FadedTextGradient extends LinearGradient {
+        private final int mWidth;
+        private final int mColor;
+
+        public FadedTextGradient(int width, int fadeWidth, int color) {
+            super(0, 0, width, 0,
+                  new int[] { color, color, 0x0 },
+                  new float[] { 0,  ((float) (width - fadeWidth) / width), 1.0f },
+                  Shader.TileMode.CLAMP);
+
+            mWidth = width;
+            mColor = color;
+        }
+
+        public int getWidth() {
+            return mWidth;
+        }
+
+        public int getColor() {
+            return mColor;
+        }
+    }
+}
--- a/mobile/android/base/widget/FadedTextView.java
+++ b/mobile/android/base/widget/FadedTextView.java
@@ -2,104 +2,46 @@
  * This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 package org.mozilla.gecko.widget;
 
 import android.content.Context;
 import android.content.res.TypedArray;
-import android.graphics.Canvas;
-import android.graphics.LinearGradient;
-import android.graphics.Shader;
-import android.graphics.drawable.Drawable;
 import android.text.Layout;
 import android.util.AttributeSet;
 
 import org.mozilla.gecko.R;
-import org.mozilla.gecko.widget.ThemedTextView;
 
 /**
- * FadedTextView fades the ends of the text by fadeWidth amount,
- * if the text is too long and requires an ellipsis.
+ * An implementation of FadedTextView should fade the end of the text
+ * by gecko:fadeWidth amount, if the text is too long and requires an ellipsis.
  */
-public class FadedTextView extends ThemedTextView {
-
+public abstract class FadedTextView extends ThemedTextView {
     // Width of the fade effect from end of the view.
-    private final int mFadeWidth;
+    protected final int fadeWidth;
 
-    // Shader for the fading edge.
-    private FadedTextGradient mTextGradient;
-
-    public FadedTextView(Context context) {
-        this(context, null);
-    }
-
-    public FadedTextView(Context context, AttributeSet attrs) {
+    public FadedTextView(final Context context, final AttributeSet attrs) {
         super(context, attrs);
 
         setSingleLine(true);
         setEllipsize(null);
 
-        TypedArray a = context.obtainStyledAttributes(attrs, R.styleable.FadedTextView);
-        mFadeWidth = a.getDimensionPixelSize(R.styleable.FadedTextView_fadeWidth, 0);
+        final TypedArray a = context.obtainStyledAttributes(attrs, R.styleable.FadedTextView);
+        fadeWidth = a.getDimensionPixelSize(R.styleable.FadedTextView_fadeWidth, 0);
         a.recycle();
     }
 
-    private int getAvailableWidth() {
+    protected int getAvailableWidth() {
         return getWidth() - getCompoundPaddingLeft() - getCompoundPaddingRight();
     }
 
-    private boolean needsEllipsis() {
+    protected boolean needsEllipsis() {
         final int width = getAvailableWidth();
         if (width <= 0) {
             return false;
         }
 
         final Layout layout = getLayout();
         return (layout != null && layout.getLineWidth(0) > width);
     }
-
-    private void updateGradientShader() {
-        final int color = getCurrentTextColor();
-        final int width = getAvailableWidth();
-
-        final boolean needsNewGradient = (mTextGradient == null ||
-                                          mTextGradient.getColor() != color ||
-                                          mTextGradient.getWidth() != width);
-
-        final boolean needsEllipsis = needsEllipsis();
-        if (needsEllipsis && needsNewGradient) {
-            mTextGradient = new FadedTextGradient(width, mFadeWidth, color);
-        }
-
-        getPaint().setShader(needsEllipsis ? mTextGradient : null);
-    }
-
-    @Override
-    public void onDraw(Canvas canvas) {
-        updateGradientShader();
-        super.onDraw(canvas);
-    }
-
-    private static class FadedTextGradient extends LinearGradient {
-        private final int mWidth;
-        private final int mColor;
-
-        public FadedTextGradient(int width, int fadeWidth, int color) {
-            super(0, 0, width, 0,
-                  new int[] { color, color, 0x0 },
-                  new float[] { 0,  ((float) (width - fadeWidth) / width), 1.0f },
-                  Shader.TileMode.CLAMP);
-
-            mWidth = width;
-            mColor = color;
-        }
-
-        public int getWidth() {
-            return mWidth;
-        }
-
-        public int getColor() {
-            return mColor;
-        }
-    }
 }
--- a/toolkit/mozapps/extensions/internal/XPIProvider.jsm
+++ b/toolkit/mozapps/extensions/internal/XPIProvider.jsm
@@ -5006,18 +5006,21 @@ AddonInstall.prototype = {
   /**
    * Cancels installation of this add-on.
    *
    * @throws if installation cannot be cancelled from the current state
    */
   cancel: function AI_cancel() {
     switch (this.state) {
     case AddonManager.STATE_DOWNLOADING:
-      if (this.channel)
+      if (this.channel) {
+        logger.debug("Cancelling download of " + this.sourceURI.spec);
         this.channel.cancel(Cr.NS_BINDING_ABORTED);
+      }
+      break;
     case AddonManager.STATE_AVAILABLE:
     case AddonManager.STATE_DOWNLOADED:
       logger.debug("Cancelling download of " + this.sourceURI.spec);
       this.state = AddonManager.STATE_CANCELLED;
       XPIProvider.removeActiveInstall(this);
       AddonManagerPrivate.callInstallListeners("onDownloadCancelled",
                                                this.listeners, this.wrapper);
       this.removeTemporaryFile();
@@ -5494,18 +5497,30 @@ AddonInstall.prototype = {
    * @see nsIStreamListener
    */
   onStopRequest: function AI_onStopRequest(aRequest, aContext, aStatus) {
     this.stream.close();
     this.channel = null;
     this.badCerthandler = null;
     Services.obs.removeObserver(this, "network:offline-about-to-go-offline");
 
-    // If the download was cancelled then all events will have already been sent
+    // If the download was cancelled then update the state and send events
     if (aStatus == Cr.NS_BINDING_ABORTED) {
+      if (this.state == AddonManager.STATE_DOWNLOADING) {
+        logger.debug("Cancelled download of " + this.sourceURI.spec);
+        this.state = AddonManager.STATE_CANCELLED;
+        XPIProvider.removeActiveInstall(this);
+        AddonManagerPrivate.callInstallListeners("onDownloadCancelled",
+                                                 this.listeners, this.wrapper);
+        // If a listener restarted the download then there is no need to
+        // remove the temporary file
+        if (this.state != AddonManager.STATE_CANCELLED)
+          return;
+      }
+
       this.removeTemporaryFile();
       if (this.restartDownload)
         this.openChannel();
       return;
     }
 
     logger.debug("Download of " + this.sourceURI.spec + " completed.");
 
--- a/toolkit/mozapps/extensions/test/xpcshell/test_install.js
+++ b/toolkit/mozapps/extensions/test/xpcshell/test_install.js
@@ -559,27 +559,31 @@ function run_test_9() {
       install.install();
     });
   }, "application/x-xpinstall", null, "Real Test 4", null, "1.0");
 }
 
 function check_test_9(install) {
   prepare_test({}, [
     "onDownloadCancelled"
-  ]);
+  ], function() {
+    let file = install.file;
+
+    // Allow the file removal to complete
+    do_execute_soon(function() {
+      AddonManager.getAllInstalls(function(activeInstalls) {
+        do_check_eq(activeInstalls.length, 0);
+        do_check_false(file.exists());
+
+        run_test_10();
+      });
+    });
+  });
 
   install.cancel();
-
-  ensure_test_completed();
-
-  AddonManager.getAllInstalls(function(activeInstalls) {
-    do_check_eq(activeInstalls.length, 0);
-
-    run_test_10();
-  });
 }
 
 // Tests that after cancelling a pending install it is removed from the active
 // installs
 function run_test_10() {
   prepare_test({ }, [
     "onNewInstall"
   ]);
@@ -1008,38 +1012,41 @@ function run_test_14() {
     ], check_test_14);
     install.install();
   }, "application/x-xpinstall");
 }
 
 function check_test_14(install) {
   prepare_test({ }, [
     "onDownloadCancelled"
-  ]);
-
-  install.cancel();
-
-  ensure_test_completed();
+  ], function() {
+    let file = install.file;
 
-  install.addListener({
-    onDownloadProgress: function() {
-      do_throw("Download should not have continued");
-    },
-    onDownloadEnded: function() {
-      do_throw("Download should not have continued");
-    }
+    install.addListener({
+      onDownloadProgress: function() {
+        do_throw("Download should not have continued");
+      },
+      onDownloadEnded: function() {
+        do_throw("Download should not have continued");
+      }
+    });
+
+    // Allow the listener to return to see if it continues downloading. The
+    // The listener only really tests if we give it time to see progress, the
+    // file check isn't ideal either
+    do_execute_soon(function() {
+      do_check_false(file.exists());
+
+      run_test_15();
+    });
   });
 
-  // Allow the listener to return to see if it continues downloading. The
-  // The listener only really tests if we give it time to see progress, the
-  // file check isn't ideal either
+  // Wait for the channel to be ready to cancel
   do_execute_soon(function() {
-    do_check_eq(install.file, null);
-
-    run_test_15();
+    install.cancel();
   });
 }
 
 // Checks that cancelling the install from onDownloadEnded actually cancels it
 function run_test_15() {
   prepare_test({ }, [
     "onNewInstall"
   ]);
@@ -1628,17 +1635,20 @@ function check_test_27(aInstall) {
     ]
   }, [
     "onDownloadStarted",
     "onDownloadEnded",
     "onInstallStarted",
     "onInstallEnded"
   ], finish_test_27);
 
+  let file = aInstall.file;
   aInstall.install();
+  do_check_neq(file.path, aInstall.file.path);
+  do_check_false(file.exists());
 }
 
 function finish_test_27(aInstall) {
   prepare_test({
     "addon3@tests.mozilla.org": [
       "onOperationCancelled"
     ]
   }, [
--- a/toolkit/mozapps/extensions/test/xpcshell/test_install_strictcompat.js
+++ b/toolkit/mozapps/extensions/test/xpcshell/test_install_strictcompat.js
@@ -548,27 +548,31 @@ function run_test_9() {
       install.install();
     });
   }, "application/x-xpinstall", null, "Real Test 4", null, "1.0");
 }
 
 function check_test_9(install) {
   prepare_test({}, [
     "onDownloadCancelled"
-  ]);
+  ], function() {
+    let file = install.file;
+
+    // Allow the file removal to complete
+    do_execute_soon(function() {
+      AddonManager.getAllInstalls(function(activeInstalls) {
+        do_check_eq(activeInstalls.length, 0);
+        do_check_false(file.exists());
+
+        run_test_10();
+      });
+    });
+  });
 
   install.cancel();
-
-  ensure_test_completed();
-
-  AddonManager.getAllInstalls(function(activeInstalls) {
-    do_check_eq(activeInstalls.length, 0);
-
-    run_test_10();
-  });
 }
 
 // Tests that after cancelling a pending install it is removed from the active
 // installs
 function run_test_10() {
   prepare_test({ }, [
     "onNewInstall"
   ]);
@@ -999,38 +1003,41 @@ function run_test_14() {
     ], check_test_14);
     install.install();
   }, "application/x-xpinstall");
 }
 
 function check_test_14(install) {
   prepare_test({ }, [
     "onDownloadCancelled"
-  ]);
-
-  install.cancel();
-
-  ensure_test_completed();
+  ], function() {
+    let file = install.file;
 
-  install.addListener({
-    onDownloadProgress: function() {
-      do_throw("Download should not have continued");
-    },
-    onDownloadEnded: function() {
-      do_throw("Download should not have continued");
-    }
+    install.addListener({
+      onDownloadProgress: function() {
+        do_throw("Download should not have continued");
+      },
+      onDownloadEnded: function() {
+        do_throw("Download should not have continued");
+      }
+    });
+
+    // Allow the listener to return to see if it continues downloading. The
+    // The listener only really tests if we give it time to see progress, the
+    // file check isn't ideal either
+    do_execute_soon(function() {
+      do_check_false(file.exists());
+
+      run_test_15();
+    });
   });
 
-  // Allow the listener to return to see if it continues downloading. The
-  // The listener only really tests if we give it time to see progress, the
-  // file check isn't ideal either
+  // Wait for the channel to be ready to cancel
   do_execute_soon(function() {
-    do_check_eq(install.file, null);
-
-    run_test_15();
+    install.cancel();
   });
 }
 
 // Checks that cancelling the install from onDownloadEnded actually cancels it
 function run_test_15() {
   prepare_test({ }, [
     "onNewInstall"
   ]);
@@ -1619,17 +1626,20 @@ function check_test_27(aInstall) {
     ]
   }, [
     "onDownloadStarted",
     "onDownloadEnded",
     "onInstallStarted",
     "onInstallEnded"
   ], finish_test_27);
 
+  let file = aInstall.file;
   aInstall.install();
+  do_check_neq(file.path, aInstall.file.path);
+  do_check_false(file.exists());
 }
 
 function finish_test_27(aInstall) {
   prepare_test({
     "addon3@tests.mozilla.org": [
       "onOperationCancelled"
     ]
   }, [