I have developed an android app that uses a timer with a call back. When a specific criteria has been satisfied, the app either rings or vibrates the phone depending on user settings. It will continue to ring until the user acknowledges an alert box. This all works fine. However, if the user has brought another app to the front then he may not realize it is my app causing the phone to ring and re-open it. Is there a way I can force my App to the front or at least the Alert Message to be on top of anything else?
Notifications are your friend. They wont interrupt a users workflow and with the new JellyBean apis you can put actions and other dynamic components in them.
Instead of doing that, you could just use a notification with a specific ringtone once it has been sent instead of annoying the user this way.
Related
I wonder if it is possible to build an application for Android that waits for incoming calls and only allows the ones that are in an internal white list to show and make sound.
I know this is what a normal call blocker would do and I know that it is possible..however what I really want is:
If a call arrives that is not in the white list, I don't want to reject it, I don't want the caller to know the call was rejected. I just want my app to be aware of it but make it invisible to the current phone app. I could mute the phone and the call wouldn't ring but the phone app would still popup in front of everything or at least on the status bar.
If a call arrives and it is in the white list then the app would do nothing..just allow the phone app to treat it.
I think I can do this by implementing my own dialer app, but would much prefer not having to do that and just use whatever the user already has.
Thank you
Carlos
Here is the thing, I am not used to the latest android yet and the new system is giving me some confusions. Usually, for the older androids, if I close all background apps, I won't get new notifications from them. But after switching to a new phone with the latest android, I realized that even if I do close all background apps, I still keep getting notifications from them. So, how are the apps still pushing notifications if I already close them from background?
(Say google maps for example, I am 100% sure I killed it in background but now it keeps notifies me about my live traffic status on my notification bar.)
So Here's the answer-
Yes, they are. Whenever the Internet is turned on or you get a message, listener of that app wakes up and check for any notification and if there is something new, it shows you the notification.
These apps keep running in the background if not put in sleep mode by your phone and use the resources.
Like you don't want to get notified by WhatsApp for a new message but the moment you change the network, unlock your phone again or turn the data on, an event listener will wake up and notify you of new messages.
Also, wake timers are used to notify you after some fixed time like after every 5 minutes.
This is the thing I hate the most.
Not promoting but here's the app - search play store for Shutapp - Real battery saver (Blocked from Play store a while ago and doesn't work anymore for "obvious" reasons). It will turn off all the background apps and you'll be amazed to see a long list on first use.
This will remove all the apps from background until you open them again. I use this app most of the time and it really works great.
Try this out.
I installed an app on my android phone to safe lock certain apps with a password. Since I installed it, sometimes, regardless what i'm doing on the phone/which app i'm using, a full size screen with advertising appears and I have to click an "X" to close it or press back/home button.
(Can be that this screen appears randomly only when I digited a password to unlock an app therefore the safe lock app was active let's say, not sure.)
I was anyway wondering what sort of code is used for this? Anyone?
I'd need it for a less despicable cause: in order to show a transparent view with alertdialog when my timer is up and the app is closed, to imitate the original builtin countdown timer.
Have a look on the below pic
The foreground pop up is handsent sms app.The back ground is my app. My problem is whenever an sms received popup window opens.The bad thing is even my app runs .Their pop up box may disturb my app users.How can block their pop up on my screens. The dafault sms app is opened then handsent sms app wont show popup on the window.Like that I also want to block other popup on my app screens.
Their pop up box may disturb my app users..How can block their pop up on my screens
You don't know that. This is not something you should try to control, if the user has an app that pops up, that is probably their preference. Your app should however be prepared for interruptions, i.e handle your app's lifecycle properly
My app is using the new VoicemailContract functionality in ICS to insert voicemails that show up in the stock call log. I've got it working perfectly, but I can't figure out how to control the new Voicemail notification that pops up when the new voicemails are added. The notifications seem to be controlled by the Phone app, and even if I manually update the voicemail's IS_READ attribute, the notification doesn't go away. In fact, I can delete the voicemail altogether, and the notification doesn't go away. The only way that it goes away is if that notification is clicked, or if I manually go into the call log and open one of the new voicemails.
Does anyone have any idea on how to control that programmatically from my app?
Unfortunately you can't. Status bar notifications can only be cleared by the app that placed them there. The phone app is the app that placed it there and this is why only that app is able to clear it.
I wish there was a way to do this myself, but currently, there is not :(