Upper-layer call process in Android

Source: Internet
Author: User

 

1. Call Process
Incallscreen calls internalresolveintent ()
Call placecall.

Number is obtained from intent.
Number = getinitialnumber (intent );

Placecall calls phoneutils. placecall in Java

Call phone. Dial In placecall to establish a connection.

Call gsmphone. Dial, gsmcalltracker. Dial in sequence
Commandsinterface. Dial
To
Dial (string address, int clirmode, message result ).

Ii. Incoming call Process

Ril_request_current_callril. Java reports processsolicited
Transferred to handlepollcils in gsmcalltracker
Phone. policynewringconnection ()
Notification callnotifier. handlemessage in Java

Phone_new_ringing_connection:
Onnewringingconnection
Startincomingcallquery
Showincomingcallui

3. Answer the call
Answer 2: Incoming call interface

Incallscreen. Java internalhandlecallkey-> internalanswercall ()
Phoneutils. answercall (mphone)
Phone. acceptcall ();
Until RIL. Java
Acceptcall

4. Hanging up the current phone call

Incallscreen. Java onclick
Phoneutils. Java hangupactivecall
Hanging up foregroundcall
Hangup (phone. getforegroundcall ());

Static Boolean hangup (call );

Gsmcall. Java hangup ()
Gsmcalltracker. Java hangup (gsmcall call)
{
.......
If (call = foregroundcall)
Hangup (gsmconnection () call. getconnections (). Get (0 ));

}

Gsmcalltracker. Java hangup (gsmconnection conn)
{
Cm. hangupconnection
}
Transfer
Hangupconnection () function in RIL. Java ()

After
Gsmcalltracker. Java
{Conn. ondisconnect (cause );}

Ondisconnect in gsmconnection. Java

Owner. Phone. policydisconnect (this );

5. Process of hanging up the phone when the bell rings
 
What is different from four is hangupringingcall.

 

 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.