Closed zakhao closed 4 years ago
I'm using Android 7.0
Can you give me a bit more information on what the situation is, what device you are using, and just a bit more info around this, in general?
In the sample code. When I do the testing, I find out when receive MMS, It will trigger MMsReceiver. But Never go to MmsReceivedReceiverImpl. I use debug at PushReceiver(in Library) to follow the code. I realize in DownloadManager, isNotificationExist will always return False. Delete it will make MMS working. After delete it, Library is working for my own project as well. Mobile is Android 7.0, it has Dual SIM. Not sure if it is for this reason
What type of device do you have?
Removing that is just going to remove the check for whether or not the notification that the MMS is available is saved to the MMS database. I don't think it will really hurt anything to remove it, just seems weird that your device doesn't have that notification in the database.
I'm using "MIUI 10" (popular customized system in China, Millions of people are using) Android system. Mobile device is XiaoMi 9. With out notification check, The MMS still saved to MMS database. I also checked the code from QKSMS(https://github.com/moezbhatti/qksms). He is using your library. But modified some of them. It's working in my system. The notification check is return True. You may check the difference of the code from him and yours. Hope that can help you.
The functions are the exact same between my app and that one, there is no difference at all, since your aren't on kitkat.
Anyways, I don't see any harm in removing it. Removing that check isn't going to cause additional failures. I released a new version of the library yesterday.
Under some situations, Unable to receive MMS in some cases, need to modify 3 lines of code in the following file. File: android-smsmms/library/src/main/java/com/android/mms/transaction/DownloadManager.java
Need delete these 3 lines of code: // TransactionService can keep uri and location in memory while SmsManager download Mms. if (!isNotificationExist(context, location)) { return; }
Then receiving MMS is working perfectly.