Sunday, September 4, 2016

[Help] Xposed module for whatsapp implement last seen tweaks.

hi, I've developed an xposed module for whatsapp.
http://ift.tt/2c3QFnM

I wanted to add feature to hide our own last seen still see others or report a fake last seen for eg: 1 Jan 1970.

I made following assumptions:
To do that first I hooked date and System.currentTimeInMillis methods to make whatsapp think its 1 Jan 1970. That worked but still last seen was shown perfectly.

Assumption: The last seen time value is directly taken from the server

Then I looked in the source to find where last_seen preference is referenced. Turns out it is only referenced in SettingsPrivacy activity's class.

Assumption: To hide our last seen ans see others we need to change last seen preference to 'visible to all' and turn that back to off once we get the last seen.

but the problem is it uses onPreferenceChangeListener. We cannot hook a method from the interface directly.

I cannot find the subclass which implements onPreferenceChangeListener as the classes shown in code are synthetic.
Please if anyone can help me with this, it will be great. I need to find which is preferencechangelistener for that preference. Rest I will manage.

Thanks.


from xda-developers http://ift.tt/2bNN4x2
via IFTTT

No comments:

Post a Comment