CN115941836A - Interface display method, electronic equipment and storage medium - Google Patents

Interface display method, electronic equipment and storage medium Download PDF

Info

Publication number
CN115941836A
CN115941836A CN202211337269.XA CN202211337269A CN115941836A CN 115941836 A CN115941836 A CN 115941836A CN 202211337269 A CN202211337269 A CN 202211337269A CN 115941836 A CN115941836 A CN 115941836A
Authority
CN
China
Prior art keywords
wallpaper
mode
electronic device
interface
resources
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202211337269.XA
Other languages
Chinese (zh)
Other versions
CN115941836B (en
Inventor
刘超
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Honor Device Co Ltd
Original Assignee
Honor Device Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Honor Device Co Ltd filed Critical Honor Device Co Ltd
Priority to CN202211337269.XA priority Critical patent/CN115941836B/en
Publication of CN115941836A publication Critical patent/CN115941836A/en
Application granted granted Critical
Publication of CN115941836B publication Critical patent/CN115941836B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Telephone Function (AREA)

Abstract

The application discloses an interface display method, electronic equipment and a storage medium, and relates to the technical field of electronics, wherein the method comprises the steps of responding to an operation of requesting the electronic equipment to display a first wallpaper after detecting the operation, and acquiring resources of the first wallpaper and a color mode of the electronic equipment, wherein the color mode of the electronic equipment comprises a daytime mode and a night mode, and the resources of the first wallpaper comprise resources based on the daytime mode and resources based on the night mode; the electronic equipment displays resources based on the daytime mode under the condition of the daytime mode, and displays the resources based on the night mode under the condition of the night mode, so that the first wallpaper can adapt to the night mode of the electronic equipment, the problem of overhigh brightness of the first wallpaper is avoided when the first wallpaper is displayed under the night mode, when the color mode of the electronic equipment is switched, the first wallpaper can be switched along with the color mode of the electronic equipment, the brightness displayed by the electronic equipment is automatically adapted, and more comfortable experience can be provided for a user.

Description

Interface display method, electronic equipment and storage medium
Technical Field
The present disclosure relates to the field of electronic technologies, and in particular, to an interface display method, an electronic device, and a storage medium.
Background
Electronic devices such as mobile phones increasingly participate in the life of people, and when a user uses the mobile phone in a dark environment, if the content displayed in the display interface of the mobile phone is bright, the eyes of the user are stimulated, and the visual fatigue of the user is easily caused. The mobile phone is provided with a night display mode, and the display brightness in the night display mode is closer to the night environment, so that the stimulation to the eyes of a user can be reduced.
At present, after the wallpaper is applied to the mobile phone, the color of the wallpaper is generally fixed, and the brightness of some wallpapers is still very high when the wallpapers are displayed in a night display mode, so that the user experience is influenced.
Disclosure of Invention
The application provides an interface display method, electronic equipment and a storage medium, which can enable wallpaper to adapt to a night display mode of the electronic equipment and improve user experience. The technical scheme is as follows:
in a first aspect, an embodiment of the present application provides an interface display method, which is executed by an electronic device, and includes:
detecting a first operation, wherein the first operation requests the electronic equipment to display first wallpaper;
responding to the first operation, acquiring resources of the first wallpaper and a color mode of the electronic device, wherein the color mode of the electronic device comprises a daytime mode and a nighttime mode, and the resources of the first wallpaper comprise resources based on the daytime mode and resources based on the nighttime mode;
one of the resources of the first wallpaper is displayed according to a mode in which the electronic device is currently.
Based on the technical scheme, the resource based on the daytime mode is used for displaying in the daytime mode of the electronic equipment, the brightness of the resource display based on the daytime mode is closer to the daytime environment, the resource based on the night mode is used for displaying in the night mode of the electronic equipment, and the brightness of the resource display based on the night mode is closer to the night environment. When the operation of requesting to display the first wallpaper is detected, the electronic device can acquire a current color mode, resources based on the daytime mode are displayed under the condition that the electronic device is currently in the daytime mode, and the resources based on the night mode are displayed under the condition that the electronic device is currently in the night mode, so that the first wallpaper can adapt to the electronic night mode, when the first wallpaper is displayed under the night mode, the problem of overhigh brightness of the first wallpaper is avoided, and user experience is improved.
With reference to the first aspect and the foregoing implementation manners, in some implementation manners of the first aspect, the first operation may be an operation of causing the electronic device to switch from any state to an interface displaying wallpaper, where the interface displaying wallpaper includes a desktop and a lock screen interface, and in some cases, the interface displaying wallpaper further includes an off screen display (AOD) interface. The first operation may be an operation of returning the electronic device from any application interface to the desktop, pressing a power key, tapping the screen, clicking a key-lock screen control, fingerprint unlocking, face unlocking, gesture unlocking, and the like. In some cases, the electronic apparatus has a folding screen, and the first operation may be an operation of unfolding the folding screen from a fully folded state.
The electronic device acquires resources of the first wallpaper in response to the first operation to display one of the resources of the first wallpaper. In certain implementations of the first aspect, the Resource of the first wallpaper may be obtained in real-time, e.g., after the first wallpaper is set as a wallpaper of the electronic device, the electronic device stores Resource identification information, e.g., a Uniform Resource Identifier (URI), of the first wallpaper, and in response to the first operation, the electronic device obtains the Resource of the first wallpaper from the internet according to the Resource identification information.
For example, after a first wallpaper setting is set as a wallpaper for the electronic device, the electronic device stores a resource of the first wallpaper, and in response to a first operation, the electronic device retrieves the resource of the first wallpaper from a storage directory.
In certain implementations of the first aspect, after the first wallpaper is set as the wallpaper of the electronic device, the electronic device stores the resources of the first wallpaper and pre-processes the resources of the first wallpaper, e.g., loads a video to the multimedia player, loads a video based on a daytime mode to the multimedia player if the electronic device is in the daytime mode when the wallpaper is set, and loads a video based on a nighttime mode to the multimedia player if the electronic device is in the nighttime mode when the wallpaper is set.
After detecting the first operation, the electronic equipment responds to the first operation, acquires a color mode in which the electronic equipment is currently positioned, and determines whether the resource loaded in the multimedia player is a resource based on a daytime mode or a resource based on a nighttime mode; and determining whether the current color mode of the electronic equipment is consistent with the mode of the resource loaded in the multimedia player, acquiring one of the resources of the first wallpaper and switching the resource loaded in the multimedia player under the condition of inconsistency.
For example, the resource loaded in the multimedia player is a resource based on a daytime mode, and in the case that the electronic device is currently in the daytime mode, the resource of the first wallpaper does not need to be acquired. And under the condition that the electronic equipment is currently in the night mode, the electronic equipment acquires the night mode-based resource in the resources of the first wallpaper, and changes the resource loaded in the multimedia player from the daytime mode-based resource to the night mode-based resource.
For example, the resource loaded in the multimedia player is a resource based on a night mode, and in the case that the electronic device is currently in the night mode, the resource of the first wallpaper does not need to be acquired. And under the condition that the electronic equipment is currently in the daytime mode, the electronic equipment acquires the resources based on the daytime mode in the resources of the first wallpaper, and the resources loaded in the multimedia player are replaced from the resources based on the nighttime mode to the resources based on the daytime mode. Therefore, the electronic equipment can respond to the first operation more quickly under the condition that the resource of the first wallpaper does not need to be acquired, and the performance of the electronic equipment is improved.
With reference to the first aspect, in some implementations of the first aspect, the electronic device is currently in a daytime mode, and the interface display method further includes: when the second operation is detected, the second operation instructs the electronic device to switch the color mode from the daytime mode to the nighttime mode, and to switch the resource of the displayed first wallpaper from the resource based on the daytime mode to the resource based on the nighttime mode.
With reference to the first aspect, in certain implementation manners of the first aspect, the electronic device is currently in a night mode, and the interface display method further includes: in a case where the third operation is detected, the third operation instructs the electronic device to switch the color mode from the night mode to the day mode, and to switch the resource of the displayed first wallpaper from the night mode-based resource to the day mode-based resource.
Based on the above technical scheme, when the color mode of the electronic device is detected to be switched, the mode is switched from the daytime mode to the night mode, the mode is switched from the night mode to the daytime mode, the first wallpaper displayed by the electronic device can be switched along with the color mode of the electronic device, so that the brightness displayed by the electronic device is automatically adapted, stimulation to eyes of a user is avoided, or the user cannot see the screen clearly, and user experience is improved.
With reference to the first aspect and the foregoing implementation manners, in some implementation manners of the first aspect, the resource of the first wallpaper includes at least one of a video and a picture.
The first wallpaper may be a static wallpaper, the static wallpaper is displayed as a picture, and the resources of the first wallpaper include a daytime mode picture and a nighttime mode picture.
The first wallpaper can also be a dynamic wallpaper, and the dynamic wallpaper can be super wallpaper, screen-locking desktop dynamic wallpaper, folding screen wallpaper and the like, wherein animation effects displayed by the dynamic wallpaper are determined by continuous video frames in a video segment, and resources of the first wallpaper comprise a daytime mode video and a nighttime mode video.
When the first wallpaper is a dynamic wallpaper, the resources of the first wallpaper can include a daytime mode picture and a night mode picture in addition to a daytime mode video and a night mode video, at this time, the picture can be a frame in the video, in the scene, the electronic device displays the daytime mode picture when displaying the lock screen interface in the daytime mode, and the electronic device displays the night mode picture when displaying the lock screen interface in the night mode, so that the lock screen interface can adapt to the electronic night mode.
In a second aspect, an embodiment of the present application provides an electronic device, including: one or more processors; one or more memories; the memory stores one or more programs that, when executed by the processor, cause the electronic device to perform any of the possible methods of the first aspect.
In a third aspect, the present application provides an apparatus, which is included in an electronic device, and has a function of implementing the behavior of the electronic device in the foregoing aspects and possible implementations of the foregoing aspects. The functions may be implemented by hardware, or by hardware executing corresponding software. The hardware or software includes one or more modules or units corresponding to the above-described functions. Such as a display module or unit, a detection module or unit, a processing module or unit, etc.
In a fourth aspect, embodiments of the present application provide a computer-readable storage medium having stored therein instructions, which, when executed on a computer, cause the computer to perform the method of the first aspect.
In a fifth aspect, embodiments of the present application provide a computer program product comprising instructions which, when run on a computer, cause the computer to perform the method of the first aspect.
The technical effects obtained by the second, third, fourth and fifth aspects are similar to the technical effects obtained by the corresponding technical means in the first aspect, and are not described herein again.
Drawings
Fig. 1 is a schematic structural diagram of an example of an electronic device 100 according to an embodiment of the present disclosure;
FIG. 2 is a schematic interface diagram illustrating an example of a color mode switching process according to an embodiment of the present disclosure;
FIG. 3 is a schematic interface diagram illustrating a color mode switching process according to another embodiment of the present disclosure;
FIG. 4 is a flowchart illustrating an example of an interface display method according to an embodiment of the present disclosure;
FIG. 5 shows schematic diagrams of wallpapers in a daytime mode and a nighttime mode according to an embodiment of the present application;
FIG. 6 is a block diagram illustrating an example of a software architecture provided by an embodiment of the present application;
FIG. 7 is a flowchart illustrating a further interface display method provided by an embodiment of the present application;
fig. 8 is a flowchart illustrating a further interface display method provided in the embodiment of the present application.
Detailed Description
To make the objects, technical solutions and advantages of the present application more clear, embodiments of the present application will be described in further detail below with reference to the accompanying drawings. In the following, the terms "first", "second" are used for descriptive purposes only and are not to be understood as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of that feature. In the description of the present embodiment, "a plurality" means two or more unless otherwise specified.
The technical scheme provided by the application is applied to the electronic equipment with the display function. Among others, electronic devices may include, but are not limited to: multimedia player, intelligent terminal, intelligent wearing equipment, intelligent household electrical appliances, virtual reality equipment etc.. Among others, the multimedia player may include but is not limited to: smart televisions, music players, video players, electronic projectors, and the like. Intelligent terminals may include, but are not limited to: smart phones, notebook computers, tablet computers, and the like. Smart wearable devices may include, but are not limited to: intelligent bracelet, intelligent wrist-watch, intelligent glasses etc.. Intelligent home devices may include, but are not limited to: intelligent electric rice cooker, intelligent switch, intelligent temperature control equipment etc.. Virtual display devices may include, but are not limited to, virtual Reality (VR) devices, augmented Reality (AR) devices, and the like.
Fig. 1 shows a hardware structure diagram of an electronic device 100.
The electronic device 100 may include a processor 110, an external memory interface 120, an internal memory 121, a Universal Serial Bus (USB) interface 130, a charging management module 140, a power management module 141, a battery 142, an antenna 1, an antenna 2, a mobile communication module 150, a wireless communication module 160, an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, an earphone interface 170D, a sensor module 180, a key 190, a motor 191, an indicator 192, a camera 193, a display screen 194, a Subscriber Identity Module (SIM) card interface 195, and the like. The sensor module 180 may include a pressure sensor 180A, a gyroscope sensor 180B, an air pressure sensor 180C, a magnetic sensor 180D, an acceleration sensor 180E, a distance sensor 180F, a proximity light sensor 180G, a fingerprint sensor 180H, a temperature sensor 180J, a touch sensor 180K, an ambient light sensor 180L, a bone conduction sensor 180M, and the like.
It is to be understood that the illustrated structure of the embodiment of the present invention does not specifically limit the electronic device 100. In other embodiments of the present application, electronic device 100 may include more or fewer components than shown, or some components may be combined, some components may be split, or a different arrangement of components. The illustrated components may be implemented in hardware, software, or a combination of software and hardware.
Processor 110 may include one or more processing units, such as: the processor 110 may include an Application Processor (AP), a modem processor, a Graphics Processing Unit (GPU), an Image Signal Processor (ISP), a controller, a video codec, a Digital Signal Processor (DSP), a baseband processor, and/or a neural-Network Processing Unit (NPU), etc. Wherein, the different processing units may be independent devices or may be integrated in one or more processors.
The controller can generate an operation control signal according to the instruction operation code and the timing signal to complete the control of instruction fetching and instruction execution.
A memory may also be provided in processor 110 for storing instructions and data. In some embodiments, the memory in the processor 110 is a cache memory. The memory may hold instructions or data that have just been used or recycled by the processor 110. If the processor 110 needs to reuse the instruction or data, it can be called directly from the memory. Avoiding repeated accesses reduces the latency of the processor 110, thereby increasing the efficiency of the system.
In some embodiments, processor 110 may include one or more interfaces. The interface may include an integrated circuit (I2C) interface, an integrated circuit built-in audio (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.
The I2C interface is a bidirectional synchronous serial bus including a serial data line (SDA) and a Serial Clock Line (SCL). In some embodiments, processor 110 may include multiple sets of I2C buses. The processor 110 may be coupled to the touch sensor 180K, a charger, a flash, a camera 193, etc. through different I2C bus interfaces, respectively. For example: the processor 110 may be coupled to the touch sensor 180K through an I2C interface, so that the processor 110 and the touch sensor 180K communicate through an I2C bus interface to implement a touch function of the electronic device 100.
The I2S interface may be used for audio communication. In some embodiments, processor 110 may include multiple sets of I2S buses. The processor 110 may be coupled to the audio module 170 through an I2S bus to enable communication between the processor 110 and the audio module 170. In some embodiments, the audio module 170 may transmit the audio signal to the wireless communication module 160 through the I2S interface, so as to implement a function of receiving a call through a bluetooth headset.
The PCM interface may also be used for audio communication, sampling, quantizing and encoding analog signals. In some embodiments, audio module 170 and wireless communication module 160 may be coupled by a PCM bus interface. In some embodiments, the audio module 170 may also transmit audio signals to the wireless communication module 160 through the PCM interface, so as to implement a function of answering a call through a bluetooth headset. Both the I2S interface and the PCM interface may be used for audio communication.
The UART interface is a universal serial data bus used for asynchronous communications. The bus may be a bidirectional communication bus. It converts the data to be transmitted between serial communication and parallel communication. In some embodiments, a UART interface is generally used to connect the processor 110 with the wireless communication module 160. For example: the processor 110 communicates with a bluetooth module in the wireless communication module 160 through a UART interface to implement a bluetooth function. In some embodiments, the audio module 170 may transmit the audio signal to the wireless communication module 160 through a UART interface, so as to implement the function of playing music through a bluetooth headset.
MIPI interfaces may be used to connect processor 110 with peripheral devices such as display screen 194, camera 193, and the like. The MIPI interface includes a Camera Serial Interface (CSI), a Display Serial Interface (DSI), and the like. In some embodiments, processor 110 and camera 193 communicate through a CSI interface to implement the capture functionality of electronic device 100. The processor 110 and the display screen 194 communicate through the DSI interface to implement the display function of the electronic device 100.
The GPIO interface may be configured by software. The GPIO interface may be configured as a control signal and may also be configured as a data signal. In some embodiments, a GPIO interface may be used to connect the processor 110 with the camera 193, the display 194, the wireless communication module 160, the audio module 170, the sensor module 180, and the like. The GPIO interface may also be configured as an I2C interface, I2S interface, UART interface, MIPI interface, and the like.
The USB interface 130 is an interface conforming to the USB standard specification, and may specifically be a Mini USB interface, a Micro USB interface, a USB Type C interface, or the like. The USB interface 130 may be used to connect a charger to charge the electronic device 100, and may also be used to transmit data between the electronic device 100 and a peripheral device. And the earphone can also be used for connecting an earphone and playing audio through the earphone. The interface may also be used to connect other electronic devices, such as AR devices and the like.
It should be understood that the connection relationship between the modules according to the embodiment of the present invention is only illustrative, and is not limited to the structure of the electronic device 100. In other embodiments of the present application, the electronic device 100 may also adopt different interface connection manners or a combination of multiple interface connection manners in the above embodiments.
The charging management module 140 is configured to receive charging input from a charger. The charger can be a wireless charger or a wired charger. In some wired charging embodiments, the charging management module 140 may receive charging input from a wired charger via the USB interface 130. In some wireless charging embodiments, the charging management module 140 may receive a wireless charging input through a wireless charging coil of the electronic device 100. The charging management module 140 may also supply power to the electronic device through the power management module 141 while charging the battery 142.
The power management module 141 is used to connect 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 charge management module 140, and supplies power to the processor 110, the internal memory 121, the display 194, the camera 193, the wireless communication module 160, and the like. The power management module 141 may also be used to monitor parameters such as battery capacity, battery cycle count, battery state of health (leakage, impedance), etc. In some other embodiments, the power management module 141 may also be disposed in the processor 110. In other embodiments, the power management module 141 and the charging management module 140 may be disposed in the same device.
The buttons 190 include a power key for a user to control the electronic device 100 to turn on, turn off, turn on, and turn off the screen. For example, in the case where the electronic apparatus 100 is powered off, the electronic apparatus 100 is powered on in response to an operation of the user pressing the power key for a long time. For another example, in a case where the electronic apparatus 100 is off, the electronic apparatus 100 turns on the screen in response to the user's operation of clicking the power key. For another example, the electronic apparatus 100 turns off the screen in response to the user's operation of clicking the power key while the screen is on. For example, when the electronic device 100 displays a screen lock interface or a desktop, in response to the user clicking the power key, the AOD interface is entered, that is, the AOD interface is displayed on the display screen. For another example, when the electronic device 100 displays the AOD interface, in response to the user clicking the power key, the desktop or the screen lock interface is entered, that is, the desktop or the screen lock interface is displayed on the display screen.
The wireless communication function of the electronic device 100 may be implemented by the antenna 1, the antenna 2, the mobile communication module 150, the wireless communication module 160, a modem processor, a baseband processor, and the like.
The antennas 1 and 2 are used for transmitting and receiving electromagnetic wave signals. Each antenna in the electronic device 100 may be used to cover a single or multiple communication bands. Different antennas can also be multiplexed to improve the utilization of the antennas. For example: the antenna 1 may be multiplexed as a diversity antenna of a wireless local area network. In other embodiments, the antenna may be used in conjunction with a tuning switch.
The mobile communication module 150 may provide a solution including wireless communication of 2G/3G/4G/5G, etc. applied to the electronic device 100. The mobile communication module 150 may include at least one filter, a switch, a power amplifier, a Low Noise Amplifier (LNA), and the like. The mobile communication module 150 may receive the electromagnetic wave from the antenna 1, filter, amplify, etc. the received electromagnetic wave, and transmit the electromagnetic wave to the modem processor for demodulation. The mobile communication module 150 may also amplify the signal modulated by the modem processor, and convert the signal into electromagnetic wave through the antenna 1 to radiate the electromagnetic wave. In some embodiments, at least some of the functional modules of the mobile communication module 150 may be disposed in the processor 110. In some embodiments, at least some of the functional modules of the mobile communication module 150 may be provided in the same device as at least some of the modules of the processor 110.
The modem processor may include a modulator and a demodulator. The modulator is used for modulating a low-frequency baseband signal to be transmitted into a medium-high frequency signal. The demodulator is used for demodulating the received electromagnetic wave signal into a low-frequency baseband signal. The demodulator then passes the demodulated low frequency baseband signal to a baseband processor for processing. The low frequency baseband signal is processed by the baseband processor and then transferred to the application processor. The application processor outputs a sound signal through an audio device (not limited to the speaker 170A, the receiver 170B, etc.) or displays an image or video through the display screen 194. In some embodiments, the modem processor may be a stand-alone device. In other embodiments, the modem processor may be provided in the same device as the mobile communication module 150 or other functional modules, independent of the processor 110.
The wireless communication module 160 may provide a solution for wireless communication applied to the electronic device 100, including Wireless Local Area Networks (WLANs) (e.g., wireless fidelity (Wi-Fi) networks), bluetooth (bluetooth, BT), global Navigation Satellite System (GNSS), frequency Modulation (FM), near Field Communication (NFC), infrared (IR), and the like. 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 the antenna 2, performs frequency modulation and filtering on electromagnetic wave signals, and transmits the processed signals to the processor 110. The wireless communication module 160 may also receive a signal to be transmitted from the processor 110, perform frequency modulation and amplification on the signal, and convert the signal into electromagnetic waves via the antenna 2 to radiate the electromagnetic waves.
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 so that electronic device 100 can communicate with networks and other devices through wireless communication techniques. 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 (time-division multiple access, TD-SCDMA), long Term Evolution (LTE), BT, GNSS, WLAN, NFC, FM, and/or IR technologies, etc. The GNSS may include a Global Positioning System (GPS), a global navigation satellite system (GLONASS), a beidou navigation satellite system (BDS), a quasi-zenith satellite system (QZSS), and/or a Satellite Based Augmentation System (SBAS).
The electronic device 100 implements display functions via the GPU, the display screen 194, and the 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 for graphics rendering. The processor 110 may include one or more GPUs that execute program instructions to generate or alter display information.
The display screen 194 is used for displaying wallpaper interfaces, such as an AOD interface, a screen lock interface, a wallpaper interface of a desktop, and the like. The display screen 194 includes a display panel. The display panel may be a Liquid Crystal Display (LCD), an organic light-emitting diode (OLED), an active-matrix organic light-emitting diode (active-matrix organic light-emitting diode, AMOLED), a flexible light-emitting diode (FLED), a miniature, a Micro-oeld, a quantum dot light-emitting diode (QLED), or the like. In some embodiments, the electronic device 100 may include 1 or N display screens 194, N being a positive integer greater than 1.
The electronic device 100 may implement a shooting function through the ISP, the camera 193, the video codec, the GPU, the display 194, the application processor, and the like.
The ISP is used to process the data fed back by the camera 193. For example, when a photo is taken, the shutter is opened, light is transmitted to the camera photosensitive element through the lens, the optical signal is converted into an electrical signal, and the camera photosensitive element transmits the electrical signal to the ISP for processing and converting into an image visible to naked eyes. The ISP can also carry out algorithm optimization on the noise, brightness and skin color of the image. The ISP can also optimize parameters such as exposure, color temperature and the like of a shooting scene. In some embodiments, the ISP may be provided in camera 193.
The camera 193 is used to capture still images or video. The object generates an optical image through the lens and projects the optical image to the photosensitive element. The photosensitive element may be a Charge Coupled Device (CCD) or a complementary metal-oxide-semiconductor (CMOS) phototransistor. The light sensing element converts the optical signal into an electrical signal, which is then passed to the ISP where it is converted into a digital image signal. And the ISP outputs the digital image signal to the DSP for processing. The DSP converts the digital image signal into image signal in standard RGB, YUV and other formats. In some embodiments, electronic device 100 may include 1 or N cameras 193, N being a positive integer greater than 1.
The digital signal processor is used for processing digital signals, and can process digital image signals and other digital signals. For example, when the electronic device 100 selects a frequency bin, the digital signal processor is used to perform fourier transform or the like on the frequency bin energy.
Video codecs are used to compress or decompress digital video. The electronic device 100 may support one or more video codecs. In this way, the electronic device 100 may play or record video in a variety of encoding formats, such as: moving Picture Experts Group (MPEG) 1, MPEG2, MPEG3, MPEG4, and the like.
The NPU is a neural-network (NN) computing processor that processes input information quickly by using a biological neural network structure, for example, by using a transfer mode between neurons of a human brain, and can also learn by itself continuously. Applications such as intelligent recognition of the electronic device 100 can be implemented by the NPU, for example: image recognition, face recognition, speech recognition, text understanding, and the like.
The external memory interface 120 may be used to connect an external memory card, such as a Micro SD card, to extend the storage capability of the electronic device 100. The external memory card communicates with the processor 110 through the external memory interface 120 to implement a data storage function. For example, files such as music, video, etc. are saved in the external memory card.
The internal memory 121 may be used to store computer-executable program code, which includes instructions. The internal memory 121 may include a program storage area and a data storage area. The storage program area may store an operating system, an application program (such as a sound playing function, an image playing function, etc.) required by at least one function, and the like. The storage data area may store data (such as audio data, phone book, etc.) created during use of the electronic device 100, and the like. In addition, the internal memory 121 may include a high speed random access memory, and may also include a non-volatile memory, such as at least one magnetic disk storage device, a flash memory device, a Universal Flash Storage (UFS), and the like. The processor 110 executes various functional applications of the electronic device 100 and data processing by executing instructions stored in the internal memory 121 and/or instructions stored in a memory provided in the processor.
The electronic device 100 may implement audio functions via the audio module 170, the speaker 170A, the receiver 170B, the microphone 170C, the headphone interface 170D, and the application processor. Such as music playing, recording, etc.
The audio module 170 is used to convert digital audio information into an analog audio signal output and also to convert an analog audio input into a digital audio signal. The audio module 170 may also be used to encode and decode audio signals. In some embodiments, the audio module 170 may be disposed in the processor 110, or some functional modules of the audio module 170 may be disposed in the processor 110.
The speaker 170A, also called a "horn", is used to convert the audio electrical signal into an acoustic signal. The electronic apparatus 100 can listen to music through the speaker 170A or listen to a hands-free call.
The receiver 170B, also called "earpiece", is used to convert the electrical audio signal into an acoustic signal. When the electronic apparatus 100 receives a call or voice information, it can receive voice by placing the receiver 170B close to the ear of the person.
The microphone 170C, also referred to as a "microphone," is used to convert sound signals into electrical signals. When making a call or transmitting voice information, the user can input a voice signal to the microphone 170C by speaking near the microphone 170C through the mouth. The electronic device 100 may be provided with at least one microphone 170C. In other embodiments, the electronic device 100 may be provided with two microphones 170C to achieve a noise reduction function in addition to collecting sound signals. In other embodiments, the electronic device 100 may further include three, four or more microphones 170C to collect sound signals, reduce noise, identify sound sources, perform directional recording, and so on.
The earphone interface 170D is used to connect a wired earphone. The headset interface 170D may be the USB interface 130, or may be a 3.5mm open mobile electronic device platform (OMTP) standard interface, a cellular telecommunications industry association (cellular telecommunications industry association of the USA, CTIA) standard interface.
The pressure sensor 180A is used for sensing a pressure signal, and can convert the pressure signal into an electrical signal. In some embodiments, the pressure sensor 180A may be disposed on the display screen 194. The pressure sensor 180A can be of a variety of types, such as a resistive pressure sensor, an inductive pressure sensor, a capacitive pressure sensor, and the like. The capacitive pressure sensor may be a sensor comprising at least two parallel plates having an electrically conductive material. When a force acts on the pressure sensor 180A, the capacitance between the electrodes changes. The electronic device 100 determines the strength of the pressure from the change in capacitance. When a touch operation is applied to the display screen 194, the electronic apparatus 100 detects the intensity of the touch operation according to the pressure sensor 180A. The electronic apparatus 100 may also calculate the touched position from the detection signal of the pressure sensor 180A. In some embodiments, the touch operations that are applied to the same touch position but different touch operation intensities may correspond to different operation instructions. For example: and when the touch operation with the touch operation intensity smaller than the first pressure threshold value acts on the short message application icon, executing an instruction for viewing the short message. And when the touch operation with the touch operation intensity larger than or equal to the first pressure threshold value acts on the short message application icon, executing an instruction of newly building the short message.
The gyro sensor 180B may be used to determine the motion attitude of the electronic device 100. In some embodiments, the angular velocity of electronic device 100 about three axes (i.e., the x, y, and z axes) may be determined by gyroscope sensor 180B. The gyro sensor 180B may be used for photographing anti-shake. For example, when the shutter is pressed, the gyro sensor 180B detects a shake angle of the electronic device 100, calculates a distance to be compensated for by the lens module according to the shake angle, and allows the lens to counteract the shake of the electronic device 100 through a reverse movement, thereby achieving anti-shake. The gyroscope sensor 180B may also be used for navigation, somatosensory gaming scenes.
The air pressure sensor 180C is used to measure air pressure. In some embodiments, electronic device 100 calculates altitude, aiding in positioning and navigation, from barometric pressure values measured by barometric pressure sensor 180C.
The magnetic sensor 180D includes a hall sensor. The electronic device 100 may detect the opening and closing of the flip holster using the magnetic sensor 180D. In some embodiments, when the electronic device 100 is a flip phone, the electronic device 100 may detect the opening and closing of the flip according to the magnetic sensor 180D. And then according to the detected opening and closing state of the leather sheath or the opening and closing state of the flip, the characteristics of automatic unlocking of the flip and the like are set.
The acceleration sensor 180E may detect the magnitude of acceleration of the electronic device 100 in various directions (typically three axes). The magnitude and direction of gravity may be detected when the electronic device 100 is stationary. The method can also be used for recognizing the posture of the electronic equipment, and is applied to horizontal and vertical screen switching, pedometers and other applications.
A distance sensor 180F for measuring a distance. The electronic device 100 may measure the distance by infrared or laser. In some embodiments, taking a picture of a scene, electronic device 100 may utilize range sensor 180F to range for fast focus.
The proximity light sensor 180G may include, for example, a Light Emitting Diode (LED) and a light detector, such as a photodiode. The light emitting diode may be an infrared light emitting diode. The electronic device 100 emits infrared light to the outside through the light emitting diode. The electronic device 100 detects infrared reflected light from a nearby object using a photodiode. When sufficient reflected light is detected, it can be determined that there is an object near the electronic device 100. When insufficient reflected light is detected, the electronic device 100 may determine that there are no objects near the electronic device 100. The electronic device 100 can utilize the proximity light sensor 180G to detect that the user holds the electronic device 100 close to the ear for talking, so as to automatically turn off the screen to achieve the purpose of saving power. The proximity light sensor 180G may also be used in a holster mode, a pocket mode automatically unlocks and locks the screen.
The ambient light sensor 180L is used to sense the ambient light level. Electronic device 100 may adaptively adjust the brightness of display screen 194 based on the perceived ambient light level. The ambient light sensor 180L may also be used to automatically adjust the white balance when taking a picture. The ambient light sensor 180L may also cooperate with the proximity light sensor 180G to detect whether the electronic device 100 is in a pocket to prevent accidental touches.
The fingerprint sensor 180H is used to collect a fingerprint. The electronic device 100 may utilize the collected fingerprint characteristics to unlock a fingerprint, access an application lock, photograph a fingerprint, answer an incoming call with a fingerprint, and so on.
The temperature sensor 180J is used to detect temperature. In some embodiments, electronic device 100 implements a temperature processing strategy using the temperature detected by temperature sensor 180J. For example, when the temperature reported by the temperature sensor 180J exceeds a threshold, the electronic device 100 performs a reduction in performance of a processor located near the temperature sensor 180J, so as to reduce power consumption and implement thermal protection. In other embodiments, the electronic device 100 heats the battery 142 when the temperature is below another threshold to avoid the low temperature causing the electronic device 100 to shut down abnormally. In other embodiments, when the temperature is lower than a further threshold, the electronic device 100 performs a boost on the output voltage of the battery 142 to avoid abnormal shutdown due to low temperature.
The touch sensor 180K is also called a "touch device". The touch sensor 180K may be disposed on the display screen 194, and the touch sensor 180K and the display screen 194 form a touch screen, which is also called a "touch screen". The touch sensor 180K is used to detect a touch operation applied thereto or nearby. The touch sensor can communicate the detected touch operation to the application processor to determine the touch event type. Visual output associated with the touch operation may be provided through the display screen 194. In other embodiments, the touch sensor 180K may be disposed on a surface of the electronic device 100, different from the position of the display screen 194.
The bone conduction sensor 180M may acquire a vibration signal. In some embodiments, the bone conduction sensor 180M may acquire a vibration signal of the human vocal part vibrating the bone mass. The bone conduction sensor 180M may also contact the human pulse to receive the blood pressure pulsation signal. In some embodiments, the bone conduction sensor 180M may also be disposed in a headset, integrated into a bone conduction headset. The audio module 170 may analyze a voice signal based on the vibration signal of the bone mass vibrated by the sound part acquired by the bone conduction sensor 180M, so as to implement a voice function. The application processor can analyze heart rate information based on the blood pressure beating signal acquired by the bone conduction sensor 180M, so as to realize the heart rate detection function.
The keys 190 include a power-on key, a volume key, and the like. The keys 190 may be mechanical keys. Or may be touch keys. The electronic apparatus 100 may receive a key input, and generate a key signal input related to user setting and function control of the electronic apparatus 100.
The motor 191 may generate a vibration cue. The motor 191 may be used for incoming call vibration cues, as well as for touch vibration feedback. For example, touch operations applied to different applications (e.g., photographing, audio playing, etc.) may correspond to different vibration feedback effects. The motor 191 may also respond to different vibration feedback effects for touch operations applied to different areas of the display screen 194. Different application scenes (such as time reminding, receiving information, alarm clock, game and the like) can also correspond to different vibration feedback effects. The touch vibration feedback effect may also support customization.
Indicator 192 may be an indicator light that may be used to indicate a state of charge, a change in charge, or a message, missed call, notification, etc.
The SIM card interface 195 is used to connect a SIM card. The SIM card can be brought into and out of contact with the electronic apparatus 100 by being inserted into the SIM card interface 195 or being pulled out of the SIM card interface 195. The electronic device 100 may support 1 or N SIM card interfaces, N being a positive integer greater than 1. The SIM card interface 195 may support a Nano SIM card, a Micro SIM card, a SIM card, etc. The same SIM card interface 195 can be inserted with multiple cards at the same time. The types of the plurality of cards may be the same or different. The SIM card interface 195 may also be compatible with different types of SIM cards. The SIM card interface 195 may also be compatible with external memory cards. The electronic device 100 interacts with the network through the SIM card to implement functions such as communication and data communication. In some embodiments, the electronic device 100 employs esims, namely: an embedded SIM card. The eSIM card can be embedded in the electronic device 100 and cannot be separated from the electronic device 100.
It is to be understood that the illustrated structure of the embodiment of the present invention does not specifically limit the electronic device 100. In other embodiments of the present application, the electronic device 100 may include more or fewer components than shown, or combine certain components, or split certain components, or arrange different components. The illustrated components may be implemented in hardware, software, or a combination of software and hardware.
The color modes of the electronic device include: the Mode name is not particularly limited in the embodiment of the present application, and the Mode name may be referred to in the present application.
The user may switch the color mode of the electronic device when entering a dark environment from a bright environment, e.g. turning off the light, or when entering a bright environment from a dark environment, e.g. turning on the light.
The following description will be given taking an electronic device as a mobile phone as an example. In one application scenario, a user may switch the color mode of the electronic device by clicking a "night mode" control in the status bar. For example, fig. 2 shows an implementation procedure in which the mobile phone turns on the night mode, and as shown in (a) of fig. 2, the mobile phone is currently in the day mode and displays an information list of the day mode. When the electronic device is in the daytime mode, the information list is displayed in a color configuration preset or default by the system, or in a color configuration customized by the user, and the white background color shown in fig. 2 (a) is a common default design and is used only for illustrating this setting manner, and is not used to limit the present application. When the mobile phone receives a signal of sliding downwards from the top of the screen, a status bar is displayed, as shown in (b) in fig. 2, a plurality of controls are arranged on the status bar, the controls include a control 21 for starting a night mode, when the mobile phone receives a signal of clicking the control 21 by a user, the color mode is switched from a daytime mode to the night mode, the status of the status bar after the switching to the night mode is as shown in (c) in fig. 2, when the mobile phone receives a signal of sliding upwards, the status bar exits, an information list is returned, and at this time, the information list of the night mode is displayed, as shown in (d) in fig. 2. When the handset is in the night mode, the information list is presented in a darker background color, such as black as shown in fig. 2 (d), and the information list presented in the night mode is also processed so that the information list can be distinguished from the black background color.
On the contrary, if the user enters the status bar in the night mode, the control 21 is clicked, and the mobile phone is switched from the night mode to the daytime mode in response to the click operation of the user.
In another application scenario, a user may switch color modes of the electronic device in setting up the application. For example, fig. 3 shows an implementation process of turning on the night mode of the mobile phone, and as shown in (a) of fig. 3, icons of a plurality of applications, such as "settings", "videos", "weather", and the like, are laid out on the main interface of the mobile phone. When the mobile phone receives a touch signal of clicking the "setting" by the user, an interface as shown in (b) of fig. 3 may be entered, and the interface includes a "night mode" control 31. When the mobile phone receives a signal that the user clicks the control 31, the color mode may be switched from the daytime mode to the nighttime mode, and the state of the control 31 after switching to the nighttime mode is shown in fig. 3 (c).
The technical scheme provided by the embodiment of the application is used for enabling the wallpaper of the electronic equipment to be adaptive to the color mode of the electronic equipment. The interface for displaying the wallpaper in the electronic device may include an AOD interface, a screen locking interface, a desktop, and an interface displayed in the process of switching between the AOD interface and the screen locking interface, switching between the screen locking interface and the desktop, and switching between the AOD interface and the desktop.
In the embodiment of the present application, the wallpaper may be a static wallpaper or a dynamic wallpaper, the static wallpaper refers to a frame of picture with the static background wallpaper, the dynamic wallpaper refers to the dynamic background wallpaper, the dynamic wallpaper may include a super wallpaper (SuperWallpaper), a dynamic wallpaper (dynamic wallpaper), a folding screen wallpaper (FoldWallpaper), and the like, and the embodiment of the present application does not particularly limit the type of the wallpaper.
The static wallpaper can be displayed on an AOD interface, a screen locking interface or a desktop freeze frame. The dynamic effect wallpaper can be displayed on an AOD interface, a screen locking interface or a desktop in a freeze frame mode, and can also be displayed in the process of switching between the AOD interface and the screen locking interface, switching between the screen locking interface and the desktop, and switching between the AOD interface and the desktop.
The dynamic effect wallpaper is essentially a video playing section when being displayed. Specifically, the super wallpaper refers to that background wallpapers played in the process that a mobile phone enters a desktop or a screen locking interface from a screen blanking display (AOD) interface, enters the screen locking interface from the AOD interface and then enters the desktop, and returns to the AOD interface from the desktop or the screen locking interface are dynamic and continuous, and has a display effect that the content of the background wallpapers changes at one go. The screen-off display means that after the mobile phone executes a screen-off instruction, a partial area of the display screen can be lightened to display the AOD interface, and then the screen is completely turned off. The AOD interface can comprise time, date and background wallpaper. The trigger time of the super wallpaper can be various, (1) for example, when the mobile phone displays an AOD interface on the display screen, if the user clicks a power key, the mobile phone responds to the operation of the user clicking the power key, exits the AOD, triggers the playing of the super wallpaper, and lights up the display screen to enter a screen locking interface, that is, an animation of the super wallpaper from the AOD interface to the screen locking interface is displayed on the display screen. (2) For example, when the mobile phone displays a screen locking interface, if the mobile phone is unlocked by a user in the screen locking interface, the mobile phone exits the screen locking interface in response to an unlocking operation of the user on the mobile phone, a desktop is displayed on the display screen, and animation of super wallpaper from the screen locking interface to the desktop is displayed on the display screen. (3) For example, when a mobile phone displays an AOD interface on a display screen, if a user passes password, fingerprint, or face authentication, an animation from the AOD interface to a desktop is displayed on the display screen in response to an unlocking operation of the mobile phone by the user. (4) For example, when the mobile phone displays a desktop on the display screen, if the user clicks the power key, the mobile phone displays an animation from the desktop to the AOD interface on the display screen in response to the user's operation of clicking the power key. (5) For example, when the mobile phone displays a screen locking interface, if a user clicks a power key, the mobile phone displays an animation from the screen locking interface to the AOD interface on the display screen in response to an operation of the user clicking the power key.
The dynamic wallpaper refers to that background wallpaper played in the process that the mobile phone enters the desktop from the screen locking interface is dynamic and continuous, has the display effect of linkage of the screen locking dynamic effect and the desktop dynamic effect, and can be called as screen locking desktop dynamic wallpaper, or the background wallpaper of the mobile phone desktop is dynamic and can be called as desktop dynamic wallpaper. For example, when the mobile phone displays the screen locking interface, if the user unlocks the mobile phone on the screen locking interface, the mobile phone responds to the unlocking operation of the user on the mobile phone, and displays the dynamic wallpaper on the display screen.
The folding screen wallpaper is applied to a folding screen mobile phone, the folding screen wallpaper refers to that background wallpaper is played when the mobile phone is in a process that a display screen is unfolded to a certain angle and is completely unfolded, or when the display screen is changed from a completely unfolded state to a folded state, the background wallpaper is dynamic and continuous, and the content of the background wallpaper changes along with the change of the folding angle of the display screen.
An interface display method provided by the embodiment of the present application is described below with reference to fig. 4. The method is executed by an electronic device with a display screen, and as shown in FIG. 4, the interface display method comprises S401-S403.
S401, a first operation is detected, and the first operation requests that a first wallpaper be displayed on a display screen of the electronic device.
The first operation is an operation of switching the electronic device from any state to an interface displaying wallpaper, and the first operation may be an operation of retreating the electronic device from any application interface to a desktop, pressing a power key, tapping a screen, clicking a one-key screen locking control, unlocking by fingerprints, unlocking by a human face, unlocking by gestures, and the like. In some cases, the electronic apparatus has a folding screen, and the first operation may be an operation of unfolding the folding screen from a fully folded state or an operation of folding the folding screen from an unfolded state.
S402, responding to the first operation, acquiring resources of the first wallpaper and a color mode of the electronic device, wherein the color mode of the electronic device comprises a daytime mode and a nighttime mode, and the resources of the first wallpaper comprise resources based on the daytime mode and resources based on the nighttime mode.
S403, displaying one of the resources of the first wallpaper according to the current mode of the electronic equipment.
The resources of the first wallpaper include resources based on daytime mode and resources based on nighttime mode. The resources based on the daytime mode are used for displaying in the daytime mode of the electronic device, the brightness of the resource display based on the daytime mode is closer to the daytime environment, the resources based on the nighttime mode are used for displaying in the nighttime mode of the electronic device, and the brightness of the resource display based on the nighttime mode is closer to the nighttime environment. For the same wallpaper, the pattern style displayed by the resources based on the daytime mode and the pattern style displayed by the resources based on the nighttime mode are the same, but the brightness parameter settings such as color, contrast, transparency and the like are different, so that the brightness of the wallpaper is different when the wallpaper is displayed.
Illustratively, fig. 5 shows a schematic interface diagram, where (a) in fig. 5 is a picture based on a daytime mode in the resource, and (b) in fig. 5 is a picture based on a nighttime mode in the resource, where the picture based on the daytime mode uses a white background color, and a pattern style is outlined by using black lines. The night mode-based picture uses a black background color and is outlined with white lines for pattern styles. Thus, the luminance of the picture based on the night mode is lower than the luminance of the picture based on the daytime mode.
The resource of the first wallpaper may include a video and may also include a picture. For example, the first wallpaper may be a static wallpaper, the static wallpaper is displayed as one picture, and the resources of the first wallpaper may include a daytime mode picture and a nighttime mode picture.
For example, the first wallpaper is a dynamic wallpaper, the animation effect displayed by the first wallpaper is determined by continuous video frames in a video segment, and the resources of the first wallpaper can comprise a daytime mode video and a nighttime mode video. In one implementation, when the first wallpaper is a dynamic wallpaper, the resources of the first wallpaper may include, in addition to a daytime mode video and a nighttime mode video, a daytime mode picture and a nighttime mode picture, where the picture may be one frame of the video, and in this implementation, the picture may be used for regularly displaying on interfaces such as a lock screen and a desktop, for example, the electronic device may display the daytime mode picture when displaying the lock screen interface in the daytime mode, and the electronic device may display the nighttime mode picture when displaying the lock screen interface in the nighttime mode.
In one implementation, the Resource of the first wallpaper may be obtained in real time, for example, after the first wallpaper is set as the wallpaper of the electronic device, the electronic device stores Resource identification information of the first wallpaper, for example, a Uniform Resource Identifier (URI), and in response to the first operation, the electronic device obtains the Resource of the first wallpaper from the internet according to the Resource identification information.
In one implementation, after a first wallpaper is set as a wallpaper of an electronic device, the electronic device downloads and stores a resource of the first wallpaper, and in response to a first operation, the electronic device retrieves the resource of the first wallpaper from a storage directory.
In one implementation, the resource of the first wallpaper is included in one data package, the data package of the first wallpaper is acquired or downloaded from the internet by the electronic device, and may be referred to as a theme package, an installation package, and the like, the theme package includes the resource of the first wallpaper, and the theme package may be a file in a compressed format, or a file in another format.
In one implementation, each time in response to the first operation, the electronic device acquires resources of the first wallpaper and a color mode in which the electronic device is currently in, acquires resources based on a daytime mode from among the resources of the first wallpaper if the electronic device is currently in the daytime mode, or acquires resources based on a nighttime mode from among the resources of the first wallpaper if the electronic device is currently in the nighttime mode.
In one implementation, in response to a first operation, the electronic device obtains a color mode in which the electronic device is currently located, and determines whether the color mode of the electronic device changes compared to whether the first wallpaper was displayed last time, and when the color mode of the electronic device does not change, the electronic device displays resources of the current first wallpaper. And when the color mode of the electronic equipment is changed, the electronic equipment acquires the resource of the first wallpaper again for displaying.
In one implementation manner, in response to a first operation, the electronic device acquires a color mode in which the electronic device is currently located, and determines whether the color mode of the electronic device is consistent with a mode of a preloaded resource, if so, the electronic device displays the preloaded resource, and if not, the electronic device acquires a resource of a first wallpaper, switches the preloaded resource, and then displays the resource.
In the embodiment of the application, under the condition that the electronic device is currently in the daytime mode, the electronic device can display resources based on the daytime mode in the resources of the first wallpaper, or under the condition that the electronic device is currently in the night mode, the electronic device can display resources based on the night mode in the resources of the first wallpaper, so that the first wallpaper can adapt to the electronic night mode, when the first wallpaper is displayed in the night mode, the problem that the brightness of the first wallpaper is too high is avoided, more comfortable experience can be provided for a user, and user experience is improved.
In some cases, the resources of the first wallpaper include only resources of one mode, color switching is not supported, in response to a first operation, the electronic device retrieves the resources of the first wallpaper, determines whether the first wallpaper supports the night mode, and in the case where the first wallpaper supports the night mode, retrieves a color mode currently in the electronic device to determine whether to display the resources based on the day mode or the resources of the night mode. And directly displaying the resources of the first wallpaper under the condition that the first wallpaper does not support the night mode.
In addition, in the embodiment of the application, the electronic device may switch the resource of the first wallpaper according to the switching of the color mode. For example, the electronic device is currently in a daytime mode, displaying a daytime mode-based resource of the resources of the first wallpaper, and if the electronic device detects the second operation, switching the displayed resources of the first wallpaper from the daytime mode-based resource to a nighttime mode-based resource. Wherein the second operation instructs the electronic device to switch the color mode from the daytime mode to the nighttime mode, for example, the second operation may be an operation of clicking the control 21 shown in (b) in fig. 2, and for example, the second operation may be an operation of clicking the control 31 shown in (b) in fig. 3.
For example, the electronic device is currently in a night mode, displays a night mode-based resource among the resources of the first wallpaper, and if the electronic device detects the third operation, switches the displayed resource of the first wallpaper from the night mode-based resource to a day mode-based resource. Wherein the third operation instructs the electronic device to switch the color mode from the night mode to the day mode, for example, the second operation may be an operation of clicking the control 21 shown in (c) in fig. 2, and for example, the second operation may be an operation of clicking the control 31 shown in (c) in fig. 3.
Based on above-mentioned technical scheme, when detecting that electronic equipment's color mode takes place to switch, including switching into night mode from day mode, switching into day mode from night mode, the first wall paper that electronic equipment shows can take place to switch along with electronic equipment's color mode to the luminance that automatic adaptation electronic equipment shows avoids causing amazing to user's eye, perhaps avoids the user can't see the screen clearly, can give user more comfortable experience. In addition, based on the method provided by the embodiment of the application, compared with a method for processing resources in real time, the method can enable the first wallpaper to be adapted automatically faster when the color mode of the electronic device is switched.
The following describes an implementation in which the resources of the first wallpaper are included in a theme pack.
Table 1 shows videos and pictures that can be configured in a theme pack, where a lock screen wallpaper picture is used as background wallpaper of a lock screen interface. The large folding screen refers to a screen after the folding screen is completely unfolded, and dynamic wallpaper and super wallpaper do not need to be configured with large folding screen locking wallpaper pictures.
TABLE 1 wallpaper resource allocation Table
video_live_wallpaper.mp4 Wallpaper video-daytime mode
dark_video_live_wallpaper.mp4 Wallpaper video-night mode
unlock_live_wallpaper.jpg Lock screen wallpaper picture-daytime mode
unlock_dark_live_wallpaper.jpg Lock screen wallpaper picture-night mode
unlock_fold_live_wallpaper.jpg Folding screen large screen locking wallpaper picture-daytime mode
unlock_fold_dark_live_wallpaper.jpg Folding screen large screen locking wallpaper picture-night mode
And adding the resource of the first wallpaper in the theme pack according to the actually required display effect of the first wallpaper. For example, the first wallpaper is a super wallpaper, and the resources thereof may include a wallpaper video in a daytime mode, a wallpaper video in a nighttime mode, a lock screen wallpaper picture in the daytime mode, and a lock screen wallpaper picture in the nighttime mode. For example, the first wallpaper is a dynamic wallpaper, and the resources thereof may include a wallpaper video in a daytime mode and a wallpaper video in a nighttime mode. For example, the first wallpaper is a folding wallpaper, and the resources thereof may include a wallpaper video in a daytime mode, a wallpaper video in a nighttime mode, a locking wallpaper picture in the daytime mode, a locking wallpaper picture in the nighttime mode, a large folding screen locking wallpaper picture in the daytime mode, and a large folding screen locking wallpaper picture in the nighttime mode, wherein the locking wallpaper picture is used when the display screen is in a folded state. For example, the type of the first wallpaper is a static wallpaper, and the resource of the first wallpaper may include a lock screen wallpaper picture in a daytime mode and a lock screen wallpaper picture in a nighttime mode, and may further include a desktop wallpaper picture in the daytime mode and a desktop wallpaper picture in the nighttime mode.
It should be noted that each wallpaper needs to call a corresponding software function when displayed, and this software function may be referred to as a wallpaper service (WallpaperService), and the wallpaper service may be registered in an application having a function of displaying wallpaper, for example, an Android Application Package (APK).
In one implementation, one type of wallpaper corresponds to one wallpaper service, and one type of wallpaper service is used for defining a playback flow of the type of wallpaper, and defining how the wallpaper of the type executes instructions after receiving the instructions at different occasions, but does not limit resources used in the playback flow. For example, the super wallpaper corresponds to a super wallpaper service, which is denoted as super wallpaperservicer, the dynamic wallpaper corresponds to a dynamic wallpaper service, which is denoted as dynamic wallpaperservicer, and the folding-screen wallpaper corresponds to a folding-screen wallpaper service, which is denoted as foldablewalpaperservicer. The same type of wallpaper for different animation contents may use the same wallpaper service, so that wallpaper output efficiency may be provided when developing wallpaper.
In one implementation, the theme pack of the first wallpaper further includes an identifier of a wallpaper service corresponding to the first wallpaper, so that the wallpaper service corresponding to the first wallpaper is called when the first wallpaper is used. The embodiment of the application has no particular limitation on the form of the identification of the wallpaper service. For example, the identification of the wallpaper service may be a wallpaper service name.
Illustratively, the theme pack includes a first file, denoted as livepaper. Xml file content style is as follows:
<?xml version="1.0"encoding="UTF-8"?>
<HwTheme>
<pkgname>com.hihonor.livewallpaper.paradise</pkgname>
<classname>com.hihonor.wallpaper.superwallpaper.SuperWallpaperService</classname>
</HwTheme>
wherein, pkgname is a package name and also represents a unique application ID for identifying the wallpaper APK. The Classname indicates the name of the wallpaper service of the first wallpaper binding, wherein the name of the super wallpaper service may be denoted as com. It may also be determined from the wallpaper service name whether the type of the first wallpaper is a super wallpaper, a dynamic wallpaper, or a folding screen wallpaper.
In some implementations, after the first wallpaper is set as the wallpaper of the electronic device, the electronic device may store the resource of the first wallpaper, and perform preprocessing on the resource of the first wallpaper, for example, pre-loading a video, pre-determining a video frame interval included in the video, or pre-setting a picture to a lock screen or a desktop, so that the electronic device can respond to the first operation more quickly, and the performance of the electronic device is improved.
Correspondingly, the theme pack of the first wallpaper further includes information for preprocessing, the information is included in the second file and is recorded as a configuration file livepaper _ config.xml, and for different types of wallpapers, the preprocessing modes are different, and the contents in the corresponding configuration files are also different. For example, a configuration file for a dynamic wallpaper may configure whether the dynamic wallpaper supports night mode, or supports motion blur. More or less contents can be configured in the configuration file according to the actual required display effect. Illustratively, the configuration file livepaper _ config of one dynamic wallpaper is configured as follows:
<support_background_blur>true</support_background_blur>
<support_dark_mode>true</support_dark_mode>
wherein, support _ background _ blue indicates whether dynamic blurring is supported, support _ dark _ mode indicates whether night mode is supported, whether support can be represented by different identifiers (e.g. true and false), true indicates support, and false indicates non-support.
For example, a configuration file for a folding screen wallpaper may configure whether the dynamic wallpaper supports nighttime mode, whether dynamic blurring is supported, and a flexible animation stiffness. Illustratively, the configuration file livepaper _ config.xml of one folding screen wallpaper is configured as follows:
<support_background_blur>true</support_background_blur>
<support_dark_mode>true</support_dark_mode>
<fold-spring-stiffness>60</fold-spring-stiffness>
the folding screen wallpaper is in elastic animation effect, and the rigidity value influences the playing speed. The stiffness may be determined according to video resources and animation effects, and is 60 in the above example.
For example, the configuration file of the super wallpaper may configure whether the super wallpaper supports the night mode, whether the super wallpaper supports the motion blur, the aod interface pattern, and the number of the playing frames. Illustratively, the configuration file livepaper _ config.xml of a super wallpaper is configured as follows:
<support_background_blur>true</support_background_blur>
<support_dark_mode>true</support_dark_mode>
<aod_to_lock_total_frame>60</aod_to_lock_total_frame>
<lock_to_launcher_total_frame>60</lock_to_launcher_total_frame>
<aod_style>DuneRealmClock;Dune Realm</aod_style>
<aod_support_transition_animation>fakse</aod_support_transition_animation>
where the aod _ to _ lock _ total _ frame represents the number of frames played from the aod interface to the lock screen interface, in the above example, this stage plays 60 frames, and the lock _ to _ launcher _ total _ frame represents the number of frames played from the lock screen interface to the desktop, in the above example, this stage plays 60 frames, and the superpaper total activity duration can be determined from the aod _ to _ lock _ total _ frame and the lock _ to _ launcher _ total _ frame. The AOD _ style represents the name of the AOD style of the current super wallpaper, the AOD style is the picture content of the wallpaper displayed by the AOD interface, for example, one style may be a character, and one style may be an animal, in the above example, the name of the AOD style is duneRealmClock, when the super wallpaper is applied and the user separately changes the AOD style, the animation of the AOD interface is not displayed, and the AOD _ support _ transition _ animation represents whether there is a transition animation when entering or exiting the AOD interface.
The following describes a process of downloading the theme pack of the first wallpaper to the resource applying the first wallpaper with reference to a software structure of the electronic device. Fig. 6 is a block diagram of the software configuration of the electronic apparatus 100.
The electronic device 100 software system may employ a hierarchical architecture, an event-driven architecture, a micro-core architecture, a micro-service architecture, or a cloud architecture. The embodiment of the present invention uses an Android system with a layered architecture as an example to exemplarily illustrate a software structure of the electronic device 100.
As shown in fig. 6, the layered architecture divides the software into several layers, each layer having a clear role and division of labor. The layers communicate with each other through a software interface. In some embodiments, the Android system is divided into an application layer, an application framework layer, a Native (Native) layer, a Hardware Abstraction Layer (HAL), a kernel layer, and a hardware layer from top to bottom.
The application program layer may include applications such as AOD application, system service (SystemUI), theme, settings, wallpaper APK, and the like. The theme provides a wallpaper preview service and a wallpaper selection service.
The AOD application comprises an AOD animation display module, a first super wallpaper playing control module and a screen-off control module. The AOD animation display module is used for controlling the position of a bright screen area of the AOD interface and displaying the content. The first super wallpaper playing control module is used for sending a super wallpaper playing instruction to the wallpaper APK when the first wallpaper is the super wallpaper and the screen is turned off. The screen-off control module is used for controlling the local part of the screen to be lightened up after the super wallpaper animation is played when the screen is turned off.
The system service (SystemUI) comprises a status bar, a screen locking window display control module, a second super wallpaper playing control module and a super wallpaper switch status recording module. The lock screen window display control module is used for managing display attributes of the lock screen wallpaper, such as whether the wallpaper is transparent or not. The super wallpaper switch state recording module is used for judging whether the super wallpaper is the super wallpaper after the wallpaper is applied. And the second super wallpaper playing control module is used for sending a super wallpaper playing instruction to the wallpaper APK when the first wallpaper is a super wallpaper and the first wallpaper is bright. The status bar may receive a color mode switch event.
The wallpaper APK comprises a wallpaper service (super wallpaper service, folding screen wallpaper service and dynamic wallpaper service), a wallpaper playing controller, a wallpaper switching controller and a multimedia player. The wallpaper playing controller realizes the playing, pausing and playing progress management of the wallpaper through the multimedia player. When the color mode of the electronic equipment is switched, the wallpaper switching controller informs the multimedia player to switch the played resources to the resources based on the daytime mode or the resources based on the nighttime mode.
The application framework layer provides an Application Programming Interface (API) and a programming framework for the application program of the application layer. The application framework layer includes a number of predefined functions.
As shown in fig. 6, the application framework layer may include a power management service (PowerManagerService), a Window Management Service (WMS), a wallpaper management service (WallpaperManagerService), a screen management service (DisplayManagerService), a sleep management service (DreamManagerService), a video codec module (MediaCodec), a multimedia extractor (MediaExtractor), a color mode management service.
The power management service is responsible for managing power and the common functions of the mobile phone, such as triggering on or off of a screen, brightness adjustment, low power mode, keeping a CPU awake and the like.
The window management service assigns and manages the attributes (e.g., hierarchy, size, display order, etc.) of the windows for the application. The window management service can also manage the display and switching of the screen locking window and the wallpaper window. The window management service may also be used to manage the display of wallpaper upper elements (e.g., icons).
The wallpaper management service is used for managing the operation and switching of the wallpaper and providing an interface for operating the wallpaper to the outside through a WallpaperManager class. When the wallpaper is switched through the interface of the WallpaperManagaer, the wallpaper management service determines whether the currently bound wallpaper service (WallpaperService) needs to be cancelled and starts the wallpaper service of the new wallpaper.
The screen management service is used for managing the current display state of the display screen, sending a notification to the system and other applications when the state is updated, and the like, for example, the screen is switched to a bright screen state or a dead screen state. For example, the screen has switched to a lock screen interface, e.g., the screen has switched to a desktop, etc.
The sleep management service, mainly providing a sleep service (DozeService), is related to the screen-off control of the AOD application.
The color mode management service is used for recording the current color mode of the electronic equipment, monitoring whether the color mode of the electronic equipment changes or not, and updating the currently recorded color mode of the electronic equipment when the color mode of the electronic equipment changes. For example, the color mode management service corresponds to a first database for recording color modes of the electronic device, which is denoted as settings.
And the video coding and decoding module is used for coding and decoding the video. The video coding and decoding module and the multimedia extractor provide support for playing resources.
Native includes a system rendering kernel (surfaceflag) that is used to render graphical interfaces, such as wallpaper. Each application may correspond to one or more graphical interfaces, each graphical interface being independent of the other, having a respective position and size on the screen, and the content displayed in each graphical interface, the size of the content, the position, etc. may change when the application is changed, for example, in a WeChat application, the top status bar and the bottom navigation button are both simultaneously present. The wallpaper is also an independent graphical interface, and the upper layer of the wallpaper graphical interface is an interface of a screen lock or a desktop. These interfaces are all drawn by surfafinger.
The Hardware abstraction layer comprises a Hardware graphics maker (HWC), a TP HAL, an LCD HAL and a Graphics Processor (GPU), wherein the HWC is a module for window synthesis and display and provides Hardware support for a system drawing core.
The kernel layer is a layer between hardware and software. The kernel layer at least comprises a Display Driver (LCD Driver), an LCD Driver (LCD Driver), a touch screen Driver (TP Driver) and an AOD node Driver.
The hardware at least comprises an LCD device and a TP device.
Based on the software structure shown in fig. 6, after the first wallpaper is applied as a wallpaper of the electronic device, the theme application downloads and parses a theme pack of the first wallpaper, generates an acquisition path of a daytime mode-based resource, a nighttime mode-based resource, and a configuration file of the first wallpaper, and determines that the first wallpaper is run by the wallpaper APK according to a package name in a live paper. The wallpaper management service calls a wallpaper service corresponding to the first wallpaper according to the wallpaper service name in the live paper.
After detecting the first operation, responding to the first operation, a wallpaper service in the wallpaper APK acquires a color mode which the electronic equipment is currently in from a color mode management service, when the color mode which the electronic equipment is currently in is a daytime mode, resources of the daytime mode are acquired from an acquisition path based on the resources of the daytime mode, or when the color mode which the electronic equipment is currently in is a nighttime mode, resources of the nighttime mode are acquired based on the acquisition path of the nighttime mode, the resources are loaded to a multimedia player, for the action class, the multimedia player decodes videos in the resources of the first wallpaper through a video coding and decoding module, a multimedia extractor sends the decoded contents to a SurfaceFlinger, the SurfaceFlinger draws the first wallpaper, and the first wallpaper is displayed on a display screen through hardware.
In one implementation, after the wallpaper service runs, and before the first operation, the current color mode of the electronic device is acquired from the color mode management service, if the electronic device is in the daytime mode, resources based on the daytime mode are loaded to the multimedia player, and if the electronic device is in the night mode, resources based on the night mode are loaded to the multimedia player. After detecting the first operation, the electronic equipment responds to the first operation, acquires a color mode in which the electronic equipment is currently positioned, and determines whether the resource loaded in the multimedia player is a resource based on a daytime mode or a resource based on a nighttime mode; and determining whether the current color mode of the electronic equipment is consistent with the resources loaded in the multimedia player, acquiring one of the resources of the first wallpaper and switching the resources loaded in the multimedia player under the condition of inconsistency.
For example, the resource loaded in the multimedia player is a resource based on a daytime mode, and in the case that the electronic device is currently in the daytime mode, the resource of the first wallpaper does not need to be acquired. And under the condition that the electronic equipment is currently in the night mode, the electronic equipment acquires the night mode-based resource in the resources of the first wallpaper, and changes the resource loaded in the multimedia player from the daytime mode-based resource to the night mode-based resource. For example, the resource loaded in the multimedia player is a resource based on a night mode, and in the case that the electronic device is currently in the night mode, the resource of the first wallpaper does not need to be acquired. And under the condition that the electronic equipment is currently in the daytime mode, the electronic equipment acquires the resources based on the daytime mode in the resources of the first wallpaper, and the resources loaded in the multimedia player are replaced from the resources based on the nighttime mode to the resources based on the daytime mode.
In the event that the resources of the first wallpaper also include pictures, after the first wallpaper is applied as a wallpaper for the electronic device, the wallpaper management service may also send a broadcast that the first wallpaper is applied to a system service that displays relevant settings for daytime mode-based pictures and nighttime mode-based pictures in the resources of the first wallpaper.
Fig. 7 is a flowchart of an interface display method, and the following describes a process of preprocessing and switching resources with reference to fig. 7. In the embodiment of the application, resources, configuration files and live paper.
S701, after the operation of applying the first wallpaper is detected, the theme pack of the first wallpaper is downloaded by the application.
S702, decompressing the theme pack to a specified directory.
For example, specify the directory path as data/the/0. And decompressing the theme pack, and acquiring the file to live paper, xml and resources of the first wallpaper by the setting application.
And S703, the setting application analyzes the live paper.xml file, and acquires the package name and the wallpaper service name of the first wallpaper from the live paper.xml file.
S704, the setting application calls the wallpaper management service according to the package name and sends the wallpaper service name to the wallpaper management service.
S705, the wallpaper management service judges whether the wallpaper service name of the first wallpaper and the wallpaper service name of the second wallpaper are the same name.
The wallpaper management service determines a wallpaper service to run a first wallpaper based on the wallpaper service name. The second wallpaper is a wallpaper applied by the electronic device prior to the first wallpaper.
If the name of the wallpaper service of the first wallpaper and the name of the wallpaper service of the second wallpaper are not the same name, it indicates that the first wallpaper and the second wallpaper are not the same type of wallpaper, for example, the first wallpaper is a dynamic wallpaper, and the second wallpaper is a super wallpaper, the running super wallpaper service needs to be exited, the dynamic wallpaper service is bound, and S706-S713 are executed. If the name of the wallpaper service of the first wallpaper and the name of the wallpaper service of the second wallpaper are the same name, which means that the first wallpaper and the second wallpaper are the same type of wallpaper, for example, the first wallpaper and the second wallpaper are both super wallpapers, the running super wallpaper service is continuously used, and no new wallpaper service needs to be bound, and S714 is executed.
S706, the wallpaper management service binds a new wallpaper service for the first wallpaper.
And S707, after the new wallpaper service is started, registering a color mode monitoring event.
The wallpaper service communicates with the color mode management service to monitor whether the electronic device is currently in a night mode or a day mode.
S708, the wallpaper APK acquires the configuration file of the first wallpaper from the specified directory and analyzes the configuration file of the first wallpaper.
S709, after the analysis is completed, checking whether the configuration file is correct.
The configuration file is checked to ensure that the configuration item can be used normally. For example, whether there is content in the configuration file, i.e. there is a field, whether the content includes a preset parameter (for example, the preset parameter is a night mode), whether the parameter has a value (the value may be true or false), whether there is a set frame number, i.e. a duration of action, for the super wallpaper type, and so on. In some implementations, the steps may be performed after performing S1308: and saving the content of the analyzed configuration file to a second database.
S710, if the configuration file is correct, the wallpaper APK stores the content of the analyzed configuration file in the second database.
For example, the first wallpaper may be written to the second database with the contents of whether the first wallpaper supports night mode, whether the first wallpaper supports motion blur, and the like. When the first wallpaper is the super wallpaper, the dynamic effect duration, the AOD pattern and the like of the super wallpaper can be written into the database. Therefore, when a screen locking interface is displayed, whether dynamic fuzzy processing is carried out or not is determined, or when a super wallpaper playing instruction is received, a played video frame interval is determined, or an AOD style is determined when an AOD interface is displayed, and the like. And ending the process under the condition that the configuration file is wrong.
When the wallpaper service displays the first wallpaper, or when the wallpaper service monitors that the color mode of the electronic device is switched, whether the first wallpaper supports the night mode can be determined from the second database.
And S711, the wallpaper APK acquires the video through the first path under the appointed directory, acquires the picture through the second path under the appointed directory, and authorizes the second path to the system service for reading.
Under the condition that the electronic equipment is currently in the daytime mode, videos and pictures based on the daytime mode in the resources are obtained, and under the condition that the electronic equipment is currently in the night mode, videos and pictures based on the night mode in the resources are obtained.
If the picture comprises a picture for locking the screen, after the screen locking wallpaper picture is obtained, if the obtained screen locking wallpaper picture is not matched with the picture in the display resource, the screen locking wallpaper picture in the second path can be updated. And the system service acquires the screen locking wallpaper picture through the second path, so that the screen locking wallpaper picture is displayed when a screen locking interface is displayed.
S712, the multimedia player is initialized.
Wallpaper APK starts the multimedia player and loads the video (dynamic wallpaper) or the picture (static wallpaper) of the first wallpaper into the multimedia player. If the electronic device is currently in the night mode and the first wallpaper supports the night mode, the multimedia player loads video or pictures based on the night mode. If the electronic equipment is in the daytime mode currently, the multimedia player loads wallpaper videos or pictures based on the daytime mode.
S713, initializing the wallpaper interface.
The wallpaper interface is initialized, namely after the first wallpaper is loaded, the player firstly plays the video of the first wallpaper to the last frame, and after the user returns to the desktop, the display screen displays the last frame in the video of the first wallpaper, namely the background wallpaper of the desktop.
S714, the wallpaper management service sends an instruction to the wallpaper APK that the wallpaper service is applied again.
Specifically, the instruction form may be android. After receiving the instruction, the wallpaper APK continues to run, analyzes the configuration file, and executes S808-S813.
The color mode management service sends a color mode switching event to a wallpaper APK when the color mode of the electronic equipment is switched, and the wallpaper APK switches resources in the multimedia player when receiving the color mode switching event, and the color mode management service specifically comprises the following steps:
s715, wallpaper APK receives a color mode switching event.
And S716, determining whether the color mode currently located by the electronic equipment is consistent with the mode of the resource loaded in the multimedia player.
And S717, releasing the multimedia player and loading the resource of the switched color mode under the condition of inconsistency.
Or, if they match, the present flow is ended.
For example, the resources loaded in the multimedia player are resources based on a daytime mode, and in the case that the electronic device is currently in a night mode, the electronic device acquires the resources based on the night mode from among the resources of the first wallpaper, and changes the resources loaded in the multimedia player from the resources based on the daytime mode to the resources based on the night mode. For example, the resource loaded in the multimedia player is a night mode-based resource, and in a case where the electronic device is currently in a day mode, the electronic device acquires a day mode-based resource from among the resources of the first wallpaper, and changes the night mode-based resource to the day mode-based resource. And displaying the resources in the multimedia player when the first wallpaper is displayed.
In one implementation, between S715 and S716, the method further includes: it is determined whether the first wallpaper supports a dark mode. In the case where the first wallpaper supports the color mode, S716 is performed.
The following describes a flow of preprocessing a lock screen wallpaper picture when a resource of a first wallpaper includes a picture for lock screen wallpaper after the first wallpaper is set as the wallpaper of an electronic device. Fig. 8 is a schematic flowchart of an interface display method according to an embodiment of the present application.
And S801, registering a color mode monitoring event after the system service is started.
Thereby determining whether the electronic device is currently in a daytime mode or a nighttime mode.
S802, the system service receives the broadcast of the wallpaper change.
In one implementation, the broadcast of the wallpaper change is received by a status bar (StatusBar) in the system service, the status bar being a function resident in the system service.
S803, the initialization of the first wallpaper is defaulted to be the static wallpaper.
Then, the display setting of the screen locking wallpaper picture is determined according to the theme pack content and some information in the wallpaper APK.
S804, the system service judges whether the wallpaper is static wallpaper broadcast or not.
In the embodiment of the application, a first parameter is obtained, and the first parameter is characterized by whether the first parameter is static wallpaper broadcast or not. If the static wallpaper is broadcast, the first wallpaper is the static wallpaper. If the wallpaper is not a static wallpaper broadcast, the first wallpaper is a dynamic wallpaper. It is understood that one wallpaper is configured with other information, namely wallpaper metadata (meta data), in the wallpaper APK in addition to the data included in the theme pack. In the embodiment of the present application, a first parameter may be configured in wallpaper meta data, and is recorded as wallpaperinfo. After receiving the broadcast with the changed wallpaper, the system service determines whether wallpaperinfo in meta data of the first wallpaper is empty, that is, whether a wallpaperinfo parameter is configured, if the wallpaperinfo is not configured, the wallpaperinfo is a static wallpaper broadcast, and if the wallpaperinfo is configured, the wallpaperinfo is a dynamic wallpaper broadcast.
S805, if the wallpaper is not the static wallpaper broadcast, the system service judges whether the first wallpaper supports screen locking wallpaper picture scaling.
In the embodiment of the application, a second parameter is obtained, and whether the second parameter mark supports zooming of the lock screen wallpaper picture or not is identified. For example, a second parameter, denoted as LiveWallpaper, may be set in meta data of the first wallpaper. In the case where LiveWallpaper is configured in the first wallpaper meta data, the first wallpaper supports lock screen wallpaper picture scaling. In the case that no LiveWallpapper is configured in meta data of the first wallpaper, the first wallpaper does not support lock screen wallpaper picture scaling.
And S806, if yes, writing the zooming support wallpaper picture in the second database.
And S807, if not, writing a picture which does not support zooming of the lock screen wallpaper picture in the second database.
The system service writes the judgment result of whether the screen locking wallpaper picture is supported to be zoomed into the second database for storage, for example, if the screen locking wallpaper picture is supported to be zoomed, writing 'live _ paper _ effect: 1' into the second database, and if the screen locking wallpaper picture is not supported to be zoomed, writing 'live _ paper _ effect: 0' into the second database, thereby judging whether the screen locking wallpaper displays the zooming effect according to the result in the second database when the screen locking window is displayed.
And S808, judging whether the screen locking wallpaper picture is copied from the wallpaper APK to the screen locking application.
In the embodiment of the application, the system service judges whether the screen locking wallpaper picture is copied from the wallpaper APK to the screen locking application according to the wallpaper service name in the live paper. If the wallpaper service name is one of a dynamic wallpaper service name, a super wallpaper service name and a folding screen wallpaper service name, copying a screen locking wallpaper picture from the wallpaper APK to a screen locking application is supported, so that the screen locking wallpaper picture is used for locking a screen sliding scene. If not, the first wallpaper is the static wallpaper, and the process is ended.
In one implementation, the dynamic wallpaper is played from the screen locking interface, the screen locking wallpaper picture can be configured without being configured separately, the screen locking wallpaper can be understood to be transparent, and the screen locking interface displays the first frame of the wallpaper video. And independently configuring the lock screen wallpaper for the super wallpaper and the folding screen wallpaper to realize the zooming effect. That is to say, when the type of the first wallpaper is super wallpaper and folding screen wallpaper, the copy of the lock screen wallpaper picture from the wallpaper APK to the lock screen application is supported.
And S809, if so, judging whether the screen locking wallpaper picture is acquired from the second path by the system service.
Considering that some resources of the wallpaper are not included in the theme pack, for the wallpaper using the theme pack provided in the embodiment of the present application, a lock screen wallpaper picture is obtained from a path (second path) generated after the resource is parsed, and a lock screen wallpaper picture is obtained from wallpaper meta data without using the wallpaper of the theme pack provided in the embodiment of the present application.
In the embodiment of the application, after the wallpaper service is bound to the first wallpaper, the wallpaper service sets a mode of copying the lock screen wallpaper picture, for example, a first switch true or false is set in the second database, true represents that the lock screen wallpaper picture is obtained from a path generated after resource analysis, and false represents that the lock screen wallpaper picture is obtained from wallpaper meta data. In the event that the first wallpaper supports copying of a lock screen wallpaper picture from a wallpaper APK to a lock screen application, the system service retrieves a first switch from a database to determine a copy mode.
S810, the system service acquires the screen locking wallpaper picture from the second path.
S811, the system service acquires a screen locking wallpaper picture from the wallpaper meta data.
The method includes the steps of obtaining a picture based on a daytime mode when the electronic equipment is in the daytime mode currently, or obtaining the picture based on a nighttime mode when the electronic equipment is in the nighttime mode currently.
S812, the system service determines whether the lock screen wallpaper picture is successfully copied to the lock screen.
The screen locking wallpaper picture is successfully copied to the screen locking application, namely the screen locking application stores the screen locking wallpaper picture. And if the copying fails, displaying the first wallpaper as the static wallpaper, and ending the process.
In addition, in some implementations, the method can further include: s813, the system service determines whether the first wallpaper supports configuration of AOD.
In the embodiment of the application, whether the first wallpaper supports AOD display or not is determined according to the name of the wallpaper service in the live paper.
S814, if configuration of AOD is supported, the system service acquires the super wallpaper dynamic duration, the AOD style and the screen locking wallpaper picture of the first wallpaper.
Therefore, when the screen is on, the screen locking application realizes the function of indicating the playing of the super wallpaper animation, and when the screen is off, the AOD application realizes the function of indicating the playing of the super wallpaper animation.
S815, if the configuration of the AOD is not supported, clearing the relevant configuration of the super wallpaper, and taking over the screen-off attribute.
In one scenario, the first wallpaper is a dynamic wallpaper and the second wallpaper is a super wallpaper, i.e., a switch is made from the super wallpaper to the dynamic wallpaper. In the application process of the second wallpaper, the system service records the setting of the duration of the dynamic effect of the super wallpaper, the AOD style, the screen locking wallpaper picture and the like, and the AOD application performs screen-off control when the screen is turned off. After the wallpaper is switched to be the first wallpaper, the system service clears the related configuration of the originally set super wallpaper, the AOD application stops running, and the system service takes over the screen-off attribute to perform screen-off control.
Optionally, in some implementations, the method may further include: and S816, setting the transparent property of the screen locking interface.
That is, when the wallpaper is displayed, whether the lock screen window displayed at different times needs to be set to be transparent, for example, when the freeze frame is at the lock screen interface, the lock screen window is set to be opaque.
And S817, completing the configuration of the screen locking related service in the system service.
S818, the system service receives a color mode switching event.
In S810 and S811, the system service acquires a lock screen wallpaper picture of one color mode, the color mode management service sends a color mode switching event to the system service when the color mode of the electronic device is switched, and the system service acquires a lock screen wallpaper picture of another color mode when receiving the color mode switching event, and then S809 is executed.
To sum up, in the embodiment of the present application, resources of a daytime mode and resources of a night mode are provided for a first wallpaper, and when an electronic device is currently in the daytime mode, the electronic device may display resources based on the daytime mode in the resources of the first wallpaper, or when the electronic device is currently in the night mode, the electronic device may display resources based on the night mode in the resources of the first wallpaper, so that the first wallpaper can adapt to the night mode of the electronic device, and when the first wallpaper is displayed in the night mode, the problem of too high brightness of the first wallpaper is avoided.
The electronic device provided by the embodiment is used for executing the method, so that the same effect as the implementation method can be achieved. Where an integrated unit is employed, the electronic device may include a processing module, a memory module, and a communication module. The processing module may be configured to control and manage actions of the electronic device, and for example, may be configured to support the electronic device to execute steps executed by the processing unit. The memory module may be used to support the electronic device in executing stored program codes and data, etc. The communication module can be used for supporting the communication between the electronic equipment and other equipment.
The embodiments of the present application further provide a computer-readable storage medium, where a computer program is stored, and when the computer program is executed by a processor, the computer program implements the steps in the above-mentioned method embodiments.
Embodiments of the present application provide a computer program product, which when running on a mobile terminal, enables an electronic device to implement the steps in the above method embodiments when executed.
In addition, embodiments of the present application also provide an apparatus, which may be specifically a chip, a component or a module, and may include a processor and a memory connected to each other; the memory is used for storing computer execution instructions, and when the device runs, the processor can execute the computer execution instructions stored in the memory, so that the chip can execute the method in the above method embodiments.
In the embodiments provided in the present application, it should be understood that the disclosed apparatus/electronic device and method may be implemented in other ways. For example, the above-described apparatus/electronic device embodiments are merely illustrative, and for example, the division of the modules or units is only one logical division, and there may be other divisions when actually implemented, for example, a plurality of units or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or units, and may be in an electrical, mechanical or other form.
In addition, functional units in the embodiments of the present application may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit can be realized in a form of hardware, and can also be realized in a form of a software functional unit.
The integrated unit, if implemented in the form of a software functional unit and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, all or part of the flow in the method of the embodiments described above can be implemented by a computer program, which can be stored in a computer readable storage medium and can implement the steps of the embodiments of the methods described above when the computer program is executed by a processor. Wherein the computer program comprises computer program code, which may be in the form of source code, object code, an executable file or some intermediate form, etc. The computer-readable medium may include at least: any entity or device capable of carrying computer program code to a photographing apparatus/terminal apparatus, a recording medium, computer memory, read-only memory (ROM), random Access Memory (RAM), electrical carrier signal, telecommunication signal, and software distribution medium. Such as a usb-drive, a removable hard drive, a magnetic or optical disk, etc. In certain jurisdictions, computer-readable media may not be an electrical carrier signal or a telecommunications signal in accordance with legislative and patent practice.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one position, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In the description above, for purposes of explanation and not limitation, specific details are set forth, such as particular system structures, techniques, etc. in order to provide a thorough understanding of the embodiments of the present application. It will be apparent, however, to one skilled in the art that the present application may be practiced in other embodiments that depart from these specific details. In other instances, detailed descriptions of well-known systems, devices, circuits, and methods are omitted so as not to obscure the description of the present application with unnecessary detail.
It will be understood that the terms "comprises" and/or "comprising," when used in this specification and the appended claims, specify the presence of stated features, integers, steps, operations, elements, and/or components, but do not preclude the presence or addition of one or more other features, integers, steps, operations, elements, components, and/or groups thereof.
It should also be understood that reference to "a plurality" in the specification and the appended claims means two or more. In the description of the present application, "/" means "or" unless otherwise stated, for example, a/B may mean a or B; "and/or" herein is merely an associative relationship that describes an associated object, and refers to any and all possible combinations of one or more of the associated listed items, and includes such combinations, e.g., a and/or B, which may mean: a exists alone, A and B exist simultaneously, and B exists alone.
As used in this specification and the appended claims, the term "if" may be interpreted contextually as "when", "upon" or "in response to" determining "or" in response to detecting ". Similarly, the phrase "if it is determined" or "if a [ described condition or event ] is detected" may be interpreted contextually to mean "upon determining" or "in response to determining" or "upon detecting [ described condition or event ]" or "in response to detecting [ described condition or event ]".
In addition, for the convenience of clearly describing the technical solutions of the present application, the terms "first", "second", and the like are used to distinguish the same items or similar items having substantially the same functions and actions. Those skilled in the art will appreciate that the terms first, second, etc. do not denote any order or importance, but rather the terms first, second, etc. are used to distinguish one element from another.
Reference throughout this specification to "one embodiment" or "some embodiments," or the like, means that a particular feature, structure, or characteristic described in connection with the embodiment is included in one or more embodiments of the present application. Thus, appearances of the phrases "in one embodiment," "in some embodiments," "in other embodiments," or the like, in various places throughout this specification are not necessarily all referring to the same embodiment, but rather "one or more but not all embodiments" unless specifically stated otherwise. The terms "comprising," "including," "having," and variations thereof mean "including, but not limited to," unless expressly specified otherwise.
The above-mentioned embodiments are only used for illustrating the technical solutions of the present application, and not for limiting the same; although the present application has been described in detail with reference to the foregoing embodiments, it should be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; such modifications and substitutions do not depart from the spirit and scope of the embodiments of the present application, and they should be construed as being included in the present application.

Claims (8)

1. An interface display method, the method being performed by an electronic device, the method comprising:
detecting a first operation, wherein the first operation requests the electronic equipment to display first wallpaper;
in response to the first operation, acquiring resources of the first wallpaper and a color mode in which the electronic device is currently located, wherein the color mode of the electronic device comprises a daytime mode and a nighttime mode, and the resources of the first wallpaper comprise resources based on the daytime mode and resources based on the nighttime mode;
displaying one of the resources of the first wallpaper according to a mode in which the electronic device is currently located.
2. The method of claim 1, wherein the electronic device is currently in the daytime mode, the method further comprising:
in a case where a second operation is detected, the second operation instructs the electronic device to switch a color mode from the daytime mode to the nighttime mode, and to switch resources of the displayed first wallpaper from resources based on the daytime mode to resources based on the nighttime mode.
3. The method of claim 1, wherein the electronic device is currently in a night mode, the method further comprising:
in a case where a third operation is detected, the third operation instructs the electronic device to switch the color mode from the night mode to the daytime mode, and to switch the resource of the displayed first wallpaper from the resource based on the night mode to the resource based on the daytime mode.
4. The method of any of claims 1-3, wherein the resource of the first wallpaper comprises at least one of a video and a picture.
5. The method of claim 4, wherein the resource of the first wallpaper is stored upon detection of a fourth operation, the fourth operation being an operation in which the first wallpaper is set as a wallpaper for the electronic device.
6. The method of claim 5, further comprising:
acquiring a color mode of the electronic equipment when a fourth operation is detected;
setting one of the resources of the first wallpaper to be displayed according to the color mode of the electronic equipment when the fourth operation is detected;
in response to the first operation, acquiring resources of the first wallpaper and a color mode in which the electronic device is currently located includes:
responding to the first operation, and acquiring a color mode in which the electronic equipment is currently positioned;
and acquiring another resource of the first wallpaper when the current color mode of the electronic equipment is not consistent with the mode of the resource of the first wallpaper in the state to be displayed.
7. An electronic device, comprising: one or more processors; one or more memories; the memory stores one or more programs that, when executed by the processor, cause the electronic device to perform the method of any of claims 1-6.
8. A computer-readable storage medium having stored therein instructions which, when run on a computer, cause the computer to perform the method of any one of claims 1 to 6.
CN202211337269.XA 2022-10-28 2022-10-28 Interface display method, electronic equipment and storage medium Active CN115941836B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202211337269.XA CN115941836B (en) 2022-10-28 2022-10-28 Interface display method, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202211337269.XA CN115941836B (en) 2022-10-28 2022-10-28 Interface display method, electronic equipment and storage medium

Publications (2)

Publication Number Publication Date
CN115941836A true CN115941836A (en) 2023-04-07
CN115941836B CN115941836B (en) 2023-10-20

Family

ID=86553160

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202211337269.XA Active CN115941836B (en) 2022-10-28 2022-10-28 Interface display method, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN115941836B (en)

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104252299A (en) * 2013-06-28 2014-12-31 上海斐讯数据通信技术有限公司 Mobile terminal for controlling wallpaper to change color
CN104735247A (en) * 2015-03-11 2015-06-24 广东欧珀移动通信有限公司 Method and device for adjusting screen brightness of mobile terminal
CN105302517A (en) * 2015-10-20 2016-02-03 魅族科技(中国)有限公司 Method and device for regulating display color of terminal screen
CN105511717A (en) * 2015-11-30 2016-04-20 北京京东尚科信息技术有限公司 Page display method and page display device
CN106126094A (en) * 2016-06-21 2016-11-16 深圳市金立通信设备有限公司 A kind of brightness adjusting method and terminal
CN108469976A (en) * 2018-03-13 2018-08-31 北京车和家信息技术有限公司 Mode switching method, mode-changeover device, mobile unit and vehicle
CN110609722A (en) * 2019-08-09 2019-12-24 华为技术有限公司 Dark mode display interface processing method, electronic equipment and storage medium
CN111209065A (en) * 2019-12-31 2020-05-29 Oppo广东移动通信有限公司 Dynamic wallpaper setting method and device, storage medium and electronic equipment
WO2022068724A1 (en) * 2020-09-29 2022-04-07 维沃移动通信有限公司 Image display method and electronic device

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104252299A (en) * 2013-06-28 2014-12-31 上海斐讯数据通信技术有限公司 Mobile terminal for controlling wallpaper to change color
CN104735247A (en) * 2015-03-11 2015-06-24 广东欧珀移动通信有限公司 Method and device for adjusting screen brightness of mobile terminal
CN105302517A (en) * 2015-10-20 2016-02-03 魅族科技(中国)有限公司 Method and device for regulating display color of terminal screen
CN105511717A (en) * 2015-11-30 2016-04-20 北京京东尚科信息技术有限公司 Page display method and page display device
CN106126094A (en) * 2016-06-21 2016-11-16 深圳市金立通信设备有限公司 A kind of brightness adjusting method and terminal
CN108469976A (en) * 2018-03-13 2018-08-31 北京车和家信息技术有限公司 Mode switching method, mode-changeover device, mobile unit and vehicle
CN110609722A (en) * 2019-08-09 2019-12-24 华为技术有限公司 Dark mode display interface processing method, electronic equipment and storage medium
CN111209065A (en) * 2019-12-31 2020-05-29 Oppo广东移动通信有限公司 Dynamic wallpaper setting method and device, storage medium and electronic equipment
WO2022068724A1 (en) * 2020-09-29 2022-04-07 维沃移动通信有限公司 Image display method and electronic device

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
阿立;: "夜景模式 眼睛的福音", 电脑爱好者, no. 19 *

Also Published As

Publication number Publication date
CN115941836B (en) 2023-10-20

Similar Documents

Publication Publication Date Title
CN112130742B (en) Full screen display method and device of mobile terminal
WO2020211701A1 (en) Model training method, emotion recognition method, related apparatus and device
CN113542839B (en) Screen projection method of electronic equipment and electronic equipment
CN109559270B (en) Image processing method and electronic equipment
CN111913750B (en) Application program management method, device and equipment
CN114556294A (en) Theme switching method and theme switching device
CN113254409A (en) File sharing method, system and related equipment
CN113542580B (en) Method and device for removing light spots of glasses and electronic equipment
WO2020118490A1 (en) Automatic screen-splitting method, graphical user interface, and electronic device
CN110989961A (en) Sound processing method and device
CN114995715B (en) Control method of floating ball and related device
WO2023241209A9 (en) Desktop wallpaper configuration method and apparatus, electronic device and readable storage medium
CN115567630A (en) Management method of electronic equipment, electronic equipment and readable storage medium
CN113467735A (en) Image adjusting method, electronic device and storage medium
CN112532508B (en) Video communication method and video communication device
CN114006698B (en) token refreshing method and device, electronic equipment and readable storage medium
CN113986369B (en) Internet of things equipment control method and system, electronic equipment and storage medium
CN113590346B (en) Method and electronic equipment for processing service request
CN115730091A (en) Comment display method and device, terminal device and readable storage medium
CN115248693A (en) Application management method and electronic equipment
CN115941836B (en) Interface display method, electronic equipment and storage medium
CN113645595A (en) Equipment interaction method and device
WO2023193720A1 (en) Control method and central control equipment
WO2023207799A1 (en) Message processing method and electronic device
CN115904576A (en) Wallpaper application method, electronic device and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant