Saturday, March 8, 2014
Android phone incoming calls
Just learning android soon, recent research calls this piece of business, encountered some problems, so would like to ask everyone! ! !
I use ITelephony.answerRingingCall (), and then the phone to root, automatic answer function calls now achieved. But the question is: is the system built-in answering interface style, but I want to be able to show my own answer interface, and this how to achieve it?
I hope everyone can dance to help me look for ideas! ! !
<-! Main posts under Banner (D4) -><-! Posts under the main text (D5) ->
Reply:
You can listen to the phone, open your own activity. Then call answerRingingCall's. This time the interface is your own. Most want to delay writing before opening his own activity, or will be covered by the system
Reply:
How think this is a backdoor ah
Reply:
Ah, I am in my PhoneReceiver class onReceive () inside so written:
telephonyService.answerRingingCall ();
After / / receive calls, to return to my page
intent.setClass (context, MyReceiver.class);
intent.setFlags (Intent.FLAG_ACTIVITY_NEW_TASK);
context.startActivity (intent);
But no, no interceptions live, still will first look at the built-in flash interface, then jump to my interface.
Reply:
I try to invert it, let it first jump, then perform answerRingingCall
Reply:
The phone can not be achieved on its own interface
Can only be covered with a layer
on existing phone system interface
You answercall after restarting activity on the line
But doing so is to have a new problem, you can not pass the key response systems, such as dial keys and the like, hang up key touches can be implemented using endcall
Reply:
Seemingly, call the system interface. If you want to use your own activity coverage, to call the bottom of the interface. Looks like android underlying interface, a more stringent checks. If there is a reality, sharing under
Reply:
No, boot the system directly on the phone after the re-start on the cover of a acticity
Reply:
Oh, and trouble!
Has now been identified system built page is not blocked, only covering.
My question now is: I have set up two pages, making and receiving calls. When performing my dial page, and suddenly a call comes in, then the system calls the page does not appear, but the answer page yet my answering system on the cover page (I can see my pages return key, so make sure the system covering me).
This is the opposite to me, I wish I could grab before the system, overwriting its answer page, I have set the priority to 1000, I think 1000 is the highest document it! Solving! ! ! !
Reply:
Set the window's type, as long as the level of type on the line more than type_phone
Reply:
???
Somewhat ambiguous? Set the page in my answer it? How to set it?
I just saw a document on WindowManager.LayoutParams property has TYPE_PHONE
Reply:
I now use the system to answer the page WindowManager.LayoutParams already covered, but with WindowManager my page set to window-type page, there seems to be unable to trigger an event, I click the button no response.
Reply:
Resolved! In fact, not without a response, but when I clicked on the button, Toast execution, it is placed on the WindowManager all programs, so I certainly do not see the Toast, and so I mistakenly thought no response.
Now overwrite the system page, but the button event was spot twice, because although covered, but it still exists, I ordered the first time, actually closed internal pages, the point is the second time in my pages in real response , alas, be it a small Bug!
Reply:
The landlord, specifically how to do, you can share with it? ?
Reply:
Hello, I'm also studying this content, how do you have a demo? Can you send me a copy?
QQ: 511643996@qq.com
Reply:
Is set higher levels than type_phone display window to override the system to call it? Or directly with type_phone like?
I now use the system to answer the page WindowManager.LayoutParams already covered, but with WindowManager my page set to window-type page, there seems to be unable to trigger an event, I click the button no response.
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment