alibaba / dexposed

dexposed enable 'god' mode for single android application.
4.51k stars 1.07k forks source link

How can I load the patch's image resource? #65

Closed milk1990 closed 7 years ago

milk1990 commented 8 years ago

In the project, I want to load some new Image,but all of them in the patch package,I use some methods as I know,but it dones't work!

hwjump commented 8 years ago

You want patch the resourceļ¼Œfirst you should hook the AssetManager.addAssetPath() and add your patch resource into system, then you should hook Resources.getDrawable() and TypedArray.getDrawable() and return your patch's image resource. And also you need make sure your patch's image resource has different resource ID number. These were what I did, hope it could help you.

milk1990 commented 8 years ago

thanks very much