Hi guys! Here's how you add roaming options to phone.apk. I forgot where I got this apk from, but I decided to dissect it and figure out how to do it to the new OTA. What I do remember, is that it came from Synergy, so thanks goes to TrevE and the whole Synergy team.
Step 1: Start off by decompiling Phone.apk with apktool, apk manager, or apk multi-tool.
Step 2: Navigate to res\values\arrays.xml and open it in Notepad++ or whatever editor you use.
Step 3: FIND:
ADD:
FINAL RESULT:
Step 4: FIND:
ADD:
FINAL RESULT:
Step 5: Navigate to com\android\phone\cdmaroaminglistpreference$myhandler.smali and open with your editor.
Step 6: FIND:
NOTE: You should only have to search for
, as the rest MAY not look like that.
CHANGE:
INTO:
Step 6: Navigate to com\android\phone\cdmaroaminglistpreference.smali and open with editor:
Step 7: FIND AROUND:
NOTE: There will be multiple occurences if this, but you should only need to find around ".line 84", which is the first occurence.
CHANGE:
INTO:
Step 8: Recompile Phone.apk and push to phone, chmod with 0644, or create flashable zip and flash in recovery.
For convenience, I've attached a flashable zip below. This is based on software version 2.17.651.5.
KNOWN ISSUES: "Roaming only" doesn't show up as "ticked" when you select it. However, it still works, and is only a minor cosmetic flaw.
Step 1: Start off by decompiling Phone.apk with apktool, apk manager, or apk multi-tool.
Step 2: Navigate to res\values\arrays.xml and open it in Notepad++ or whatever editor you use.
Step 3: FIND:
Code:
<string-array name="cdma_system_select_choices_sprint">
<item>Sprint only</item>
<item>Automatic</item>
ADD:
Code:
<item>Roam only</item>
FINAL RESULT:
Code:
<string-array name="cdma_system_select_choices_sprint">
<item>Sprint only</item>
<item>Automatic</item>
<item>Roam only</item>
</string-array>
Step 4: FIND:
Code:
<string-array name="cdma_system_select_values_sprint">
<item>0</item>
<item>2</item>
</string-array>
ADD:
Code:
<item>3</item>
FINAL RESULT:
Code:
<string-array name="cdma_system_select_values_sprint">
<item>0</item>
<item>2</item>
<item>3</item>
</string-array>
Step 5: Navigate to com\android\phone\cdmaroaminglistpreference$myhandler.smali and open with your editor.
Step 6: FIND:
Code:
.local v1, settingsRoamingMode:I
if-eqz v2, :cond_0
const/4 v3, 0x2
if-eq v2, v3, :cond_0
const/4 v3, 0x3
NOTE: You should only have to search for
Code:
.local v1, settingsRoamingMode:I
CHANGE:
Code:
const/4 v3, 0x3
Code:
const/4 v3, 0x1
Step 6: Navigate to com\android\phone\cdmaroaminglistpreference.smali and open with editor:
Step 7: FIND AROUND:
Code:
.line 84
.end local v2 #statusCdmaRoamingMode:I
:pswitch_1
const/4 v2, 0x3
NOTE: There will be multiple occurences if this, but you should only need to find around ".line 84", which is the first occurence.
CHANGE:
Code:
const/4 v2, 0x3
Code:
const/4 v2, 0x1
Step 8: Recompile Phone.apk and push to phone, chmod with 0644, or create flashable zip and flash in recovery.
For convenience, I've attached a flashable zip below. This is based on software version 2.17.651.5.
KNOWN ISSUES: "Roaming only" doesn't show up as "ticked" when you select it. However, it still works, and is only a minor cosmetic flaw.
Attachments
Last edited: