Will Verduzco · Dec 1, 2013 at 06:00 pm

Write to SMS Content Provider in KitKat without Being Default SMS App

Alongside the various user-facing and security-related changes introduced Android 4.4 KitKat, Google also significantly modified how the SMS Content Provider works. In Android 4.4, users can now select a default SMS app from within Settings -> Wireless & Networks. Then, two intent broadcasts are sent: one for all SMS apps (SMS_RECEIVED_ACTION) and one for only the default SMS app (SMS_DELIVER_ACTION). Thus, non-default SMS apps are able to receive incoming SMS messages, but they are not able to do certain things such as abort the broadcast.

Despite the positive effect on software modularity afforded by being able to select a default SMS app, the change also brings a few limitations. Namely, in order to delete (or restore) an SMS message, your app must temporarily become the default app if it isn’t already. This is problematic from a UX standpoint because there will be two mandatory prompts, where the user must select the default SMS app: one to select your app and one to revert.

Thankfully, XDA Senior Member stepic came up with a workaround that allows app developers to write to the SMS Content Provider in KitKat without being the default SMS app. Stepic made his discovery by looking in the Android source code and finding a special permission: OP_WRITE_SMS. Unfortunately, this workaround either requires user interaction or root access. However, this is only a one-time affair, rather than two prompts for user input every time a non-default SMS app needs to perform certain tasks.

If you’re an app developer looking to make an SMS app for KitKat, head over to the guide thread to learn more about this workaround.


_________
Want something on the XDA Portal? Send us a tip!
Emil Kako · Feb 1, 2015 at 02:54 pm · no comments

Good Games to Show off Graphics on My Phone?

Mobile games may not be ready to replace your consoles, but they have seen incredible improvements over the years. What are some of your favorite graphic-intensive games to show off how powerful your device is?

DISCUSS
Pulser_G2 · Feb 1, 2015 at 11:30 am · no comments

ITaaS – Identity Theft as a Service with FileThis

It's not often I look at a product or service and say "I really really hope this isn't real, and it's an elaborate fake". Alas, this day has come. It's time for a look at something which cropped up on my radar today, namely a service called FileThis. I won't do them the search-engine-ranking honor of providing a direct link to their site, but a quick search will find them, and their app on the Play Store and iTunes store....

XDA NEWS
Emil Kako · Jan 31, 2015 at 02:59 pm · 2 comments

Do You Prefer Physical or on Screen Buttons?

More and more smartphone manufacturers have been moving towards on-screen buttons, with Google really pushing for it over the physical button alternative. However, there are still a few OEMs (we're looking at you, Samsung) that have preferred to keep things a bit more traditional. Tell us which way you prefer and why.

DISCUSS