[go: up one dir, main page]

CN116991274A - A method for handling exceptions in scrolling effects and electronic equipment - Google Patents

A method for handling exceptions in scrolling effects and electronic equipment Download PDF

Info

Publication number
CN116991274A
CN116991274A CN202311265723.XA CN202311265723A CN116991274A CN 116991274 A CN116991274 A CN 116991274A CN 202311265723 A CN202311265723 A CN 202311265723A CN 116991274 A CN116991274 A CN 116991274A
Authority
CN
China
Prior art keywords
electronic device
touch event
event
sliding
touch
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
CN202311265723.XA
Other languages
Chinese (zh)
Other versions
CN116991274B (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 CN202311265723.XA priority Critical patent/CN116991274B/en
Publication of CN116991274A publication Critical patent/CN116991274A/en
Application granted granted Critical
Publication of CN116991274B publication Critical patent/CN116991274B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0481Interaction techniques based on graphical user interfaces [GUI] based on specific properties of the displayed interaction object or a metaphor-based environment, e.g. interaction with desktop elements like windows or icons, or assisted by a cursor's changing behaviour or appearance
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0484Interaction techniques based on graphical user interfaces [GUI] for the control of specific functions or operations, e.g. selecting or manipulating an object, an image or a displayed text element, setting a parameter value or selecting a range
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0487Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser
    • G06F3/0488Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser using a touch-screen or digitiser, e.g. input of commands through traced gestures
    • G06F3/04883Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser using a touch-screen or digitiser, e.g. input of commands through traced gestures for inputting data by handwriting, e.g. gesture or text
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/72Mobile telephones; Cordless telephones, i.e. devices for establishing wireless links to base stations without route selection
    • H04M1/724User interfaces specially adapted for cordless or mobile telephones
    • H04M1/72448User interfaces specially adapted for cordless or mobile telephones with means for adapting the functionality of the device according to specific conditions
    • H04M1/72454User interfaces specially adapted for cordless or mobile telephones with means for adapting the functionality of the device according to specific conditions according to context-related or environment-related conditions

Landscapes

  • Engineering & Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Human Computer Interaction (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Environmental & Geological Engineering (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Telephone Function (AREA)

Abstract

The application provides an up-sliding effect exception handling method and electronic equipment, wherein the method comprises the following steps: the electronic equipment receives a first sliding operation on a first display interface, wherein the first display interface is indicated as an application program page; displaying a movement effect entering a multitasking mode in response to the first up-sliding operation; in the process of displaying the dynamic effect entering the multitasking, responding to a second sliding operation of a user, and triggering a preset processing flow; in the preset process flow: before the action of clearing all states is executed, modifying the value of the current dynamic effect operation zone bit, wherein after the value of the current dynamic effect operation zone bit is modified, when the action of clearing all states is executed, the processing of cancelling the current dynamic effect is not triggered, the situation that the display interface of the electronic equipment returns to an application program page due to the action cancellation of entering multiple tasks can be avoided, the problem of abnormal upper sliding effect can be effectively solved, and the electronic equipment can smoothly display a desktop after the execution of a preset processing flow is completed.

Description

一种上滑动效异常处理方法及电子设备A method for handling exceptions in upward sliding effects and electronic equipment

技术领域Technical field

本申请涉及终端技术领域,尤其涉及一种上滑动效异常处理方法及电子设备。The present application relates to the field of terminal technology, and in particular to a scroll-up effect exception processing method and electronic equipment.

背景技术Background technique

终端显示应用程序页面时,用户可以从屏幕底部边缘向上滑动并停顿,终端响应于该从屏幕底部边缘向上滑动并停顿的操作,会显示进入多任务管理页面的动效。一般情况下,在显示进入该多任务管理页面的动效的过程中,用户再次从屏幕底部边缘向上滑动,终端会从多任务管理页面进入桌面。然而,当前在进入该多任务管理页面的动效的过程中,用户再次从屏幕底部边缘向上滑动时,会引起取消当前动效的处理逻辑,导致进入多任务的动效取消,终端返回应用程序页面,而不是进入桌面,出现上滑动效异常,造成用户使用体验降低。When the terminal displays the application page, the user can swipe up from the bottom edge of the screen and pause. In response to the operation of swiping up from the bottom edge of the screen and pausing, the terminal will display the animation of entering the multi-tasking management page. Generally, during the process of displaying the animation of entering the multi-tasking management page, the user swipes upward from the bottom edge of the screen again, and the terminal will enter the desktop from the multi-tasking management page. However, during the current process of entering the animation of the multi-tasking management page, when the user swipes upward from the bottom edge of the screen again, the processing logic for canceling the current animation will be caused, causing the animation of entering the multi-tasking to be cancelled, and the terminal will return to the application. page, instead of entering the desktop, an abnormal scrolling effect occurs, resulting in a reduced user experience.

发明内容Contents of the invention

为了解决上述技术问题,本申请提供一种上滑动效异常处理方法及电子设设备,该方法中,电子设备在显示进入多任务的动效的过程中,处理用户的第二上滑操作的过程中,不触发取消当前动效的处理,有效避免用户进行第二上滑操作时,电子设备不显示桌面,而是返回应用程序的异常场景。In order to solve the above technical problems, the present application provides a slide-up effect exception processing method and an electronic device. In this method, the electronic device processes the user's second slide-up operation during the process of displaying the dynamic effect of entering multitasking. , does not trigger the process of canceling the current animation, effectively avoiding the abnormal scenario where the electronic device does not display the desktop but returns to the application when the user performs the second swipe up operation.

第一方面,本申请提供一种上滑动效异常处理方法,在该方法中,电子设备接收对第一显示界面的第一上滑操作,该第一显示界面指示为应用程序页面;电子设备响应于该第一上滑操作,显示进入多任务的动效;在显示该进入多任务的动效的过程中,电子设备响应于用户的第二上滑操作,触发预设处理流程。在该预设处理流程中:在执行清除所有状态的动作之前,修改当前动效运行标志位的值,其中,在修改当前动效运行标志位的值后,在执行清除所有状态的动作时,不触发取消当前动效的处理,能够避免由于进入多任务的动效取消,而导致的电子设备的显示界面返回到应用程序页面的情况,可以有效解决上滑动效异常的问题,提高用户使用体验,使得电子设备在预设处理流程执行完成后顺利显示桌面。In a first aspect, the present application provides a method for handling slide-up effect exceptions. In this method, the electronic device receives a first slide-up operation on a first display interface, and the first display interface indicates an application page; the electronic device responds During the first sliding up operation, the dynamic effect of entering multitasking is displayed; during the process of displaying the dynamic effect of entering multitasking, the electronic device responds to the user's second sliding up operation and triggers a preset processing flow. In this preset processing flow: before executing the action of clearing all states, modify the value of the current dynamic effect running flag bit. After modifying the value of the current dynamic effect running flag bit, when executing the action of clearing all states, Not triggering the cancellation of the current dynamic effect can avoid the display interface of the electronic device returning to the application page due to the cancellation of the dynamic effect when entering multi-tasking. It can effectively solve the problem of abnormal upward sliding effects and improve the user experience. , so that the electronic device can successfully display the desktop after the preset processing flow is completed.

根据第一方面,在执行清除所有状态的动作之前,修改当前动效运行标志位的值,包括:在执行清除侦听状态的动作之前,修改当前动效运行标志位的值。According to the first aspect, before performing the action of clearing all states, modifying the value of the current dynamic effect running flag bit includes: before performing the action of clearing the listening state, modifying the value of the current dynamic effect running flag bit.

本申请实施例中,清除所有状态的动作包含清除多个状态的动作,但只有清除侦听状态的动作会触发清除当前动效的处理。因此,可以在执行清除侦听状态的动作之前,修改当前动效运行标志位的值,其中,在修改当前动效运行标志位的值后,在执行清除侦听状态的动作时,不触发取消当前动效的处理,可以精确避免由于进入多任务的动效取消,而导致的电子设备的显示界面返回到应用程序页面的情况,提高用户使用体验。In the embodiment of this application, the action of clearing all states includes the action of clearing multiple states, but only the action of clearing the listening state will trigger the process of clearing the current animation effect. Therefore, you can modify the value of the current dynamic effect running flag before executing the action of clearing the listening state. After modifying the value of the current dynamic effect running flag, the cancellation will not be triggered when the action of clearing the listening state is executed. The current processing of motion effects can accurately avoid the situation where the display interface of the electronic device returns to the application page due to the cancellation of motion effects when entering multitasking, thereby improving the user experience.

根据第一方面,或者以上第一方面的任意一种实现方式,修改当前动效运行标志位的值,包括:将当前动效运行标志位的值修改为第一值。According to the first aspect, or any implementation of the above first aspect, modifying the value of the current dynamic effect running flag includes: modifying the value of the current dynamic effect running flag to the first value.

本申请实施例中,在当前动效运行标志位的值为第一值的情况下,在执行清除所有(侦听)状态的动作时,不触发取消当前动效的处理,可以避免由于进入多任务的动效取消,而导致的电子设备的显示界面返回到应用程序页面的情况,提高用户使用体验。In the embodiment of the present application, when the value of the current motion effect running flag is the first value, when the action of clearing all (listening) states is performed, the process of canceling the current motion effect is not triggered, which can avoid the problem of entering multiple The animation of the task is canceled and the display interface of the electronic device returns to the application page, thereby improving the user experience.

根据第一方面,或者以上第一方面的任意一种实现方式,响应于第一上滑操作,显示进入多任务的动效,包括:输入管理模块将接收的第一上滑操作转换为第一触摸事件;输入管理模块将第一触摸事件,分发给触摸交互管理模块;触摸交互管理模块在确定第一触摸事件触发于手势导航热区的情况下,将第一触摸事件发送至对应的手势处理模块;手势处理模块基于第一触摸事件,触发视图系统显示进入多任务的动效。According to the first aspect, or any implementation of the above first aspect, in response to the first sliding up operation, displaying the dynamic effect of entering multitasking includes: the input management module converts the received first sliding up operation into the first Touch event; the input management module distributes the first touch event to the touch interaction management module; the touch interaction management module sends the first touch event to the corresponding gesture processing when it is determined that the first touch event is triggered in the gesture navigation hot zone. Module; the gesture processing module triggers the view system to display the animation of entering multitasking based on the first touch event.

根据第一方面,或者以上第一方面的任意一种实现方式,第一触摸事件指示为down事件、move事件和up事件中的任一种,手势处理模块基于第一触摸事件,触发视图系统显示进入多任务的动效,包括:在手势处理模块在第一触摸事件指示为up事件时,触发视图系统显示进入多任务的动效。According to the first aspect, or any implementation of the above first aspect, the first touch event indication is any one of a down event, a move event, and an up event, and the gesture processing module triggers the view system to display based on the first touch event. The dynamic effect of entering multitasking includes: when the gesture processing module indicates that the first touch event is an up event, triggering the view system to display the dynamic effect of entering multitasking.

本申请实施例中,在手势处理模块在第一触摸事件指示为up事件时,表示用户进行了抬手操作,即第一上滑操作已完成,该第一上滑操作不会再产生新的事件导致需要显示跟手动效,由此,可以触发视图系统显示进入多任务的动效。In the embodiment of the present application, when the gesture processing module indicates that the first touch event is an up event, it means that the user has performed a hand-raising operation, that is, the first sliding up operation has been completed, and the first sliding up operation will not generate a new The event causes the need to display and follow manual effects, thereby triggering the view system to display the animation for entering multitasking.

根据第一方面,或者以上第一方面的任意一种实现方式,手势处理模块基于第一触摸事件,触发视图系统显示进入多任务的动效之前,还包括:在手势处理模块在第一触摸事件指示为move事件时,将当前动效运行标志位的值修改为第二值。According to the first aspect, or any implementation of the above first aspect, before the gesture processing module triggers the view system to display the dynamic effect of entering multitasking based on the first touch event, the gesture processing module further includes: When the indication is a move event, the value of the current animation running flag is modified to the second value.

本申请实施例中,手势处理模块在第一触摸事件指示为move事件时,会触发跟手动效,因此,可以将当前动效运行标志位的值修改为第二值,以标识电子设备中当前存在动效显示,避免出现动效冲突的问题。In the embodiment of the present application, the gesture processing module will trigger the follow-up hand effect when the first touch event indicates a move event. Therefore, the value of the current motion effect running flag can be modified to a second value to identify the current motion in the electronic device. There is dynamic effect display to avoid the problem of dynamic effect conflict.

根据第一方面,或者以上第一方面的任意一种实现方式,响应于第二上滑操作,触发预设处理流程,包括:输入管理模块将第二上滑操作,转换为第二触摸事件;输入管理模块将第二触摸事件,分发给触摸交互管理模块;触摸交互管理模块在确定第二触摸事件触发于手势导航热区的情况下,将第二触摸事件发送至对应的手势处理模块;手势处理模块基于第二触摸事件,向滑动共享状态模块发送状态清除指令;滑动共享状态模块响应于状态清除指令,修改当前动效运行标志位的值,以及执行清除所有状态的动作。According to the first aspect, or any implementation of the above first aspect, in response to the second slide-up operation, triggering a preset processing flow includes: the input management module converts the second slide-up operation into a second touch event; The input management module distributes the second touch event to the touch interaction management module; when the touch interaction management module determines that the second touch event is triggered in the gesture navigation hot zone, it sends the second touch event to the corresponding gesture processing module; the gesture processing module The processing module sends a state clearing instruction to the sliding sharing state module based on the second touch event; the sliding sharing state module responds to the state clearing instruction, modifies the value of the current motion effect running flag, and performs the action of clearing all states.

本申请实施例中,在该预设处理流程中:在修改当前动效运行标志位的值后,执行清除所有状态的动作,可以不触发取消当前动效的处理,能够避免由于进入多任务的动效取消,而导致的电子设备的显示界面返回到应用程序页面的情况,可以有效解决上滑动效异常的问题,提高用户使用体验。In the embodiment of the present application, in the preset processing flow: after modifying the value of the current motion effect running flag, the action of clearing all states is performed, which does not trigger the process of canceling the current motion effect, and can avoid entering multi-tasking. Canceling the animation effect causes the display interface of the electronic device to return to the application page, which can effectively solve the problem of abnormal upward sliding effects and improve the user experience.

根据第一方面,或者以上第一方面的任意一种实现方式,第一上滑操作指示为从屏幕底部边缘向上滑动并停顿的操作;第二上滑操作指示为从屏幕底部边缘向上滑动的操作。According to the first aspect, or any implementation of the first aspect above, the first slide-up operation instruction is an operation of sliding upward from the bottom edge of the screen and pausing; the second slide-up operation instruction is an operation of sliding upward from the bottom edge of the screen. .

第二方面,本申请提供了一种电子设备,该电子设备包括:一个或多个处理器;存储器;以及计算机程序,其中计算机程序存储在存储器上,当计算机程序被一个或多个处理器执行时,使得电子设备执行第一方面或第一方面的任意可能的实现方式中的方法的指令。In a second aspect, the present application provides an electronic device, which includes: one or more processors; a memory; and a computer program, wherein the computer program is stored on the memory, and when the computer program is executed by the one or more processors when causing the electronic device to execute the instructions of the method in the first aspect or any possible implementation of the first aspect.

第二方面以及第二方面的任意一种实现方式分别与第一方面以及第一方面的任意一种实现方式相对应。第二方面以及第二方面的任意一种实现方式所对应的技术效果可参见上述第一方面以及第一方面的任意一种实现方式所对应的技术效果,此处不再赘述。The second aspect and any implementation manner of the second aspect respectively correspond to the first aspect and any implementation manner of the first aspect. The technical effects corresponding to the second aspect and any implementation manner of the second aspect may be referred to the technical effects corresponding to the above-mentioned first aspect and any implementation manner of the first aspect, which will not be described again here.

第三方面,本申请提供了一种计算机存储介质,包括计算机指令,当计算机指令在电子设备上运行时,使得电子设备执行第一方面或第一方面的任意可能的实现方式中的方法的指令。In a third aspect, the present application provides a computer storage medium, including computer instructions. When the computer instructions are run on an electronic device, the electronic device causes the electronic device to execute the instructions of the method in the first aspect or any possible implementation of the first aspect. .

第三方面以及第三方面的任意一种实现方式分别与第一方面以及第一方面的任意一种实现方式相对应。第三方面以及第三方面的任意一种实现方式所对应的技术效果可参见上述第一方面以及第一方面的任意一种实现方式所对应的技术效果,此处不再赘述。The third aspect and any implementation manner of the third aspect respectively correspond to the first aspect and any implementation manner of the first aspect. For the technical effects corresponding to the third aspect and any implementation manner of the third aspect, please refer to the technical effects corresponding to the above-mentioned first aspect and any implementation manner of the first aspect, which will not be described again here.

附图说明Description of the drawings

图1为本申请实施例提供的一种场景示意图一;Figure 1 is a schematic diagram of a scenario provided by an embodiment of the present application;

图2为本申请实施例提供的一种场景示意图二;Figure 2 is a schematic diagram 2 of a scenario provided by the embodiment of the present application;

图3为本申请实施例提供的一种场景示意图三;Figure 3 is a schematic diagram three of a scenario provided by the embodiment of the present application;

图4为本申请实施例提供的一种电子设备的结构示意图;Figure 4 is a schematic structural diagram of an electronic device provided by an embodiment of the present application;

图5为本申请实施例的电子设备的软件结构框图;Figure 5 is a software structure block diagram of the electronic device according to the embodiment of the present application;

图6本申请实施例提供的一种上滑动效异常处理方法的流程图;Figure 6 is a flow chart of a scroll-up effect exception handling method provided by an embodiment of the present application;

图7为本申请实施例提供的一种进入多任务的动效的示意图;Figure 7 is a schematic diagram of an animation for entering multitasking provided by an embodiment of the present application;

图8为本申请实施例提供的一种第一上滑操作的处理方法示意图;Figure 8 is a schematic diagram of a processing method for the first sliding upward operation provided by an embodiment of the present application;

图9为本申请实施例提供的一种多任务动效处理流程示意图;Figure 9 is a schematic flowchart of a multi-task dynamic effect processing provided by an embodiment of the present application;

图10为本申请实施例提供的一种预设处理流程的示意图。Figure 10 is a schematic diagram of a preset processing flow provided by an embodiment of the present application.

具体实施方式Detailed ways

下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例是本申请一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有作出创造性劳动前提下所获得的所有其他实施例,都属于本申请保护的范围。The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, rather than all of the embodiments. Based on the embodiments in this application, all other embodiments obtained by those of ordinary skill in the art without creative efforts fall within the scope of protection of this application.

本文中术语“和/或”,仅仅是一种描述关联对象的关联关系,表示可以存在三种关系,例如,A和/或B,可以表示:单独存在A,同时存在A和B,单独存在B这三种情况。The term "and/or" in this article is just an association relationship that describes related objects, indicating that three relationships can exist. For example, A and/or B can mean: A exists alone, A and B exist simultaneously, and they exist alone. B these three situations.

本申请实施例的说明书和权利要求书中的术语“第一”和“第二”等是用于区别不同的对象,而不是用于描述对象的特定顺序。例如,第一目标对象和第二目标对象等是用于区别不同的目标对象,而不是用于描述目标对象的特定顺序。The terms “first” and “second” in the description and claims of the embodiments of this application are used to distinguish different objects, rather than to describe a specific order of objects. For example, the first target object, the second target object, etc. are used to distinguish different target objects, rather than to describe a specific order of the target objects.

在本申请实施例中,“示例性的”或者“例如”等词用于表示作例子、例证或说明。本申请实施例中被描述为“示例性的”或者“例如”的任何实施例或设计方案不应被解释为比其它实施例或设计方案更优选或更具优势。确切而言,使用“示例性的”或者“例如”等词旨在以具体方式呈现相关概念。In the embodiments of this application, words such as "exemplary" or "for example" are used to represent examples, illustrations or explanations. Any embodiment or design described as "exemplary" or "such as" in the embodiments of the present application is not to be construed as preferred or advantageous over other embodiments or designs. Rather, use of the words "exemplary" or "such as" is intended to present the concept in a concrete manner.

在本申请实施例的描述中,除非另有说明,“多个”的含义是指两个或两个以上。例如,多个处理单元是指两个或两个以上的处理单元;多个系统是指两个或两个以上的系统。In the description of the embodiments of this application, unless otherwise specified, the meaning of “plurality” refers to two or more. For example, multiple processing units refer to two or more processing units; multiple systems refer to two or more systems.

图1为本申请实施例提供的一种场景示意图一。图2为本申请实施例提供的一种场景示意图二。图3为本申请实施例提供的一种场景示意图三。Figure 1 is a schematic diagram of a scenario provided by an embodiment of the present application. Figure 2 is a schematic diagram 2 of a scenario provided by an embodiment of the present application. Figure 3 is a schematic diagram three of a scenario provided by the embodiment of the present application.

在介绍本申请实施例之前,首先基于图1、图2和图3对本申请实施例的应用场景进行说明。图1、图2和图3均以手机作为电子设备的实例。Before introducing the embodiments of the present application, the application scenarios of the embodiments of the present application are first described based on Figures 1, 2 and 3. Figures 1, 2 and 3 all use mobile phones as examples of electronic devices.

图1的(1)示出了手机的第一显示界面101,该第一显示界面101为备忘录的应用程序页面,该第一显示界面101包括用于管理待办事件的控件1011、没有待办事件的提醒图标1012、用于添加待办事件的控件1013、用于进入笔记页面的控件1014和用于进入待办页面的控件1015。用户在手机显示该第一显示界面101时,做出从屏幕底部边缘向上滑动并停顿的操作,操作轨迹如图1中(1)虚线所示,用户的手指沿虚线上箭头所指的方向滑动并在虚线顶部黑色圆点处停顿。手机在显示第一显示界面101时,响应于接收到的从屏幕底部边缘向上滑动并停顿的操作,显示进入多任务的动效,并最终显示如图1的(2)所示的第二显示界面102。其中,动效指的是显示界面中各元素的动态变化效果。(1) of Figure 1 shows the first display interface 101 of the mobile phone. The first display interface 101 is a memo application page. The first display interface 101 includes controls 1011 for managing to-do events. There are no to-do items. Reminder icon 1012 of the file, control 1013 for adding to-do events, control 1014 for entering the note page, and control 1015 for entering the to-do page. When the first display interface 101 is displayed on the mobile phone, the user slides upward from the bottom edge of the screen and pauses. The operation trajectory is shown as the dotted line in (1) in Figure 1. The user slides his finger in the direction pointed by the arrow on the dotted line. And pause at the black dot at the top of the dotted line. When the mobile phone displays the first display interface 101, in response to the received operation of sliding upward from the bottom edge of the screen and pausing, the mobile phone displays the animation of entering multitasking, and finally displays the second display as shown in (2) of Figure 1 Interface 102. Among them, dynamic effects refer to the dynamic changes of each element in the display interface.

该图1的(2)所示的第二显示界面102指示为多任务管理界面。多任务管理界面包括用户最近使用的多个应用程序的预览界面,该多个应用程序的预览界面,会按照应用程序使用时间由近及远的顺序,从右向左排列。例如,用户先使用电话,再使用备忘录,并在手机显示备忘录的应用程序页面时,做出从屏幕底部边缘向上滑动并停顿的操作,手机显示第二显示界面102,该第二显示界面102包括电话的预览界面1022和备忘录的预览界面1024。其中,备忘录的预览界面1024位于最右侧,且界面部分显示;电话的预览界面1022位于在备忘录的预览界面1024的左边,该预览界面可以全部显示。多任务管理界面还包括每个预览界面所指示的应用程序的标识(应用程序图标和应用程序名称),例如第二显示界面102中,包括电话的标识1021和备忘录的标识1023(该备忘录的名称未显示出来)。第二显示界面102还包括清理后台的控件1025。The second display interface 102 shown in (2) of FIG. 1 is indicated as a multi-task management interface. The multi-task management interface includes a preview interface of multiple applications recently used by the user. The preview interfaces of the multiple applications will be arranged from right to left in order of application usage time from recent to remote. For example, the user first uses the phone and then uses the memo, and when the phone displays the memo application page, he slides upward from the bottom edge of the screen and pauses. The phone displays the second display interface 102, and the second display interface 102 includes The preview interface 1022 of the phone and the preview interface 1024 of the memo. Among them, the preview interface 1024 of the memo is located on the far right, and the interface is partially displayed; the preview interface 1022 of the phone is located on the left side of the preview interface 1024 of the memo, and the preview interface can be fully displayed. The multi-task management interface also includes the identification of the application (application icon and application name) indicated by each preview interface. For example, the second display interface 102 includes the identification of the phone 1021 and the identification of the memo 1023 (the name of the memo). not shown). The second display interface 102 also includes a background cleaning control 1025.

一般情况下,如图2所示,用户在手机显示该第二显示界面102时,做出从屏幕底部边缘向上滑动的操作,操作轨迹如图2中(1)虚线所示,用户的手指沿虚线上箭头所指的方向滑动。如图2的(2)所示,手机响应于接收到的从屏幕底部边缘向上滑动的操作,进入桌面状态,显示第三显示界面103。其中,第二显示界面102可参见前述图1中(2)的描述,此处不再赘述。该第三显示界面103包含多个应用程序,例如时钟、日历、图库、备忘录、文件管理、电子邮件、音乐、计算器、相机、通讯录、电话和信息等。Generally, as shown in Figure 2, when the second display interface 102 is displayed on the mobile phone, the user performs an operation of sliding upward from the bottom edge of the screen. The operation trajectory is shown as the dotted line (1) in Figure 2. The user's finger moves along the Slide in the direction indicated by the arrow on the dotted line. As shown in (2) of Figure 2 , the mobile phone enters the desktop state and displays the third display interface 103 in response to the received operation of sliding upward from the bottom edge of the screen. For the second display interface 102, please refer to the description of (2) in FIG. 1, which will not be described again here. The third display interface 103 includes multiple application programs, such as clock, calendar, gallery, memo, file management, email, music, calculator, camera, address book, phone and message, etc.

然而,如图3所示,用户在手机显示第一显示界面101时,做出从屏幕底部边缘向上滑动(第一次上滑)并停顿的操作,手机响应于该操作,显示进入多任务的动效,并最终显示第二显示界面102。用户在第一次上滑停顿之后的极短时间,再次做出从屏幕底部边缘向上滑动(第二次上滑)的操作(两次滑动的时间间隔小于时间阈值,该时间间隔指示为进入多任务的动效的时长,例如0.3秒),会引起取消当前动效的处理逻辑,导致进入多任务状态的动效取消,手机会返回显示第一显示界面101,而不是显示桌面,出现上滑动效异常,造成用户使用体验降低。However, as shown in Figure 3, when the first display interface 101 is displayed on the mobile phone, the user slides upward from the bottom edge of the screen (swipe up for the first time) and pauses. In response to this operation, the mobile phone displays the message "Entering multitasking". animation, and finally display the second display interface 102. A very short time after the first swipe up pause, the user swipes up from the bottom edge of the screen again (the second swipe up) (the time interval between the two swipes is less than the time threshold, which indicates that the user has entered multiple The duration of the task's animation (for example, 0.3 seconds) will cause the processing logic to cancel the current animation, causing the animation to enter the multi-tasking state to be canceled, and the phone will return to displaying the first display interface 101 instead of displaying the desktop, and an upward slide will appear. Abnormal performance results in reduced user experience.

为此,本申请实施例提供一种上滑动效异常处理方法,该方法应用于:电子设备响应于用户从屏幕底部边缘向上滑动并停顿(第一次上滑操作),显示进入多任务页面的动效的过程中,又再次响应于用户从屏幕底部边缘向上滑动(第二次上滑操作)的场景。本申请实施例中,电子设备响应于第二次上滑操作,触发预设处理流程,并在该预设处理流程中,在执行清除所有状态的动作之前,将当前动效运行标志位设置为第一值,以不触发执行取消当前动效的处理,能够有效避免用户在进入多任务动效过程中,进行第二上滑操作时返回应用程序的异常场景,解决上滑动效异常的问题,提高用户使用体验。To this end, embodiments of the present application provide a sliding-up effect exception processing method, which method is applied to: in response to the user sliding upward from the bottom edge of the screen and pausing (the first sliding-up operation), the electronic device displays the entry to the multi-tasking page. During the animation process, it again responds to the scene where the user slides up from the bottom edge of the screen (the second slide-up operation). In the embodiment of the present application, the electronic device triggers a preset processing flow in response to the second slide-up operation, and in the preset processing flow, before performing the action of clearing all states, the current motion effect running flag is set to The first value does not trigger the execution of the process of canceling the current animation effect, which can effectively avoid the abnormal scenario of the user returning to the application when performing the second swipe up operation during the multi-task animation process, and solve the problem of abnormal swipe up effects. Improve user experience.

本申请实施例提供的上滑动效异常处理方法可以应用于电子设备中,电子设备可以为可穿戴电子设备(如手表)、便捷式计算机(如手机)、平板电脑、笔记本电脑、个人计算机(personal computer,PC)、增强现实(augment reality,AR)\虚拟现实(virtualreality,VR)设备、车载电脑等设备,以下实施例对该电子设备的具体形式不做特殊限制。The slide-up effect exception handling method provided by the embodiments of the present application can be applied to electronic devices. The electronic devices can be wearable electronic devices (such as watches), portable computers (such as mobile phones), tablet computers, notebook computers, and personal computers (personal computers). Computer (PC), augmented reality (AR)/virtual reality (VR) equipment, vehicle-mounted computer and other equipment. The following embodiments do not impose special restrictions on the specific form of the electronic equipment.

在对本申请实施例的技术方案说明之前,首先结合附图对本申请实施例的电子设备进行说明。图4为本申请实施例提供的一种电子设备100的结构示意图。应该理解的是,图4所示电子设备100仅是电子设备的一个范例,并且电子设备100可以具有比图中所示的更多的或者更少的部件,可以组合两个或多个的部件,或者可以具有不同的部件配置。图4中所示出的各种部件可以在包括一个或多个信号处理和/或专用集成电路在内的硬件、软件、或硬件和软件的组合中实现。Before describing the technical solutions of the embodiments of the present application, the electronic equipment of the embodiments of the present application will first be described with reference to the drawings. FIG. 4 is a schematic structural diagram of an electronic device 100 provided by an embodiment of the present application. It should be understood that the electronic device 100 shown in FIG. 4 is only an example of an electronic device, and the electronic device 100 may have more or fewer components than shown in the figure, and two or more components may be combined. , or can have different component configurations. The various components shown in Figure 4 may be implemented in hardware, software, or a combination of hardware and software including one or more signal processing and/or application specific integrated circuits.

电子设备100可以包括:处理器110,外部存储器接口120,内部存储器121,通用串行总线(universal serial bus,USB)接口130,充电管理模块140,电源管理模块141,电池142,天线1,天线2,移动通信模块150,无线通信模块160,音频模块170,扬声器170A,受话器170B,麦克风170C,耳机接口170D,传感器模块180,按键190,马达191,指示器192,摄像头193,显示屏194,以及用户标识模块(subscriber identification module,SIM)卡接口195等。其中传感器模块180可以包括压力传感器180A,陀螺仪传感器180B,气压传感器180C,磁传感器180D,加速度传感器180E,距离传感器180F,接近光传感器180G,指纹传感器180H,温度传感器180J,触摸传感器180K,环境光传感器180L,骨传导传感器180M等。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. Mobile communication module 150, wireless communication module 160, audio module 170, speaker 170A, receiver 170B, microphone 170C, headphone interface 170D, sensor module 180, button 190, motor 191, indicator 192, camera 193, display screen 194, And subscriber identification module (subscriber identification module, SIM) card interface 195, etc. The sensor module 180 may include a pressure sensor 180A, a gyro 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, and ambient light. Sensor 180L, bone conduction sensor 180M, etc.

处理器110可以包括一个或多个处理单元,例如:处理器110可以包括应用处理器(application processor,A P),调制解调处理器,图形处理器(graphics processingunit,GPU),图像信号处理器(image signal processor,ISP),控制器,存储器,视频编解码器,数字信号处理器(digital signal processor,DSP),基带处理器,和/或神经网络处理器(neural-network processing unit,NPU)等。其中,不同的处理单元可以是独立的器件,也可以集成在一个或多个处理器中。The processor 110 may include one or more processing units. For example, the processor 110 may include an application processor (application processor, AP), a modem processor, a graphics processing unit (GPU), an image signal processor ( image signal processor (ISP), controller, memory, video codec, digital signal processor (digital signal processor, DSP), baseband processor, and/or neural-network processing unit (NPU), etc. . Among them, different processing units can be independent devices or integrated in one or more processors.

其中,控制器可以是电子设备100的神经中枢和指挥中心。控制器可以根据指令操作码和时序信号,产生操作控制信号,完成取指令和执行指令的控制。The controller may be the nerve center and command center of the electronic device 100 . The controller can generate operation control signals based on the instruction operation code and timing signals to complete the control of fetching and executing instructions.

处理器110中还可以设置存储器,用于存储指令和数据。在一些实施例中,处理器110中的存储器为高速缓冲存储器。该存储器可以保存处理器110刚用过或循环使用的指令或数据。如果处理器110需要再次使用该指令或数据,可从所述存储器中直接调用。避免了重复存取,减少了处理器110的等待时间,因而提高了系统的效率。The processor 110 may also be provided with a memory for storing instructions and data. In some embodiments, the memory in processor 110 is cache memory. This memory may hold instructions or data that have been recently used or recycled by processor 110 . If the processor 110 needs to use the instructions or data again, it can be called directly from the memory. Repeated access is avoided and the waiting time of the processor 110 is reduced, thus improving the efficiency of the system.

在一些实施例中,处理器110可以包括一个或多个接口。接口可以包括集成电路(inter-integrated circuit,I2C)接口,集成电路内置音频(inter-integrated circuitsound,I2S)接口,脉冲编码调制(pulse code modulation,PCM)接口,通用异步收发传输器(universal asynchronous receiver/transmitter,UART)接口,移动产业处理器接口(mobile industry processor interface,MIPI),通用输入输出(general-purposeinput/output,GPIO)接口,用户标识模块(subscriber identity module,SIM)接口,和/或通用串行总线(universal serial bus,USB)接口等。In some embodiments, processor 110 may include one or more interfaces. The interface may include an integrated circuit (inter-integrated circuit, I2C) interface, an integrated circuit built-in audio (inter-integrated circuitsound, I2S) interface, a pulse code modulation (PCM) interface, and a universal asynchronous receiver (universal asynchronous receiver) /transmitter, UART) interface, mobile industry processor interface (MIPI), general-purpose input/output (GPIO) interface, subscriber identity module (subscriber identity module, SIM) interface, and/or Universal serial bus (USB) interface, etc.

I2C接口是一种双向同步串行总线,包括一根串行数据线(serial data line,SDA)和一根串行时钟线(derail clock line,SCL)。在一些实施例中,处理器110可以包含多组I2C总线。处理器110可以通过不同的I2C总线接口分别耦合触摸传感器180K,充电器,闪光灯,摄像头193等。例如:处理器110可以通过I2C接口耦合触摸传感器180K,使处理器110与触摸传感器180K通过I2C总线接口通信,实现电子设备100的触摸功能。The I2C interface is a bidirectional synchronous serial bus, including a serial data line (SDA) and a serial clock line (derail clock line, SCL). In some embodiments, processor 110 may include multiple sets of I2C buses. The processor 110 can separately couple the touch sensor 180K, charger, flash, camera 193, etc. through different I2C bus interfaces. For example, the processor 110 can be coupled to the touch sensor 180K through an I2C interface, so that the processor 110 and the touch sensor 180K communicate through the I2C bus interface to implement the touch function of the electronic device 100 .

I2S接口可以用于音频通信。在一些实施例中,处理器110可以包含多组I2S总线。处理器110可以通过I2S总线与音频模块170耦合,实现处理器110与音频模块170之间的通信。在一些实施例中,音频模块170可以通过I2S接口向无线通信模块160传递音频信号,实现通过蓝牙耳机接听电话的功能。The I2S interface can be used for audio communication. In some embodiments, processor 110 may include multiple sets of I2S buses. The processor 110 can be coupled with the audio module 170 through the I2S bus to implement communication between the processor 110 and the audio module 170 . In some embodiments, the audio module 170 can transmit audio signals to the wireless communication module 160 through the I2S interface to implement the function of answering calls through a Bluetooth headset.

PCM接口也可以用于音频通信,将模拟信号抽样,量化和编码。在一些实施例中,音频模块170与无线通信模块160可以通过PCM总线接口耦合。在一些实施例中,音频模块170也可以通过PCM接口向无线通信模块160传递音频信号,实现通过蓝牙耳机接听电话的功能。所述I2S接口和所述PCM接口都可以用于音频通信。The PCM interface can also be used for audio communications to sample, quantize and encode analog signals. In some embodiments, the audio module 170 and the wireless communication module 160 may be coupled through a PCM bus interface. In some embodiments, the audio module 170 can also transmit audio signals to the wireless communication module 160 through the PCM interface to implement the function of answering calls through a Bluetooth headset. Both the I2S interface and the PCM interface can be used for audio communication.

UART接口是一种通用串行数据总线,用于异步通信。该总线可以为双向通信总线。它将要传输的数据在串行通信与并行通信之间转换。在一些实施例中,UART接口通常被用于连接处理器110与无线通信模块160。例如:处理器110通过UART接口与无线通信模块160中的蓝牙模块通信,实现蓝牙功能。在一些实施例中,音频模块170可以通过UART接口向无线通信模块160传递音频信号,实现通过蓝牙耳机播放音乐的功能。The UART interface is a universal serial data bus used for asynchronous communication. The bus can 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 and the wireless communication module 160 . For example, the processor 110 communicates with the Bluetooth module in the wireless communication module 160 through the UART interface to implement the Bluetooth function. In some embodiments, the audio module 170 can transmit audio signals to the wireless communication module 160 through the UART interface to implement the function of playing music through a Bluetooth headset.

MIPI接口可以被用于连接处理器110与显示屏194,摄像头193等外围器件。MIPI接口包括摄像头串行接口(camera serial interface,CSI),显示屏串行接口(displayserial interface,DSI)等。在一些实施例中,处理器110和摄像头193通过CSI接口通信,实现电子设备100的拍摄功能。处理器110和显示屏194通过DSI接口通信,实现电子设备100的显示功能。The MIPI interface can be used to connect the processor 110 with peripheral devices such as the display screen 194 and the camera 193 . MIPI interfaces include camera serial interface (CSI), display serial interface (displayserial interface, DSI), etc. In some embodiments, the processor 110 and the camera 193 communicate through the CSI interface to implement the shooting function of the 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 .

GPIO接口可以通过软件配置。GPIO接口可以被配置为控制信号,也可被配置为数据信号。在一些实施例中,GPIO接口可以用于连接处理器110与摄像头193,显示屏194,无线通信模块160,音频模块170,传感器模块180等。GPIO接口还可以被配置为I2C接口,I2S接口,UART接口,MIPI接口等。The GPIO interface can be configured through software. The GPIO interface can be configured as a control signal or as a data signal. In some embodiments, the GPIO interface can be used to connect the processor 110 with the camera 193, display screen 194, wireless communication module 160, audio module 170, sensor module 180, etc. The GPIO interface can also be configured as an I2C interface, I2S interface, UART interface, MIPI interface, etc.

USB接口130是符合USB标准规范的接口,具体可以是Mini USB接口,Micro USB接口,USB Type C接口等。USB接口130可以用于连接充电器为电子设备100充电,也可以用于电子设备100与外围设备之间传输数据。也可以用于连接耳机,通过耳机播放音频。该接口还可以用于连接其他电子设备,例如AR设备等。The USB interface 130 is an interface that complies with USB standard specifications, and may specifically be a Mini USB interface, a Micro USB interface, a USB Type C interface, etc. The USB interface 130 can be used to connect a charger to charge the electronic device 100, and can also be used to transmit data between the electronic device 100 and peripheral devices. It can also be used to connect headphones to play audio through them. This interface can also be used to connect other electronic devices, such as AR devices, etc.

可以理解的是,本申请实施例示意的各模块间的接口连接关系,只是示意性说明,并不构成对电子设备100的结构限定。在本申请另一些实施例中,电子设备100也可以采用上述实施例中不同的接口连接方式,或多种接口连接方式的组合。It can be understood that the interface connection relationships between the modules illustrated in the embodiments of the present application are only schematic illustrations and do not constitute a structural limitation of the electronic device 100 . In other embodiments of the present application, the electronic device 100 may also adopt different interface connection methods in the above embodiments, or a combination of multiple interface connection methods.

充电管理模块140用于从充电器接收充电输入。其中,充电器可以是无线充电器,也可以是有线充电器。在一些有线充电的实施例中,充电管理模块140可以通过USB接口130接收有线充电器的充电输入。在一些无线充电的实施例中,充电管理模块140可以通过电子设备100的无线充电线圈接收无线充电输入。充电管理模块140为电池142充电的同时,还可以通过电源管理模块141为电子设备供电。The charging management module 140 is used to receive charging input from the charger. Among them, 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 the wired charger through the USB interface 130 . In some wireless charging embodiments, the charging management module 140 may receive wireless charging input through the wireless charging coil of the electronic device 100 . While the charging management module 140 charges the battery 142, it can also provide power to the electronic device through the power management module 141.

电源管理模块141用于连接电池142,充电管理模块140与处理器110。电源管理模块141接收电池142和/或充电管理模块140的输入,为处理器110,内部存储器121,外部存储器,显示屏194,摄像头193,和无线通信模块160等供电。电源管理模块141还可以用于监测电池容量,电池循环次数,电池健康状态(漏电,阻抗)等参数。在其他一些实施例中,电源管理模块141也可以设置于处理器110中。在另一些实施例中,电源管理模块141和充电管理模块140也可以设置于同一个器件中。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 charging management module 140, and supplies power to the processor 110, internal memory 121, external memory, display screen 194, camera 193, wireless communication module 160, etc. The power management module 141 can also be used to monitor battery capacity, battery cycle times, battery health status (leakage, impedance) and other parameters. In some other embodiments, the power management module 141 may also be provided in the processor 110 . In other embodiments, the power management module 141 and the charging management module 140 may also be provided in the same device.

电子设备100的无线通信功能可以通过天线1,天线2,移动通信模块150,无线通信模块160,调制解调处理器以及基带处理器等实现。The wireless communication function of the electronic device 100 can be implemented through the antenna 1, the antenna 2, the mobile communication module 150, the wireless communication module 160, the modem processor and the baseband processor.

天线1和天线2用于发射和接收电磁波信号。电子设备100中的每个天线可用于覆盖单个或多个通信频带。不同的天线还可以复用,以提高天线的利用率。例如:可以将天线1复用为无线局域网的分集天线。在另外一些实施例中,天线可以和调谐开关结合使用。Antenna 1 and Antenna 2 are used to transmit and receive electromagnetic wave signals. Each antenna in electronic device 100 may be used to cover a single or multiple communication frequency bands. Different antennas can also be reused to improve antenna utilization. For example: Antenna 1 can be reused as a diversity antenna for a wireless LAN. In other embodiments, antennas may be used in conjunction with tuning switches.

移动通信模块150可以提供应用在电子设备100上的包括2G/3G/4G/5G等无线通信的解决方案。移动通信模块150可以包括至少一个滤波器,开关,功率放大器,低噪声放大器(low noise amplifier,LNA)等。移动通信模块150可以由天线1接收电磁波,并对接收的电磁波进行滤波,放大等处理,传送至调制解调处理器进行解调。移动通信模块150还可以对经调制解调处理器调制后的信号放大,经天线1转为电磁波辐射出去。在一些实施例中,移动通信模块150的至少部分功能模块可以被设置于处理器110中。在一些实施例中,移动通信模块150的至少部分功能模块可以与处理器110的至少部分模块被设置在同一个器件中。The mobile communication module 150 can provide solutions for wireless communication including 2G/3G/4G/5G applied on the electronic device 100 . The mobile communication module 150 may include at least one filter, switch, power amplifier, low noise amplifier (LNA), etc. The mobile communication module 150 can receive electromagnetic waves through the antenna 1, perform filtering, amplification and other processing on the received electromagnetic waves, and transmit them to the modem processor for demodulation. The mobile communication module 150 can also amplify the signal modulated by the modem processor and convert it into electromagnetic waves through the antenna 1 for radiation. In some embodiments, at least part of the functional modules of the mobile communication module 150 may be disposed in the processor 110 . In some embodiments, at least part of the functional modules of the mobile communication module 150 and at least part of the modules of the processor 110 may be provided in the same device.

调制解调处理器可以包括调制器和解调器。其中,调制器用于将待发送的低频基带信号调制成中高频信号。解调器用于将接收的电磁波信号解调为低频基带信号。随后解调器将解调得到的低频基带信号传送至基带处理器处理。低频基带信号经基带处理器处理后,被传递给应用处理器。应用处理器通过音频设备(不限于扬声器170A,受话器170B等)输出声音信号,或通过显示屏194显示图像或视频。在一些实施例中,调制解调处理器可以是独立的器件。在另一些实施例中,调制解调处理器可以独立于处理器110,与移动通信模块150或其他功能模块设置在同一个器件中。A modem processor may include a modulator and a demodulator. Among them, the modulator is used to modulate the low-frequency baseband signal to be sent into a medium-high frequency signal. The demodulator is used to demodulate the received electromagnetic wave signal into a low-frequency baseband signal. The demodulator then transmits the demodulated low-frequency baseband signal to the baseband processor for processing. After the low-frequency baseband signal is processed by the baseband processor, it is passed to the application processor. The application processor outputs sound signals through audio devices (not limited to speaker 170A, receiver 170B, etc.), or displays images or videos through display screen 194. In some embodiments, the modem processor may be a stand-alone device. In other embodiments, the modem processor may be independent of the processor 110 and may be provided in the same device as the mobile communication module 150 or other functional modules.

无线通信模块160可以提供应用在电子设备100上的包括无线局域网(wirelesslocal area networks,WLAN)(如无线保真(wireless fidelity,Wi-Fi)网络),蓝牙(bluetooth,BT),全球导航卫星系统(global navigation satellite system,GNSS),调频(frequency modulation,FM),近距离无线通信技术(near field communication,NFC),红外技术(infrared,IR)等无线通信的解决方案。无线通信模块160可以是集成至少一个通信处理模块的一个或多个器件。无线通信模块160经由天线2接收电磁波,将电磁波信号调频以及滤波处理,将处理后的信号发送到处理器110。无线通信模块160还可以从处理器110接收待发送的信号,对其进行调频,放大,经天线2转为电磁波辐射出去。The wireless communication module 160 can provide applications on the electronic device 100 including wireless local area networks (WLAN) (such as wireless fidelity (Wi-Fi) network), Bluetooth (bluetooth, BT), and global navigation satellite system. (global navigation satellite system, GNSS), frequency modulation (FM), near field communication technology (near field communication, NFC), infrared technology (infrared, IR) and other wireless communication solutions. 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 , frequency modulates and filters the electromagnetic wave signals, and sends the processed signals to the processor 110 . The wireless communication module 160 can also receive the signal to be sent from the processor 110, frequency modulate it, amplify it, and convert it into electromagnetic waves through the antenna 2 for radiation.

在一些实施例中,电子设备100的天线1和移动通信模块150耦合,天线2和无线通信模块160耦合,使得电子设备100可以通过无线通信技术与网络以及其他设备通信。In some embodiments, the antenna 1 of the electronic device 100 is coupled to the mobile communication module 150, and the antenna 2 is coupled to the wireless communication module 160, so that the electronic device 100 can communicate with the network and other devices through wireless communication technology.

电子设备100通过GPU,显示屏194,以及应用处理器等实现显示功能。GPU为图像处理的微处理器,连接显示屏194和应用处理器。GPU用于执行数学和几何计算,用于图形渲染。处理器110可包括一个或多个GPU,其执行程序指令以生成或改变显示信息。The electronic device 100 implements display functions through a GPU, a display screen 194, an application processor, and the like. The GPU is an image processing microprocessor and is connected to the display screen 194 and the application processor. GPUs are used to perform mathematical and geometric calculations for graphics rendering. Processor 110 may include one or more GPUs that execute program instructions to generate or alter display information.

显示屏194用于显示图像,视频等。显示屏194包括显示面板。显示面板可以采用液晶显示屏(liquid crystal display,LCD),有机发光二极管(organic light-emittingdiode,OLED),有源矩阵有机发光二极体或主动矩阵有机发光二极体(active-matrixorganic light emitting diode的,AMOLED),柔性发光二极管(flex light-emittingdiode,FLED),Miniled,MicroLed,Micro-oLed,量子点发光二极管(quantum dot lightemitting diodes,QLED)等。在一些实施例中,电子设备100可以包括1个或N个显示屏194,N为大于1的正整数。The display screen 194 is used to display images, videos, etc. Display 194 includes a display panel. The display panel can use a liquid crystal display (LCD), an organic light-emitting diode (OLED), an active matrix organic light emitting diode or an active matrix organic light emitting diode (active-matrix organic light emitting diode). (AMOLED), flexible light-emitting diode (FLED), Miniled, MicroLed, Micro-oLed, quantum dot light-emitting diodes (QLED), etc. In some embodiments, the electronic device 100 may include 1 or N display screens 194, where N is a positive integer greater than 1.

电子设备100可以通过ISP,摄像头193,视频编解码器,GPU,显示屏194以及应用处理器等实现拍摄功能。The electronic device 100 can implement the shooting function through an ISP, a camera 193, a video codec, a GPU, a display screen 194, an application processor, and the like.

摄像头193用于捕获静态图像或视频。物体通过镜头生成光学图像投射到感光元件。感光元件可以是电荷耦合器件(charge coupled device,CCD)或互补金属氧化物半导体(complementary metal-oxide-semiconductor,CMOS)光电晶体管。感光元件把光信号转换成电信号,之后将电信号传递给ISP转换成数字图像信号。ISP将数字图像信号输出到DSP加工处理。DSP将数字图像信号转换成标准的RGB,YUV等格式的图像信号。在一些实施例中,电子设备100可以包括1个或N个摄像头193,N为大于1的正整数。Camera 193 is used to capture still images or video. The object passes through the lens to produce an optical image that is projected onto the photosensitive element. The photosensitive element may be a charge coupled device (CCD) or a complementary metal-oxide-semiconductor (CMOS) phototransistor. The photosensitive element converts the optical signal into an electrical signal, and then passes the electrical signal to the ISP to convert it into a digital image signal. ISP outputs digital image signals to DSP for processing. DSP converts digital image signals into standard RGB, YUV and other format image signals. In some embodiments, the electronic device 100 may include 1 or N cameras 193, where N is a positive integer greater than 1.

数字信号处理器用于处理数字信号,除了可以处理数字图像信号,还可以处理其他数字信号。例如,当电子设备100在频点选择时,数字信号处理器用于对频点能量进行傅里叶变换等。Digital signal processors are used to process digital signals. In addition to digital image signals, they can also process other digital signals. For example, when the electronic device 100 selects a frequency point, the digital signal processor is used to perform Fourier transform on the frequency point energy.

视频编解码器用于对数字视频压缩或解压缩。电子设备100可以支持一种或多种视频编解码器。这样,电子设备100可以播放或录制多种编码格式的视频,例如:动态图像专家组(moving picture experts group,MPEG)1,MPEG2,MPEG3,MPEG4等。Video codecs are used to compress or decompress digital video. Electronic device 100 may support one or more video codecs. In this way, the electronic device 100 can play or record videos in multiple encoding formats, such as moving picture experts group (moving picture experts group, MPEG) 1, MPEG2, MPEG3, MPEG4, etc.

NPU为神经网络(neural-network ,NN)计算处理器,通过借鉴生物神经网络结构,例如借鉴人脑神经元之间传递模式,对输入信息快速处理,还可以不断的自学习。通过NPU可以实现电子设备100的智能认知等应用,例如:图像识别,人脸识别,语音识别,文本理解等。NPU is a neural-network (NN) computing processor. By drawing on the structure of biological neural networks, such as the transmission mode between human brain neurons, it can quickly process input information and can continuously learn by itself. Intelligent cognitive applications of the electronic device 100 can be implemented through the NPU, such as image recognition, face recognition, speech recognition, text understanding, etc.

外部存储器接口120可以用于连接外部存储卡,例如Micro SD卡,实现扩展电子设备100的存储能力。外部存储卡通过外部存储器接口120与处理器110通信,实现数据存储功能。例如将音乐,视频等文件保存在外部存储卡中。The external memory interface 120 can be used to connect an external memory card, such as a Micro SD card, to expand the storage capacity of the electronic device 100 . The external memory card communicates with the processor 110 through the external memory interface 120 to implement the data storage function. Such as saving music, videos, etc. files in external memory card.

内部存储器121可以用于存储计算机可执行程序代码,所述可执行程序代码包括指令。处理器110通过运行存储在内部存储器121的指令,从而执行电子设备100的各种功能应用以及数据处理。内部存储器121可以包括存储程序区和存储数据区。其中,存储程序区可存储操作系统,至少一个功能所需的应用程序(比如声音播放功能,图像播放功能等)等。存储数据区可存储电子设备100使用过程中所创建的数据(比如音频数据,电话本等)等。此外,内部存储器121可以包括高速随机存取存储器,还可以包括非易失性存储器,例如至少一个磁盘存储器件,闪存器件,通用闪存存储器(universal flash storage,UFS)等。Internal memory 121 may be used to store computer executable program code, which includes instructions. The processor 110 executes instructions stored in the internal memory 121 to execute various functional applications and data processing of the electronic device 100 . The internal memory 121 may include a program storage area and a data storage area. Among them, the stored program area can store an operating system, at least one application program required for a function (such as a sound playback function, an image playback function, etc.). The storage data area may store data created during use of the electronic device 100 (such as audio data, phone book, etc.). In addition, the internal memory 121 may include high-speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, universal flash storage (UFS), etc.

电子设备100可以通过音频模块170,扬声器170A,受话器170B,麦克风170C,耳机接口170D,以及应用处理器等实现音频功能。例如音乐播放,录音等。The electronic device 100 can implement audio functions through the audio module 170, the speaker 170A, the receiver 170B, the microphone 170C, the headphone interface 170D, and the application processor. Such as music playback, recording, etc.

音频模块170用于将数字音频信息转换成模拟音频信号输出,也用于将模拟音频输入转换为数字音频信号。音频模块170还可以用于对音频信号编码和解码。在一些实施例中,音频模块170可以设置于处理器110中,或将音频模块170的部分功能模块设置于处理器110中。The audio module 170 is used to convert digital audio information into analog audio signal output, and is also used to convert analog audio input into digital audio signals. Audio module 170 may also be used to encode and decode audio signals. In some embodiments, the audio module 170 may be provided in the processor 110 , or some functional modules of the audio module 170 may be provided in the processor 110 .

扬声器170A,也称“喇叭”,用于将音频电信号转换为声音信号。电子设备100可以通过扬声器170A收听音乐,或收听免提通话。Speaker 170A, also called "speaker", is used to convert audio electrical signals into sound signals. The electronic device 100 can listen to music through the speaker 170A, or listen to hands-free calls.

受话器170B,也称“听筒”,用于将音频电信号转换成声音信号。当电子设备100接听电话或语音信息时,可以通过将受话器170B靠近人耳接听语音。Receiver 170B, also called "earpiece", is used to convert audio electrical signals into sound signals. When the electronic device 100 answers a call or a voice message, the voice can be heard by bringing the receiver 170B close to the human ear.

麦克风170C,也称“话筒”,“传声器”,用于将声音信号转换为电信号。当拨打电话或发送语音信息时,用户可以通过人嘴靠近麦克风170C发声,将声音信号输入到麦克风170C。电子设备100可以设置至少一个麦克风170C。在另一些实施例中,电子设备100可以设置两个麦克风170C,除了采集声音信号,还可以实现降噪功能。在另一些实施例中,电子设备100还可以设置三个,四个或更多麦克风170C,实现采集声音信号,降噪,还可以识别声音来源,实现定向录音功能等。Microphone 170C, also called "microphone" or "microphone", is used to convert sound signals into electrical signals. When making a call or sending a voice message, the user can speak close to the microphone 170C with the human mouth and input the sound signal to the microphone 170C. 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, which in addition to collecting sound signals, may also implement a noise reduction function. In other embodiments, the electronic device 100 can also be provided with three, four or more microphones 170C to collect sound signals, reduce noise, identify sound sources, and implement directional recording functions, etc.

耳机接口170D用于连接有线耳机。耳机接口170D可以是USB接口130,也可以是3.5mm的开放移动电子设备平台(open mobile terminal platform,OMTP)标准接口,美国蜂窝电信工业协会(cellular telecommunications industry association of the USA,CTIA)标准接口。The headphone interface 170D is used to connect wired headphones. The headphone interface 170D may be a USB interface 130, or may be a 3.5 mm open mobile terminal platform (OMTP) standard interface or a Cellular Telecommunications Industry Association of the USA (CTIA) standard interface.

压力传感器180A用于感受压力信号,可以将压力信号转换成电信号。在一些实施例中,压力传感器180A可以设置于显示屏194。压力传感器180A的种类很多,如电阻式压力传感器,电感式压力传感器,电容式压力传感器等。电容式压力传感器可以是包括至少两个具有导电材料的平行板。当有力作用于压力传感器180A,电极之间的电容改变。电子设备100根据电容的变化确定压力的强度。当有触摸操作作用于显示屏194,电子设备100根据压力传感器180A检测所述触摸操作强度。电子设备100也可以根据压力传感器180A的检测信号计算触摸的位置。在一些实施例中,作用于相同触摸位置,但不同触摸操作强度的触摸操作,可以对应不同的操作指令。例如:当有触摸操作强度小于第一压力阈值的触摸操作作用于短消息应用图标时,执行查看短消息的指令。当有触摸操作强度大于或等于第一压力阈值的触摸操作作用于短消息应用图标时,执行新建短消息的指令。The pressure sensor 180A is used to sense pressure signals and can convert the pressure signals into electrical signals. In some embodiments, pressure sensor 180A may be disposed on display screen 194 . There are many types of pressure sensors 180A, such as resistive pressure sensors, inductive pressure sensors, capacitive pressure sensors, etc. A capacitive pressure sensor may include at least two parallel plates of conductive material. When a force is applied to pressure sensor 180A, the capacitance between the electrodes changes. The electronic device 100 determines the intensity of the pressure based on the change in capacitance. When a touch operation is performed on the display screen 194, the electronic device 100 detects the intensity of the touch operation according to the pressure sensor 180A. The electronic device 100 may also calculate the touched position based on the detection signal of the pressure sensor 180A. In some embodiments, touch operations acting on the same touch location but with different touch operation intensities may correspond to different operation instructions. For example: when a touch operation with a touch operation intensity less than the first pressure threshold is applied to the short message application icon, an instruction to view the short message is executed. When a touch operation with a touch operation intensity greater than or equal to the first pressure threshold is applied to the short message application icon, an instruction to create a new short message is executed.

陀螺仪传感器180B可以用于确定电子设备100的运动姿态。在一些实施例中,可以通过陀螺仪传感器180B确定电子设备100围绕三个轴(即,x,y和z轴)的角速度。陀螺仪传感器180B可以用于拍摄防抖。示例性的,当按下快门,陀螺仪传感器180B检测电子设备100抖动的角度,根据角度计算出镜头模组需要补偿的距离,让镜头通过反向运动抵消电子设备100的抖动,实现防抖。陀螺仪传感器180B还可以用于导航,体感游戏场景。The gyro sensor 180B may be used to determine the motion posture of the electronic device 100 . In some embodiments, the angular velocity of electronic device 100 about three axes (ie, x, y, and z axes) may be determined by gyro sensor 180B. The gyro sensor 180B can be used for image stabilization. For example, when the shutter is pressed, the gyro sensor 180B detects the angle at which the electronic device 100 shakes, calculates the distance that the lens module needs to compensate based on the angle, and allows the lens to offset the shake of the electronic device 100 through reverse movement to achieve anti-shake. The gyro sensor 180B can also be used for navigation and somatosensory game scenes.

气压传感器180C用于测量气压。在一些实施例中,电子设备100通过气压传感器180C测得的气压值计算海拔高度,辅助定位和导航。Air pressure sensor 180C is used to measure air pressure. In some embodiments, the electronic device 100 calculates the altitude through the air pressure value measured by the air pressure sensor 180C to assist positioning and navigation.

磁传感器180D包括霍尔传感器。电子设备100可以利用磁传感器180D检测翻盖皮套的开合。在一些实施例中,当电子设备100是翻盖机时,电子设备100可以根据磁传感器180D检测翻盖的开合。进而根据检测到的皮套的开合状态或翻盖的开合状态,设置翻盖自动解锁等特性。Magnetic sensor 180D includes a Hall sensor. The electronic device 100 may utilize the magnetic sensor 180D to detect opening and closing of the flip holster. In some embodiments, when the electronic device 100 is a flip machine, the electronic device 100 may detect the opening and closing of the flip according to the magnetic sensor 180D. Then, based on the detected opening and closing status of the leather case or the opening and closing status of the flip cover, features such as automatic unlocking of the flip cover are set.

加速度传感器180E可检测电子设备100在各个方向上(一般为三轴)加速度的大小。当电子设备100静止时可检测出重力的大小及方向。还可以用于识别电子设备姿态,应用于横竖屏切换,计步器等应用。The acceleration sensor 180E can detect the acceleration of the electronic device 100 in various directions (generally three axes). When the electronic device 100 is stationary, the magnitude and direction of gravity can be detected. It can also be used to identify the posture of electronic devices and be used in horizontal and vertical screen switching, pedometer and other applications.

距离传感器180F,用于测量距离。电子设备100可以通过红外或激光测量距离。在一些实施例中,拍摄场景,电子设备100可以利用距离传感器180F测距以实现快速对焦。Distance sensor 180F for measuring distance. Electronic device 100 can measure distance via infrared or laser. In some embodiments, when shooting a scene, the electronic device 100 may utilize the distance sensor 180F to measure distance to achieve fast focusing.

接近光传感器180G可以包括例如发光二极管(LED)和光检测器,例如光电二极管。发光二极管可以是红外发光二极管。电子设备100通过发光二极管向外发射红外光。电子设备100使用光电二极管检测来自附近物体的红外反射光。当检测到充分的反射光时,可以确定电子设备100附近有物体。当检测到不充分的反射光时,电子设备100可以确定电子设备100附近没有物体。电子设备100可以利用接近光传感器180G检测用户手持电子设备100贴近耳朵通话,以便自动熄灭屏幕达到省电的目的。接近光传感器180G也可用于皮套模式,口袋模式自动解锁与锁屏。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 outwardly through the light emitting diode. Electronic device 100 uses photodiodes to detect infrared reflected light from nearby objects. 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 is no object near the electronic device 100 . The electronic device 100 can use the proximity light sensor 180G to detect when the user holds the electronic device 100 close to the ear for talking, so as to automatically turn off the screen to save power. The proximity light sensor 180G can also be used in holster mode, and pocket mode automatically unlocks and locks the screen.

环境光传感器180L用于感知环境光亮度。电子设备100可以根据感知的环境光亮度自适应调节显示屏194亮度。环境光传感器180L也可用于拍照时自动调节白平衡。环境光传感器180L还可以与接近光传感器180G配合,检测电子设备100是否在口袋里,以防误触。The ambient light sensor 180L is used to sense ambient light brightness. The electronic device 100 can adaptively adjust the brightness of the display screen 194 according to the perceived ambient light brightness. The ambient light sensor 180L can also be used to automatically adjust the white balance when taking pictures. The ambient light sensor 180L can also cooperate with the proximity light sensor 180G to detect whether the electronic device 100 is in the pocket to prevent accidental touching.

指纹传感器180H用于采集指纹。电子设备100可以利用采集的指纹特性实现指纹解锁,访问应用锁,指纹拍照,指纹接听来电等。Fingerprint sensor 180H is used to collect fingerprints. The electronic device 100 can use the collected fingerprint characteristics to achieve fingerprint unlocking, access to application locks, fingerprint photography, fingerprint answering of incoming calls, etc.

温度传感器180J用于检测温度。在一些实施例中,电子设备100利用温度传感器180J检测的温度,执行温度处理策略。例如,当温度传感器180J上报的温度超过阈值,电子设备100执行降低位于温度传感器180J附近的处理器的性能,以便降低功耗实施热保护。在另一些实施例中,当温度低于另一阈值时,电子设备100对电池142加热,以避免低温导致电子设备100异常关机。在其他一些实施例中,当温度低于又一阈值时,电子设备100对电池142的输出电压执行升压,以避免低温导致的异常关机。Temperature sensor 180J is used to detect temperature. In some embodiments, the electronic device 100 utilizes the temperature detected by the temperature sensor 180J to execute the temperature processing strategy. For example, when the temperature reported by the temperature sensor 180J exceeds a threshold, the electronic device 100 reduces the performance of a processor located near the temperature sensor 180J in order to reduce power consumption and implement thermal protection. In other embodiments, when the temperature is lower than another threshold, the electronic device 100 heats the battery 142 to prevent the low temperature from causing the electronic device 100 to shut down abnormally. In some other embodiments, when the temperature is lower than another threshold, the electronic device 100 performs boosting on the output voltage of the battery 142 to avoid abnormal shutdown caused by low temperature.

触摸传感器180K,也称“触控面板”。触摸传感器180K可以设置于显示屏194,由触摸传感器180K与显示屏194组成触摸屏,也称“触控屏”。触摸传感器180K用于检测作用于其上或附近的触摸操作。触摸传感器可以将检测到的触摸操作传递给应用处理器,以确定触摸事件类型。可以通过显示屏194提供与触摸操作相关的视觉输出。在另一些实施例中,触摸传感器180K也可以设置于电子设备100的表面,与显示屏194所处的位置不同。Touch sensor 180K, also called "touch panel". The touch sensor 180K can be disposed on the display screen 194. 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 on or near the touch sensor 180K. The touch sensor can pass the detected touch operation to the application processor to determine the touch event type. Visual output related to the touch operation may be provided through display screen 194 . In other embodiments, the touch sensor 180K may also be disposed on the surface of the electronic device 100 at a location different from that of the display screen 194 .

骨传导传感器180M可以获取振动信号。在一些实施例中,骨传导传感器180M可以获取人体声部振动骨块的振动信号。骨传导传感器180M也可以接触人体脉搏,接收血压跳动信号。在一些实施例中,骨传导传感器180M也可以设置于耳机中,结合成骨传导耳机。音频模块170可以基于所述骨传导传感器180M获取的声部振动骨块的振动信号,解析出语音信号,实现语音功能。应用处理器可以基于所述骨传导传感器180M获取的血压跳动信号解析心率信息,实现心率检测功能。Bone conduction sensor 180M can acquire vibration signals. In some embodiments, the bone conduction sensor 180M can acquire the vibration signal of the vibrating bone mass of the human body's vocal part. The bone conduction sensor 180M can also contact the human body's pulse and receive blood pressure beating signals. In some embodiments, the bone conduction sensor 180M can also be provided in an earphone and combined into a bone conduction earphone. The audio module 170 can analyze the voice signal based on the vibration signal of the vocal vibrating bone obtained by the bone conduction sensor 180M to implement the voice function. The application processor can analyze the heart rate information based on the blood pressure beating signal acquired by the bone conduction sensor 180M to implement the heart rate detection function.

按键190包括开机键,音量键等。按键190可以是机械按键。也可以是触摸式按键。电子设备100可以接收按键输入,产生与电子设备100的用户设置以及功能控制有关的键信号输入。The buttons 190 include a power button, a volume button, etc. Key 190 may be a mechanical key. It can also be a touch button. The electronic device 100 may receive key inputs and generate key signal inputs related to user settings and function control of the electronic device 100 .

马达191可以产生振动提示。马达191可以用于来电振动提示,也可以用于触摸振动反馈。例如,作用于不同应用(例如拍照,音频播放等)的触摸操作,可以对应不同的振动反馈效果。作用于显示屏194不同区域的触摸操作,马达191也可对应不同的振动反馈效果。不同的应用场景(例如:时间提醒,接收信息,闹钟,游戏等)也可以对应不同的振动反馈效果。触摸振动反馈效果还可以支持自定义。The motor 191 can generate vibration prompts. The motor 191 can be used for vibration prompts for incoming calls and can also be used for touch vibration feedback. For example, touch operations for different applications (such as taking pictures, audio playback, etc.) can correspond to different vibration feedback effects. The motor 191 can also respond to different vibration feedback effects for touch operations in different areas of the display screen 194 . Different application scenarios (such as time reminders, receiving information, alarm clocks, games, etc.) can also correspond to different vibration feedback effects. The touch vibration feedback effect can also be customized.

指示器192可以是指示灯,可以用于指示充电状态,电量变化,也可以用于指示消息,未接来电,通知等。The indicator 192 may be an indicator light, which may be used to indicate charging status, power changes, or may be used to indicate messages, missed calls, notifications, etc.

电子设备100的软件系统可以采用分层架构,事件驱动架构,微核架构,微服务架构,或云架构。本申请实施例以分层架构的Android系统为例,示例性说明电子设备100的软件结构。The software system of the electronic device 100 may adopt a layered architecture, an event-driven architecture, a microkernel architecture, a microservice architecture, or a cloud architecture. The embodiment of this application takes the Android system with a layered architecture as an example to illustrate the software structure of the electronic device 100 .

图5为本申请实施例的电子设备100的软件结构框图。FIG. 5 is a software structure block diagram of the electronic device 100 according to the embodiment of the present application.

电子设备100的分层架构将软件分成若干个层,每一层都有清晰的角色和分工。层与层之间通过软件接口通信。在一些实施例中,将Android系统分为四层,从上至下分别为应用程序层,应用程序框架层,安卓运行时(Android runtime)和系统库,以及内核层。The layered architecture of the electronic device 100 divides the software into several layers, and each layer has clear roles and division of labor. The layers communicate through software interfaces. In some embodiments, the Android system is divided into four layers, from top to bottom: application layer, application framework layer, Android runtime (Android runtime) and system libraries, and kernel layer.

应用程序层可以包括一系列应用程序包。The application layer can include a series of application packages.

如图5所示,该应用程序包可以包括相机,图库,日历,电话,地图,导航,WLAN,音乐,备忘录等应用程序。As shown in Figure 5, the application package can include camera, gallery, calendar, phone, map, navigation, WLAN, music, memo and other applications.

在一些实施例中,如图5所示,应用程序层还包括桌面启动器(Launcher),该桌面启动器中包含多个类,例如触摸交互管理模块(Touch Interaction Manager)、手势处理模块、窗口转换滑动处理模块(WindowsTransformSwipeHandler)、多任务动画包装模块(RecentsAnimationWrapper)、远程动画目标处理模块(RemoteAnimationTargetSet)、滑动共享状态模块(SwipeSharedState)、动效管理模块等。In some embodiments, as shown in Figure 5, the application layer also includes a desktop launcher (Launcher), which contains multiple classes, such as a touch interaction management module (Touch Interaction Manager), a gesture processing module, a window Transformation sliding processing module (WindowsTransformSwipeHandler), multi-task animation packaging module (RecentsAnimationWrapper), remote animation target processing module (RemoteAnimationTargetSet), sliding shared state module (SwipeSharedState), motion effect management module, etc.

其中,触摸交互管理模块用于确定接收的触摸事件在电子设备的哪个手势区域触发,从而将该触摸事件发送至对应的消费者。例如,触摸交互管理模块调用onInputEvent方法,该onInputEvent方法作为视图系统监视到系统 Input 事件回调的入口,将展开整个返回手势的判断、视图和动画的刷新以及返回事件的触发。例如,确定触摸事件的MotionEvent 类型,之后通过onMotionEvent方法预处理。onInputEvent方法中处理滑动事件(包含down事件、move事件和up事件),在down事件时根据不同的场景创建不同的输入消费者(InputConsumer),例如在桌面、或其他界面等不同情况下使用手势,对应的InputConsumer是不同的。The touch interaction management module is used to determine in which gesture area of the electronic device the received touch event is triggered, so as to send the touch event to the corresponding consumer. For example, the touch interaction management module calls the onInputEvent method. The onInputEvent method serves as the entry point for the view system to monitor the system Input event callback. It will expand the judgment of the entire return gesture, refresh the view and animation, and trigger the return event. For example, determine the MotionEvent type of the touch event, and then preprocess it through the onMotionEvent method. The onInputEvent method handles sliding events (including down events, move events, and up events), and creates different input consumers (InputConsumers) according to different scenarios during the down event, such as using gestures in different situations such as the desktop or other interfaces. The corresponding InputConsumer is different.

手势处理模块可以是onMotionEvent方法中创建的输入消费者,该输入消费者包括OverviewInputConsumer、OtherActivityInputConsumer或者新建的消费者(newConsumer)等。其中,OverviewInputConsumer是在桌面或者多任务界面下处理事件的消费者;该OtherActivityInputConsumer是在非桌面界面下处理事件的消费者。新建的消费者可以是新建的特殊消费者,也可以是新建的基础消费者(newBaseConsumer)。该手势处理模块可以对接收的触摸事件进行处理,触发该触摸事件对应的动效,例如跟手动效、进入多任务的动效等。The gesture processing module can be an input consumer created in the onMotionEvent method. The input consumer includes OverviewInputConsumer, OtherActivityInputConsumer or a new consumer (newConsumer). Among them, OverviewInputConsumer is a consumer that processes events under a desktop or multi-tasking interface; the OtherActivityInputConsumer is a consumer that processes events under a non-desktop interface. The new consumer can be a new special consumer or a new base consumer (newBaseConsumer). The gesture processing module can process the received touch event and trigger the motion effect corresponding to the touch event, such as following the motion effect, entering multi-tasking motion effect, etc.

窗口转换滑动处理模块用于在手势处理模块触发进入多任务的动效之后,将多任务标志位(isToRecents)设置为真,以标识电子设备进入到多任务的处理逻辑;还用于在电子设备显示完该进入多任务的动效时,例如,显示出图7中的(2)之后,向多任务动画包装模块发送动画完成指令,该动画完成指令包含isToRecents=true的信息。The window transition sliding processing module is used to set the multitasking flag bit (isToRecents) to true after the gesture processing module triggers the animation of entering multitasking to identify that the electronic device has entered the processing logic of multitasking; it is also used in electronic devices After displaying the animation for entering multitasking, for example, after displaying (2) in Figure 7, an animation completion command is sent to the multitasking animation packaging module. The animation completion command contains the information of isToRecents=true.

多任务动画包装模块以及远程动画目标处理模块用于协助窗口转换滑动处理模块,将isToRecents=true的信息传递至应用程序框架层。The multi-task animation packaging module and the remote animation target processing module are used to assist the window conversion sliding processing module and pass the isToRecents=true information to the application framework layer.

滑动共享状态模块用于执行清除所有状态的动作,例如清除侦听状态。在本申请实施例中,该滑动共享状态模块还用于响应于状态清除指令,将当前动效运行标志位设置为第一值(假),再执行清除所有状态的动作,从而不引起取消动效的处理逻辑。The sliding shared state module is used to perform actions to clear all states, such as clearing the listening state. In the embodiment of the present application, the sliding shared state module is also used to respond to the state clearing instruction, set the current motion effect running flag bit to the first value (false), and then perform the action of clearing all states, so as not to cause the cancellation of the action. Efficient processing logic.

动效管理模块例如,删除动画目标集模块(RemoveAnimationTargetset)和多任务动画控制兼容模块(RecentsAnimationControllerCompat),会将动效取消指令传递至应用程序框架层的视图系统,以控制进入多任务的动效取消。The motion effect management module, for example, removes the animation target set module (RemoveAnimationTargetset) and the multi-task animation control compatibility module (RecentsAnimationControllerCompat), will pass the motion effect cancellation command to the view system of the application framework layer to control the motion effect cancellation when entering multi-tasking. .

应用程序框架层为应用程序层的应用程序提供应用编程接口(applicationprogramming interface,API)和编程框架。应用程序框架层包括一些预先定义的函数。The application framework layer provides an application programming interface (API) and programming framework for applications in the application layer. The application framework layer includes some predefined functions.

如图5所示,应用程序框架层可以包括窗口管理器,内容提供器,视图系统,电话管理器,资源管理器,通知管理器等。As shown in Figure 5, the application framework layer can include window manager, content provider, view system, phone manager, resource manager, notification manager, etc.

窗口管理器用于管理窗口程序。窗口管理器可以获取显示屏大小,判断是否有状态栏,锁定屏幕,截取屏幕等。A window manager is used to manage window programs. The window manager can obtain the display size, determine whether there is a status bar, lock the screen, capture the screen, etc.

内容提供器用来存放和获取数据,并使这些数据可以被应用程序访问。所述数据可以包括视频,图像,音频,拨打和接听的电话,浏览历史和书签,电话簿等。Content providers are used to store and retrieve data and make this data accessible to applications. Said data can include videos, images, audio, calls made and received, browsing history and bookmarks, phone books, etc.

视图系统包括可视控件,例如显示文字的控件,显示图片的控件等。视图系统可用于构建应用程序。显示界面可以由一个或多个视图组成的。例如,包括短信通知图标的显示界面,可以包括显示文字的视图以及显示图片的视图。The view system includes visual controls, such as controls that display text, controls that display pictures, etc. A view system can be used to build applications. The display interface can be composed of one or more views. For example, a display interface including a text message notification icon may include a view for displaying text and a view for displaying pictures.

电话管理器用于提供电子设备100的通信功能。例如通话状态的管理(包括接通,挂断等)。The phone manager is used to provide communication functions of the electronic device 100 . For example, call status management (including connected, hung up, etc.).

资源管理器为应用程序提供各种资源,比如本地化字符串,图标,图片,布局文件,视频文件等等。The resource manager provides various resources to applications, such as localized strings, icons, pictures, layout files, video files, etc.

通知管理器使应用程序可以在状态栏中显示通知信息,可以用于传达告知类型的消息,可以短暂停留后自动消失,无需用户交互。比如通知管理器被用于告知下载完成,消息提醒等。通知管理器还可以是以图表或者滚动条文本形式出现在系统顶部状态栏的通知,例如后台运行的应用程序的通知,还可以是以对话窗口形式出现在屏幕上的通知。例如在状态栏提示文本信息,发出提示音,电子设备振动,指示灯闪烁等。The notification manager allows applications to display notification information in the status bar, which can be used to convey notification-type messages and can automatically disappear after a short stay without user interaction. For example, the notification manager is used to notify download completion, message reminders, etc. The notification manager can also be notifications that appear in the status bar at the top of the system in the form of charts or scroll bar text, such as notifications for applications running in the background, or notifications that appear on the screen in the form of conversation windows. For example, text information is prompted in the status bar, a beep sounds, the electronic device vibrates, the indicator light flashes, etc.

在一些实施例中,该应用程序框架层还包括输入管理模块,该输入管理模块用于从电子设备的硬件获取输入,并将该输入转换为事件(Event),以及将事件分发给相应处理模块。In some embodiments, the application framework layer also includes an input management module, which is used to obtain input from the hardware of the electronic device, convert the input into an event (Event), and distribute the event to the corresponding processing module .

Android Runtime包括核心库和虚拟机。Android runtime负责安卓系统的调度和管理。Android Runtime includes core libraries and virtual machines. The Android runtime is responsible for the scheduling and management of the Android system.

核心库包含两部分:一部分是java语言需要调用的功能函数,另一部分是安卓的核心库。The core library contains two parts: one is the functional functions that need to be called by the Java language, and the other is the core library of Android.

应用程序层和应用程序框架层运行在虚拟机中。虚拟机将应用程序层和应用程序框架层的java文件执行为二进制文件。虚拟机用于执行对象生命周期的管理,堆栈管理,线程管理,安全和异常的管理,以及垃圾回收等功能。The application layer and application framework layer run in virtual machines. The virtual machine executes the java files of the application layer and application framework layer into binary files. The virtual machine is used to perform object life cycle management, stack management, thread management, security and exception management, and garbage collection and other functions.

系统库可以包括多个功能模块。例如:表面管理器(surface manager),媒体库(Media Libraries),三维图形处理库(例如:OpenGL ES),2D图形引擎(例如:SGL)等。System libraries can include multiple functional modules. For example: surface manager (surface manager), media libraries (Media Libraries), 3D graphics processing library (for example: OpenGL ES), 2D graphics engine (for example: SGL), etc.

表面管理器用于对显示子系统进行管理,并且为多个应用程序提供了2D和3D图层的融合。The surface manager is used to manage the display subsystem and provides the fusion of 2D and 3D layers for multiple applications.

媒体库支持多种常用的音频,视频格式回放和录制,以及静态图像文件等。媒体库可以支持多种音视频编码格式,例如: MPEG4,H.264,MP3,AAC,AMR,JPG,PNG等。The media library supports playback and recording of a variety of commonly used audio and video formats, as well as static image files, etc. The media library can support multiple audio and video encoding formats, such as: MPEG4, H.264, MP3, AAC, AMR, JPG, PNG, etc.

三维图形处理库用于实现三维图形绘图,图像渲染,合成,和图层处理等。The 3D graphics processing library is used to implement 3D graphics drawing, image rendering, composition, and layer processing.

2D图形引擎是2D绘图的绘图引擎。2D Graphics Engine is a drawing engine for 2D drawing.

内核层是硬件和软件之间的层。内核层至少包含显示驱动,摄像头驱动,音频驱动,传感器驱动。The kernel layer is the layer between hardware and software. The kernel layer contains at least display driver, camera driver, audio driver, and sensor driver.

可以理解的是,图2示出的软件结构中的层以及各层中包含的部件,并不构成对电子设备100的具体限定。在本申请另一些实施例中,电子设备100可以包括比图示更多或更少的层,以及每个层中可以包括更多或更少的部件,本申请不做限定。It can be understood that the layers in the software structure shown in FIG. 2 and the components included in each layer do not constitute specific limitations on the electronic device 100. In other embodiments of the present application, the electronic device 100 may include more or fewer layers than shown in the figures, and each layer may include more or fewer components, which is not limited by this application.

图6本申请实施例提供的一种上滑动效异常处理方法的流程图。如图6所示,该异常处理方法应用于电子设备,该电子设备显示第一显示界面,该第一显示界面指示为应用程序页面。该异常处理方法包括:步骤S601-步骤S604。Figure 6 is a flow chart of a scroll-up effect exception handling method provided by an embodiment of the present application. As shown in Figure 6, the exception handling method is applied to an electronic device. The electronic device displays a first display interface, and the first display interface is indicated as an application page. The exception handling method includes: step S601-step S604.

步骤S601、响应于第一上滑操作,显示进入多任务的动效。Step S601: In response to the first sliding up operation, display the dynamic effect of entering multitasking.

在本申请实施例中,电子设备接收对第一显示界面的第一上滑操作,其中,第一显示界面指示为应用程序页面。可以理解的是,用户在第一显示界面进行第一上滑操作,其目的是进入多任务管理页面,该第一上滑操作的动作可以根据实际应用情况进行设置,例如,第一上滑操作指示为从电子设备的屏幕底部边缘向上滑动并停顿的操作。In this embodiment of the present application, the electronic device receives a first slide-up operation on the first display interface, where the first display interface is indicated as an application page. It can be understood that the purpose of the user performing the first swipe up operation on the first display interface is to enter the multi-task management page. The action of the first swipe up operation can be set according to the actual application situation, for example, the first swipe up operation Indicated by swiping up from the bottom edge of the screen of an electronic device and pausing.

该进入多任务的动效,包括但不限于:应用程序的预览页面从左边向右边移动到预定位置、预览页面所指示的应用程序的标识显示出来、以及桌面背景模糊等动画效果。The animation effects for entering multitasking include but are not limited to: the preview page of the application moves from left to right to a predetermined position, the logo of the application indicated by the preview page is displayed, and the desktop background is blurred and other animation effects.

图7为本申请实施例提供的一种进入多任务的动效的示意图。用户在电子设备上进行第一上滑操作,电子设备会显示跟手动效,用户抬手时电子设备显示的界面为图7的(1)所示的第四显示界面104。该第四显示界面104包括最近使用的应用程序的预览页面,例如,未完全显示的电话的预览页面1041和完全显示的备忘录的预览页面1042。电子设备响应于该第一上滑操作,显示进入多任务的动效,其中,动效指的是显示界面中各元素的动态变化效果,例如,电话的预览页面1041和备忘录的预览页面1042的动态变化效果:该电话的预览页面1041和备忘录的预览页面1042会按照图7(1)中虚线箭头所示的方向从左向右移动到预定位置。FIG. 7 is a schematic diagram of an animation for entering multitasking provided by an embodiment of the present application. The user performs the first swipe-up operation on the electronic device, and the electronic device will display a follow-up effect. When the user raises his hand, the interface displayed by the electronic device is the fourth display interface 104 shown in (1) of Figure 7 . The fourth display interface 104 includes preview pages of recently used applications, for example, a preview page 1041 of an incompletely displayed phone and a preview page 1042 of a fully displayed memo. In response to the first sliding up operation, the electronic device displays a dynamic effect for entering multitasking, where the dynamic effect refers to the dynamic change effect of each element in the display interface, for example, the preview page 1041 of the phone and the preview page 1042 of the memo. Dynamic change effect: The preview page 1041 of the phone and the preview page 1042 of the memo will move from left to right to the predetermined position in the direction shown by the dotted arrow in Figure 7 (1).

参见图7(2)中第五显示界面105,移动后的电话的预览页面如页面1052所示,移动后的备忘录的预览页面如页面1054所示,并且,电话的标识1051显示在电话的预览页面1052上方,备忘录的标识1053(应用程序名称在右侧隐藏显示)显示在备忘录的预览页面1054的上方;清理后台的控件1055显示在应用程序的预览页面所处界面的下方。本申请实施例中,用户在电子设备上进行第一上滑操作,抬手后,电子设备由第四显示界面104自动变化为第五显示界面105的过程,即为电子设备显示进入多任务的动效的过程。Referring to the fifth display interface 105 in Figure 7(2), the preview page of the moved phone is shown on page 1052, the preview page of the moved memo is shown on page 1054, and the phone logo 1051 is displayed on the preview page of the phone. Above the page 1052, the logo of the memo 1053 (the application name is hidden and displayed on the right) is displayed above the preview page 1054 of the memo; the control 1055 for cleaning the background is displayed below the interface where the preview page of the application is located. In the embodiment of the present application, the user performs the first swipe-up operation on the electronic device. After raising the hand, the electronic device automatically changes from the fourth display interface 104 to the fifth display interface 105 , which is the process in which the electronic device enters multi-tasking. The process of animation.

图8为本申请实施例提供的一种第一上滑操作的处理方法示意图。在一个实施方式中,如图8所示,电子设备响应于第一上滑操作,显示进入多任务的动效,包括:步骤S6011-步骤S6014。FIG. 8 is a schematic diagram of a processing method for the first slide-up operation provided by an embodiment of the present application. In one embodiment, as shown in FIG. 8 , in response to the first slide-up operation, the electronic device displays an animation for entering multitasking, including: step S6011 to step S6014.

步骤S6011、输入管理模块接收到第一上滑操作,将该第一上滑操作转换为第一触摸事件。Step S6011: The input management module receives the first slide-up operation and converts the first slide-up operation into a first touch event.

在一些实施例中,电子设备当前显示应用程序页面,用户做出从电子设备的屏幕底部边缘向上滑动并停顿的操作(第一上滑操作)。该第一上滑操作包括一个接触屏幕的按压操作、一个或多个滑动操作和一个抬手操作。输入管理模块将该第一上滑操作转换为第一触摸事件,包括:将按压操作转换为按压(down)事件,将滑动操作转换为移动(move)事件,将抬手操作转换为抬手(up)事件。In some embodiments, the electronic device currently displays an application page, and the user performs an operation of sliding upward from the bottom edge of the screen of the electronic device and pausing (the first sliding upward operation). The first sliding-up operation includes a pressing operation of contacting the screen, one or more sliding operations and a hand-raising operation. The input management module converts the first slide-up operation into a first touch event, including: converting a press operation into a press (down) event, converting a slide operation into a move (move) event, and converting a hand-raising operation into a hand-raising ( up) event.

步骤S6012、输入管理模块将该第一触摸事件,分发至桌面启动器中的触摸交互管理模块。Step S6012: The input management module distributes the first touch event to the touch interaction management module in the desktop launcher.

在一些实施例中,输入管理模块可以将触摸事件包含的一系列事件分别发送至桌面启动器,例如,输入管理模块可以在用户触摸屏幕时,将接收到的按压操作转换为down事件,并将down事件发送至桌面启动器;在用户滑动时,将接收到的滑动操作转换为move事件,并将move事件发送至桌面启动器;在用户抬手后,将接收到的抬手操作转换为up事件,并将up事件发送至桌面启动器。In some embodiments, the input management module can send a series of events included in the touch event to the desktop launcher respectively. For example, when the user touches the screen, the input management module can convert the received press operation into a down event, and The down event is sent to the desktop launcher; when the user slides, the received sliding operation is converted into a move event, and the move event is sent to the desktop launcher; after the user raises his hand, the received hand raising operation is converted into up event and sends the up event to the desktop launcher.

步骤S6013、触摸交互管理模块在确定该第一触摸事件触发于手势导航热区的情况下,将该第一触摸事件发给对应的手势处理模块。Step S6013: When the touch interaction management module determines that the first touch event is triggered in the gesture navigation hot zone, the touch interaction management module sends the first touch event to the corresponding gesture processing module.

在一些实施例中,触摸交互管理模块首先接收到第一触摸事件中的down事件,通过该down事件的按压位置,确定该down事件是否触发于手势导航热区。在第一触摸事件中的down事件触发于手势导航热区的情况下,触摸交互管理模块将该down事件发给对应的手势处理模块。该触摸交互管理模块还可以将后续接收到的与该down事件关联的move事件和up事件均发送至相同的手势处理模块。需要说明的是,触摸交互管理模块在确定该第一触摸事件不是触发于手势导航热区的情况下,执行与该第一触摸事件对应的其他处理流程,本实施例中对此不进行限定。In some embodiments, the touch interaction management module first receives the down event in the first touch event, and determines whether the down event is triggered in the gesture navigation hot zone based on the pressing position of the down event. When the down event in the first touch event is triggered in the gesture navigation hot zone, the touch interaction management module sends the down event to the corresponding gesture processing module. The touch interaction management module can also send the subsequently received move events and up events associated with the down event to the same gesture processing module. It should be noted that when the touch interaction management module determines that the first touch event is not triggered in the gesture navigation hot zone, it executes other processing flows corresponding to the first touch event, which is not limited in this embodiment.

在一些示例中,该手势处理模块可以是输入消费者(InputConsumer),该输入消费者包括OverviewInputConsumer、OtherActivityInputConsumer或者新建的消费者(newConsumer)等。其中,OverviewInputConsumer是在桌面或者多任务界面下处理事件的消费者;该OtherActivityInputConsumer是在非桌面界面下处理事件的消费者。新建的消费者可以新建的特殊消费者,也可以是新建的基础消费者(newBaseConsumer)。In some examples, the gesture processing module may be an input consumer (InputConsumer), which includes OverviewInputConsumer, OtherActivityInputConsumer, or a new consumer (newConsumer). Among them, OverviewInputConsumer is a consumer that processes events under a desktop or multi-tasking interface; the OtherActivityInputConsumer is a consumer that processes events under a non-desktop interface. The new consumer can be a new special consumer or a new base consumer (newBaseConsumer).

在一些实施例中,由于该第一触摸事件是电子设备在显示应用程序界面(非桌面界面)的情况下接收到的触摸事件,因此,该第一触摸事件由手势处理模块中的OtherActivityInputConsumer处理。In some embodiments, since the first touch event is a touch event received by the electronic device when the application interface (non-desktop interface) is displayed, the first touch event is processed by the OtherActivityInputConsumer in the gesture processing module.

步骤S6014、手势处理模块基于该第一触摸事件,触发视图系统显示进入多任务的动效。Step S6014: Based on the first touch event, the gesture processing module triggers the view system to display the animation of entering multitasking.

在一些实施例中,手势处理模块基于该第一触摸事件,触发视图系统显示进入多任务的动效之前,基于接收到的第一触摸事件中的 move事件,触发显示上滑跟手动效,并将当前动效运行标志位(mIsLastAnimationRunning)设置为第二值,以表明当前存在动效运行,该第二值可以是真(true)。一般情况下,该当前动效运行标志位会在该第一触摸事件触发的所有动效结束后,即进入多任务的动效结束之后,被设置为第一值,该第一值可以是假(fasle)。In some embodiments, the gesture processing module triggers the display of the slide-up and manual effects based on the move event in the received first touch event before triggering the view system to display the dynamic effect of entering multitasking based on the first touch event, and Set the current animation running flag bit (mIsLastAnimationRunning) to a second value to indicate that there is currently an animation running. The second value may be true. Under normal circumstances, the current animation running flag will be set to the first value after all animations triggered by the first touch event have ended, that is, after the animation entering multi-tasking has ended. The first value can be false. (fasle).

在一些实施例中,手势处理模块接收到第一触摸事件中的up事件,结束针对该第一触摸事件的追踪,触发视图系统显示进入多任务的动效。In some embodiments, the gesture processing module receives the up event in the first touch event, ends tracking for the first touch event, and triggers the view system to display the animation of entering multitasking.

在一些实施例中,手势处理模块可以通过调用doActionUp、processForUpWhenHomeEnable、processGestureWhenUp等方法处理该第一触摸事件,以触发视图系统显示进入多任务的动效。例如,通过调用processGestureWhenUp,可以实现收到up事件时,开始处理该第一触摸事件;通过调用processForUpWhenHomeEnable,可以实现对第一触摸事件中触摸位置、滑动速度等信息的获取与分析;通过调用doActionUp,可以触发该进入多任务动效中的各个动画的显示。In some embodiments, the gesture processing module can process the first touch event by calling methods such as doActionUp, processForUpWhenHomeEnable, processGestureWhenUp, etc., to trigger the view system to display the dynamic effect of entering multitasking. For example, by calling processGestureWhenUp, you can start processing the first touch event when the up event is received; by calling processForUpWhenHomeEnable, you can obtain and analyze the touch position, sliding speed and other information in the first touch event; by calling doActionUp, The display of each animation in the multi-tasking animation can be triggered.

图9为本申请实施例提供的一种多任务动效处理流程示意图。在一些实施例中,手势处理模块基于该第一触摸事件,触发视图系统显示进入多任务的动效之后,如图9所示,窗口转换滑动处理模块(WindowsTransformSwipeHandler)会将多任务标志位(isToRecents)设置为真,以标识电子设备进入到多任务的处理逻辑。Figure 9 is a schematic flowchart of a multi-task dynamic effect processing provided by an embodiment of the present application. In some embodiments, after the gesture processing module triggers the view system to display the dynamic effect of entering multitasking based on the first touch event, as shown in Figure 9, the window transition sliding processing module (WindowsTransformSwipeHandler) will set the multitasking flag (isToRecents ) is set to true to identify the electronic device to enter the multi-tasking processing logic.

参照图9,在步骤S901中,窗口转换滑动处理模块调用“完成当前到多任务进程的转换”方法(finishCurrentTransitionToRecentsProc),将isToRecents设置为true。Referring to Figure 9, in step S901, the window transition sliding processing module calls the "complete current to multi-tasking process conversion" method (finishCurrentTransitionToRecentsProc) and sets isToRecents to true.

在步骤S902中,窗口转换滑动处理模块还调用finish方法,向多任务动画包装模块(RecentsAnimationWrapper)发送动画完成指令,该动画完成指令包含该isToRecents=true的信息,以供多任务动画包装模块将该isToRecents=true的信息传递至应用程序框架层。In step S902, the window transition sliding processing module also calls the finish method to send an animation completion instruction to the multi-task animation packaging module (RecentsAnimationWrapper). The animation completion instruction contains the isToRecents=true information for the multi-task animation packaging module to convert the The information of isToRecents=true is passed to the application framework layer.

在一个示例中,窗口转换滑动处理模块在电子设备显示完该进入多任务的动效时,例如,显示出图7中的(2)之后,向多任务动画包装模块发送动画完成指令。In one example, the window transition sliding processing module sends an animation completion instruction to the multitasking animation packaging module after the electronic device displays the animation for entering multitasking, for example, after displaying (2) in Figure 7 .

在步骤S903中,多任务动画包装模块向远程动画目标处理模块(RemoteAnimationTargetSet)发送动画完成指令,以供该远程动画目标处理模块将该isToRecents=true的信息传递至应用程序框架层。In step S903, the multi-task animation packaging module sends an animation completion instruction to the remote animation target processing module (RemoteAnimationTargetSet), so that the remote animation target processing module can pass the isToRecents=true information to the application framework layer.

在步骤S904中,远程动画目标处理模块通过调用finish方法,将动画完成指令发送给应用程序框架层,以实现将isToRecents=true的信息传递至应用程序框架层。In step S904, the remote animation target processing module sends the animation completion instruction to the application framework layer by calling the finish method, so as to transfer the isToRecents=true information to the application framework layer.

如图9所示的多任务动效处理流程中,桌面启动器在触发视图系统显示进入多任务的动效之后,将多任务标志位设置为真,并在该进入多任务的动效显示出多任务管理页面(图7中的(2))时,将该多任务标志位设置为真的信息传递至应用程序框架层的视图系统中,以结束本次显示进入多任务的动效的进程。换言之,本申请实施例中,显示进入多任务的动效的过程,由用户的第一上滑操作结束开始,至桌面启动器将多任务标志位设置为真的信息传递至应用程序框架层为止。In the multi-tasking animation processing process shown in Figure 9, after triggering the view system to display the animation for entering multi-tasking, the desktop launcher sets the multi-tasking flag bit to true, and displays the animation for entering multi-tasking. When entering the multi-tasking management page ((2) in Figure 7), the information that the multi-tasking flag bit is set to true is passed to the view system of the application framework layer to end the process of displaying the dynamic effect of entering multi-tasking. . In other words, in the embodiment of the present application, the process of displaying the dynamic effect of entering multitasking starts from the end of the user's first swipe up operation until the desktop launcher transmits the information that the multitasking flag bit is set to true to the application framework layer. .

步骤S602、在显示进入多任务的动效的过程中,响应于第二上滑操作,触发预设处理流程。Step S602: During the process of displaying the dynamic effect of entering multitasking, in response to the second sliding up operation, a preset processing flow is triggered.

其中,第二上滑操作是用于进入桌面的手势操作,例如,该第二上滑操作指示为从电子设备的屏幕底部边缘向上滑动的操作。The second slide-up operation is a gesture operation for entering the desktop. For example, the second slide-up operation is indicated as a slide-up operation from the bottom edge of the screen of the electronic device.

图10为本申请实施例提供的一种预设处理流程的示意图。如图10所示,在一个实施方式中,预设处理流程的步骤,包括:步骤S6021-步骤S6025。Figure 10 is a schematic diagram of a preset processing flow provided by an embodiment of the present application. As shown in Figure 10, in one embodiment, the steps of the preset processing flow include: step S6021-step S6025.

步骤6021、输入管理模块接收到第二上滑操作,将该第二上滑操作转换为第二触摸事件。Step 6021: The input management module receives the second slide-up operation and converts the second slide-up operation into a second touch event.

其中,该第二上滑操作包括一个接触屏幕的按压操作、一个或多个滑动操作和一个抬手操作。输入管理模块将该第二上滑操作转换为第二触摸事件,包括:将按压操作转换为按压(down)事件,将滑动操作转换为移动(move)事件,将抬手操作转换为抬手(up)事件。Wherein, the second upward sliding operation includes a pressing operation of contacting the screen, one or more sliding operations and a hand-raising operation. The input management module converts the second slide-up operation into a second touch event, including: converting the press operation into a press (down) event, converting the slide operation into a move (move) event, and converting the hand-raising operation into a hand-raising ( up) event.

步骤S6022、输入管理模块将该第二触摸事件,分发至桌面启动器中的触摸交互管理模块。Step S6022: The input management module distributes the second touch event to the touch interaction management module in the desktop launcher.

在一些实施例中,输入管理模块可以将触摸事件包含的一系列事件分别发送至桌面启动器的触摸交互管理模块,例如,输入管理模块可以在用户触摸屏幕时,将down事件发送至桌面启动器;在用户滑动时,将move事件发送至桌面启动器;在用户抬手后,将up事件发送至桌面启动器。In some embodiments, the input management module can send a series of events included in the touch event to the touch interaction management module of the desktop launcher respectively. For example, the input management module can send a down event to the desktop launcher when the user touches the screen. ; When the user slides, send the move event to the desktop launcher; after the user raises their hand, send the up event to the desktop launcher.

步骤S6023、触摸交互管理模块在确定该第二触摸事件触发于手势导航热区的情况下,将该第二触摸事件发给对应的手势处理模块。Step S6023: When the touch interaction management module determines that the second touch event is triggered in the gesture navigation hot zone, it sends the second touch event to the corresponding gesture processing module.

在一些实施例中,触摸交互管理模块首先接收到第二触摸事件中的down事件,通过该down事件的按压位置,确定该down事件是否触发于手势导航热区。在该down事件触发于手势导航热区的情况下,触摸交互管理模块将该第二触摸事件中的down事件发给对应的手势处理模块。需要说明的是,触摸交互管理模块在确定该第二触摸事件不是触发于手势导航热区的情况下,执行与该第二触摸事件对应的其他处理流程,本实施例中对此不进行限定。In some embodiments, the touch interaction management module first receives the down event in the second touch event, and determines whether the down event is triggered in the gesture navigation hot zone based on the pressing position of the down event. When the down event is triggered in a gesture navigation hotspot, the touch interaction management module sends the down event in the second touch event to the corresponding gesture processing module. It should be noted that when the touch interaction management module determines that the second touch event is not triggered in the gesture navigation hot zone, it executes other processing procedures corresponding to the second touch event, which is not limited in this embodiment.

步骤S6024、手势处理模块基于该第二触摸事件,向滑动共享状态模块(SwipeSharedState)发送状态清除指令。Step S6024: Based on the second touch event, the gesture processing module sends a state clearing instruction to the sliding shared state module (SwipeSharedState).

在一些实施例中,该第二触摸事件由手势处理模块中的newBaseConsumer处理。In some embodiments, the second touch event is handled by newBaseConsumer in the gesture processing module.

在一些实施例中,手势处理模块中的newBaseConsumer处理该第二触摸事件,包括:下述步骤一和步骤二。In some embodiments, newBaseConsumer in the gesture processing module processes the second touch event, including: the following steps one and two.

步骤一、根据该第二触摸事件,newBaseConsumer中的isOverviewConsumer子模块返回真值(true),并将多任务标志位(isToRecents)的值置为假(false)。Step 1. According to the second touch event, the isOverviewConsumer submodule in newBaseConsumer returns a true value (true) and sets the value of the multitasking flag (isToRecents) to false (false).

其中,newBaseConsumer中的isOverviewConsumer子模块返回真值(true),表示该isOverviewConsumer子模块可以处理该第二触摸事件。Among them, the isOverviewConsumer submodule in newBaseConsumer returns a true value (true), indicating that the isOverviewConsumer submodule can handle the second touch event.

步骤二、基于该第二触摸事件,newBaseConsumer向滑动共享状态模块(SwipeSharedState)发送状态清除指令。Step 2: Based on the second touch event, newBaseConsumer sends a state clearing instruction to the sliding shared state module (SwipeSharedState).

步骤S6025、滑动共享状态模块响应于状态清除指令,执行清除所有状态(clearAllState)的动作。Step S6025: The sliding shared state module responds to the state clearing instruction and performs the action of clearing all states (clearAllState).

其中,清除所有状态的动作包括多个清除状态的动作,例如,可以包括:清除侦听状态动作(clearListenerState)、还原标志位状态的动作等。The action of clearing all states includes multiple actions of clearing states. For example, it may include: an action of clearing listening state (clearListenerState), an action of restoring flag bit state, etc.

需要说明的是,在相关技术中 ,滑动共享状态模块在执行清除侦听状态动作时,在确定多任务标志位为真(isToRecents=true)、且当前动效运行标志位为真(mIsLastAnimationRunning= true)的情况下,会触发取消动效的流程,即滑动共享状态模块会向动效管理模块发送动效取消指令,该动效取消指令包括isToRecents=false的信息。该动效管理模块,例如,删除动画目标集模块(RemoveAnimationTargetset)和多任务动画控制兼容模块(RecentsAnimationControllerCompat),会将动效取消指令传递至应用程序框架层的视图系统,以控制进入多任务的动效取消。然而,进入多任务的动效取消,会使电子设备返回显示应用程序的页面,而不是显示桌面,导致上滑动效出现异常。It should be noted that in related technologies, when the sliding shared state module performs the action of clearing the listening state, it determines that the multi-task flag bit is true (isToRecents=true) and the current animation running flag bit is true (mIsLastAnimationRunning= true ), the process of canceling the animation will be triggered, that is, the sliding sharing state module will send the animation cancellation instruction to the animation management module, and the animation cancellation instruction includes the information of isToRecents=false. The animation management module, for example, remove animation target set module (RemoveAnimationTargetset) and multi-task animation control compatibility module (RecentsAnimationControllerCompat), will pass the animation cancellation command to the view system of the application framework layer to control the animation entering multi-tasking. Effectively cancelled. However, canceling the animation when entering multitasking will cause the electronic device to return to the page displaying the application instead of displaying the desktop, resulting in abnormal scrolling effects.

因此,在本申请实施例提供的上滑动效异常处理方法中,电子设备在响应于第二上滑操作触发的预设处理流程中,执行下述步骤S603,以对第二上滑操作的处理流程进行优化,解决上滑动效异常的问题。Therefore, in the slide-up effect exception handling method provided by the embodiment of the present application, the electronic device executes the following step S603 in the preset processing flow triggered in response to the second slide-up operation to process the second slide-up operation. The process is optimized to solve the problem of abnormal upward sliding effect.

步骤S603、在该预设处理流程中,在执行清除所有状态的动作之前,将当前动效运行标志位设置为第一值。Step S603: In the preset processing flow, before performing the action of clearing all states, the current animation running flag bit is set to the first value.

其中,将当前动效运行标志位设置为假后,在执行清除所有状态的动作时,不触发执行取消当前动效的处理。Among them, after setting the current dynamic effect running flag bit to false, when performing the action of clearing all states, the processing of canceling the current dynamic effect will not be triggered.

在本申请实施例中,该第一值可以为falses。例如,滑动共享状态模块响应于状态清除指令,将当前动效运行标志位设置为假(即mIsLastAnimationRunning= false),再执行清除所有状态的动作。在该情况下,后续执行清除侦听状态动作时,滑动共享状态模块会判断当前动效运行标志位为假,则不触发取消动效的流程,即滑动共享状态模块不向动效管理模块发送动效取消指令。In this embodiment of the present application, the first value may be false. For example, the sliding shared state module responds to the state clearing instruction by setting the current animation running flag bit to false (i.e., mIsLastAnimationRunning=false), and then performs the action of clearing all states. In this case, when the clear listening state action is subsequently executed, the sliding sharing state module will determine that the current motion effect running flag is false, and the process of canceling the motion effect will not be triggered, that is, the sliding sharing state module will not send a message to the motion effect management module. Animation cancellation command.

需要说明的是,该当前动效运行标志位一般会在该第一触摸事件触发的所有动效结束后,即进入多任务的动效结束之后,被设置为假。但在本申请实施例中,一旦滑动共享状态模块接收到状态清除指令,就提前改变该当前动效运行标志位,从而不引起取消动效的处理逻辑,优化用户在进入多任务动效过程中,进行第二上滑操作时,电子设备返回应用程序的异常场景。It should be noted that the current motion effect running flag will generally be set to false after all motion effects triggered by the first touch event have ended, that is, after the motion effects entering multitasking have ended. However, in the embodiment of this application, once the sliding shared state module receives the state clearing instruction, it changes the current motion effect running flag in advance, thereby not causing the processing logic of canceling the motion effect, and optimizing the user's ability to enter multi-tasking motion effects. , when performing the second swipe up operation, the electronic device returns to the abnormal scene of the application.

在一个示例中,滑动共享状态模块执行清除侦听状态动作时,可以通过if(mIsLastAnimationRunning&&getLastAnimationTarget()!=null)来确定是否触发取消动效的流程,例如,该条件成立则触发取消动效的流程,该条件不成立则不触发取消动效的流程。In an example, when the sliding shared state module performs the action of clearing the listening state, you can use if (mIsLastAnimationRunning&&getLastAnimationTarget()!=null) to determine whether to trigger the process of canceling the animation. For example, if this condition is true, the process of canceling the animation is triggered. , if this condition is not met, the process of canceling the animation will not be triggered.

步骤S604、在该预设处理流程执行完成后显示桌面。Step S604: Display the desktop after the execution of the preset processing flow is completed.

本申请实施例中,滑动共享状态模块执行完成清除所有状态的动作,电子设备显示的界面变为桌面。In the embodiment of this application, the sliding sharing status module performs the action of clearing all statuses, and the interface displayed by the electronic device changes to the desktop.

本申请实施例提供的一种异常动效处理方法,该方法中,电子设备接收对第一显示界面的第一上滑操作,该第一显示界面指示为应用程序页面;电子设备响应于该第一上滑操作,显示进入多任务的动效;在显示该进入多任务的动效的过程中,电子设备响应于用户的第二上滑操作,触发预设处理流程。在该预设处理流程中:在执行清除所有状态的动作之前,修改当前动效运行标志位的值,以在执行清除所有状态的动作时,不触发取消当前动效的处理,避免由于进入多任务的动效取消而导致电子设备的显示界面返回到应用程序页面,能够有效解决上滑动效异常的问题,提高用户使用体验,使得电子设备基于触发的预设处理流程顺利显示桌面。An embodiment of the present application provides a method for handling abnormal dynamic effects. In the method, the electronic device receives a first slide-up operation on a first display interface, and the first display interface indicates an application page; the electronic device responds to the first slide-up operation. A sliding-up operation displays the dynamic effect of entering multitasking; during the process of displaying the dynamic effect of entering multi-tasking, the electronic device responds to the user's second sliding-up operation and triggers a preset processing flow. In this preset processing flow: before executing the action of clearing all states, modify the value of the current dynamic effect running flag so that when the action of clearing all states is executed, the process of canceling the current dynamic effect is not triggered to avoid multiple entries. Canceling the animation of the task causes the display interface of the electronic device to return to the application page, which can effectively solve the problem of abnormal upward sliding effects, improve the user experience, and enable the electronic device to smoothly display the desktop based on the preset processing flow triggered.

可以理解的是,电子设备为了实现上述功能,其包含了执行各个功能相应的硬件和/或软件模块。结合本文中所公开的实施例描述的各示例的算法步骤,本申请能够以硬件或硬件和计算机软件的结合形式来实现。某个功能究竟以硬件还是计算机软件驱动硬件的方式来执行,取决于技术方案的特定应用和设计约束条件。本领域技术人员可以结合实施例对每个特定的应用来使用不同方法来实现所描述的功能,但是这种实现不应认为超出本申请的范围。It can be understood that, in order to implement the above functions, the electronic device includes corresponding hardware and/or software modules that perform each function. In conjunction with the algorithm steps of each example described in the embodiments disclosed herein, the present application can be implemented in the form of hardware or a combination of hardware and computer software. Whether a function is performed by hardware or computer software driving the hardware depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions in conjunction with the embodiments for each specific application, but such implementations should not be considered to be beyond the scope of this application.

上述本申请实施例提供的一种上滑动效异常处理方法中电子设备200所执行的步骤,也可以由电子设备200中包括的一种芯片系统来执行,其中,该芯片系统可以包括处理器和蓝牙芯片。该芯片系统可以与存储器耦合,使得该芯片系统运行时调用该存储器中存储的计算机程序,实现上述电子设备200执行的步骤。其中,该芯片系统中的处理器可以是应用处理器也可以是非应用处理器的处理器。The steps performed by the electronic device 200 in the slide-up effect exception handling method provided by the above embodiments of the present application can also be performed by a chip system included in the electronic device 200 , where the chip system can include a processor and Bluetooth chip. The chip system can be coupled with a memory, so that when the chip system is running, it calls the computer program stored in the memory to implement the steps performed by the electronic device 200 . The processor in the chip system may be an application processor or a non-application processor.

本实施例还提供一种计算机可读介质,该计算机可读介质中存储有计算机指令,当该计算机指令在电子设备上运行时,使得电子设备执行上述相关方法步骤实现上述实施例中的方法。This embodiment also provides a computer-readable medium. Computer instructions are stored in the computer-readable medium. When the computer instructions are run on an electronic device, the electronic device causes the electronic device to execute the above related method steps to implement the method in the above embodiment.

本实施例还提供了一种计算机程序产品,当该计算机程序产品在计算机上运行时,使得计算机执行上述相关步骤,以实现上述实施例中的方法。This embodiment also provides a computer program product. When the computer program product is run on a computer, it causes the computer to perform the above related steps to implement the method in the above embodiment.

另外,本申请的实施例还提供一种装置,这个装置具体可以是芯片,组件或模块,该装置可包括相连的处理器和存储器;其中,存储器用于存储计算机执行指令,当装置运行时,处理器可执行存储器存储的计算机执行指令,以使芯片执行上述各方法实施例中的方法。In addition, embodiments of the present application also provide a device. This device may be a chip, a component or a module. The device may include a connected processor and a memory. The memory is used to store computer execution instructions. When the device is running, The processor can execute computer execution instructions stored in the memory, so that the chip executes the methods in each of the above method embodiments.

其中,本实施例提供的电子设备、计算机可读介质、计算机程序产品或芯片均用于执行上文所提供的对应的方法,因此,其所能达到的有益效果可参考上文所提供的对应的方法中的有益效果,此处不再赘述。Among them, the electronic equipment, computer-readable media, computer program products or chips provided in this embodiment are all used to execute the corresponding methods provided above. Therefore, the beneficial effects they can achieve can refer to the corresponding methods provided above. The beneficial effects of this method will not be repeated here.

通过以上实施方式的描述,所属领域的技术人员可以了解到,为描述的方便和简洁,仅以上述各功能模块的划分进行举例说明,实际应用中,可以根据需要而将上述功能分配由不同的功能模块完成,即将装置的内部结构划分成不同的功能模块,以完成以上描述的全部或者部分功能。Through the description of the above embodiments, those skilled in the art can understand that for the convenience and simplicity of description, only the division of the above functional modules is used as an example. In practical applications, the above functions can be allocated to different modules according to needs. The functional module is completed, that is, the internal structure of the device is divided into different functional modules to complete all or part of the functions described above.

在本申请所提供的几个实施例中,应该理解到,所揭露的装置和方法,可以通过其它的方式实现。例如,以上所描述的装置实施例仅仅是示意性的,例如,模块或单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个装置,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通信连接可以是通过一些接口,装置或单元的间接耦合或通信连接,可以是电性,机械或其它的形式。In the several embodiments provided in this application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only illustrative. For example, the division of modules or units is only a logical function division. In actual implementation, there may be other division methods, for example, multiple units or components may be combined or can be integrated into another device, or some features can be ignored, or not implemented. On the other hand, the coupling or direct coupling or communication connection between each other shown or discussed may be through some interfaces, and the indirect coupling or communication connection of the devices or units may be in electrical, mechanical or other forms.

作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是一个物理单元或多个物理单元,即可以位于一个地方,或者也可以分布到多个不同地方。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。另外,在本申请各个实施例中的各功能单元可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。A unit described as a separate component may or may not be physically separate. A component shown as a unit may be one physical unit or multiple physical units, that is, it may be located in one place, or it may be distributed to multiple different places. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of this embodiment. In addition, each functional unit in each embodiment of the present application can be integrated into one processing unit, each unit can exist physically alone, or two or more units can be integrated into one unit. The above integrated units can be implemented in the form of hardware or software functional units.

本申请各个实施例的任意内容,以及同一实施例的任意内容,均可以自由组合。对上述内容的任意组合均在本申请的范围之内。集成的单元如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个可读取存储介质中。基于这样的理解,本申请实施例的技术方案本质上或者说对现有技术做出贡献的部分或者该技术方案的全部或部分可以以软件产品的形式体现出来,该软件产品存储在一个存储介质中,包括若干指令用以使得一个设备(可以是单片机,芯片等)或处理器(processor)执行本申请各个实施例方法的全部或部分步骤。而前述的存储介质包括:U盘、移动硬盘、只读存储器(read onlymemory,ROM)、随机存取存储器(random access memory,RAM)、磁碟或者光盘等各种可以存储程序代码的介质。上面结合附图对本申请的实施例进行了描述,但是本申请并不局限于上述的具体实施方式,上述的具体实施方式仅仅是示意性的,而不是限制性的,本领域的普通技术人员在本申请的启示下,在不脱离本申请宗旨和权利要求所保护的范围情况下,还可做出很多形式,均属于本申请的保护之内。Any contents of various embodiments of this application, as well as any contents of the same embodiment, can be freely combined. Any combination of the above is within the scope of this application. Integrated units may be stored in a readable storage medium if they are implemented in the form of software functional units and sold or used as independent products. Based on this understanding, the technical solutions of the embodiments of the present application are essentially or contribute to the existing technology, or all or part of the technical solution can be embodied in the form of a software product, and the software product is stored in a storage medium , including several instructions to cause a device (which can be a microcontroller, a chip, etc.) or a processor to execute all or part of the steps of the methods of various embodiments of the present application. The aforementioned storage media include: U disk, mobile hard disk, read only memory (ROM), random access memory (RAM), magnetic disk or optical disk and other media that can store program code. The embodiments of the present application have been described above in conjunction with the accompanying drawings. However, the present application is not limited to the above-mentioned specific implementations. The above-mentioned specific implementations are only illustrative and not restrictive. Those of ordinary skill in the art will Inspired by this application, many forms can be made without departing from the purpose of this application and the scope protected by the claims, all of which fall within the protection of this application.

结合本申请实施例公开内容所描述的方法或者算法的步骤可以硬件的方式来实现,也可以是由处理器执行软件指令的方式来实现。软件指令可以由相应的软件模块组成,软件模块可以被存放于随机存取存储器(Random Access Memory,RAM)、闪存、只读存储器(Read Only Memory,ROM)、可擦除可编程只读存储器(Erasable Programmable ROM,EPROM)、电可擦可编程只读存储器(Electrically EPROM,EEPROM)、寄存器、硬盘、移动硬盘、只读光盘(CD-ROM)或者本领域熟知的任何其它形式的存储介质中。一种示例性的存储介质耦合至处理器,从而使处理器能够从该存储介质读取信息,且可向该存储介质写入信息。当然,存储介质也可以是处理器的组成部分。The steps of the methods or algorithms described in connection with the disclosure of the embodiments of this application can be implemented in hardware or by a processor executing software instructions. Software instructions can be composed of corresponding software modules. The software modules can be stored in random access memory (Random Access Memory, RAM), flash memory, read only memory (Read Only Memory, ROM), erasable programmable read only memory ( Erasable Programmable ROM (EPROM), Electrically Erasable Programmable Read-Only Memory (Electrically EPROM, EEPROM), register, hard disk, removable hard disk, CD-ROM or any other form of storage media well known in the art. An exemplary storage medium is coupled to the processor such that the processor can read information from the storage medium and write information to the storage medium. Of course, the storage medium can also be an integral part of the processor.

本领域技术人员应该可以意识到,在上述一个或多个示例中,本申请实施例所描述的功能可以用硬件、软件、固件或它们的任意组合来实现。当使用软件实现时,可以将这些功能存储在计算机可读介质中或者作为计算机可读介质上的一个或多个指令或代码进行传输。计算机可读介质包括计算机可读介质和通信介质,其中通信介质包括便于从一个地方向另一个地方传送计算机程序的任何介质。存储介质可以是通用或专用计算机能够存取的任何可用介质。Those skilled in the art should realize that in one or more of the above examples, the functions described in the embodiments of the present application can be implemented using hardware, software, firmware, or any combination thereof. When implemented using software, the functions may be stored on or transmitted over as one or more instructions or code on a computer-readable medium. Computer-readable media includes both computer-readable media and communication media including any medium that facilitates transfer of a computer program from one place to another. Storage media can be any available media that can be accessed by a general purpose or special purpose computer.

以上所述,以上实施例仅用以说明本申请的技术方案,而非对其限制;尽管参照前述实施例对本申请进行了详细的说明,本领域的普通技术人员应当理解:其依然可以对前述各实施例所记载的技术方案进行修改,或者对其中部分技术特征进行等同替换;而这些修改或者替换,并不使相应技术方案的本质脱离本申请各实施例技术方案的范围。As mentioned above, the above embodiments are only used to illustrate the technical solution of the present application, but not to limit it. Although the present application has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that they can still make the foregoing technical solutions. The technical solutions described in each embodiment may be modified, or some of the technical features may be equivalently replaced; however, these modifications or substitutions do not cause the essence of the corresponding technical solutions to depart from the scope of the technical solutions in each embodiment of the present application.

Claims (10)

1. A method for handling an up-slip effect exception, the method comprising:
receiving a first sliding operation on a first display interface, wherein the first display interface is indicated as an application program page;
displaying a movement effect entering a multitasking mode in response to the first up-sliding operation;
in the process of displaying the dynamic effect entering the multitasking, responding to a second sliding operation, and triggering a preset processing flow;
after the execution of the preset processing flow is completed, displaying a desktop;
the preset processing flow comprises the following steps:
modifying the value of the current active operation flag bit before executing the action of clearing all states; after the value of the current active effect operation flag bit is modified, when the action of clearing all states is executed, the process of canceling the current active effect is not triggered.
2. The method of claim 1, wherein modifying the value of the current active run flag bit before performing the act of clearing all states comprises:
the value of the current active run flag bit is modified before the act of clearing the snoop state is performed.
3. The method according to claim 1 or 2, wherein said modifying the value of the current active run flag bit comprises:
and modifying the value of the current active operation zone bit to be a first value.
4. The method of claim 1, wherein displaying a move-on effect into a multitasking in response to the first slide-up operation comprises:
the input management module converts the received first sliding operation into a first touch event;
the input management module distributes the first touch event to a touch interaction management module;
the touch interaction management module sends the first touch event to a corresponding gesture processing module under the condition that the first touch event is determined to be triggered in a gesture navigation hot zone;
the gesture processing module triggers a view system to display the dynamic effect entering the multi-task based on the first touch event.
5. The method of claim 4, wherein the first touch event is indicated as any one of a down event, a move event, and an up event, wherein the gesture processing module triggers a view system to display the action to enter multitasking based on the first touch event, comprising:
and when the gesture processing module indicates that the first touch event is an up event, triggering a view system to display the dynamic effect entering the multitasking.
6. The method of claim 5, wherein the gesture processing module, based on the first touch event, further comprises, prior to triggering a view system to display the action to enter multitasking:
and when the first touch event is indicated to be the move event, the gesture processing module modifies the value of the current active operation zone bit into a second value.
7. The method of claim 1, wherein triggering the preset process flow in response to the second slide up operation comprises:
the input management module converts the second sliding operation into a second touch event;
the input management module distributes the second touch event to a touch interaction management module;
The touch interaction management module sends the second touch event to the corresponding gesture processing module under the condition that the second touch event is determined to be triggered in the gesture navigation hot zone;
the gesture processing module sends a state clearing instruction to the sliding sharing state module based on the second touch event;
the sliding shared state module is used for responding to the state clearing instruction, modifying the value of the current active operation zone bit and executing the action of clearing all states.
8. The method of claim 1, wherein the first up-slide operation is indicated as an operation of sliding up and pausing from a bottom edge of the screen;
the second up-slide operation is indicated as an operation of sliding upward from the bottom edge of the screen.
9. An electronic device, the electronic device comprising:
one or more processors;
a memory;
and a computer program, wherein the computer program is stored on the memory, which when executed by the one or more processors, causes the electronic device to perform the up-slip effect exception handling method of any one of claims 1-8.
10. A computer storage medium comprising computer instructions which, when executed on an electronic device, cause the electronic device to perform the up-slip effect exception handling method of any one of claims 1 to 8.
CN202311265723.XA 2023-09-28 2023-09-28 A method for handling exceptions in upward sliding effects and electronic equipment Active CN116991274B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202311265723.XA CN116991274B (en) 2023-09-28 2023-09-28 A method for handling exceptions in upward sliding effects and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202311265723.XA CN116991274B (en) 2023-09-28 2023-09-28 A method for handling exceptions in upward sliding effects and electronic equipment

Publications (2)

Publication Number Publication Date
CN116991274A true CN116991274A (en) 2023-11-03
CN116991274B CN116991274B (en) 2023-12-19

Family

ID=88528751

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202311265723.XA Active CN116991274B (en) 2023-09-28 2023-09-28 A method for handling exceptions in upward sliding effects and electronic equipment

Country Status (1)

Country Link
CN (1) CN116991274B (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN118885098A (en) * 2024-09-18 2024-11-01 荣耀终端有限公司 Camera control method, electronic device, chip system and readable storage medium
CN119127020A (en) * 2024-09-14 2024-12-13 荣耀终端有限公司 A dynamic effect display method and electronic device
CN119396505A (en) * 2024-09-26 2025-02-07 荣耀终端有限公司 Interface switching method, device, storage medium and program product

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20090216341A1 (en) * 2005-04-01 2009-08-27 Abb Research Ltd. Method and System for Providing a User Interface
CN101930339A (en) * 2010-08-11 2010-12-29 惠州Tcl移动通信有限公司 Method for switching interface of electronic equipment and device thereof
CN114518817A (en) * 2022-01-10 2022-05-20 荣耀终端有限公司 Display method, electronic equipment and storage medium

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20090216341A1 (en) * 2005-04-01 2009-08-27 Abb Research Ltd. Method and System for Providing a User Interface
CN101930339A (en) * 2010-08-11 2010-12-29 惠州Tcl移动通信有限公司 Method for switching interface of electronic equipment and device thereof
CN114518817A (en) * 2022-01-10 2022-05-20 荣耀终端有限公司 Display method, electronic equipment and storage medium
CN116501210A (en) * 2022-01-10 2023-07-28 荣耀终端有限公司 A display method, electronic device and storage medium

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN119127020A (en) * 2024-09-14 2024-12-13 荣耀终端有限公司 A dynamic effect display method and electronic device
CN119127020B (en) * 2024-09-14 2025-11-25 荣耀终端股份有限公司 A method and electronic device for displaying animation effects
CN118885098A (en) * 2024-09-18 2024-11-01 荣耀终端有限公司 Camera control method, electronic device, chip system and readable storage medium
CN118885098B (en) * 2024-09-18 2025-01-24 荣耀终端有限公司 Camera control method, electronic device, chip system and readable storage medium
CN119396505A (en) * 2024-09-26 2025-02-07 荣耀终端有限公司 Interface switching method, device, storage medium and program product

Also Published As

Publication number Publication date
CN116991274B (en) 2023-12-19

Similar Documents

Publication Publication Date Title
EP4131911B1 (en) Application interface interaction method, electronic device, and computer readable storage medium
KR102470275B1 (en) Voice control method and electronic device
JP7081048B2 (en) System navigation bar display method, system navigation bar control method, graphical user interface, and electronic devices
EP4027628B1 (en) Control method for electronic device, and electronic device
EP4012544B1 (en) Split-screen processing method and terminal device
WO2021017889A1 (en) Display method of video call appliced to electronic device and related apparatus
US20200249821A1 (en) Notification Handling Method and Electronic Device
WO2021103981A1 (en) Split-screen display processing method and apparatus, and electronic device
CN110825469A (en) Voice assistant display method and device
CN111176506A (en) Screen display method and electronic equipment
WO2021000881A1 (en) Screen splitting method and electronic device
CN110798552A (en) A kind of volume adjustment method and electronic device
US12216899B2 (en) Display element display method and electronic device
US20220244846A1 (en) User Interface Display Method and Electronic Device
WO2021190524A1 (en) Screenshot processing method, graphic user interface and terminal
CN116991274B (en) A method for handling exceptions in upward sliding effects and electronic equipment
JP2022501739A (en) Stylus pen detection method, system and related equipment
CN116048358B (en) Control methods and related devices for suspended balls
CN113746961A (en) Display control method, electronic device, and computer-readable storage medium
CN110471604A (en) A multi-application switching method and related device
CN118444832A (en) Touch operation method and electronic equipment
WO2024139257A1 (en) Method for displaying interfaces of application programs and electronic device
WO2024012346A1 (en) Task migration method, electronic device, and system

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
CP03 Change of name, title or address
CP03 Change of name, title or address

Address after: Unit 3401, unit a, building 6, Shenye Zhongcheng, No. 8089, Hongli West Road, Donghai community, Xiangmihu street, Futian District, Shenzhen, Guangdong 518040

Patentee after: Honor Terminal Co.,Ltd.

Country or region after: China

Address before: 3401, unit a, building 6, Shenye Zhongcheng, No. 8089, Hongli West Road, Donghai community, Xiangmihu street, Futian District, Shenzhen, Guangdong

Patentee before: Honor Device Co.,Ltd.

Country or region before: China