Let’s Bring the Home Button Animation of Pixel Phone to Nexus on Android 7.1.1

Google announced two Pixel phones on 9 October. These phones are coming up with new navigation bar, as an open source world, we have got the new white button of Pixel navigation bar, but all the mod was lack an interesting things, it is the Home button animation when activating Google Assistant, four dots slide out in each respective direction, and then quickly aligning themselves horizontally.

After analysis the code of SystemUI.apk, I’m succeed in modifying the app to enable the animation. This mod is for Nexus 5X/6P with Android N 7.1.1 DP1, it can give you the full experience of Pixel phone.

Before you download the mod, I’d like to tell you how the animation being actived.

As we know, Google Assistant is one of the features which is unique to the Google Pixel phones, I think you already know how to enable Google Assistant on Nexus phones, and using the Pixel launcher, somehow when you unlock the Google Assistan, you just active the ability to active the Home button animation, actually Google Search App will tell the system to enable the animation every time you boot up the Nexus phone, but the phone just not received the signal, we need to digg in the SystemUI to find the reason.

What is sending the signal of Home button animation:

new-instance v1, Landroid/content/Intent;
const-string v2, "com.google.android.systemui.OPA_ENABLED"
invoke-direct {v1, v2}, Landroid/content/Intent;->(Ljava/lang/String;)V
const-string v2, "OPA_ENABLED"
invoke-virtual {v1, v2, v0}, Landroid/content/Intent;->putExtra(Ljava/lang/String;Z)Landroid/content/Intent;
invoke-virtual {p1, v1}, Landroid/content/Context;->sendBroadcast(Landroid/content/Intent;)V

OPA_ENABLED is the key, as you may remember how to enable Google Assistan, there is also an opa in the line. I Compared the Nexus’s SystemUI file with Pixel’s, Nexus’s SystemUI are lack of the animation resources and functions. One good thing is, the function’s code is separate with main functions. First, import everything related to Pixel’s style resources, this is an easy job. The hard part is the control function. I have found an BroadcastReceiver to receive the animation signal and trun it on, but it’s write in AndroidManifest but I can’t change it, as that will make the system boot failure. I need to find other solution.

Finally, I made it, tracking the animation logic, I have found the key code to change the original function, force the program to think have received it signal and enabled the Opa animation.

Here is the Guide for who was interesting in how to port Pixel animation.

Nav bar animation Pixel

Let’s play the screen record video.

How to apply the mod:

This mod is only for Nexus 5X/6P running stock Android 7.1.1 DP1. DO NOT try on other roms especially 7.1 / 7.0 custom roms. And DO Make a Backup first.

To apply the mod, download the flashable package, flash it in TWRP recovery(if you don’t know what is TWRP, don’t do anything further, you may mess your phone, search for “how to unlock Nexus” to understand the risks.). ( Backup is very important! )

If it doesn’t work, you can try apply it manually.
1. Download the flashable package, extract the SystemUI.apk in the package, use any root file manager to put it to /System/priv-app/SystemUI/ directory, set its permission to rw-r-r.
2. It’s normal if a FC warning popup, just reboot the phone.

Update 11/13
Clean the Mod, add flashable package, and Nexus 6P version.

If you get FC when tap on the home button, try reset the syste UI tuner settings.

Download link:
(I repeat again before you click the link, if you don’t know what is TWRP recovery, don’t do anything further, you may mess your phone, search for “how to unlock Nexus” to understand the risks.).
Nexus 5X:
Pixel Home Button Animation Mod for Nexus 5X (Flashable zip)
If google drive overload, try Mega mirror | AFH mirror

Nexus 6P: PS. As I did not own this device, it’s not been tested, tell me if something goes wrong, make backup first! Confirm working
Pixel Home Button Animation Mod for Nexus 6P (Flashable zip)
If google drive overload, try Mega mirror | AFH mirror

Back to stock flashable zip download:
Discussion on XDA-Dev forum
N5X Thread
N6P Thread

Taggs: , , , .
Posted in Android Share, Featured, Nexus 5X