But how does WhitePages handle this? They are able to show a dialog on top of the incoming caller screen. See following image: http://gadgetophilia.com/wp-content/uploads/2008/10/callerid.png
How can I show a notification like this and dismiss it when the caller state has changed? // Ronald On Aug 21, 1:03 am, "Roman ( T-Mobile USA)" <roman.baumgaert...@t- mobile.com> wrote: > Are you referring "call picked up" to "call is accepted"? > > After the call is accepted (state CALL_STATE_OFFHOOK) you are able to > get your dialog displayed but not earlier (at least I was not able to > manage this ....) > > -- > Roman Baumgaertner > Sr. SW Engineer-OSDC > ·T· · ·Mobile· stick together > The views, opinions and statements in this email are those of the > author solely in their individual capacity, and do not necessarily > represent those of T-Mobile USA, Inc. > > On Aug 18, 7:18 pm, "[email protected]" <[email protected]> > wrote: > > > > > My last ditch effort to get my idea working is this. > > > Let Android perform the default action on an incoming call (run the in- > > call screen) but at the same time run my app. Since I am not looking > > to replace the actual telephone actions, only the pre-pick-up actions, > > my app would terminate immediately when the phone call is "picked > > up". My app doesn't require very many widgets and could run as a > > dialog. Running as a dialog, hypothetically, would allow the in-call > > screen to remain visible, which would allow it to run more or less > > without serious interruption. Assuming it is possible for Android to > > start the default in-call screen AND a third party dialog window, all > > my app would need to do is relay any input received to the to the in- > > call screen. > > > The above idea I'll admit is very convoluted and awkward, but the > > project is currently in the pre-prerelease stage, it doesn't have to > > be pretty or useful, it just needs to be able to prove the concept. > > An actual pretty and useful app can wait till the Android SDK matures > > a little. > > > Thank you > > > On Aug 18, 9:57 pm, Dianne Hackborn <[email protected]> wrote: > > > > I think it is not. Have a look atInCallScreen.javaand everything it does, > > > if you don't believe me. > > > > On Tue, Aug 18, 2009 at 6:50 PM, Mingli Wang <[email protected]> wrote: > > > > I think it is possible to do so, just a little inconvenient. There is a > > > > full set of APIs in the ITelephony you can use. I did it before, it > > > > worked > > > > fine > > > > > 2009/8/19 Dianne Hackborn <[email protected]> > > > > >> Sorry, it is not possible to fully implement the current in-call screen > > > >> features, because a number of things require running in the same > > > >> process as > > > >> the telephony stack. > > > > >> On Tue, Aug 18, 2009 at 6:25 PM, [email protected] < > > > >> [email protected]> wrote: > > > > >>> Thank you for the info, I have another question. > > > > >>> The goal of my project is to replace the incoming call app with my > > > >>> own. My app would contain all the standard features (answer, ignore, > > > >>> display phone number etc.) and more. Some sources say this is > > > >>> impossible and others say it is not impossible, in any event, most of > > > >>> these sources are very old and likely reflect an out of date SDK. > > > > >>> Is what I want done possible, and if it is not, can someone point me > > > >>> to a reliable (preferably Google) source that will explain this, so I > > > >>> can forward it to my boss. > > > > >>> I appreciate any info, thank you very much. > > > > >>> On Aug 17, 9:59 pm, "Roman ( T-Mobile USA)" <roman.baumgaert...@t- > > > >>> mobile.com> wrote: > > > >>> > Do the following: > > > > >>> > 1. In your manifest you should have > > > > >>> > <uses-permission android:name="android.permission.CALL_PHONE" /> > > > >>> > <uses-permission > > > >>> > android:name="android.permission.PROCESS_OUTGOING_CALLS"/> > > > >>> > <uses-permission > > > >>> > android:name="android.permission.READ_PHONE_STATE"/> > > > > >>> > <intent-filter> > > > >>> > <action android:name="android.intent.action.PHONE_STATE"/> > > > >>> > <action android:name="Test" /> > > > >>> > </intent-filter> > > > > >>> > 2. Register your broadcast receiver in the main activity > > > > >>> > IntentFilter filter = new IntentFilter > > > >>> > ("bct.com.MyEventReceiver"); > > > >>> > eventRcvr = new MyEventReceiver(); > > > >>> > this.registerReceiver(eventRcvr, filter); > > > > >>> > 3. Implement a Broadcast receiver > > > > >>> > public class MyEventReceiver extends BroadcastReceiver { > > > >>> > ... > > > >>> > public void onReceive(Context context, Intent intent) { > > > >>> > System.out.println("Receiver Object in onReceive: "+this); > > > > >>> > NewPhoneStateListener phoneListener=new > > > >>> > NewPhoneStateListener > > > >>> > (); > > > >>> > TelephonyManager telephony = (TelephonyManager) > > > >>> > context.getSystemService > > > >>> > (Context.TELEPHONY_SERVICE); > > > >>> > telephony.listen > > > >>> > (phoneListener,PhoneStateListener.LISTEN_CALL_STATE); > > > > >>> > Log.d(TAG,"intent:"+intent.toString()); > > > >>> > } > > > >>> > ...} > > > > >>> > 4. New Class > > > > >>> > public class NewPhoneStateListener extends PhoneStateListener { > > > >>> > public void onCallStateChanged(int state,String incomingNumber){ > > > >>> > switch(state) > > > >>> > { > > > >>> > //whatever you want to do here > > > >>> > } > > > >>> > } > > > >>> > } > > > > >>> > -- > > > >>> > Roman Baumgaertner > > > >>> > Sr. SW Engineer-OSDC > > > >>> > ·T· · ·Mobile· stick together > > > >>> > The views, opinions and statements in this email are those of the > > > >>> > author solely in their individual capacity, and do not necessarily > > > >>> > represent those of T-Mobile USA, Inc. > > > > >>> > On Aug 17, 1:45 pm, "[email protected]" > > > >>> > <[email protected]> > > > >>> > wrote: > > > > >>> > > I'm trying to write an app that will run when the phone rings but > > > >>> > > NOT > > > >>> > > answer the incoming call. The app would have an answer button > > > >>> > > that > > > >>> > > when pressed would perform the regular call answer action, but > > > >>> > > this > > > >>> > > isn't what I need help with. > > > > >>> > > I've searched the internet and haven't been able to find any > > > >>> consensus > > > >>> > > on this issue. My app only needs to run during the call ringing > > > >>> stage > > > >>> > > and nothing more. What would I have to listen for to do this and > > > >>> what > > > >>> > > manifest entries would I need? Forgive my incorrect/nonexistant > > > >>> > > use > > > >>> > > of terminology, I haven't worked with Android in close to a year > > > >>> > > and > > > >>> > > haven't freshened up fully yet. > > > > >>> > > Thank you > > > > >> -- > > > >> Dianne Hackborn > > > >> Android framework engineer > > > >> [email protected] > > > > >> Note: please don't send private questions to me, as I don't have time > > > >> to > > > >> provide private support, and so won't reply to such e-mails. All such > > > >> questions should be posted on public forums, where I and others can > > > >> see and > > > >> answer them. > > > > -- > > > Dianne Hackborn > > > Android framework engineer > > > [email protected] > > > > Note: please don't send private questions to me, as I don't have time to > > > provide private support, and so won't reply to such e-mails. All such > > > questions should be posted on public forums, where I and others can see > > > and > > > answer them.- Hide quoted text - > > - Show quoted text - --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~----------~----~----~----~------~----~------~--~---

