• Introducing XDA Computing: Discussion zones for Hardware, Software, and more!    Check it out!

[GUIDE] Modify mms.apk

Search This thread

deltaquarty

Senior Member
Jan 17, 2012
65
20
Mantova
this is a step-by-step guid to modify your mms.apk in order to modify the MMStoSMS limit and max receiver per message, it works with custom roms

1 download Apk Manager from here (thanks to Daneshm90)
Apk Manager 4.9
(windows only)

extract apk manager

copy your mms.apk file from /system/app
and twframework-res.apk from /system/framework to your computer
copy mms.apk into place-apk-here-for-modding folder

start script.bat

select option 22 (Set current project)

select mms.apk from the list that appear

select option 10 (decompile apk with dependencies)

when asks for dependencies drag and drop twframework-res.apk into the window
then select enter, let it work, don't close apk manager at the end of his work!!!

open apk_manager/projects/Mms.apk folder

go in /res/xml and open mms_config.xml, you can use notepad or every text editor you like

go to
Code:
<int name=”recipientLimit”>10</int>
and change it to
Code:
<int name=”recipientLimit”>100</int>
with this option you can max the number of receiver person in a message up to 100

now go to
Code:
<int name=”smsToMmsTextThreshold”>4</int>
and change it to
Code:
<int name=”smsToMmsTextThreshold”>100</int>
this way you can make up to 100 SMS before it automatically converts it into an MMS

save and close

now we will make a modify so the sms we receive doesn't show the time we RECEIVE the message, but the real time the SENDER wrote the message :D

go to /smali/com/android/mms/transaction/SmsReceiverService.smali
open it with any text editor
search this line
Code:
invoke-static {}, Ljava/lang/System;->currentTimeMillis()J
substitute all the line with this
Code:
invoke-virtual {p1}, Landroid/telephony/SmsMessage;->getTimestampMillis()J
now search the line
Code:
invoke-static {}, Ljava/lang/System;->currentTimeMillis()J
(it's the same line but it's correct don't worry, there are 2 of them :D )

substitute all the line with this
Code:
invoke-virtual {v0}, Landroid/telephony/gsm/CbMessage;->getTimestampMillis()J
save and close

now return to apk manager
select option 11 (compile apk)
select yes (y) to both the question
let it finish, now don't close apk manager yet, open apk manager folder, you will find a new folder named keep, open it and go for the file mms_config.xml (/res/xml) delete it, also delete resources.arsc e classes.dex in main keep folder

now return to apk manager and press enter on the script
when the work is done close the program (option 24)
go to place-apk-here-for-modding folder and you'll find 2 files, delete the mms.apk file and rename the Unsignedmms.apk file to "Mms.apk"
(REMEMBER TO MAKE BACKUP OF ORIGINAL Mms.apk file in order to quickly backup in case of error :D )
copy this file back to /system/app in your phone, overwrite the original file
enjoy :D
 
Last edited:

deltaquarty

Senior Member
Jan 17, 2012
65
20
Mantova
thanks dude. is it works all gb roms?
hi :D the first part, concerning the changing of max message size and max receiver works with all phones, personally i tested it with samsung i9001, i9000,i9003 and s5570, the second part, concerning the time the sms was SENT instead of RECEIVED works only with phones that have CB options inside, for example on s5570, the 2° part doesn't work, because the phone doesn't have CB messages options in sms app, understand?
 

iscio

Senior Member
Aug 23, 2011
486
81
42
Bergamo
you mean sg2? however yes, it works for all android phones :D

yes sorry but I have no dipendencies from twframeworks...I try to modify the mms.apk without dipendencies but when I put it on the phone I see again the received time
 

Attachments

  • Immagine.jpg
    Immagine.jpg
    50.2 KB · Views: 135
Last edited:

Top Liked Posts

  • There are no posts matching your filters.
  • 11
    this is a step-by-step guid to modify your mms.apk in order to modify the MMStoSMS limit and max receiver per message, it works with custom roms

    1 download Apk Manager from here (thanks to Daneshm90)
    Apk Manager 4.9
    (windows only)

    extract apk manager

    copy your mms.apk file from /system/app
    and twframework-res.apk from /system/framework to your computer
    copy mms.apk into place-apk-here-for-modding folder

    start script.bat

    select option 22 (Set current project)

    select mms.apk from the list that appear

    select option 10 (decompile apk with dependencies)

    when asks for dependencies drag and drop twframework-res.apk into the window
    then select enter, let it work, don't close apk manager at the end of his work!!!

    open apk_manager/projects/Mms.apk folder

    go in /res/xml and open mms_config.xml, you can use notepad or every text editor you like

    go to
    Code:
    <int name=”recipientLimit”>10</int>
    and change it to
    Code:
    <int name=”recipientLimit”>100</int>
    with this option you can max the number of receiver person in a message up to 100

    now go to
    Code:
    <int name=”smsToMmsTextThreshold”>4</int>
    and change it to
    Code:
    <int name=”smsToMmsTextThreshold”>100</int>
    this way you can make up to 100 SMS before it automatically converts it into an MMS

    save and close

    now we will make a modify so the sms we receive doesn't show the time we RECEIVE the message, but the real time the SENDER wrote the message :D

    go to /smali/com/android/mms/transaction/SmsReceiverService.smali
    open it with any text editor
    search this line
    Code:
    invoke-static {}, Ljava/lang/System;->currentTimeMillis()J
    substitute all the line with this
    Code:
    invoke-virtual {p1}, Landroid/telephony/SmsMessage;->getTimestampMillis()J
    now search the line
    Code:
    invoke-static {}, Ljava/lang/System;->currentTimeMillis()J
    (it's the same line but it's correct don't worry, there are 2 of them :D )

    substitute all the line with this
    Code:
    invoke-virtual {v0}, Landroid/telephony/gsm/CbMessage;->getTimestampMillis()J
    save and close

    now return to apk manager
    select option 11 (compile apk)
    select yes (y) to both the question
    let it finish, now don't close apk manager yet, open apk manager folder, you will find a new folder named keep, open it and go for the file mms_config.xml (/res/xml) delete it, also delete resources.arsc e classes.dex in main keep folder

    now return to apk manager and press enter on the script
    when the work is done close the program (option 24)
    go to place-apk-here-for-modding folder and you'll find 2 files, delete the mms.apk file and rename the Unsignedmms.apk file to "Mms.apk"
    (REMEMBER TO MAKE BACKUP OF ORIGINAL Mms.apk file in order to quickly backup in case of error :D )
    copy this file back to /system/app in your phone, overwrite the original file
    enjoy :D
    2
    could you update the guide with the possibility to change received time in sent time?
    thanks
    with this guide the time you see in received message is the tiem the message was sent, not received :D
    1
    thanks dude. is it works all gb roms?
    1
    wow thank you dude, maybe I'll develop a nice ROM.... ;)

    Send with Tapatalk on my Samsung Galaxy S i9000 @Android 4.0.3 AOKP

    i'm glad you find my guide useful :D

    Sent from my GT-I9001 using xda premium
    1
    can anyone send me a stock mms.apk :D plss. accidentally un installed it :(
    for i9001? which telephone? :D