[GUIDE]Add “Delete” button to the screenshot preview

Hey, guys, we know that some ROMs don’t have the “Delete” button on the screenshot preview like the Sony Xperia series. Hence, here is the guide that can help you add “Delete” button to your screenshot preview.
1.    Copy the “system/priv-app/SystemUI.apk” to you computer;
2.    Decompile it (if you are using an odexed ROM, you need to combine the “SystemUI.apk” and “SystemUI.odex” first);
3.    Open “SystemUI/res/values/strings.xml” and add these two line below;

4. Unzip the “add_delete_button.zip” provided here below and copy it to “SystemUI/”;
5. Open “SystemUI/smali/com/android/systemui/screenshot/ SaveImageInBackgroundTask.smali” and you will find this line:

6. Add these lines below:

7. Change the addresses “v8, v5, v12, v17, v23, v22, v21, v20, v19” to the correct addresses.
[code language=”plain” title=”For example(For C6833_HK_108):”]
Before – After
v8 – v15
v5 – v3
v12 – v11
v17 – v16
v23 – v22
v22 – v21
v21 – v20
v20 – v19
v19 – v18[/code]
8. Compile the package and then decompile it;
9. Open “SystemUI/smali/com/android/systemui/screenshot/DeleteScreenshot.smali” and you will find this line and then replace it with yours’:

10. Open “SystemUI/smali/com/android/systemui/screenshot/ SaveImageInBackgroundTask.smali” and you will find these two lines and then replace the values with yours’:

11. Open “SystemUI/ AndroidManifest.xml” and you will find this line below (if can’t, please search the keyword “screenshot”, and you will find a similar sentence):

12. Change it to:

13. Compile it and then copy it to your phone, enjoy!

Leave a Reply

Your email address will not be published. Required fields are marked *

Translate »