Method, device and equipment for deleting list items and storage medium
By displaying a pop-up window confirming deletion after sliding operation in the terminal device, the problem of false deletion caused by false operation in convenient operation is solved, the security of operation is improved and excessive consumption of system resources is avoided.
Patent Information
- Application Number
- CN202411921044.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2021-12-29
- Publication Date
- 2025-04-22
AI Technical Summary
In terminal devices, when convenient operation such as sliding deletion function, error deletion caused by user error is prone to occur. How to avoid such errors has become an urgent problem to be solved.
By displaying the first interface and detecting the sliding operation of the target list entry, a sliding box corresponding to the target list entry is displayed in response to the sliding operation, while hiding a part of the list box. After the sliding operation is completed, a second interface is displayed after the preset time interval is made. The second interface includes a pop-up window and controls for indicating deletion, requiring the user to confirm the deletion operation.
It effectively avoids the misdeletion caused by misoperation in convenient operations, and at the same time avoids excessive system resource consumption caused by sliding dynamic effects and pop-up windows, thereby avoiding frame drops.
Smart Images

Figure CN119861849A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of terminals, and more specifically, to a method, apparatus, device and storage medium for deleting list entries. Background Art
[0002] As the functions of terminal devices become more and more abundant, terminal devices can perform various complex operations. In order to improve the convenience of user operation, convenient operations are usually used on terminal devices to implement corresponding functions, that is, to implement functions implemented by a series of complex operations through one operation.
[0003] For example, the function of deleting text messages can be realized by sliding left, that is, sliding the text message to be deleted to the left, and directly deleting the text message to be deleted when the sliding distance is greater than a threshold. However, the use of the above convenient operation to realize the function of deleting text messages is prone to accidental deletion due to user misoperation.
[0004] Based on this, how to avoid misoperation of convenient operations has become an urgent problem to be solved. Summary of the invention
[0005] The present application provides a list entry method, apparatus, device and storage medium, which can avoid misoperation of convenient operations.
[0006] In a first aspect, a method for deleting a list entry is provided, comprising:
[0007] Displaying a first interface, the first interface including at least one list item;
[0008] A first operation on a target list entry is detected at time T0, where the target list entry is any one of the at least one list entry; the target list entry is located in the list box;
[0009] In response to the first operation at time T1, a sliding box corresponding to the target list item is displayed, and a portion of the list box is hidden, so that the sliding box and the adjacent borders of the list box overlap;
[0010] The completion of the first operation is detected at time T2. After a preset time, the second interface is displayed at time T3. The second interface includes a first pop-up window. The first pop-up window includes a first control. The first control is used to indicate deletion of the target list entry.
[0011] For ease of understanding, the first operation is a sliding operation. It should be understood that the T0 moment may refer to the moment when the user touches the display screen, and the T1 moment may refer to the moment when the first interface starts to display the sliding frame. The T2 moment may be the moment when the user raises his hand. The T3 moment may be the moment after the user raises his hand for a preset time. That is, T3 is later than T2, T2 is later than T1, and T1 is later than T0.
[0012] The first interface may refer to an interface that displays data in a list format. The second interface may refer to an interface that adds a first pop-up window based on the first interface.
[0013] In an embodiment of the present application, by displaying the first interface, and detecting the first operation on the target list item at time T0, in response to the first operation at time T1, a sliding box corresponding to the target list item is displayed, and a part of the list box is hidden, and the first operation is detected to be completed at time T2, and after a preset time interval, the second interface is displayed at time T3. Among them, the first interface includes at least one list item, the target list item is any one of the at least one list item, the target list item is located in the list box, and the sliding box coincides with the adjacent boundary of the list box, and the second interface includes a first pop-up window, and the first pop-up window includes a first control, and the first control is used to indicate the deletion of the target list item. This is equivalent to adding the operation of the first control on the second interface in the process of directly deleting the target list item through the first operation, thereby avoiding the situation of accidental deletion caused by misoperation when deleting the target list item in a convenient way. Furthermore, since the pop-up window consumes system resources, the dynamic effect of sliding will also consume system resources. If both are executed at the same time, the dynamic effect of sliding will be affected, resulting in frame loss. In an embodiment of the present application, the completion of the first operation is detected at time T2, and after a preset time interval, the second interface is displayed at time T3, thereby avoiding excessive consumption of system resources caused by simultaneously executing the dynamic effect of sliding and popping up the first pop-up window, and further avoiding frame loss.
[0014] In one embodiment, the first operation is a sliding operation, and a sliding distance of the sliding operation is greater than and equal to a preset threshold.
[0015] It should be understood that when the first operation is a sliding operation, the sliding distance of the sliding operation is greater than and equal to the preset threshold, which generally means that the current first operation completes the preset action. Exemplarily, when the first operation is used to delete a target list item, when the sliding distance of the sliding operation is greater than and equal to the preset threshold, it means that the current operation reaches the sliding distance required to delete the target list item.
[0016] In the embodiment of the present application, the first operation is a sliding operation, and the sliding distance of the sliding operation is greater than and equal to a preset threshold. In other words, the first operation is a simple sliding operation, and the user can implement the corresponding deletion function through a simple sliding operation, thereby improving the convenience of using the electronic device.
[0017] In one embodiment, the sliding box includes a delete icon, and the delete icon includes a first delete graphic and a second delete graphic. At time T1, the angle between the first delete graphic and the second delete graphic is 0.
[0018] It should be understood that the first deletion graphic may refer to the lid of the trash can, and the second deletion graphic may refer to the body of the trash can. At time T1, the angle between the first deletion graphic and the second deletion graphic is 0, which is equivalent to the deletion icon displayed on the sliding box as "a trash can with an open lid" at time T1.
[0019] In one embodiment, after responding to the first operation at time T1, the method also includes: elastically stretching the length of the sliding box; when the length of the sliding box does not reach a preset threshold, the position of the deletion icon moves as the length of the sliding box increases; as the length of the sliding box increases, the angle between the first deletion graphic and the second deletion graphic increases as the first deletion graphic rotates around the rotation axis, and the second deletion graphic remains stationary; when the length of the sliding box reaches or exceeds a preset threshold, the position of the deletion icon moves toward the center of the sliding box, the size of the deletion icon increases, and the angle between the first deletion graphic and the second deletion graphic remains unchanged.
[0020] It should be understood that as the sliding operation continues, the length of the sliding box stretches elastically. When the length of the sliding box does not reach the preset threshold, the position of the delete icon moves as the length of the sliding box increases; as the length of the sliding box increases, the angle between the first deletion graphic and the second deletion graphic increases as the first deletion graphic rotates around the rotation axis, and the second deletion graphic remains stationary. This is equivalent to the lid of the trash can gradually opening as the sliding operation proceeds.
[0021] Furthermore, when the length of the sliding box reaches or exceeds a preset threshold, the position of the delete icon moves toward the center of the sliding box, the size of the delete icon increases, and the angle between the first delete graphic and the second delete graphic remains unchanged. In one possible case, when the length of the sliding box reaches or exceeds a preset threshold, the angle between the first delete graphic and the second delete graphic can reach 60°, which is equivalent to the displayed delete icon being a "trash can with an open lid".
[0022] In an embodiment of the present application, in response to a first operation, the length of the sliding box is elastically stretched; when the length of the sliding box does not reach a preset threshold, the position of the delete icon moves as the length of the sliding box increases; as the length of the sliding box increases, the angle between the first delete graphic and the second delete graphic increases as the first delete graphic rotates around the rotation axis, and the second delete graphic remains stationary; when the length of the sliding box reaches or exceeds a preset threshold, the position of the delete icon moves toward the center of the sliding box, the size of the delete icon increases, and the angle between the first delete graphic and the second delete graphic remains unchanged. By displaying the delete icon to the user through the above operation, the user's interest in using the first operation to implement the function of the electronic device can be increased.
[0023] In one embodiment, the first pop-up window further includes a second control, which is used to cancel the deletion of the target list entry; the method further includes: detecting a second operation on the second control, the second operation refers to a touch operation on the second control; in response to the second operation, displaying the target list entry in the list box.
[0024] In an embodiment of the present application, after the user performs a second operation on the second control on the first pop-up window, the target list item is displayed in response to the second operation, which is equivalent to providing the user with an option to cancel the deletion of the target list item, further avoiding the situation where the target list item is accidentally deleted due to an erroneous operation when deleting the target list item in a convenient manner. Furthermore, in the process of canceling the deletion of the target list item, the second dynamic effect can be used to vividly show the user the process of canceling the deletion, thereby improving the user experience.
[0025] In one embodiment, the first operation is a sliding operation, and a sliding distance of the sliding operation is less than a preset threshold.
[0026] It should be understood that when the first operation is a sliding operation, the sliding distance of the sliding operation is less than the preset threshold, which generally means that the current first operation has not completed the preset action. Exemplarily, when the first operation is used to delete a target list item, when the sliding distance of the sliding operation is less than the preset threshold, it means that the current operation has not reached the sliding distance required to delete the target list item.
[0027] In an embodiment of the present application, by displaying a first interface, a sliding operation on a target list item whose sliding distance is less than a preset threshold is detected, and in response to the sliding operation, a second interface is displayed. The first interface includes at least one list item, and the target list item is any one of the at least one list item. The second interface includes a first pop-up window, and the first pop-up window includes a first control, and the first control is used to indicate the deletion of the target list item. With the trend of larger screens of electronic devices, it is difficult for users to complete the sliding operation on the screen with one hand, and it is impossible to more conveniently implement the function corresponding to the sliding operation. By popping up the first pop-up window, the user can perform a second operation on the first pop-up window to implement the function corresponding to the sliding operation.
[0028] In one embodiment, the above-mentioned detecting the completion of the first operation at time T2 and displaying the second interface at time T3 after a preset time period includes: detecting the completion of the first operation at time T2 and displaying the second interface through the list management module in the front-end framework UIkit after a preset time period, the first instruction is used to instruct the display of the second interface, and the list management module is used to manage the list where at least one list entry is located; the target application responds to the first instruction and displays the second interface at time T3.
[0029] In the embodiment of the present application, the target application displays a first interface and detects a first operation on a target list item. In response to the first operation, a first instruction is sent to the target application through a list management module in the front-end framework UIkit. The target application displays a second interface in response to the first instruction. That is to say, in the embodiment of the present application, the function of popping up the first pop-up window during the process of deleting the target list item can be realized by directly calling the module in UIkit, which improves the convenience of realizing the function of deleting list items during the process of developing App.
[0030] In one embodiment, the above elastically stretches the length of the sliding box; when the length of the sliding box does not reach a preset threshold, the position of the delete icon moves as the length of the sliding box increases; as the length of the sliding box increases, the angle between the first delete graphic and the second delete graphic increases as the first delete graphic rotates around the rotation axis, and the second delete graphic remains fixed; when the length of the sliding box reaches or exceeds the preset threshold, the position of the delete icon moves toward the center of the sliding box, the size of the delete icon increases, and the angle between the first delete graphic and the second delete graphic remains unchanged, including: the list management module in the front-end framework UIkit calls the animation module in UIkit, and elastically stretches the length of the sliding box through the animation module; when the length of the sliding box does not reach the preset threshold, the position of the delete icon moves as the length of the sliding box increases; as the length of the sliding box increases, the angle between the first delete graphic and the second delete graphic increases as the first delete graphic rotates around the rotation axis, and the second delete graphic remains fixed; when the length of the sliding box reaches or exceeds the preset threshold, the position of the delete icon moves toward the center of the sliding box, the size of the delete icon increases, and the angle between the first delete graphic and the second delete graphic remains unchanged.
[0031] In an embodiment of the present application, the animation module is called through the list management module, and the length of the sliding box is elastically stretched through the animation module; when the length of the sliding box does not reach the preset threshold, the position of the deletion icon moves as the length of the sliding box increases; as the length of the sliding box increases, the angle between the first deletion graphic and the second deletion graphic increases as the first deletion graphic rotates around the rotation axis, and the second deletion graphic remains stationary; when the length of the sliding box reaches or exceeds the preset threshold, the position of the deletion icon moves toward the center of the sliding box, the size of the deletion icon becomes larger, and the angle between the first deletion graphic and the second deletion graphic remains unchanged, so that the dynamic effect in the process of deleting the target list items is realized through the animation module in UIkit, which improves the convenience of realizing the dynamic effect in the process of deleting the target list items in the process of developing App.
[0032] In one embodiment, the above-mentioned displaying the target list items in the list box in response to the second operation includes: in response to the user's second operation, calling the animation module in the front-end framework UIkit, the animation module is used to display the target list items in the list box through preset dynamic effects.
[0033] In an embodiment of the present application, the list management module calls the animation module to display the target list items through the second dynamic effect, so that the dynamic effect in the process of restoring the display of the target list bar is realized through the animation module in UIkit, thereby improving the convenience of realizing the function of restoring the dynamic effect in the process of displaying the target list bar during the development of the App.
[0034] In one embodiment, the method also includes: in response to the first operation, the target application sends the coordinate information of the first operation to the list management module; the list management module sends the coordinate information to the entry management module in UIkit; the entry management module determines the target list entry corresponding to the first operation based on the coordinate information.
[0035] In an embodiment of the present application, in response to a sliding operation, the target application sends the coordinate information of the sliding operation to the list management module, the list management module sends the coordinate information to the entry management module, and the entry management module determines the target list entry corresponding to the sliding operation based on the coordinate information. In other words, the target list entry can be accurately determined through the module in UIkit, so that in the process of developing the App, the module in UIkit can be directly called to implement the function of determining the object of the sliding operation.
[0036] In a second aspect, a device for deleting a list entry is provided, comprising a unit for executing any one of the methods in the first aspect. The device may be a terminal device or a chip in the terminal device. The device may include an input unit and a processing unit.
[0037] When the device is a terminal device, the processing unit may be a processor, and the input unit may be a communication interface; the terminal device may also include a memory, which is used to store computer program code. When the processor executes the computer program code stored in the memory, the terminal device executes any one of the methods in the first aspect.
[0038] When the device is a chip in a terminal device, the processing unit may be a processing unit inside the chip, and the input unit may be an output interface, a pin or a circuit, etc.; the chip may also include a memory, which may be a memory inside the chip (for example, a register, a cache, etc.) or a memory located outside the chip (for example, a read-only memory, a random access memory, etc.); the memory is used to store computer program code, and when the processor executes the computer program code stored in the memory, the chip executes any one of the methods in the first aspect or the second aspect.
[0039] In one possible implementation, a memory is used to store computer program code; a processor executes the computer program code stored in the memory, and when the computer program code stored in the memory is executed, the processor is used to perform: displaying a first interface, the first interface includes at least one list entry; detecting a first operation on a target list entry at time T0, the target list entry is any one of the at least one list entry; the target list entry is located in a list box; in response to the first operation at time T1, displaying a sliding box corresponding to the target list entry, and hiding a part of the list box, the sliding box and the list box adjacent The border coincides; detecting the completion of the first operation at time T2, and after a preset time interval, displaying a second interface at time T3, the second interface includes a first pop-up window, the first pop-up window includes a first control, and the first control is used to indicate the deletion of the target list entry.
[0040] According to a third aspect, an electronic device is provided. The electronic device includes a processor, wherein the processor is coupled to a memory, reads instructions in the memory, and enables the electronic device to execute the method provided in the first aspect according to the instructions.
[0041] In a fourth aspect, a computer-readable storage medium is provided, wherein the computer-readable storage medium stores computer instructions, and when the computer instructions are executed on an electronic device, the electronic device executes the method provided in the first aspect.
[0042] In a fifth aspect, a chip is provided, the chip comprising a processor, the processor being used to couple with a memory and execute a computer program in the memory to perform the method provided in the first aspect.
[0043] In a sixth aspect, a computer program product comprising instructions is provided. When the computer program product is run on an electronic device, the electronic device executes the method provided in the first aspect. BRIEF DESCRIPTION OF THE DRAWINGS
[0044] Figure 1 is a schematic diagram of a hardware system of an electronic device applicable to the present application;
[0045] Figure 2is a schematic diagram of a software system for an electronic device applicable to the present application;
[0046] Figure 3 It is a schematic diagram of an application scenario provided by an embodiment of the present application;
[0047] Figure 4 is a flowchart of a method for deleting a list entry provided by an embodiment of the present application;
[0048] FIG5( a ) is a schematic diagram of an interface of a method for deleting a list entry provided in one embodiment of the present application;
[0049] FIG5( b ) is a schematic diagram of an interface of a method for deleting a list entry provided in an embodiment of the present application;
[0050] FIG5( c ) is a schematic diagram of an interface of a method for deleting a list entry provided by an embodiment of the present application;
[0051] FIG5( d ) is a schematic diagram of an interface of a method for deleting a list entry provided in one embodiment of the present application;
[0052] FIG5(e) is a schematic diagram of an interface of a method for deleting a list entry provided by an embodiment of the present application;
[0053] FIG5( f ) is a schematic diagram of an interface of a method for deleting a list entry provided by an embodiment of the present application;
[0054] Figure 6 It is a schematic diagram of an interface of a method for deleting list items at different times provided by an embodiment of the present application;
[0055] Figure 7 is a schematic diagram of an interface of a method for deleting a list entry provided by another embodiment of the present application;
[0056] Figure 8 is a schematic diagram of an interface of a method for deleting a list entry provided by another embodiment of the present application;
[0057] Fig. 9 is a flowchart of a method for deleting a list entry provided by another embodiment of the present application;
[0058] Fig.10 is a schematic diagram of an interface of a method for deleting a list entry provided by another embodiment of the present application;
[0059] Fig.11 is a flowchart of a method for deleting a list entry provided by another embodiment of the present application;
[0060] Fig.12 is a schematic diagram of a software system for an electronic device applicable to the present application;
[0061] Fig.13 is a schematic diagram of an interface of a method for deleting a list entry provided by another embodiment of the present application;
[0062] Fig.14 is a schematic diagram of a device for deleting list items provided by the present application;
[0063] Fig.15 It is a schematic diagram of an electronic device for deleting list items provided by the present application. DETAILED DESCRIPTION
[0064] The technical solutions in the embodiments of the present application will be described below in conjunction with the drawings in the embodiments of the present application. In the description of the embodiments of the present application, unless otherwise specified, " / " means or, for example, A / B can mean A or B; "and / or" in this article is only a description of the association relationship of associated objects, indicating that there can be three relationships, for example, A and / or B can mean: A exists alone, A and B exist at the same time, and B exists alone. In addition, in the description of the embodiments of the present application, "multiple" means two or more than two.
[0065] In the following, the terms "first", "second", and "third" are used for descriptive purposes only and are not to be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features. Thus, a feature defined as "first", "second", and "third" may explicitly or implicitly include one or more of the features.
[0066] The method for deleting list entries provided in the embodiment of the present application can be applied to electronic devices. Optionally, the electronic device 100 can be a mobile phone, a smart screen, a tablet computer, a wearable electronic device, an in-vehicle electronic device, an augmented reality (AR) device, a virtual reality (VR) device, a laptop computer, an ultra-mobile personal computer (UMPC), a netbook, a personal digital assistant (PDA), a projector, etc. The embodiment of the present application does not impose any restrictions on the specific type of the electronic device 100. Exemplarily, the electronic device 100 can be a terminal device.
[0067] For example, Figure 11 shows a schematic diagram of the structure of the electronic device 100. The electronic device 100 may include a processor 110, an external memory interface 120, an internal memory 121, a universal serial bus (USB) interface 130, a charging management module 140, a power management module 141, a battery 142, an antenna 1, an antenna 2, a mobile communication module 150, a wireless communication module 160, an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, an earphone interface 170D, a sensor module 180, a button 190, a motor 191, an indicator 192, a camera 193, a display screen 194, and a subscriber identification module (SIM) card interface 195. The sensor module 180 may include a pressure sensor 180A, a gyroscope sensor 180B, an air pressure sensor 180C, a magnetic sensor 180D, an acceleration sensor 180E, a distance sensor 180F, a proximity light sensor 180G, a fingerprint sensor 180H, a temperature sensor 180J, a touch sensor 180K, an ambient light sensor 180L, a bone conduction sensor 180M, etc.
[0068] It should be noted that Figure 1 The structure shown does not constitute a specific limitation on the electronic device 100. In other embodiments of the present application, the electronic device 100 may include Figure 1 More or fewer components than those shown, or the electronic device 100 may include Figure 1 Combinations of some of the components shown, or the electronic device 100 may include Figure 1 Subassemblies of some of the components shown. Figure 1 The components shown may be implemented in hardware, software, or a combination of software and hardware.
[0069] The processor 110 may include one or more processing units. For example, the processor 110 may include at least one of the following processing units: an application processor (AP), a modem processor, a graphics processing unit (GPU), an image signal processor (ISP), a controller, a video codec, a digital signal processor (DSP), a baseband processor, and a neural-network processing unit (NPU). Different processing units may be independent devices or integrated devices.
[0070] The controller can generate operation control signals according to the instruction operation code and timing signal to complete the control of instruction fetching and execution.
[0071] The processor 110 may also be provided with a memory for storing instructions and data. In some embodiments, the memory in the processor 110 is a cache memory. The memory may store instructions or data that the processor 110 has just used or cyclically used. If the processor 110 needs to use the instruction or data again, it may be directly called from the memory. This avoids repeated access, reduces the waiting time of the processor 110, and thus improves the efficiency of the system.
[0072] In some embodiments, the processor 110 may include one or more interfaces. For example, the processor 110 may include at least one of the following interfaces: an inter-integrated circuit (I2C) interface, an inter-integrated circuit sound (I2S) interface, a pulse code modulation (PCM) interface, a universal asynchronous receiver / transmitter (UART) interface, a mobile industry processor interface (MIPI), a general-purpose input / output (GPIO) interface, a SIM interface, and a USB interface.
[0073] The MIPI interface can be used to connect the processor 110 with peripheral devices such as the display screen 194 and the camera 193. The MIPI interface includes a camera serial interface (CSI), a display serial interface (DSI), etc. In some embodiments, the processor 110 and the camera 193 communicate through the CSI interface to realize the shooting function of the electronic device 100. The processor 110 and the display screen 194 communicate through the DSI interface to realize the display function of the electronic device 100. Exemplarily, an embodiment of the present application displays a first interface through the display screen 194. The processor 110 detects a first operation on a target list item and responds to the first operation. Then, the sliding box corresponding to the target list item is displayed through the display screen 194, and a part of the list box is hidden. Further, after the processor 110 detects that the first operation is completed and the preset time interval has passed, the second interface is displayed through the display screen 194.
[0074] The GPIO interface can be configured by software. The GPIO interface can be configured as a control signal interface or a data signal interface.
[0075] In some embodiments, the GPIO interface can be used to connect the processor 110 with the camera 193, the display screen 194, the wireless communication module 160, the audio module 170 and the sensor module 180. The GPIO interface can also be configured as an I2C interface, an I2S interface, a UART interface or a MIPI interface.
[0076] Figure 1 The connection relationship between the modules shown is only a schematic illustration and does not constitute a limitation on the connection relationship between the modules of the electronic device 100. Optionally, the modules of the electronic device 100 may also adopt a combination of multiple connection modes in the above embodiments.
[0077] The electronic device 100 can realize the display function through the GPU, the display screen 194 and the application processor. The GPU is a microprocessor for image processing, which connects the display screen 194 and the application processor. The GPU is used to perform mathematical and geometric calculations for graphics rendering. The processor 110 may include one or more GPUs, which execute program instructions to generate or change display information.
[0078] The display screen 194 can be used to display images or videos. The display screen 194 includes a display panel. The display panel can be a liquid crystal display (LCD), an organic light-emitting diode (OLED), an active-matrix organic light-emitting diode (AMOLED), a flexible light-emitting diode (FLED), a mini light-emitting diode (Mini LED), a micro light-emitting diode (Micro LED), a micro OLED (Micro OLED) or a quantum dot light emitting diode (QLED). In some embodiments, the electronic device 100 may include 1 or N display screens 194, where N is a positive integer greater than 1.
[0079] The electronic device 100 can realize the shooting function through the ISP, the camera 193, the video codec, the GPU, the display screen 194 and the application processor.
[0080] The ISP is used to process the data fed back by the camera 193. For example, when taking a photo, the shutter is opened, and the light is transmitted to the camera photosensitive element through the lens. The light signal is converted into an electrical signal, and the camera photosensitive element transmits the electrical signal to the ISP for processing and converts it into an image visible to the naked eye. The ISP can perform algorithm optimization on the noise, brightness and color of the image. The ISP can also optimize the exposure and color temperature of the shooting scene. In some embodiments, the ISP can be set in the camera 193.
[0081] The pressure sensor 180A is used to sense the pressure signal and can convert the pressure signal into an electrical signal. In some embodiments, the pressure sensor 180A can be set on the display screen 194. There are many types of pressure sensors 180A, for example, they can be resistive pressure sensors, inductive pressure sensors or capacitive pressure sensors. The capacitive pressure sensor can be a parallel plate including at least two conductive materials. When the force acts on the pressure sensor 180A, the capacitance between the electrodes changes, and the electronic device 100 determines the intensity of the pressure according to the change in capacitance. When the touch operation acts on the display screen 194, the electronic device 100 detects the touch operation according to the pressure sensor 180A. The electronic device 100 can also calculate the position of the touch according to the detection signal of the pressure sensor 180A. In some embodiments, touch operations acting on the same touch position but with different touch operation intensities can correspond to different operation instructions. For example: when a touch operation with a touch operation intensity less than the first pressure threshold acts on a 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 acts on a short message application icon, an instruction to create a new short message is executed.
[0082] The touch sensor 180K is also called a touch control device. The touch sensor 180K can be set on the display screen 194. The touch sensor 180K and the display screen 194 form a touch screen, which is also called a touch control screen. The touch sensor 180K is used to detect touch operations acting on or near it. The touch sensor 180K can pass the detected touch operation to the application processor to determine the type of touch event. Visual output related to the touch operation can be provided through the display screen 194. In other embodiments, the touch sensor 180K can also be set on the surface of the electronic device 100 and set at a different position from the display screen 194.
[0083] The hardware system of the electronic device 100 is described in detail above, and the software system of the electronic device 100 is introduced below. The software system can adopt a layered architecture, an event-driven architecture, a micro-core architecture, a micro-service architecture, or a cloud architecture. The embodiment of the present application takes the layered architecture as an example to exemplarily describe the software system of the electronic device 100.
[0084] like Figure 2As shown, the software system using a layered architecture is divided into several layers, each layer has a clear role and division of labor. The layers communicate with each other through software interfaces. In some embodiments, the software system can be divided into four layers, from top to bottom, namely, the application layer, the application framework layer, the Android runtime (Android Runtime) and the system library, and the kernel layer.
[0085] The application layer may include applications such as camera, gallery, calendar, call, map, navigation, WLAN, Bluetooth, music, video, short message, etc.
[0086] The application framework layer provides an application programming interface (API) and a programming framework for the applications in the application layer. The application framework layer may include some predefined functions.
[0087] For example, the application framework layer includes the window manager, content provider, view system, telephony manager, resource manager, and notification manager.
[0088] The window manager is used to manage window programs. The window manager can obtain the display screen size, determine whether there is a status bar, lock the screen, and capture the screen.
[0089] Content providers are used to store and retrieve data and make it accessible to applications. The data may include video, images, audio, calls made and received, browsing history and bookmarks, and phone books.
[0090] The view system includes visual controls, such as controls for displaying text and controls for displaying images. The view system can be used to build applications. A display interface can be composed of one or more views. For example, a display interface including a text notification icon can include a view for displaying text and a view for displaying images.
[0091] The phone manager is used to provide communication functions of the electronic device 100, such as management of call status (connected or hung up).
[0092] The resource manager provides various resources for applications, such as localized strings, icons, images, layout files, and video files.
[0093] The notification manager enables applications to display notification information in the status bar. It can be used to convey notification-type messages and can disappear automatically after a short stay without user interaction. For example, the notification manager is used for download completion notifications and message reminders. The notification manager can also manage notifications that appear in the system's top status bar in the form of icons or scrolling text, such as notifications from applications running in the background. The notification manager can also manage notifications that appear on the screen in the form of dialog windows, such as prompting text messages in the status bar, emitting reminder sounds, vibrating electronic devices, and flashing indicator lights.
[0094] Android Runtime includes core libraries and virtual machines. Android runtime is responsible for scheduling and management of the Android system.
[0095] The core library consists of two parts: one part is the function that needs to be called by the Java language, and the other part is the Android core library.
[0096] The application layer and the application framework layer run in the virtual machine. The virtual machine executes the Java files of the application layer and the application framework layer as binary files. The virtual machine is used to perform functions such as object life cycle management, stack management, thread management, security and exception management, and garbage collection.
[0097] The system library may include multiple functional modules, such as: surface manager, media library, 3D graphics processing library (such as open graphics library for embedded systems (OpenGL ES)) and 2D graphics engine (such as skia graphics library (SGL)).
[0098] The surface manager is used to manage the display subsystem and provide the fusion of 2D layers and 3D layers for multiple applications.
[0099] The media library supports playback and recording of multiple audio formats, playback and recording of multiple video formats, and still image files. The media library can support multiple audio and video coding formats, such as: MPEG4, H.264, moving picture experts group audio layer III (MP3), advanced audio coding (AAC), adaptive multi-rate (AMR), joint photographic experts group (JPG) and portable network graphics (PNG).
[0100] The 3D graphics processing library can be used to implement 3D graphics drawing, image rendering, compositing and layer processing.
[0101] A 2D graphics engine is a drawing engine for 2D drawings.
[0102] The kernel layer is the layer between hardware and software. The kernel layer can include driver modules such as display driver, camera driver, audio driver and sensor driver.
[0103] The application scenarios of the embodiments of the present application are briefly described below.
[0104] When using a terminal device, a user may need to delete an item in a list. For example, when using a mobile phone, a user needs to delete a text message in a text message list, such as Figure 3 Or, if you need to delete an alarm in the alarm list, Figure 3 As shown in (b) in FIG. 1 , the user can delete the text message by sliding the text message to the left. Similarly, the user can delete the alarm by sliding the alarm to the left.
[0105] In one possible case, the user mistakenly slides to the left a text message that he does not want to delete. At this time, a pop-up window 1000 may pop up on the display interface of the mobile phone, such as Figure 3 As shown in (c) in FIG. 1 , the user can delete the text message by clicking the delete button 1100 on the pop-up window, or cancel the deletion of the text message by clicking the cancel button 1200 on the pop-up window.
[0106] The following will be combined Figures 4 to 12 The method for deleting list entries provided in the embodiment of the present application is described in detail.
[0107] Figure 4 A flowchart of a method for deleting a list entry provided in one embodiment of the present application is shown in FIG. Figure 4 As shown, the method includes:
[0108] S101. An electronic device displays a first interface, where the first interface includes at least one list entry (or referred to as a list message, entry, or item, etc.).
[0109] With the emergence of various apps, lists, as an important form of data display, are widely used in various apps. Displaying data such as text and pictures in the form of a list makes it easier for users to browse. For example, the short message display function is to display multiple short messages in the form of a list on the SMS interface for users to browse. The alarm setting function is to display multiple set alarm times in the form of a list on the alarm setting interface for users to choose the appropriate time. In other words, the list may include one or more list items. Among them, a list item refers to each piece of data displayed in a list. For example, a list item may refer to a text message in a list displaying short messages, or an alarm time on a list displaying alarm settings.
[0110] The first interface may be an interface for displaying the above-mentioned list items. The first interface includes at least one list item. For example, the first interface may be a short message display interface as shown in FIG. 5( a ), wherein the short message display interface includes a list 500, and the list 500 includes three list items corresponding to three short messages.
[0111] S102: The electronic device detects a first operation on a target list item at time T0, where the target list item is any one of at least one list item, and the target list item is located in a list box.
[0112] When the first interface is displayed, the user can perform a first operation on the target list item on the first interface to delete the list item. The target list item may refer to any one of the at least one list item displayed on the first interface, such as the first short message in FIG5(a).
[0113] The first operation can be used to delete the target list item, which can be an operation that satisfies a preset condition. For example, the first operation can be a sliding operation of sliding to the left, and the sliding distance of the sliding operation is greater than a preset threshold; the first operation can also be a sliding operation of sliding to the right, and the sliding speed of the sliding operation is greater than a second preset threshold. The embodiment of the present application is not limited to this.
[0114] In a possible case, optionally, the first operation refers to a sliding operation, and a sliding distance of the sliding operation is greater than and equal to a preset threshold.
[0115] Among them, the preset threshold value can be 2 / 3 of the total length of the screen, or a specific value, which is not limited in the embodiments of the present application. For example, as shown in Figure 5(b), the first operation is a sliding operation to the left, and the preset threshold value refers to 2 / 3 of the total length of the screen. When it is detected that the sliding distance of the sliding operation to the left exceeds 2 / 3 of the total length of the screen of the electronic device, the electronic device can determine that the sliding operation to the left is the first operation.
[0116] It should be understood that the sliding distance of the sliding operation is greater than and equal to the preset threshold, which may mean that the total length of the sliding operation exceeds the preset threshold, or that the position where the sliding operation finally stops exceeds the preset threshold (for example, 2 / 3 of the total length of the screen of the electronic device), or that the distance that the list item moves as the sliding operation moves exceeds the preset threshold. The embodiments of the present application do not limit this.
[0117] In the embodiment of the present application, the first operation refers to a sliding operation, and the sliding distance / sliding speed of the sliding operation is greater than and equal to a preset threshold. In other words, the first operation is a simple sliding operation, and the user can implement the corresponding deletion function through a simple sliding operation, thereby improving the convenience of using the electronic device.
[0118] S103: The electronic device responds to the first operation at time T1 by displaying a sliding box corresponding to the target list item and hiding a portion of the list box, with the sliding box and the adjacent borders of the list box overlapping.
[0119] The target list entry is located in a list box of the first interface. When the first operation is a sliding operation, after the electronic device detects the first operation, it displays a sliding box corresponding to the target list entry in response to the first operation, and hides a portion of the list box, so that the sliding box overlaps with the adjacent border of the list box.
[0120] For example, as shown in FIG5(c), in response to a leftward sliding operation (first operation), the list box 10A of the first item (i.e., the thumbnail of the first short message) on the first interface moves to the left as the sliding operation moves, that is, the list box is shortened, which is equivalent to hiding a part of the list box 10A. At the same time, the sliding box 10B corresponding to the target list item is displayed. The adjacent boundaries of the list box 10A and the sliding box 10B overlap.
[0121] In a possible case, optionally, the sliding box includes a deletion icon, the deletion icon includes a first deletion graphic and a second deletion graphic, and at time T1, an angle between the first deletion graphic and the second deletion graphic is 0.
[0122] Continuing as shown in FIG. 5( c ), the sliding frame 10B includes a delete icon 110, and the delete icon 110 includes a first delete graphic 111 and a second delete graphic 112. As shown in FIG. 5( c ), the first delete graphic 111 may refer to the lid of the trash can, and the second delete graphic 112 may refer to the body of the trash can. At time T1, the angle between the first delete graphic 111 and the second delete graphic 112 is 0, which is equivalent to the delete icon 110 displayed on the sliding frame 10B as a "trash can with an open lid" at time T1.
[0123] In one possible case, optionally, as the sliding operation continues, the length of the sliding box 10B is elastically stretched; when the length of the sliding box 10B does not reach a preset threshold, the position of the delete icon 110 moves as the length of the sliding box 10B increases; as the length of the sliding box 110 increases, the angle between the first deletion graphic 111 and the second deletion graphic 112 increases as the first deletion graphic 111 rotates around the rotation axis, and the second deletion graphic 112 remains stationary; when the length of the sliding box 10B reaches or exceeds a preset threshold, the position of the delete icon 110 moves toward the center of the sliding box, the size of the delete icon 110 increases, and the angle between the first deletion graphic 111 and the second deletion graphic 112 remains unchanged.
[0124] Exemplarily, as shown in FIG5(d), compared with time T1, the length of the sliding box 10B is elastically stretched with the sliding operation. When the length of the sliding box 10B does not reach the preset threshold, the position of the deletion icon 110 moves as the length of the sliding box 10B increases; as the length of the sliding box 110 increases, the angle between the first deletion graphic 111 and the second deletion graphic 112 increases as the first deletion graphic 111 rotates around the rotation axis, and the second deletion graphic 112 remains stationary. This is equivalent to the lid of the trash can gradually opening with the sliding operation.
[0125] Further, as shown in FIG. 5( e ), when the length of the sliding box 10B reaches or exceeds the preset threshold, the position of the delete icon 110 moves toward the center of the sliding box, the size of the delete icon 110 increases, and the angle between the first delete graphic 111 and the second delete graphic 112 remains unchanged. In one possible case, when the length of the sliding box 10B reaches or exceeds the preset threshold, the angle between the first delete graphic 111 and the second delete graphic 112 can reach 60°, which is equivalent to the displayed delete icon 110 being a "trash can with an open lid".
[0126] In an embodiment of the present application, in response to a first operation, the length of the sliding box is elastically stretched; when the length of the sliding box does not reach a preset threshold, the position of the delete icon moves as the length of the sliding box increases; as the length of the sliding box increases, the angle between the first delete graphic and the second delete graphic increases as the first delete graphic rotates around the rotation axis, and the second delete graphic remains stationary; when the length of the sliding box reaches or exceeds a preset threshold, the position of the delete icon moves toward the center of the sliding box, the size of the delete icon increases, and the angle between the first delete graphic and the second delete graphic remains unchanged. By displaying the delete icon to the user through the above operation, the user's interest in using the first operation to implement the function of the electronic device can be increased.
[0127] S104. The electronic device detects that the first operation is completed at time T2, and after a preset time interval, displays a second interface at time T3, where the second interface includes a first pop-up window, and the first pop-up window includes a first control, and the first control is used to indicate deletion of the target list entry.
[0128] After the first operation on the target list item is detected, in response to the first operation, a second interface including a first pop-up window is displayed. Exemplarily, the second interface may be as shown in FIG. 5( f ), where a first pop-up window 1000 is added to the original first interface, and the first pop-up window 1000 includes a first control 1100. The first control is used to indicate the deletion of the target list item.
[0129] It should be understood that the T2 moment refers to the moment when the sliding operation is completed, that is, the moment when the user raises his hand, and does not correspond to the moment when the length of the sliding box reaches the preset threshold. In other words, after the user's sliding distance reaches the preset threshold, the user can continue to slide to the left. In the embodiment of the present application, when the user completes the first operation, after the preset time interval, when the T3 moment is reached, the second interface is displayed. This is equivalent to displaying the second interface after the dynamic effect of sliding is executed. Since pop-up windows consume system resources, executing the dynamic effect of sliding will also consume system resources. If both are executed at the same time, it will affect the dynamic effect of sliding and cause frame loss. Therefore, when the user completes the first operation, after the preset time interval, when the T3 moment is reached, the second interface is displayed.
[0130] In an embodiment of the present application, a first interface is displayed, and a first operation on a target list entry is detected at time T0. In response to the first operation at time T1, a sliding box corresponding to the target list entry is displayed, and a portion of the list box is hidden. The completion of the first operation is detected at time T2. After a preset time interval, a second interface is displayed at time T3. The first interface includes at least one list entry, the target list entry is any one of the at least one list entry, the target list entry is located in the list box, the sliding box coincides with the adjacent boundary of the list box, and the second interface includes a first pop-up window, the first pop-up window includes a first control, and the first control is used to indicate the deletion of the target list entry. This is equivalent to adding an operation on the first control on the second interface in the process of directly deleting the target list entry through the first operation, thereby avoiding the situation of accidental deletion caused by misoperation when deleting the target list entry in a convenient way.
[0131] In a possible case, the electronic device can automatically directly perform the operation of displaying the second interface after the first operation is completed, which can further improve the convenience of the user to implement related functions through the first operation.
[0132] Optionally, in the case where the first operation is an operation at a first moment, S103 may be implemented by “displaying a second interface at a second moment in response to the first operation, with a preset time interval between the second moment and the first moment”.
[0133] For example, Figure 6 As shown, at time T0, a sliding operation on the target list entry is detected. At time T1, in response to the sliding operation, a sliding box corresponding to the target list entry is displayed, and a portion of the list box is hidden. At time T2, when it is detected that the user has raised his hand, that is, when the sliding operation is completed, the timer is started. Exemplarily, the duration of the timer is 100ms. When the duration of the timer is reached, that is, at time T3, that is, at time T2+100ms, a second interface is displayed, and the second interface includes a first pop-up window, and the first pop-up window includes a first control, and the first control is used to indicate the deletion of the target list entry.
[0134] In an embodiment of the present application, when the user completes the first operation, after a preset time interval, when the T3 moment is reached, the second interface is displayed. This is equivalent to displaying the second interface after the dynamic effect of sliding is executed. Since pop-up windows consume system resources, executing the dynamic effect of sliding will also consume system resources. If both are executed at the same time, the dynamic effect of sliding will be affected, resulting in frame loss. Therefore, when the user completes the first operation, after a preset time interval, when the T3 moment is reached, the second interface is displayed, avoiding excessive consumption of system resources caused by the simultaneous execution of the dynamic effect of sliding and the pop-up of the first pop-up window, and thus avoiding frame loss.
[0135] In response to the first operation, the second interface can be displayed as follows: Figure 7 As shown in (a), the second interface includes a first pop-up window, and the first pop-up window includes a first control for indicating the deletion of the target list item. When the user clicks the first control, the electronic device determines that the user wants to delete the first short message (target list item). At this time, the electronic device automatically fills the position of the target list item with other list items, that is, the position of the first short message.
[0136] For example, Figure 7 As shown in (b), after the first short message is deleted, the second short message is moved from its original position to the initial position of the first short message to fill in the first short message. The third short message is moved from its original position to the initial position of the second short message to fill in the second short message.
[0137] It should be understood that the first pop-up window of the second interface may also include a second control for canceling the deletion of the target list item, so that the user can cancel the deletion of the target list item. The second control 1200 may be as shown in FIG5(f).
[0138] Optionally, after S103, the method for deleting list items provided by the embodiment of the present application may further include: "detecting a second operation on the second control, and displaying the target list item at the first position through a second dynamic effect in response to the second operation."
[0139] The second operation may refer to a touch operation on the second control. When the electronic device detects the touch operation on the second control, that is, the user needs to cancel the deletion of the target list item, the electronic device responds to the second operation and redisplays the target list item at the initial position of the target list item through the second dynamic effect. The second dynamic effect may be that the target list item is stretched in the opposite direction of the first operation, so that the target list item that is gradually shortened by the first operation becomes longer until the initial length of the target list item is restored.
[0140] For example, Figure 8 The second interface shown in (a) of FIG. 1 includes a first pop-up window, and the first pop-up window includes a second control, and the second control is used to cancel the deletion of the target list item. When the user performs a touch operation (a second operation) on the second control, in response to the second operation, the electronic device stretches the first short message to the right at the first position, that is, the position where the first short message is located, so that the first short message becomes longer, such as Figure 8 Until the initial length of the first short message is restored, as shown in (b) in Figure 8 As shown in (c) in .
[0141] In an embodiment of the present application, after the user performs a second operation on the second control on the first pop-up window, the target list entry is displayed at the first position through a second dynamic effect in response to the second operation, so that in the process of canceling the deletion of the target list entry, the second dynamic effect can be used to vividly show the user the process of canceling the deletion, thereby improving the user experience.
[0142] According to the description of the above embodiment, when the first operation is a sliding operation and the sliding distance of the sliding operation is greater than or equal to the preset threshold, the above Figure 5(a) to Figure 8 The interface shown implements the method for deleting a list item provided in an embodiment of the present application; when the sliding distance of the sliding operation is less than a preset threshold, the target list item can be directly restored without displaying the first pop-up window; or when the sliding distance of the sliding operation is less than a preset threshold, the following is executed. Fig. 9 The method shown is to delete list entries.
[0143] As the screens of electronic devices become larger, it is difficult for users to complete the sliding operation on the screen with one hand. In a possible case, the user cannot slide the list item to 2 / 3 of the screen with one hand. At this time, a first pop-up window may pop up and accept the user's selection on the first pop-up window to determine whether the target list item needs to be deleted.
[0144] Fig. 9 FIG. 1 is a flow chart of a method for deleting a list entry in another embodiment of the present application. Fig. 9 As shown, the method includes:
[0145] S201: An electronic device displays a first interface, where the first interface includes at least one list item.
[0146] S202: The electronic device detects a sliding operation on a target list item at time T0, where the target list item is any one of at least one list item, and the target list item is located in a list box.
[0147] S203. The electronic device responds to the sliding operation at time T1 by displaying a sliding box corresponding to the target list item and hiding a portion of the list box, wherein the sliding box and the adjacent borders of the list box overlap, and the sliding distance of the sliding operation is less than a preset threshold.
[0148] S204. The electronic device detects that the sliding operation is completed at time T2, and after a preset time interval, displays a second interface at time T3, where the second interface includes a first pop-up window, which includes a first control, and the first control is used to indicate deletion of the target list entry.
[0149] For example, Fig.10As shown in (a) in FIG. 1 , a sliding operation on the first short message is detected on the first interface, and the sliding distance of the sliding operation is less than a preset threshold, such as Fig.10 In response to the sliding operation, a first pop-up window pops up on the first interface, that is, the second interface is displayed. The first pop-up window includes a first control for indicating the deletion of the target list entry, such as Fig.10 Further, when the user clicks the first control, the first short message is deleted, such as Fig.10 As shown in (d) in the figure, when the sliding distance of the sliding operation is less than the preset threshold, the function of deleting the target list item can be conveniently realized.
[0150] In an embodiment of the present application, by displaying a first interface, a sliding operation on a target list item whose sliding distance is less than a preset threshold is detected, and in response to the sliding operation, a second interface is displayed. The first interface includes at least one list item, and the target list item is any one of the at least one list item. The second interface includes a first pop-up window, and the first pop-up window includes a first control, and the first control is used to indicate the deletion of the target list item. With the trend of larger screens of electronic devices, it is difficult for users to complete the sliding operation on the screen with one hand, and it is impossible to more conveniently implement the function corresponding to the sliding operation. By popping up the first pop-up window, the user can perform a second operation on the first pop-up window to implement the function corresponding to the sliding operation.
[0151] Fig.11 FIG. 1 is a flow chart of a method for deleting a list entry in another embodiment of the present application. Fig.11 As shown, the method includes:
[0152] S301, displaying a first interface.
[0153] The first interface includes at least one list item.
[0154] S302: A sliding operation on a target list item is detected.
[0155] The target list entry is any one of the at least one list entry.
[0156] S303: Determine whether the sliding distance of the sliding operation is greater than and equal to a preset threshold. If yes, execute S304; if no, execute S306.
[0157] S304: Display the first icon through a first dynamic effect.
[0158] S305: Record the target list entry, and execute S308.
[0159] S306: Display a delete button.
[0160] S307: Determine whether the user clicks the delete button, if so, execute S308.
[0161] S308: Display the second interface.
[0162] The second interface includes a first pop-up window, which includes a first control and a second control. The first control is used to indicate deletion of a target list item, and the second control is used to indicate cancellation of deletion of the target list item.
[0163] S309: Determine whether to delete the target list entry. If yes, execute S310; if no, execute S312.
[0164] If a touch operation on the first control is detected, it is determined to delete the target list entry; if a touch operation on the second control is detected, the deletion of the target list entry is cancelled.
[0165] S310, delete the target list entry.
[0166] S311. Display the third interface through the second dynamic effect.
[0167] Compared with the second interface, the third interface has no first pop-up window and no target list item, and the third interface is equivalent to the first interface without the target list item. The second dynamic effect includes the dynamic effect of the first pop-up window disappearing and the dynamic effect of other list items in the list filling the position of the target list item.
[0168] S312: Display the target list items through a fourth dynamic effect.
[0169] The above method of deleting list entries, its implementation method and beneficial effects are similar to Figures 4 to 9 The embodiments shown are similar and will not be described again here.
[0170] The method for deleting list items provided in the embodiment of the present application can be implemented by the front-end framework (UIkit), as shown below. Fig.12 and Fig.13 The illustrated embodiment is described in detail.
[0171] Fig.12 The software system of the electronic device 100 to which the method for deleting a list entry in an embodiment of the present application is applied is as follows: Fig.12As shown, the software system using a layered architecture is divided into several layers, and each layer has a clear role and division of labor. The layers communicate with each other through software interfaces. In some embodiments, the software system can be divided into three layers, from top to bottom, namely, the application layer, the front-end framework UIkit, and the vendor application framework layer vendor Frameworks. In some embodiments, UIkit and vendor Frameworks may also be collectively referred to as the application framework layer (Framework). In some embodiments, UIkit may also be set in vendor Frameworks, which is not limited in the embodiments of the present application.
[0172] The application layer may include applications such as camera, gallery, calendar, call, map, navigation, WLAN, Bluetooth, music, video, short message, etc.
[0173] UIkit can include animation module, item management module and list management module.
[0174] It should be understood that the modules in UIkit are equivalent to Figure 2 The interfaces of multiple modules in the software system shown in the figure are implemented by calling the modules in UIkit. Figure 2 The multiple modules in the software system shown assist in realizing the corresponding functions.
[0175] The animation module can be used to achieve dynamic effects, such as stretching dynamic effects, shortening dynamic effects, displaying icons, etc.
[0176] The list management module can be used to manage the display interface that displays data through lists.
[0177] The item management module may be used to manage each list item on a display interface displaying a list.
[0178] The following will describe the workflow of the software system of the electronic device 100 in conjunction with the method for deleting a list entry provided in an embodiment of the present application.
[0179] Fig.13 FIG. 1 is a flow chart of a method for deleting a list entry in one embodiment of the present application. Fig.13 As shown, including:
[0180] S401: The target application displays a first interface.
[0181] Among them, the target application can be Fig.12 Any application in the application layers shown.
[0182] S402: The target application detects a sliding operation with a sliding distance greater than or equal to a preset threshold.
[0183] S403: In response to the sliding operation, the target application sends coordinate information of the sliding operation to the list management module.
[0184] S404: The list management module sends the coordinate information to the entry management module.
[0185] S405: The item management module determines the target list item corresponding to the sliding operation according to the coordinate information.
[0186] In an embodiment of the present application, in response to a sliding operation, the target application sends the coordinate information of the sliding operation to the list management module, the list management module sends the coordinate information to the entry management module, and the entry management module determines the target list entry corresponding to the sliding operation based on the coordinate information. In other words, the target list entry can be accurately determined through the module in UIkit, so that in the process of developing the App, the module in UIkit can be directly called to implement the function of determining the object of the sliding operation.
[0187] S406: The item management module sends the information of the target list item to the list management module.
[0188] S407, the list management module calls the animation module.
[0189] S408: The dynamic effect module displays the first icon through a first dynamic effect.
[0190] In an embodiment of the present application, the animation module is called through the list management module, and the first icon is displayed through the first dynamic effect, so that the dynamic effect in the process of deleting the target list item is realized through the animation module in UIkit, thereby improving the convenience of realizing the dynamic effect function in the process of deleting the target list item in the process of developing the App.
[0191] S409: The list management module sends a first instruction to the target application.
[0192] The first instruction is used to instruct displaying the second interface.
[0193] The second interface includes a first pop-up window, which includes a first control and a second control. The first control is used to indicate deletion of a target list item, and the second control is used to indicate cancellation of deletion of the target list item.
[0194] S410: The target application responds to the first instruction, clears the stored list to be deleted and records the target list entries, and displays the second interface after a delay of 100 ms.
[0195] In the embodiment of the present application, the target application displays a first interface and detects a first operation on a target list item. In response to the first operation, a first instruction is sent to the target application through a list management module in the front-end framework UIkit. The target application displays a second interface in response to the first instruction. That is to say, in the embodiment of the present application, the function of popping up the first pop-up window during the process of deleting the target list item can be realized by directly calling the module in UIkit, which improves the convenience of realizing the function of deleting list items during the process of developing App.
[0196] S411: The target application detects an operation on the first control and sends a delete instruction to the list management module.
[0197] S412: The list management module sends a deletion instruction to the entry management module.
[0198] S413: The entry management module deletes the target list entry.
[0199] S414, the list management module calls the animation module.
[0200] S415. The dynamic effect module displays the third interface through the third dynamic effect.
[0201] The third dynamic effect may be a dynamic effect that the first pop-up window disappears from the second interface, and at the same time, other list items on the list fill in the position of the target list item. Compared with the first interface, the third interface is an interface where the target list item is removed from the first interface.
[0202] S416: The target application detects the operation on the second control and sends a cancel deletion instruction to the list management module.
[0203] S417, the list management module calls the animation module.
[0204] S418: The dynamic effect module displays the target list items through a second dynamic effect.
[0205] In an embodiment of the present application, the list management module calls the animation module to display the target list items through the second dynamic effect, so that the dynamic effect in the process of restoring the display of the target list bar is realized through the animation module in UIkit, thereby improving the convenience of realizing the function of restoring the dynamic effect in the process of displaying the target list bar during the development of the App.
[0206] S419: The target application displays the first interface through a fourth dynamic effect.
[0207] The fourth dynamic effect may refer to a dynamic effect in which the first pop-up window disappears from the second interface. For example, the fourth dynamic effect may refer to a dynamic effect in which the first pop-up window disappears directly, or a dynamic effect in which the first pop-up window gradually disappears from the second interface, or a dynamic effect in which the first pop-up window flies out from the edge of the screen, which is not limited in the present embodiment.
[0208] It should be understood that the fourth dynamic effect may be the same as or different from the third dynamic effect, and this embodiment of the present application does not limit this.
[0209] Since the second control refers to canceling the deletion of the target list entry, after the target application detects the operation on the second control, the currently displayed interface is restored to the first interface.
[0210] The method for deleting list entries in the embodiment of the present application has the same implementation principle and beneficial effects as the above Figures 4 to 10 The embodiments shown are similar and will not be described again here.
[0211] It should be understood that, although each step in the flow chart in the above-described embodiment is shown in sequence according to the indication of the arrow, these steps are not necessarily performed in sequence according to the order indicated by the arrow. Unless there is clear explanation in this article, the execution of these steps does not have strict order restriction, and these steps can be performed in other orders. Moreover, at least a portion of the steps in the flow chart may include a plurality of sub-steps or a plurality of stages, and these sub-steps or stages are not necessarily performed at the same time, but can be performed at different times, and the execution order of these sub-steps or stages is not necessarily performed in sequence, but can be performed in turn or alternately with at least a portion of other steps or sub-steps or stages of other steps.
[0212] Fig.14 It is a schematic diagram of a device for deleting list entries provided in an embodiment of the present application.
[0213] It should be understood that the list entry deletion device 600 may execute Figures 3 to 13 The method for deleting a list entry shown in the figure; the device 600 for deleting a list entry includes: an acquisition unit 610 and a processing unit 620.
[0214] In one example, the processing unit 620 is used to display a first interface, the first interface includes at least one list entry; a first operation on a target list entry is detected at time T0, the target list entry is any one of at least one list entry; the target list entry is located in a list box; in response to the first operation at time T1, a sliding box corresponding to the target list entry is displayed, and a portion of the list box is hidden, and the sliding box coincides with the adjacent boundaries of the list box; the completion of the first operation is detected at time T2, and after a preset time interval, a second interface is displayed at time T3, the second interface includes a first pop-up window, the first pop-up window includes a first control, and the first control is used to indicate the deletion of the target list entry.
[0215] In one example, the first operation is a sliding operation, and a sliding distance of the sliding operation is greater than and equal to a preset threshold.
[0216] In one example, the sliding box includes a delete icon, the delete icon includes a first delete graphic and a second delete graphic, and at time T1, the angle between the first delete graphic and the second delete graphic is 0.
[0217] In one example, after responding to the first operation at time T1, the processing unit 620 is further used to elastically stretch the length of the sliding box; when the length of the sliding box does not reach a preset threshold, the position of the deletion icon moves as the length of the sliding box increases; as the length of the sliding box increases, the angle between the first deletion graphic and the second deletion graphic increases as the first deletion graphic rotates around the rotation axis, and the second deletion graphic remains stationary; when the length of the sliding box reaches or exceeds a preset threshold, the position of the deletion icon moves toward the center of the sliding box, the size of the deletion icon increases, and the angle between the first deletion graphic and the second deletion graphic remains unchanged.
[0218] In one example, the first pop-up window also includes a second control, which is used to cancel the deletion of the target list entry. The processing unit 620 is also used to detect a second operation on the second control, and the second operation refers to a touch operation on the second control; in response to the second operation, the target list entry is displayed in the list box.
[0219] In one example, the first operation is a sliding operation, and a sliding distance of the sliding operation is less than a preset threshold.
[0220] In one example, the processing unit 620 is specifically used to detect the completion of the first operation at time T2, and after a preset time interval, send a first instruction to the target application through the list management module in the front-end framework UIkit, the first instruction is used to instruct the display of the second interface, and the list management module is used to manage the list where at least one list entry is located; the target application responds to the first instruction and displays the second interface at time T3.
[0221] In one example, the processing unit 620 is specifically used for the list management module in the front-end framework UIkit to call the animation module in the UIkit, and elastically stretch the length of the sliding box through the animation module; when the length of the sliding box does not reach a preset threshold, the position of the deletion icon moves as the length of the sliding box increases; as the length of the sliding box increases, the angle between the first deletion graphic and the second deletion graphic increases as the first deletion graphic rotates around the rotation axis, and the second deletion graphic remains stationary; when the length of the sliding box reaches or exceeds a preset threshold, the position of the deletion icon moves toward the center of the sliding box, the size of the deletion icon increases, and the angle between the first deletion graphic and the second deletion graphic remains unchanged.
[0222] In one example, the processing unit 620 is specifically used to call a dynamic effect module in the front-end framework UIkit in response to the user's second operation, and the dynamic effect module is used to display the target list item in the list box through a preset dynamic effect.
[0223] In one example, the processing unit 620 is also used to respond to the first operation, the target application sends the coordinate information of the first operation to the list management module; the list management module sends the coordinate information to the entry management module in the UIkit; the entry management module determines the target list entry corresponding to the first operation based on the coordinate information.
[0224] It should be noted that the above-mentioned apparatus 600 for deleting a list entry is embodied in the form of a functional unit. The term "unit" here can be implemented in the form of software and / or hardware, and is not specifically limited to this.
[0225] For example, a "unit" may be a software program, a hardware circuit, or a combination of the two that implements the above functions. The hardware circuit may include an application specific integrated circuit (ASIC), an electronic circuit, a processor (e.g., a shared processor, a dedicated processor, or a group processor, etc.) and a memory for executing one or more software or firmware programs, a combined logic circuit, and / or other suitable components that support the described functions.
[0226] Therefore, the units of each example described in the embodiments of the present application can be implemented by electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of the present application.
[0227] Fig.15 A structural schematic diagram of an electronic device provided by the present application is shown. Fig.15The dotted line in the figure indicates that the unit or the module is optional. The electronic device 700 can be used to implement the method for deleting a list entry described in the above method embodiment.
[0228] The electronic device 700 includes one or more processors 701, which can support the electronic device 700 to implement the method of deleting a list entry in the method embodiment. The processor 701 can be a general-purpose processor or a special-purpose processor. For example, the processor 701 can be a central processing unit (CPU), a digital signal processor (DSP), an application specific integrated circuit (ASIC), a field programmable gate array (FPGA), or other programmable logic devices, such as discrete gates, transistor logic devices, or discrete hardware components.
[0229] The processor 701 may be used to control the electronic device 700, execute software programs, and process data of the software programs. The electronic device 700 may also include a communication unit 705 to implement input (reception) and output (transmission) of signals.
[0230] For example, the electronic device 700 may be a chip, the communication unit 705 may be an input and / or output circuit of the chip, or the communication unit 705 may be a communication interface of the chip, and the chip may be a component of a terminal device or other electronic devices.
[0231] For another example, the electronic device 700 may be a terminal device, and the communication unit 705 may be a transceiver of the terminal device, or the communication unit 705 may be a transceiver circuit of the terminal device.
[0232] The electronic device 700 may include one or more memories 702 on which a program 704 is stored. The program 704 can be executed by the processor 701 to generate instructions 703, so that the processor 701 executes the method for deleting list entries described in the above method embodiment according to the instructions 703.
[0233] Optionally, data may be stored in the memory 702. Optionally, the processor 701 may read data stored in the memory 702. The data may be stored at the same storage address as the program 704, or may be stored at a different storage address than the program 704.
[0234] The processor 701 and the memory 702 may be provided separately or integrated together; for example, integrated on a system on chip (SOC) of a terminal device.
[0235] Exemplarily, the memory 702 can be used to store a related program 704 of the method for deleting list entries provided in an embodiment of the present application, and the processor 701 can be used to call the related program 704 of the method for deleting list entries stored in the memory 702 when performing image repair on the terminal device, and execute the method for deleting list entries in an embodiment of the present application; for example, a first interface is displayed, and the first interface includes at least one list entry; a first operation on a target list entry is detected at time T0, and the target list entry is any one of the at least one list entry; the target list entry is located in a list box; in response to the first operation at time T1, a sliding box corresponding to the target list entry is displayed, and a part of the list box is hidden, and the sliding box coincides with the adjacent boundary of the list box; the completion of the first operation is detected at time T2, and after a preset time interval, a second interface is displayed at time T3, and the second interface includes a first pop-up window, and the first pop-up window includes a first control, and the first control is used to indicate the deletion of the target list entry.
[0236] The present application also provides a computer program product, which, when executed by the processor 701, implements the method for deleting a list entry described in any method embodiment of the present application.
[0237] The computer program product may be stored in the memory 702 , for example, a program 704 , which is finally converted into an executable target file that can be executed by the processor 701 after preprocessing, compiling, assembling, and linking.
[0238] The present application also provides a computer-readable storage medium on which a computer program is stored, and when the computer program is executed by a computer, the method for deleting a list entry described in any method embodiment of the present application is implemented. The computer program can be a high-level language program or an executable target program.
[0239] The computer-readable storage medium is, for example, a memory 702. The memory 702 may be a volatile memory or a nonvolatile memory, or the memory 702 may include both a volatile memory and a nonvolatile memory. Among them, the nonvolatile memory may be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), or a flash memory. The volatile memory may be a random access memory (RAM), which is used as an external cache. By way of example and not limitation, many forms of RAM are available, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate synchronous dynamic random access memory (DDR SDRAM), enhanced synchronous dynamic random access memory (ESDRAM), synchronous link dynamic random access memory (SLDRAM), and direct rambus RAM (DR RAM).
[0240] In this application, "at least one" means one or more, and "more than one" means two or more. "At least one of the following" or similar expressions refers to any combination of these items, including any combination of single or plural items. For example, at least one of a, b, or c can be represented by: a, b, c, ab, ac, bc, or abc, where a, b, c can be single or multiple.
[0241] It should be understood that in the various embodiments of the present application, the size of the serial numbers of the above-mentioned processes does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present application.
[0242] Those of ordinary skill in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.
[0243] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.
[0244] In the several embodiments provided in the present 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 merely schematic; for example, the division of the units is only a logical function division, and there may be other division methods in actual implementation; for example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0245] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0246] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.
[0247] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any person skilled in the art who is familiar with the present technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.
Claims
1. A method for deleting a list entry, characterized in that: include: Displaying a first interface, wherein the first interface includes at least one list item; detecting a first operation on a target list item, the target list item being any one of the at least one list item, the target list item being located in a list box; In response to the first operation, displaying a sliding box corresponding to the target list item and hiding a portion of the list box, wherein the sliding box overlaps with adjacent boundaries of the list box, the sliding box includes a delete icon, and the delete icon includes a first delete graphic and a second delete graphic; A second operation on the target list entry continues to be detected, and as the second operation is performed, the angle between the first deletion graphic and the second deletion graphic increases.
2. The method according to claim 1, characterized in that The method further comprises: As the first operation is performed, the length of the sliding frame gradually increases; As the second operation is performed, the length of the sliding frame gradually increases; When the length of the sliding box does not reach a preset threshold, the position of the delete icon moves as the length of the sliding box increases; As the second operation is performed, the angle between the first deletion graphic and the second deletion graphic increases, specifically: When the length of the sliding box does not reach the preset threshold, as the length of the sliding box increases, the angle between the first deletion figure and the second deletion figure increases as the first deletion figure rotates around the rotation axis, and the second deletion figure remains stationary.
3. The method according to claim 2, characterized in that The method further comprises: When the length of the sliding box reaches or exceeds the preset threshold, the position of the deletion icon moves toward the center of the sliding box, the size of the deletion icon increases, and the angle between the first deletion graphic and the second deletion graphic remains unchanged.
4. The method according to any one of claims 1 to 3, characterized in that The first operation is a sliding operation, and the second operation is a sliding operation.
5. The method according to any one of claims 1 to 3, characterized in that: The first operation and the second operation are one continuous sliding operation.
6. The method according to claim 4, characterized in that A sum of a sliding distance of the first operation and a sliding distance of the second operation is greater than or equal to a preset threshold.
7. The method according to claim 5, characterized in that The continuous sliding distance of the first operation and the second operation is greater than or equal to a preset threshold.
8. The method according to claim 6 or 7, characterized in that: The method further comprises: In response to the second operation being completed, deleting the target list entry.
9. The method according to claim 6 or 7, characterized in that: The method further comprises: In response to the second operation being completed, displaying a first pop-up window, wherein the first pop-up window includes a first control; In response to an operation on the first control, the target list entry is deleted.
10. The method according to claim 9, characterized in that In response to the second operation being completed, displaying the first pop-up window specifically includes: In response to the completion of the second operation, the first pop-up window is displayed after a preset time interval.
11. The method according to claim 4 or 5, characterized in that: The method further comprises: In response to the second operation being completed, the target list item is restored to display, and when the second operation is completed, the sum of the sliding distance of the first operation and the sliding distance of the second operation is less than a preset threshold.
12. The method according to claim 9 or 10, characterized in that: The first pop-up window further includes a second control, and the method further includes: In response to an operation on the second control, the target list item is restored to display.
13. The method according to claim 11 or 12, characterized in that: The restoration displays the target list items, specifically: At the initial position of the target list entry, the target list entry is stretched in the opposite direction of the first operation and the second operation, so that the target list entry gradually shortened by the first operation and the second operation becomes longer until the initial length of the target list entry is restored.
14. The method according to any one of claims 1 to 13, characterized in that The list item is a text message item, and the target list item is a target text message item.
15. The method according to claim 14, characterized in that The sliding frame also includes a read icon.
16. The method according to any one of claims 1 to 13, characterized in that The list entry is an alarm entry, and the target list entry is a target alarm entry.
17. The method according to claim 10, characterized in that In response to the completion of the second operation, the first pop-up window is displayed after a preset time interval, specifically: In response to the completion of the second operation, after a preset time interval, a first instruction is sent to the target application through a list management module in the front-end framework UIkit, wherein the first instruction is used to instruct to display the first pop-up window, and the list management module is used to manage the list where the at least one list item is located; The target application displays the first pop-up window in response to the first instruction.
18. The method according to claim 3, characterized in that The method is specifically as follows: The list management module in the front-end framework UIkit calls the motion effect module in the front-end framework UIkit, and through the motion effect module: the length of the sliding box is gradually lengthened; when the length of the sliding box does not reach the preset threshold, the position of the deletion icon moves as the length of the sliding box increases; when the length of the sliding box does not reach the preset threshold, as the length of the sliding box increases, the angle between the first deletion graphic and the second deletion graphic increases as the first deletion graphic rotates around the rotation axis, and the second deletion graphic remains stationary; when the length of the sliding box reaches or exceeds the preset threshold, the position of the deletion icon moves toward the center of the sliding box, the size of the deletion icon increases, and the angle between the first deletion graphic and the second deletion graphic remains unchanged.
19. The method according to claim 13, characterized in that The restoration displays the target list items, specifically: The animation module in the front-end framework UIkit is called to restore the display of the target list item.
20. The method according to any one of claims 17 to 19, characterized in that: The method further comprises: In response to the first operation or the second operation, the target application sends coordinate information of the first operation or the second operation to the list management module; The list management module sends the coordinate information to the entry management module in the front-end framework UIkit; The entry management module determines the target list entry corresponding to the first operation or the second operation according to the coordinate information.
21. A device for deleting a list item, characterized in that: The device for deleting a list entry comprises a processor and a memory, wherein the memory is used to store a computer program, and the processor is used to call and run the computer program from the memory, so that the device for deleting a list entry executes the method according to any one of claims 1 to 20.
22. A chip, characterized in that: The method comprises a processor, and when the processor executes instructions, the processor performs the method according to any one of claims 1 to 20.
23. An electronic device, characterized in that: The electronic device comprises a processor, wherein the processor is coupled to a memory, reads instructions in the memory, and enables the electronic device to execute the method according to any one of claims 1 to 20 according to the instructions.
24. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed on an electronic device, the electronic device executes the method according to any one of claims 1 to 20.
25. A computer program product, the computer program product comprising: Computer program code, when the computer program code is executed on an electronic device, causes the electronic device to execute the method according to any one of claims 1 to 20.