Calling method and related device

By automatically acquiring and storing the country code of a phone number in electronic devices, the problem of dialing failures caused by users not adding the country code when traveling abroad is solved, achieving successful cross-border calls and optimizing power consumption.

CN121644725APending Publication Date: 2026-03-10HUAWEI TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-09-10
Publication Date
2026-03-10

AI Technical Summary

Technical Problem

When users go abroad and use electronic devices to dial domestic phone numbers, they may experience dialing failures due to the lack of a country code, resulting in a poor user experience.

Method used

After an electronic device successfully makes a domestic phone call, it automatically obtains and stores the country code of that phone number, and automatically adds the country code when the user dials again after leaving the country to ensure a successful call.

Benefits of technology

This solution resolves the issue of dialing failures caused by users not adding country codes when traveling abroad, ensuring successful calls in different countries, reducing the power consumption of electronic devices in determining whether country codes are consistent, and reducing redundancy in the call interface.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121644725A_ABST
    Figure CN121644725A_ABST
Patent Text Reader

Abstract

The invention discloses a calling method and a related device. In the method, the electronic equipment can determine the country code of the telephone number and store the country code in the electronic equipment after the telephone number is successfully called. Wherein the country code of the telephone number is the country code of the country when the electronic equipment is successfully called. Afterwards, under the condition that the electronic equipment calls the telephone number again, the electronic equipment can successfully call by adding the stored country code before the telephone number. Therefore, the electronic equipment successfully calls a certain telephone number in China, and after the user goes out of the country, the electronic equipment still can successfully call the telephone number again.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of communications, and more particularly to a method and related apparatus for making a call. Background Technology

[0002] Users can make domestic calls using their electronic devices while in China. However, when users travel abroad, their devices may fail to dial domestic numbers. Enabling users to successfully make domestic calls from abroad is a pressing problem that needs to be solved. Summary of the Invention

[0003] This application provides a method and related apparatus for making a call, which can obtain the country code of the telephone number and avoid dialing failure due to the lack of a country code when a user dials a domestic telephone number after leaving the country.

[0004] In a first aspect, this application provides a method for making a call, characterized in that the method is applied to a first electronic device, the method comprising: when the first electronic device is located in a first country, the first electronic device calls a first number, the first number including a first telephone number but excluding a country code; after the call is successful, the first electronic device stores the country code of the first country as the country code of the first telephone number.

[0005] By implementing the above method, the electronic device can successfully obtain the country code of the first phone number, so that it can successfully make a call to the first phone number again in the future.

[0006] In conjunction with the first aspect, in some implementations, after the first electronic device determines that the country code of the first phone number is the country code of the first country, the method further includes: the first electronic device receiving a first operation, the first operation including: entering the first phone number in a dial pad and dialing it, or dialing a number to a first contact whose number is the first phone number, or selecting the first phone number in the call log and dialing it; the first electronic device calling a second number, the second number including the country code of the first phone number and the first phone number.

[0007] In this way, regardless of which country the electronic device is in when receiving the first operation, it can successfully call the first phone number, and it can also reduce the power consumption of the electronic device in determining whether the country code is consistent.

[0008] In conjunction with the first aspect, in some implementations, after the first electronic device determines that the country code of the first phone number is the country code of the first country, the method further includes: if the first electronic device is located in a second country, the first electronic device receives a first operation, the first operation including: entering the first phone number in a dial pad and dialing it, or dialing a number to a first contact whose number is the first phone number, or selecting the first phone number in the call log and dialing it; the first electronic device calls a second number, the second number including the country code of the first phone number and the first phone number.

[0009] In this way, the electronic device can successfully call the second number even if the country code of the country where the electronic device is located does not match the country code of the first phone number, after storing the country code of the first phone number.

[0010] In conjunction with the first aspect, in some implementations, before the first electronic device calls the second number, the method further includes: the first electronic device determining that it is located in the second country based on a public terrestrial mobile network; and the first electronic device determining that the country code of the second country where it is located does not match the country code of the first telephone number. In some implementations, the electronic device may also determine that it is located in the second country by other means.

[0011] In conjunction with the first aspect, in some implementations, the first operation includes either entering the first phone number into the dial pad and dialing it, or selecting the first phone number in the call log and dialing it. Following this, the method further includes, during the call to the second number, the first electronic device displays a first call interface, which includes the first phone number and its country code. In this way, the electronic device can display a call interface containing only the phone number when calling the first number, and a call interface containing both the phone number and the country code when calling the second number, thus reducing the likelihood of users perceiving the call interface as redundant.

[0012] In conjunction with the first aspect, in some implementations, before the first electronic device calls the first number, the method further includes: the first electronic device determining that it is located in the first country based on a public terrestrial mobile network; and the first electronic device obtaining the country code of the first country based on that first country. In some implementations, the electronic device may also determine that it is located in the first country through other means.

[0013] In conjunction with the first aspect, in some implementations, after the first electronic device determines that the country code of the first phone number is the country code of the first country, the method further includes: if the first electronic device is located in the first country, the first electronic device receives a third operation, the third operation including: entering the first phone number in the dial pad and dialing it, or dialing a number to a first contact whose number is the first phone number, or selecting the first phone number in the communication record and dialing it; the first electronic device calls the first number.

[0014] In this way, the electronic device can successfully call the first number after storing the country code of the first phone number, provided that the country code of the country where the electronic device is located matches the country code of the first phone number.

[0015] In conjunction with the first aspect, in some implementations, after the first electronic device determines that the country code of the first phone number is the country code of the first country, the method further includes: the first electronic device displaying a first interface for creating a new contact, the first interface including: the name of the first contact entered by the user, the first phone number filled in by the first electronic device, and the country code of the first phone number. The first electronic device stores the name of the first contact, the first phone number, and the country code of the first phone number.

[0016] In this way, after determining the country code of the first phone number, the electronic device can create a new first contact, and the electronic device can automatically fill in the country code of the first phone number during the process of creating the first contact.

[0017] In conjunction with the first aspect, in some implementations, before the first electronic device calls the first number, the method further includes: the first electronic device displaying a second interface for creating a new contact, the second interface including: the name of the first contact entered by the user and the first phone number; the first electronic device storing the name of the first contact and the first phone number; after the first electronic device determines that the country code of the first phone number is the country code of the first country, the method further includes: the first electronic device storing the name of the first contact, the first phone number, and the country code of the first phone number.

[0018] In this way, the electronic device can create a new first contact before determining the country code of the first phone number. The electronic device can also automatically fill in the country code of the first phone number after determining it.

[0019] In conjunction with the first aspect, in some implementations, after the first electronic device stores the name of the first contact person, the first phone number, and the country code of the first phone number, the method further includes: the first electronic device receiving a second operation; and the first electronic device responding to the second operation by modifying or deleting the country code of the first phone number.

[0020] In this way, users can change the country code of their primary phone number if the country code obtained by their electronic device does not meet their expectations.

[0021] In conjunction with the first aspect, in some implementations, before the first electronic device determines that the country code of the first phone number is the country code of the first country, the method further includes: the duration of the call between the first electronic device and the electronic device possessing the first phone number exceeds a first threshold. Thus, if the duration of the call between the electronic device and the device possessing the first phone number exceeds a preset threshold, it can be assumed that the device possessing the first phone number is the target device dialed by the user of the electronic device, thereby increasing the reliability of determining the country code of the first phone number.

[0022] In conjunction with the first aspect, in some implementations, the first number does not include a country code, while the second number does. In some implementations, the electronic device can store the country code of the first country after determining that the country code of the first phone number is the country code of the first country. Furthermore, since the country code needs to be used in conjunction with the country code during use, the electronic device can also store the country code along with the country code of the first country in the electronic device.

[0023] In a second aspect, this application provides an electronic device including a memory, a processor, and computer instructions stored in the memory, wherein the processor executes the computer program to implement the method described in the first aspect or any embodiment of the first aspect.

[0024] Thirdly, embodiments of this application provide a computer-readable storage medium storing a computer program that, when executed by a processor, implements the method described in the first aspect or any of the embodiments of the first aspect.

[0025] Fourthly, embodiments of this application provide a computer program product comprising computer instructions that, when executed by a processor, implement the method described in the first aspect or any of the embodiments of the first aspect.

[0026] The beneficial effects of the second to fourth aspects can be referenced from the beneficial effects of the first aspect mentioned above. Attached Figure Description

[0027] Figure 1This is a schematic flowchart of a calling method provided in an embodiment of this application;

[0028] Figures 2A-2C A user interface provided for a set of phone numbers before making a call, as exemplified in this application;

[0029] Figures 3A-3C User interface provided for a set of address book applications in the embodiments of this application

[0030] Figures 4A-4B This application provides a user interface for another set of phone numbers before making a call, as per the embodiments of this application.

[0031] Figures 5A-5B A user interface for a set of telephone numbers provided in an embodiment of this application;

[0032] Figure 6 A schematic diagram of the hardware structure of an electronic device provided in an embodiment of this application;

[0033] Figure 7 This is a schematic diagram of the software structure of an electronic device provided in an embodiment of this application. Detailed Implementation

[0034] The technical solutions in the embodiments of this application will be clearly and thoroughly described below with reference to the accompanying drawings. In the description of the embodiments of this application, unless otherwise stated, " / " means "or," for example, A / B can mean A or B; the word "and / or" in the text is merely a description of the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A existing alone, A and B existing simultaneously, and B existing alone. Furthermore, in the description of the embodiments of this application, "multiple" refers to two or more than two.

[0035] Hereinafter, the terms "first" and "second" are used for descriptive purposes only and should not be construed as implying or suggesting relative importance or implicitly indicating the number of indicated technical features. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of that feature, and in the description of the embodiments of this application, unless otherwise stated, "multiple" means two or more.

[0036] The following describes some terms used in the embodiments of this application.

[0037] A telephone number is a number assigned by the telephone administration to electronic devices (such as mobile phones). Electronic devices can use telephone numbers to call other electronic devices. The electronic device that initiates the call is called the calling device, and the electronic device that receives the call is called the called device. Telephone numbers used in different countries may have the same or different digits. For example, telephone numbers used in China are 11 digits long. The first three digits are the network identification number, used to identify the operator. For example, China Mobile's network identification numbers include 136, 137, etc., and China Telecom's network identification numbers include 133, 180, etc. The fourth to seventh digits are the area code, used to indicate the user's home location; the eighth to eleventh digits are the user number, randomly assigned to each user.

[0038] A country code is a unique numerical code used to identify the target country when dialing a number abroad. It is added before the phone number. A country code can be understood as an international long-distance dialing code, also known as a country code or country number. Each country or region has its own specific country code; for example, China's country code is "86", the United States' country code is "1", and the United Kingdom's country code is "44".

[0039] A country code is a set of numbers or symbols added before the international code when dialing a phone number abroad. The country code informs the telephone communication network that the number being called is an international number. For example, a country code may include "+" or "00".

[0040] Roaming area refers to the region where a user uses mobile phone services on their electronic device outside of their home operator's network. Non-roaming area refers to the region where a user uses mobile phone services on their electronic device within their home operator's network. Non-roaming area is also known as the home area. For example, if phone number A is operated by China Mobile, and China Mobile's network covers China, then other countries and regions outside of China are roaming areas for phone number A, while China is a non-roaming area for phone number A.

[0041] A local number refers to a telephone number used within the network of its home operator. For example, a local number in China can refer to a telephone number used in China, but it is not necessarily a telephone number registered in China.

[0042] A domestic phone number refers to a telephone number registered and used within a specific country. For example, a domestic phone number in China could refer to a telephone number used by China Mobile, China Telecom, or China Unicom in China.

[0043] In some implementations, an electronic device can successfully make a call under the following conditions:

[0044] 1. When an electronic device dials a domestic number while not roaming, it does not add the country prefix and country code before the domestic number. For example, an electronic device with a China Mobile phone number A is located in China. When dialing a phone number B registered and used in China, it does not need to add the country prefix "00" or "+" and the country code "86" before the phone number B to dial successfully.

[0045] Optionally, when an electronic device dials a domestic number while not roaming, adding the country prefix and country code before the domestic number will also allow the call to be successful.

[0046] 2. When an electronic device dials a local number while roaming, it fails to add the country prefix and country code before the local number. For example, an electronic device with a China Mobile phone number A in country B can successfully dial a phone number B used within country B without adding the country prefix "00" or "+" and the country code of country B before the phone number B. Here, country B refers to a country or region outside of China.

[0047] Optionally, when an electronic device dials a local number while roaming, adding the country prefix and country code before the local number will also allow the call to be successful.

[0048] 3. When an electronic device dials a phone number used abroad while in a non-roaming or roaming area, the country prefix and the country code of the corresponding country must be added before the phone number. For example, if an electronic device with a China Mobile phone number A is in China or in country B, and dials a phone number B used in country C, the country prefix "00" or "+" and the country code of country C must be added before the phone number B for the dialing to be successful.

[0049] If an electronic device dials a foreign phone number while not roaming or while roaming, and does not add the country prefix and the corresponding country code before the phone number, the call will fail.

[0050] Based on the above, when an electronic device located in country A dials a phone number used within country A, it does not need to add the country code or its own country code. In other words, when an electronic device dials a phone number, it defaults to dialing a phone number used within the country where the electronic device is currently located.

[0051] When an electronic device located in country A dials a phone number used in country B, it must include the country prefix and the corresponding country code. This is because the country of origin of a phone number cannot be determined solely by its characteristics; the country code must be added to confirm the specific country in which the phone number is used, thus ensuring a successful call.

[0052] In some implementations, the following scenario exists: an electronic device successfully calls a phone number domestically, but fails to call the same number again after the user travels abroad. This creates a poor user experience and makes the user wonder if they remembered the phone number incorrectly. The reasons for the call failure include: the electronic device did not add the country code and the domestic country code when calling the phone number from abroad. This is because when a user successfully calls a phone number domestically, only the phone number is used, meaning the electronic device only obtains the phone number and not the country code. Consequently, the electronic device only saves the phone number and not the country code. Therefore, when the electronic device calls the same phone number again, it does not add the country code and country code before the phone number, resulting in a call failure.

[0053] To reduce the aforementioned problems, this application provides a method for making a call. In this method, if the electronic device successfully calls only a phone number, it indicates that the calling device and the called device are in the same country, such as country A. In this case, the calling device can determine the country code of country A as the country code of the phone number. Subsequently, if the calling device moves to country B and then calls the same phone number again, the calling device will proactively add the country prefix and country code before the phone number. If the called device is still in country A, the call will be successful.

[0054] In this way, if an electronic device successfully calls a certain phone number in country A, it will be able to successfully call that phone number again after the user leaves the country.

[0055] The following describes a calling method flow provided by an embodiment of this application.

[0056] Figure 1 An exemplary flowchart of a calling method provided in an embodiment of this application is illustrated. The method includes:

[0057] S101. When an electronic device is located in a first country, the electronic device calls a first number, which includes a first telephone number but does not include the country prefix and country code.

[0058] The first country can refer to any country that provides communication services.

[0059] In some implementations, an electronic device can call a first number in the following ways: The electronic device can receive an operation to dial a first number entered via a dial pad, thus calling the first number. The electronic device can also receive an operation to select a contact to whom the first number belongs and dial that contact, thus calling the first number. The electronic device can also receive an operation to select a first number from the call log and dial that number.

[0060] The first number can be entered into the electronic device by the user when executing S101, or it can be stored in the electronic device's address book before executing S101, or it can be stored in the electronic device's call log before executing S101.

[0061] In one possible implementation, the electronic device can store the first phone number in its address book by copying the contact information of the first number from another electronic device.

[0062] If the electronic device successfully calls the first number, then execute S102.

[0063] If the electronic device fails to call the first number, it means that the first number is not used in the first country, and the electronic device cannot know which country the first number is used in, thus ending the process.

[0064] Optionally, before executing S101, the electronic device may have attempted to call the first number, but the call failed. In this case, the first number may be stored in the call log, but because the call failed, the electronic device does not store the country code of the first number.

[0065] For example, refer to Figure 2A The user interface 200 shown is a user interface for dialing functions provided by a calling application. The user interface 200 includes a dial pad 201, an input field 202, and a call control 203. When the user interface 200 is displayed, the electronic device can receive a user's input of a first number via the dial pad 201, such as the phone number "12311111111" displayed in the input field 202, and then click the call control 203 to call the first number.

[0066] refer to Figure 2B The user interface 210 shown is a user interface for contact-related information provided by the Contacts application. The user interface 210 includes: contact name 211, contact number 212, and call control 213. When the user interface 210 is displayed, the electronic device can receive a user's click on the call control 213 to call a first number, such as the phone number "12311111111" displayed in contact number 212.

[0067] refer to Figure 2C The user interface 220 shown is a call log interface provided by a calling application. The user interface 220 includes a call log field 221. The call log field 221 includes the phone number, call date, and call status. When the user interface 220 is displayed, the electronic device can receive a user's tap on the call log field 221 to call a first number, such as the phone number "12311111111" displayed in the call log field 221.

[0068] It is worth noting that the user interface of the aforementioned electronic devices does not contain the country code or country prefix of the first phone number before calling the first number.

[0069] In the embodiments of this application, the user interface presented by the electronic device before calling the first number is only an example. There may be more or fewer user interfaces. For example, the electronic device may respond to a voice command to call the first number while displaying any user interface. This is not limited.

[0070] S102. After a successful call, the electronic device determines and stores the country code of the first telephone number as the country code of the first country.

[0071] If the electronic device successfully calls the first number (meaning it successfully calls the first phone number without adding a country code or country code), it indicates that the electronic device and the device with the first phone number are in the same country. In some methods, the electronic device executes S102 after executing S101. After successfully calling the first number, the electronic device can determine that the country code of the first phone number is the country code of the first country.

[0072] Specifically, an electronic device can determine its country of origin when a call is successfully made based on the Public Land Mobile Network (PLMN). In other words, the electronic device can determine its location in a first country based on the PLMN. The PLMN is provided by the network currently used by the electronic device, and each PLMN includes a unique Mobile Country Code (MCC) and Mobile Network Code (MNC). Each country's mobile communication network has a unique MCC, which consists of 3 digits. For example, China's MCC is 460. In this embodiment, the method of obtaining the country code of the first country described above is merely illustrative; the electronic device can also obtain the country code of the first country through other means, such as GPS, and this is not limited.

[0073] In some implementations, the electronic device can store the country code of the first country after determining that the country code of the first phone number is the country code of the first country. Furthermore, since the country code needs to be used in conjunction with the country prefix during use, the electronic device can also store the country prefix and the country of the first country together in the electronic device.

[0074] In some implementations, a successful call can mean that the electronic device has established a communication connection with a device that has a first phone number. The user can then use the electronic device to communicate with a user using a device that has the first phone number.

[0075] Furthermore, before the electronic device determines and stores the country code of the first phone number as the country code of the first country, it must also satisfy the following condition: the duration of the call between the electronic device and the device holding the first phone number exceeds a preset threshold. For example, exceeding 30 seconds. For instance, a user wants to dial phone number A in Germany, but there may be a device 'a' in China that is also registered and using phone number A. If the electronic device directly calls phone number A without a country prefix and country code, it will connect to device 'a' using phone number A in China. Obviously, device 'a' is not the user's target device, and the call will end immediately after connection. In this case, the call duration is short and does not exceed the preset threshold. The electronic device can consider the call to phone number A unsuccessful and will not determine the country code of phone number A as the country code of China. Therefore, the fact that the duration of the call between the electronic device and the device holding the first phone number exceeds the preset threshold can be considered that the device holding the first phone number is the target device dialed by the user of the electronic device, thus increasing the reliability of determining the country code of the first phone number.

[0076] In one possible implementation, if the first number is already stored in the address book before executing S101, then before executing S102, the electronic device needs to determine whether the electronic device stores the country code of the first phone number and / or whether the user has processed the country code of the first phone number, such as modifying, adding, or deleting it.

[0077] In some implementations, if the electronic device stores a first phone number in its address book but not its country code, and the user has not processed the country code of the first phone number, then S102 can be executed before S102 is performed. In this case, the user may not know the country code of the first phone number or may not have considered storing it in the electronic device. Therefore, after a successful call, the electronic device can obtain and store the country code of the first phone number.

[0078] In another embodiment, before executing S102, if the electronic device has a first phone number stored in its address book but not its country code, and the user has previously processed the country code of the first phone number, then S102 can be executed or not. This is because, in this case, the electronic device may have previously stored the country code of the first phone number, but the user believed that the previously stored country code was incorrect and deleted it, thus the electronic device currently does not store the country code of the first phone number. Therefore, the electronic device can either obtain the country code of the first phone number that the user considers correct by executing S102, or it can choose not to execute S102 and wait for the user to actively add the country code of the first phone number later.

[0079] In some embodiments, if the electronic device stores a first phone number and its country code in its address book before executing S102, then S102 is not executed. This is because, in this case, the electronic device may store the country code of the first phone number that the user considers correct, and thus the user has not processed that country code. Alternatively, the country code of the first phone number stored by the electronic device may be one that the user actively added, and the user believes that the country code of the first electronic device number that they actively added is correct. Therefore, there is no need for the electronic device to obtain the country code of the first electronic device number again.

[0080] It is worth noting that in this embodiment of the application, the country code of the first telephone number and the first telephone number are stored in the electronic device respectively. This allows the electronic device to directly read the country code without having to confirm which numbers are country codes and which numbers are telephone numbers.

[0081] Furthermore, in this embodiment of the application, the electronic device can store the country prefix code and the country code together.

[0082] In some implementations, after executing S102, the electronic device can store the first telephone number and its country code. Depending on the scenario, the electronic device can implement the following storage configurations:

[0083] Storage Scenario 1: If the first phone number and its country code are not stored in the electronic device's address book before executing S101, then after executing S102, the electronic device can respond to the user's operation of creating a new contact, thus storing the first phone number and its country code in both the address book and the call log. For example, refer to... Figure 3A The user interface 230 shown is for creating a new contact based on the first number after a successful call. User interface 230 includes: a contact name 231, a country code for the phone number 232, and a phone number 233. The name displayed in contact name 231, such as "Xiaoming," is entered by the user. The country code displayed in phone number country code 232, such as "+86," and the phone number displayed in phone number 233, such as "12311111111," are automatically filled in by the electronic device.

[0084] Storage scenario 2: Before executing S101, the electronic device did not store the first phone number and its country code in the address book. After executing S102, if the electronic device does not receive the user's operation to create a new contact, it only stores the first phone number and its country code in the call log.

[0085] Storage Scenario 3: If the electronic device's address book contains the first phone number before executing S101, then after executing S102, the electronic device can automatically store the country code of the first phone number in the address book, and also store the first phone number and its country code in the call log. For example, refer to... Figure 3B The user interface 240 shown is a user interface for viewing the contacts to which the first phone number belongs after a successful call to the first number. User interface 240 includes: a contact name 241, a contact number 242, a call control 243, and a call log 244. The contact number 241 includes: a country prefix (e.g., "+"), the country code of the first phone number (e.g., "86"), and the first phone number (e.g., "12311111111"). The name in the contact name 241 and the first phone number in the contact number 242 are entered by the user and stored in the electronic device before executing S101. The country prefix and country code in the contact number 242 are determined by the electronic device and actively added to the contact number 242 after executing S102. The call log 244 is used to indicate the date, time, and call duration of the call to the first phone number in S102.

[0086] In some implementations, after storing the first phone number and its country code in the call log, when the electronic device accesses the relevant interface to view the successfully called call record in S102, the number displayed in the call log may or may not include the country code of the first phone number. In other words, the electronic device may or may not display the country code of the first phone number to the user after storing it in the call log.

[0087] It's worth noting that data stored in call logs and contacts are different. The content stored differs: the former includes country code, phone number, country code, and call time; the latter includes contact name, country code, phone number, and country code. Their storage locations also differ: the former resides in the call log database, while the latter resides in the contacts database. Their expiration processes also differ: without user intervention, the former will be deleted by the device after a certain period, while the latter remains permanently stored. Finally, their impact differs: the former ensures successful dialing of phone numbers from the call log and dialing from the dial pad, while the latter ensures successful dialing of phone numbers from contacts.

[0088] In one possible implementation, after executing S102, the electronic device stores a first phone number and its country code in its address book. The electronic device can respond to user input by modifying the country code of the first phone number stored in the address book. Furthermore, the electronic device subsequently performs relevant checks based on the modified country code of the first phone number.

[0089] For example, a user wants to dial phone number A in Germany. However, there might be a device 'a' in China that is also registered and using phone number A. If the electronic device in China directly calls phone number A without adding a country code and prefix, the call will be connected to device 'a' using phone number A in China. If the call duration exceeds a preset threshold, the electronic device will recognize the country code of phone number A as the country code of China and store it in its contacts. Obviously, the user perceives the country code of phone number A stored in their contacts as incorrect. The user can then change the country code of phone number A stored in their contacts to the country code of Germany. Subsequently, when the electronic device calls phone number A again, it will determine whether to add the German country code based on whether the electronic device is currently in Germany. If the electronic device is currently in Germany, no German country code is needed when calling phone number A. If the electronic device is not currently in Germany, the German country code must be added when calling phone number A.

[0090] For example, refer to Figure 3C The user interface 250 is a user interface for editing the contact to which the first phone number belongs after a successful call to the first number. The user interface 250 includes: contact name 251, country code 252, and phone number 253. The electronic device can individually modify, delete, or add the country code displayed in country code 252 of the phone number within the user interface 250. Furthermore, after modification, the electronic device can store the modified country code of the first phone number.

[0091] S103. The electronic device receives a user operation, which is the user inputting or selecting a first phone number and then dialing that first phone number.

[0092] In some implementations, after executing S102, the electronic device can execute S103. After determining and storing the country code of the first telephone number as the country code of the first country, the electronic device can receive user operations.

[0093] The aforementioned user operation refers to the operation of dialing a first phone number after the user inputs or selects it. For example, the user operation may include any of the following: entering the first phone number on the dial pad and dialing; selecting a contact to which the first phone number belongs and dialing; or selecting the first phone number in the call log and dialing. In this embodiment, the above user operation is only illustrative and may include more operations to indicate that the user intends to dial the first number.

[0094] For example, the time when S101 dialed the first number was "9:00 AM on August 21, 2024", and the call lasted for "1 minute".

[0095] refer to Figure 4A The user interface 260 shown is a user interface for dialing functions provided by a calling application. User interface 260 includes a dial pad 261, an input field 262, and a call control 263. When user interface 260 is displayed, the electronic device can receive an operation from a user who inputs a first number via dial pad 261, such as the phone number "12311111111" displayed in input field 262, and then clicks the call control 263. Before clicking the call control 263, the electronic device can also display call logs for calls to the first number in S101 on user interface 260. Optionally, if the first phone number is stored in a contact list, the call logs for calls to the first number displayed on user interface 260 in S101 can also include the name of the contact to which the first phone number belongs.

[0096] refer to Figure 3B The user interface 240 shown is a user interface for viewing the contacts belonging to the first phone number after a successful call to the first number. The electronic device can receive a user's click on the call control 243 while the user interface 240 is displayed.

[0097] refer to Figure 4B The user interface 270 shown is a call log user interface provided by a calling application. The user interface 270 includes a call log bar 271. The call log bar 271 is used to indicate the call log of a successful call to the first number in S101. The electronic device can receive a user's tap on the call log bar 271 while the user interface 270 is displayed.

[0098] Specifically, upon receiving an operation to enter and dial the first phone number from the dial pad, the electronic device retrieves the country code of the first phone number from its stored information. Upon receiving an operation to select a contact for the first phone number and dial, the electronic device retrieves the country code of the first phone number from its stored information in the address book. Before receiving the operation to select a contact for the first phone number and dial, the electronic device can display the first phone number and its country code in the contact interface. Similarly, upon receiving an operation to select and dial the first phone number from the call log, the electronic device retrieves the country code of the first phone number from its stored information in the call log. Before receiving the operation to select and dial the first phone number from the call log, the electronic device can display the first phone number and its country code in the call log interface.

[0099] S104. An electronic device calls a second number, the second number including the country code of the first telephone number and the first telephone number.

[0100] In some implementations, after executing S103, the electronic device can execute S104. After receiving the user's operation, the electronic device does not need to determine whether the country code of its current location matches the country code of the first phone number, and directly calls the second number. In this way, regardless of the country the electronic device is in when executing S103, it can successfully call the first phone number, reducing the power consumption of some electronic devices in determining country code consistency.

[0101] In some implementations, the second number may include both the country code and the first phone number. Furthermore, the second number may also include a country prefix.

[0102] In one possible implementation, to avoid the user perceiving the call interface as always displaying redundant country codes and phone numbers, the electronic device may execute the following optional steps S105, S106, and S107 after executing S103.

[0103] S105. The electronic device determines whether the country code of the country where the electronic device is currently located is consistent with the country code of the first telephone number.

[0104] In some implementations, the electronic device can determine whether the country code of the country where the electronic device is currently located matches the country code of the first phone number based on the current location of the electronic device or the country code of the country where the electronic device is currently located.

[0105] Specifically, after the electronic device determines the country code of the phone number the user wishes to dial based on the user's operation in S103 and the stored information, that is, after the electronic device determines the country code of the first phone number, it can determine whether the country code of the country where the electronic device is currently located corresponds to the country code of the first phone number.

[0106] Specifically, electronic devices can determine their current country based on the PLMN, and then determine the country code of that country. For details, please refer to the relevant description in S102 above, which will not be repeated here.

[0107] If the country code of the country where the current electronic device is located matches the country code of the first phone number, then execute S106.

[0108] If the country code of the country where the current electronic device is located does not match the country code of the first telephone number, then execute S107.

[0109] S106, Electronic device calls the first number.

[0110] In some implementations, if the country code of the current electronic device matches the country code of the first phone number, it means the electronic device's current country matches the country corresponding to the first phone number's country code. In this case, the electronic device can successfully call the first phone number without needing to add the first phone number's country code. Therefore, in this situation, the electronic device can directly call the first number, i.e., call the first phone number.

[0111] In one possible implementation, after the electronic device dials the first number, it can display a call interface. This call interface includes the first phone number but does not include the country code of the first phone number.

[0112] For example, refer to Figure 5A The user interface 280 shown is a user interface for the calling function provided by a calling application. User interface 280 includes a telephone number 281. Telephone number 281 includes a first telephone number dialed by the electronic device, such as "12311111111", but does not include the country code of the first telephone number.

[0113] S107. An electronic device calls a second number, the second number including the country code of the first telephone number and the first telephone number.

[0114] In some implementations, if the country code of the country where the electronic device is currently located does not match the country code of the first phone number, it means that the country corresponding to the country code of the first phone number is inconsistent. The electronic device needs to add the country code of the first phone number to successfully call it. Therefore, in this case, the electronic device can call the second number.

[0115] In some implementations, the second number may include both the country code and the first phone number. Furthermore, the second number may also include a country prefix.

[0116] In one possible implementation, after the electronic device dials the second number, a call interface can be displayed. This call interface includes: the country code of the first phone number and the first phone number itself. Furthermore, the call interface may also include a country prefix.

[0117] For example, refer to Figure 5B The user interface 290 shown is a user interface for the calling function provided by the calling application. The user interface 290 includes: a telephone number 291. The telephone number 291 includes: a country prefix, such as "+", the country code of the first telephone number dialed by the electronic device, such as "86", and the first telephone number dialed by the electronic device, such as "12311111111".

[0118] In some implementations, if the device with the first phone number has not moved to another country, the electronic device can successfully call the second number.

[0119] In this way, the electronic device can display a call interface containing only the phone number when executing S106, and display a call interface containing both the phone number and the country code when executing S107, thereby reducing the possibility of users perceiving the call interface as redundant.

[0120] By implementing the above method, when users go abroad and call domestic phone numbers, they can avoid dialing failures due to the absence of the country prefix and country code.

[0121] Furthermore, the user interface for creating a new contact on the electronic device displays a separate editable box for entering the country code. This encourages users to actively enter the country code when creating a new contact. The electronic device can also store the phone number and its country code separately, allowing it to determine whether to include the country code when dialing.

[0122] In one possible implementation, after executing S107, the electronic device stores a first phone number and its country code in its address book. The electronic device can respond to user actions by modifying the country code of the first phone number stored in the address book, or by creating a new contact. For example, when a user moves to Germany, the electronic device stores a Chinese phone number A and its country code in its address book. The user wants to dial the German phone number A, but as described in S107, because the electronic device stores phone number A and its country code, it automatically adds "+86" before the phone number A. Clearly, the user perceives this as an incorrect dialing of the Chinese country code and phone number A. The user can then modify the country code of phone number A stored in the address book to the German country code; or the user can create a new contact whose phone number A's country is Germany.

[0123] In one possible implementation, the electronic device can convert non-standard country codes into standard country codes and store them in the device. Non-standard country codes refer to country codes other than the plus sign ("+"). Standard country codes are country codes with the plus sign ("+"). Specifically, if the electronic device receives a call and obtains the country code, country code, and phone number, and the country code is "00", the device automatically converts the "00" to a plus sign ("+") before storing it. Similarly, if the electronic device receives a user's input of a new contact and the input number includes the country code, country code, and phone number, and the country code is "00", the device automatically converts the "00" to a plus sign ("+") before storing it. This avoids situations where some countries do not recognize non-standard country codes, leading to call failures.

[0124] Figure 6 This illustration shows a schematic diagram of the hardware structure of an electronic device 100 provided in an embodiment of this application.

[0125] The following description uses electronic device 100 as an example to illustrate the embodiment. It should be understood that... Figure 6 The electronic device 100 shown is merely an example, and the electronic device 100 may have more than Figure 6 The more or fewer components shown can be combined into two or more components, or they can have different component configurations. Figure 6 The various components shown can be implemented in hardware, software, or a combination of hardware and software, including one or more signal processing and / or application-specific integrated circuits.

[0126] For example, electronic device 100 may be a mobile phone, tablet computer, desktop computer, laptop computer, handheld computer, notebook computer, ultra-mobile personal computer (UMPC), netbook, as well as cellular phone, personal digital assistant (PDA), augmented reality (AR) device, virtual reality (VR) device, artificial intelligence (AI) device, wearable device, in-vehicle device, smart home device and / or smart city device. This application embodiment does not impose any special restrictions on the specific type of electronic device 100.

[0127] Electronic device 100 may include: processor 110, external memory interface 120, internal memory 121, universal serial bus (USB) interface 130, charging management module 140, power management module 141, battery 142, antenna 1, antenna 2, mobile communication module 150, wireless communication module 160, audio module 170, speaker 170A, receiver 170B, microphone 170C, headphone jack 170D, sensor module 180, button 190, motor 191, indicator 192, camera 193, display screen 194, and subscriber identification module (SIM) card interface 195, etc. The sensor module 180 may include a pressure sensor 180A, a gyroscope sensor 180B, a barometric pressure sensor 180C, a magnetic sensor 180D, an accelerometer sensor 180E, a distance sensor 180F, a proximity sensor 180G, a fingerprint sensor 180H, a temperature sensor 180J, a touch sensor 180K, an ambient light sensor 180L, a bone conduction sensor 180M, etc.

[0128] It is understood that the structures illustrated in the embodiments of the present invention do not constitute a specific limitation on the electronic device 100. In other embodiments of this application, the electronic device 100 may include more or fewer components than illustrated, or combine some components, or split some components, or have different component arrangements. The illustrated components may be implemented in hardware, software, or a combination of software and hardware.

[0129] Processor 110 may include one or more processing units, such as: application processor (AP), modem processor, graphics processing unit (GPU), image signal processor (ISP), controller, memory, video codec, digital signal processor (DSP), baseband processor, and / or neural network processing unit (NPU), etc. Different processing units may be independent devices or integrated into one or more processors.

[0130] In some implementations, processor 110 can be used to determine that the country code of the first phone number is the country code of the first country. Processor 110 can also be used to determine whether the country code of the country where the current electronic device is located matches the country code of the first phone number. If they match, processor 110 initiates a call using only the first phone number; if they do not match, processor 110 initiates a call using both the country code of the first phone number and the first phone number. Processor 110 can also be used to determine whether the electronic device 100 has stored the country code of the phone number when calling it.

[0131] The controller can be the nerve center and command center of the electronic device 100. The controller can generate operation control signals according to the instruction opcode and timing signals to complete the control of fetching and executing instructions.

[0132] The processor 110 may also include a memory for storing instructions and data. In some embodiments, the memory in the processor 110 is a cache memory. This memory can store instructions or data that the processor 110 has just used or that are used repeatedly. If the processor 110 needs to use the instruction or data again, it can retrieve it directly from the memory. This avoids repeated accesses, reduces the waiting time of the processor 110, and thus improves the efficiency of the system.

[0133] In some implementations, the memory can be used to store the country code of the first telephone number separately from the first telephone number.

[0134] In some embodiments, the processor 110 may include one or more interfaces. Interfaces may include an inter-integrated circuit (I2C) interface, an inter-integrated circuit sound (I2S) interface, a pulse code modulation (PCM) interface, a universal asynchronous receiver / transmitter (UART) interface, a mobile industry processor interface (MIPI), a general-purpose input / output (GPIO) interface, a subscriber identity module (SIM) interface, and / or a universal serial bus (USB) interface, etc.

[0135] It is understood that the interface connection relationships between the modules illustrated in the embodiments of the present invention are merely illustrative and do not constitute a structural limitation on the electronic device 100. In other embodiments of this application, the electronic device 100 may also employ different interface connection methods or combinations of multiple interface connection methods as described in the above embodiments.

[0136] The charging management module 140 is used to receive charging input from the charger.

[0137] The power management module 141 connects the battery 142, the charging management module 140, and the processor 110. The power management module 141 receives input from the battery 142 and / or the charging management module 140, providing power to the processor 110, internal memory 121, external memory, display screen 194, camera 193, and wireless communication module 160, etc. The power management module 141 can also monitor parameters such as battery capacity, battery cycle count, and battery health status (leakage current, impedance). In some other embodiments, the power management module 141 may also be located within the processor 110. In other embodiments, the power management module 141 and the charging management module 140 may be located in the same device.

[0138] The wireless communication function of electronic device 100 can be realized through antenna 1, antenna 2, mobile communication module 150, wireless communication module 160, modem processor and baseband processor, etc.

[0139] Antenna 1 and antenna 2 are used to transmit and receive electromagnetic wave signals. Each antenna in electronic device 100 can be used to cover one or more communication frequency bands. Different antennas can also be multiplexed to improve antenna utilization. For example, antenna 1 can be multiplexed as a diversity antenna for a wireless local area network. In some other embodiments, the antennas can be used in conjunction with tuning switches.

[0140] The mobile communication module 150 can provide solutions for wireless communication, including 2G / 3G / 4G / 5G, applied to the electronic device 100. The mobile communication module 150 may include at least one filter, switch, power amplifier, low noise amplifier (LNA), etc. The mobile communication module 150 can receive electromagnetic waves via antenna 1, and perform filtering, amplification, and other processing on the received electromagnetic waves before transmitting them to a modem processor for demodulation. The mobile communication module 150 can also amplify the signal modulated by the modem processor and convert it into electromagnetic waves for radiation via antenna 1. In some embodiments, at least some functional modules of the mobile communication module 150 may be housed in the processor 110. In some embodiments, at least some functional modules of the mobile communication module 150 and at least some modules of the processor 110 may be housed in the same device.

[0141] In some implementations, the mobile communication module 150 can be used to enable electronic devices to call a first number and a second number.

[0142] The modem processor may include a modulator and a demodulator. The wireless communication module 160 can provide solutions for wireless communication applications on the electronic device 100, including wireless local area networks (WLANs) (such as wireless fidelity (Wi-Fi) networks), Bluetooth (BT), global navigation satellite system (GNSS), frequency modulation (FM), near field communication (NFC), and infrared (IR) technologies. The wireless communication module 160 may be one or more devices integrating at least one communication processing module. The wireless communication module 160 receives electromagnetic waves via antenna 2, performs frequency modulation and filtering of the electromagnetic wave signal, and sends the processed signal to processor 110. The wireless communication module 160 can also receive signals to be transmitted from processor 110, perform frequency modulation and amplification, and convert them into electromagnetic waves for radiation via antenna 2.

[0143] In some embodiments, antenna 1 of electronic device 100 is coupled to mobile communication module 150, and antenna 2 is coupled to wireless communication module 160, enabling electronic device 100 to communicate with networks and other devices via wireless communication technology. The wireless communication technology may include Global System for Mobile Communications (GSM), General Packet Radio Service (GPRS), Code Division Multiple Access (CDMA), Wideband Code Division Multiple Access (WCDMA), Time Division Code Division Multiple Access (TD-SCDMA), Long Term Evolution (LTE), BT, GNSS, WLAN, NFC, FM, and / or IR technologies, etc. The GNSS may include the Global Positioning System (GPS), the Global Navigation Satellite System (GLONASS), the BeiDou Navigation Satellite System (BDS), the Quasi-Zenith Satellite System (QZSS), and / or satellite-based augmentation systems (SBAS).

[0144] Electronic device 100 implements display functions through a GPU, a display screen 194, and an application processor. The GPU is a microprocessor for image processing, connected to the display screen 194 and the application processor. The GPU is used to perform mathematical and geometric calculations and for graphics rendering. Processor 110 may include one or more GPUs, which execute program instructions to generate or modify display information.

[0145] Display screen 194 is used to display images, videos, etc. Display screen 194 includes a display panel. The display panel can be a liquid crystal display (LCD). The display panel can also be manufactured using organic light-emitting diodes (OLEDs), active-matrix organic light-emitting diodes (AMOLEDs), flexible light-emitting diodes (FLEDs), miniled, microled, micro-OLEDs, quantum dot light-emitting diodes (QLEDs), etc. In some embodiments, electronic device 100 may include one or N displays 194, where N is a positive integer greater than 1.

[0146] In some implementations, the display screen 194 can be used to display a user interface prior to calling the first or second number. The display screen 194 can also be used to display a call interface when speaking with a device that has a first phone number.

[0147] Electronic device 100 can perform shooting functions through ISP, camera 193, video codec, GPU, display 194 and application processor.

[0148] The ISP (Image Signal Processor) is used to process data fed back from the camera 193. For example, when taking a picture, the shutter is opened, and light is transmitted through the lens to the camera's photosensitive element. The light signal is converted into an electrical signal, and the camera's photosensitive element transmits the electrical signal to the ISP for processing, transforming it into an image visible to the naked eye. The ISP can also perform algorithmic optimizations on image noise, brightness, etc. The ISP can also optimize parameters such as exposure and color temperature of the shooting scene. In some embodiments, the ISP can be set in the camera 193.

[0149] Camera 193 is used to capture still images or videos. An object is projected onto a photosensitive element by generating an optical image through the lens. The photosensitive element can be a charge-coupled device (CCD) or a complementary metal-oxide-semiconductor (CMOS) phototransistor. The photosensitive element converts the light signal into an electrical signal, which is then passed to an ISP for conversion into a digital image signal. The ISP outputs the digital image signal to a DSP for processing. The DSP converts the digital image signal into image signals in standard RGB, YUV, or other formats. In some embodiments, the electronic device 100 may include one or N cameras 193, where N is a positive integer greater than 1.

[0150] Digital signal processors (DSPs) are used to process digital signals. Besides digital image signals, they can also process other digital signals. For example, when electronic device 100 selects a frequency, the DSP can perform Fourier transforms on the frequency energy.

[0151] Video codecs are used to compress or decompress digital video. Electronic device 100 may support one or more video codecs. Thus, electronic device 100 can play or record videos in various encoding formats, such as Moving Picture Experts Group (MPEG) 1, MPEG2, MPEG3, MPEG4, etc.

[0152] An NPU (Neural Processing Unit) is a computational processor for neural networks (NNs). By borrowing the structure of biological neural networks, such as the transmission patterns between neurons in the human brain, it can rapidly process input information and continuously learn on its own. NPUs enable intelligent cognitive applications in electronic devices, such as image recognition, facial recognition, speech recognition, and text understanding.

[0153] The external storage interface 120 can be used to connect an external memory card, such as a Micro SD card, to expand the storage capacity of the electronic device 100. The external memory card communicates with the processor 110 through the external storage interface 120 to perform data storage functions. For example, music, video, and other files can be saved on the external memory card.

[0154] Internal memory 121 can be used to store computer executable program code, which includes instructions. Processor 110 executes various functional applications and data processing of electronic device 100 by running the instructions stored in internal memory 121. Internal memory 121 may include a program storage area and a data storage area. The program storage area may store the operating system, at least one application program required for a function (such as sound playback, image playback, etc.), etc. The data storage area may store data created during the use of electronic device 100 (such as audio data, phonebook, etc.). Furthermore, internal memory 121 may include high-speed random access memory and may also include non-volatile memory, such as at least one disk storage device, flash memory device, universal flash storage (UFS), etc.

[0155] Electronic device 100 can implement audio functions, such as music playback and recording, through audio module 170, speaker 170A, receiver 170B, microphone 170C, headphone jack 170D, and application processor.

[0156] The audio module 170 is used to convert digital audio information into analog audio signals for output, and also to convert analog audio input into digital audio signals. The audio module 170 can also be used for encoding and decoding audio signals. In some embodiments, the audio module 170 may be located in the processor 110, or some functional modules of the audio module 170 may be located in the processor 110.

[0157] The speaker 170A, also known as a "loudspeaker," is used to convert audio electrical signals into sound signals. The electronic device 100 can listen to music or make hands-free calls through the speaker 170A.

[0158] The receiver 170B, also known as the "earpiece," is used to convert audio electrical signals into sound signals. When the electronic device 100 answers a telephone call or voice message, the receiver 170B can be brought close to the ear to listen to the voice.

[0159] The microphone 170C, also known as a "microphone" or "voice transducer," is used to convert sound signals into electrical signals. The headphone jack 170D is used to connect wired headphones. The headphone jack 170D can be a USB 130 interface or a 3.5mm Open Mobile Terminal Platform (OMTP) standard interface, a CTIA (Cellular Telecommunications Industry Association of the USA) standard interface.

[0160] Motor 191 can generate vibration as a notification. Motor indicator 192 can be an indicator light used to indicate charging status, battery level changes, messages, missed calls, notifications, etc.

[0161] The SIM card interface 195 is used to connect a SIM card. The SIM card can be inserted into or removed from the SIM card interface 195 to make contact with and separate from the electronic device 100. The electronic device 100 can support one or N SIM card interfaces, where N is a positive integer greater than 1. The SIM card interface 195 can support Nano SIM cards, Micro SIM cards, SIM cards, etc. Multiple cards can be inserted into the same SIM card interface 195 simultaneously. The multiple cards can be of the same or different types. The SIM card interface 195 is also compatible with different types of SIM cards. The SIM card interface 195 is also compatible with external memory cards. The electronic device 100 interacts with the network through the SIM card to realize functions such as calls and data communication. In some embodiments, the electronic device 100 uses an eSIM, i.e., an embedded SIM card. The eSIM card can be embedded in the electronic device 100 and cannot be separated from the electronic device 100.

[0162] The software system of electronic device 100 can adopt a layered architecture, event-driven architecture, microkernel architecture, microservice architecture, or cloud architecture. This embodiment of the invention uses the layered architecture Android system as an example to exemplify the software structure of electronic device 100.

[0163] Figure 7 This is a schematic diagram of the software structure of the electronic device 100 according to an embodiment of the present invention.

[0164] A layered architecture divides software into several layers, each with a clear role and function. Layers communicate with each other through software interfaces. In some embodiments, the Android system is divided into four layers, from top to bottom: the application layer, the application framework layer, the Android runtime and system libraries, and the kernel layer.

[0165] The application layer can include a series of application packages.

[0166] like Figure 7 As shown, the application package may include applications such as camera, gallery, calendar, call, map, navigation, WLAN, Bluetooth, music, video, and SMS.

[0167] The application framework layer provides application programming interfaces (APIs) and a programming framework for applications in the application layer. The application framework layer includes some predefined functions.

[0168] like Figure 7 As shown, the application framework layer may include a window manager, content provider, view system, phone manager, resource manager, notification manager, etc.

[0169] The window manager is used to manage windowed applications. It can retrieve screen size, determine the presence of a status bar, lock the screen, and capture screenshots, among other things.

[0170] Content providers store and retrieve data, making that data accessible to applications. This data may include videos, images, audio, made and received phone calls, browsing history and bookmarks, phone books, etc.

[0171] A view system includes visual controls, such as controls for displaying text and controls for displaying images. View systems can be used to build applications. A display interface can consist of one or more views. For example, a display interface including a text notification icon could include views for displaying text and views for displaying images.

[0172] The phone manager is used to provide communication functions for electronic device 100. For example, it manages call status (including connection and disconnection).

[0173] The file explorer provides applications with various resources, such as localized strings, icons, images, layout files, video files, and more.

[0174] The notification manager allows applications to display notifications in the status bar. These notifications can be used to deliver informational messages and can disappear automatically after a short pause, requiring no user interaction. For example, the notification manager can be used to notify users of completed downloads or message alerts. The notification manager can also display notifications as icons or scrolling text in the top status bar, such as notifications from background applications, or as dialog boxes on the screen. Examples include displaying text messages in the status bar, emitting sounds, vibrating electronic devices, and flashing indicator lights.

[0175] The Android Runtime consists of core libraries and a virtual machine. The Android runtime is responsible for the scheduling and management of the Android system.

[0176] The core library consists of two parts: one part is the functionalities that need to be called by the Java language, and the other part is the Android core library.

[0177] The application layer and application framework layer run in a virtual machine. The virtual machine executes the Java files of the application layer and application framework layer as binary files. The virtual machine is used to perform functions such as object lifecycle management, stack management, thread management, security and exception management, and garbage collection.

[0178] System libraries can include multiple functional modules. For example: surface manager, media libraries, 3D graphics processing libraries (e.g., OpenGL ES), 2D graphics engines (e.g., SGL), etc.

[0179] The Surface Manager is used to manage the display subsystem and provides the blending of 2D and 3D layers for multiple applications.

[0180] The media library supports playback and recording of various common audio and video formats, as well as still image files. It supports multiple audio and video encoding formats, such as MPEG4, H.264, MP3, AAC, AMR, JPG, and PNG.

[0181] The 3D graphics processing library is used to implement 3D graphics drawing, image rendering, compositing, and layer processing.

[0182] A 2D graphics engine is a graphics engine for 2D drawing.

[0183] The kernel layer is the layer between hardware and software. The kernel layer contains at least the display driver, camera driver, audio driver, and sensor driver.

[0184] This application provides an electronic device, which includes a memory, a processor, and a computer program stored in the memory. The processor executes the computer program to implement the above-described method for displaying notifications.

[0185] This application also provides a computer-readable storage medium storing a computer program, which, when executed by a processor, can implement the steps in the above-described method embodiments.

[0186] This application also provides a computer program product, including a computing program, which, when run on a computer, enables the computer to perform the steps in the various method embodiments described above.

[0187] This application also provides a chip system, which includes a processing circuit interface circuit. The interface circuit receives code instructions and transmits them to the processing circuit. The processing circuit executes the code instructions to enable the chip system to implement the steps of any method embodiment of this application. The chip system can be a single chip or a chip module composed of multiple chips.

[0188] The above-described embodiments are only used to illustrate the technical solutions of this application, and are not intended to limit it. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of this application.

Claims

1. A method of calling, characterized by, The method is applied to a first electronic device, and the method comprises: When the first electronic device is located in a first country, the first electronic device calls a first number, the first number comprising a first telephone number and not comprising a country code; After the call is successful, the first electronic device stores a country code of the first country as a country code of the first telephone number.

2. The method of claim 1, wherein, After the first electronic device stores the country code of the first country as the country code of the first telephone number, the method further comprises: The first electronic device receives a first operation, the first operation comprising: an operation of inputting the first telephone number in a dial pad and dialing, or an operation of dialing a number to a first contact, the number of the first contact being the first telephone number, or an operation of selecting the first telephone number in a call log and dialing; The first electronic device calls a second number, the second number comprising the country code of the first telephone number and the first telephone number.

3. The method of claim 1, wherein, After the first electronic device stores the country code of the first country as the country code of the first telephone number, the method further comprises: When the first electronic device is located in a second country, the first electronic device receives a first operation, the first operation comprising: an operation of inputting the first telephone number in a dial pad and dialing, or an operation of dialing a number to a first contact, the number of the first contact being the first telephone number, or an operation of selecting the first telephone number in a call log and dialing; The first electronic device calls a second number, the second number comprising the country code of the first telephone number and the first telephone number.

4. The method of claim 3, wherein, Before the first electronic device calls the second number, the method further comprises: The first electronic device determines that the first electronic device is located in the second country based on a public land mobile network; The first electronic device determines that the country code of the second country where the first electronic device is located is inconsistent with the country code of the first telephone number.

5. The method according to any one of claims 2-4, characterized in that, The first operation comprises: after the operation of inputting the first telephone number in the dial pad and dialing, or the operation of selecting the first telephone number in the call log and dialing, the method further comprises: During the call of the second number, the first electronic device displays a first call interface, the first call interface comprising: the first telephone number, the country code of the first telephone number.

6. The method according to any one of claims 1-5, characterized in that, Before the first electronic device calls the first number, the method further comprises: The first electronic device determines that the first electronic device is located in the first country based on a public land mobile network; The first electronic device acquires the country code of the first country based on the first country.

7. The method according to claim 3 or 4, characterized in that, After the first electronic device stores the country code of the first country as the country code of the first telephone number, the method further comprises: In a case that the first electronic device is located in the first country, the first electronic device receives a third operation, the third operation comprising: an operation of inputting the first phone number in a dial pad and dialing, or, an operation of dialing a number of a first contact, the number of the first contact being the first phone number, or, an operation of selecting the first phone number in a communication record and dialing; The first electronic device calls the first number.

8. The method according to any one of claims 1 to 7, characterized in that, After the first electronic device stores the country code of the first country as the country code of the first phone number, the method further comprises: The first electronic device displays a first interface of creating a new contact, the first interface comprising: a name of the first contact input by a user, and the first phone number and the country code of the first phone number filled by the first electronic device; The first electronic device stores the name of the first contact, the first phone number, and the country code of the first phone number.

9. The method according to any one of claims 1-8, characterized in that, Before the first electronic device calls the first number, the method further comprises: The first electronic device displays a second interface of creating a new contact, the second interface comprising: a name of the first contact input by a user, and the first phone number; The first electronic device stores the name of the first contact and the first phone number; After the first electronic device stores the country code of the first country as the country code of the first phone number, the method further comprises: The first electronic device stores the name of the first contact, the first phone number, and the country code of the first phone number.

10. The method according to claim 8 or 9, characterized in that, After the first electronic device stores the name of the first contact, the first phone number, and the country code of the first phone number, the method further comprises: The first electronic device receives a second operation; The first electronic device modifies or deletes the country code of the first phone number in response to the second operation.

11. The method according to any one of claims 1-10, characterized in that, Before the first electronic device stores the country code of the first country as the country code of the first phone number, the method further comprises: The first electronic device keeps a call with an electronic device having the first phone number for a duration exceeding a first threshold.

12. The method according to any one of claims 1-11, characterized in that, The first number does not comprise a country prefix, and the second number comprises the country prefix.

13. An electronic device, comprising: The electronic device comprises a memory, a processor, and computer instructions stored in the memory, the processor executes the computer program to implement the method of any one of claims 1-12.

14. A computer-readable storage medium, characterized in that, The computer readable storage medium stores a computer program, the computer program is executed by a processor to implement the method of any one of claims 1-12.

15. A computer program product, characterised in that, The computer program product comprises computer instructions, when the computer instructions are executed by a processor, the method of any one of claims 1-12 is implemented.