revanced-patches icon indicating copy to clipboard operation
revanced-patches copied to clipboard

feat(X / Twitter): Get Back Twitter Bird

Open monefiera opened this issue 1 year ago • 9 comments

Feature description

A patch to revert the ugliest X brand back to the beloved Twitter.
LarryOnX LSPosed module is flawed in that it can't log in from no login statement.
I know I can revert it by rewriting some codes in the res directory, but I haven't had ability to make patcher of this...

These are methods I found after months of research and analysis to return this apk.

â‘ Replace all capital "X " with "Twitter" in res\values(-Country Code)\strings.xml.

  • It is the most important thing I think.

â‘¡All "post" word replace to "tweet" in res\values(-Country Code)\strings.xml (if it's possible)

  • Unfortunately however, some parts, such as the Notification column, get their text directly from the server and cannot be completely restored.

â‘¢In the following internal file, replace "dynamicColorGray1100" to "@color/twitter_blue".

  • res\layout\ocf_twitter_logo.xml
  • res\layout\channels_toolbar_main.xml
  • [windowSplashScreenBackground] in res\values\styles.xml
  • [ic_launcher_background] in res\values\colors.xml

â‘£These files contain ugly "X" logo vector data. Replace this with the version 9.98.0-release-0's code.

  • res\drawable\ic_vector_twitter.xml
  • res\drawable\ic_vector_twitter_white.xml
  • res\drawable\splash_screen_icon.xml
  • and app icon change from res\mipmap & others

⑤(edit 2024/01/08)Elon even went further in his misdeed by altering the birdcage. You can replace the vector file here to restore the original.

  • res\drawable\ic_vector_home.xml
  • res\drawable\ic_vector_home_stroke.xml

â‘¥The webp in these drawable-hdpi and others also contain logos that should be modified. However, I think it won't matter much.

  • identity.webp
  • ic_stat_twitter.webp

Motivation

Many users seem to avoid the ugly "X," and in fact there are extensions such as Control Panel for Twitter and Twitter UI Customizer that revert changes made to the web version.
I crave this feature on mobile and I'm actually using apk(modified by me), but a patch function would make this much easier to achieve.

Acknowledgements

  • [X] This issue is not a duplicate of an existing feature request.
  • [X] I have chosen an appropriate title.
  • [X] All requested information has been provided properly.

monefiera avatar Nov 24 '23 17:11 monefiera

https://github.com/ReVanced/revanced-patches/issues/543

monefiera avatar Nov 24 '23 17:11 monefiera

Complicated patches

cyberboh avatar Nov 25 '23 05:11 cyberboh

This should definitely be intregrated, as older versions of the app, including the very last one to have Twitter branding, recently broke and now will not show quote tweets at all.

aubymori avatar Jan 11 '24 22:01 aubymori

Also, @monefiera, consider re-uploading your APK on a file sharing site that isn't complete shit.

aubymori avatar Jan 11 '24 22:01 aubymori

@aubymori OK, I put the link here using a different uploader as I already make newer version (10.26.0) that does the same thing! This includes not only design changes, but also the addition of a mod by the great therealswak. https://gofile.io/d/4ah7KL

monefiera avatar Jan 12 '24 00:01 monefiera

â‘ Replace all capital "X " with "Twitter" in res\values(-Country Code)\strings.xml.

It is the most important thing I think.

There are many words like EXAMPLE, & more with Capital X

This is just an example for you. I've checked string.xml, you can't just replace all capital X with Twitter

Same goes for post also.

kazimmt avatar Feb 15 '24 09:02 kazimmt

â‘ Replace all capital "X " with "Twitter" in res\values(-Country Code)\strings.xml. It is the most important thing I think.

There are many words like EXAMPLE, & more with Capital X

This is just an example for you. I've checked string.xml, you can't just replace all capital X with Twitter

Same goes for post also.

This is true, and I understood that rewriting all the strings would be difficult to process (that's why I wrote "if possible" in the POST section). Also, it turns out that changing to Twitter will also crash if we are not careful (it will not start if the values of google_api_key and google_crash_reporting_api_key are rewritten). Currently, we believe that renaming the app and restoring the design would be optimal. By the way, patches to achieve this is under development and I hope it will be integrated into this patch.

monefiera avatar Mar 06 '24 14:03 monefiera

This is an addendum to my previous post. In strings, there are items called google_api_key and google_crash_reporting_api_key, which contain an uppercase X. Changing this will cause the app to crash. Since this is a value that does not change with version upgrades, it would be easy to patch to replace X→Twitter if only a workaround is provided here. However, according to apkmirror, the app is available in 41 languages, and replacing all of them is obviously not practical.

monefiera avatar Mar 22 '24 16:03 monefiera

/(?<=^| )X(?=$| )/g? or something like that

aubymori avatar Mar 22 '24 16:03 aubymori

Over time, a lot of feature requests have been made, which is why I am closing some according to the contribution guidelines:

Requests can be accepted or rejected at the discretion of maintainers of ReVanced Patches

This feature request has been closed for one or more of the following reasons:

  • Stale for too long
  • Low priority
  • Maintainers un-interested
  • Too complex to realize

Regardless, anyone who comes across this feature request can PR it. Thanks for the feature request!

oSumAtrIX avatar Jun 01 '24 21:06 oSumAtrIX