Operation processing method and device, electronic equipment, computer readable storage medium and computer program product
Patent Information
- Application Number
- CN202511814804.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-12-03
- Publication Date
- 2026-03-06
Smart Images

Figure CN121614077A_ABST
Abstract
Description
Technical Field
[0001] This application relates to computer technology, and more particularly to an operation processing method, apparatus, electronic device, computer-readable storage medium, and computer program product. Background Technology
[0002] In related technologies, the coordinates of the touch point at the moment the user's finger leaves the screen are determined as the final position of the drag operation. However, when the user quickly lifts their finger to release the operation, the touch point often undergoes an unexpected slight offset due to inertia or uneven force, causing the final landing point of the interface element to deviate from the user's expected target position, thereby reducing the accuracy of interactive control. Summary of the Invention
[0003] This application provides an operation processing method, apparatus, electronic device, computer-readable storage medium, and computer program product, which improves the accuracy of operation.
[0004] The technical solution of this application embodiment is implemented as follows: This application provides an operation processing method, the method including: Display draggable interface elements in the view interface; In response to a drag operation on the interface element, the process of the interface element moving in accordance with the touch point of the drag operation is displayed. In response to the release of the drag operation, when a misoperation is detected in the drag operation, the interface element is controlled to revert to a historical position in the movement trajectory based on the movement trajectory of the interface element, so as to correct the misoperation in the drag operation.
[0005] This application provides an operation processing apparatus, the apparatus comprising: The display module is used to display draggable interface elements in the view interface. A drag module is used to respond to a drag operation on the interface element and display the process of the interface element moving as the touch point of the drag operation is applied. A correction module is used to respond to the release of the drag operation. When a misoperation is detected in the drag operation, the module controls the interface element to return to a historical position in the movement trajectory based on the movement trajectory of the interface element, so as to correct the misoperation in the drag operation.
[0006] In the above scheme, the operation processing device further includes: a first erroneous operation determination module, used to record a first movement distance of the interface element within a first time period before the drag operation is released, and a second movement distance of the interface element within a second time period before the drag operation is released, before controlling the interface element to return to a historical position in the movement trajectory based on the movement trajectory of the interface element; wherein, the first time period is longer than the second time period; in response to the distance difference between the first movement distance and the second movement distance being less than a preset first distance threshold and the second movement distance being less than a second distance threshold, it is determined that the drag operation contains the erroneous operation.
[0007] In the above scheme, the first time period corresponds to the first trajectory segment in the movement trajectory, and the second time period corresponds to the second trajectory segment in the movement trajectory. The operation processing device further includes: a first threshold determination module, used to determine the pause frequency of the touch point in the first trajectory segment and the second trajectory segment, the average acceleration between the second trajectory segment and the first trajectory segment, and the average movement speed of the touch point in the second trajectory segment; calculate the first contribution of the pause frequency to the first distance threshold, the second contribution of the average acceleration to the first distance threshold, the third contribution of the average movement speed to the first distance threshold, and the fourth contribution of the average movement speed to the second distance threshold; determine the first weighting coefficient corresponding to the first distance threshold, and perform a weighted summation of the first contribution, the second contribution, and the third contribution based on the first weighting coefficient to obtain the first distance threshold; determine the second weighting coefficient corresponding to the second distance threshold, and perform a weighted summation of the first contribution, the second contribution, and the fourth contribution based on the second weighting coefficient to obtain the second distance threshold.
[0008] In the above scheme, the operation processing device further includes: a second threshold determination module, used to determine the control type to which the interface control belongs when the interface element is an interface control; Based on the control type, determine the first distance threshold and the second distance threshold corresponding to the interface control.
[0009] In the above scheme, the second time period corresponds to the second trajectory segment in the movement trajectory; the first misoperation determination module is also used to control the interface element to revert to the starting position of the second trajectory segment in the movement trajectory based on the movement trajectory of the interface element.
[0010] In the above scheme, the operation processing device further includes: a second erroneous operation determination module, used to determine that the drag operation does not include the erroneous operation in response to the distance difference between the first moving distance and the second moving distance being not less than the first distance threshold, or the second moving distance being not less than the second distance threshold.
[0011] In the above scheme, the operation processing device further includes: a third erroneous operation determination module, used to record the pressure change of the touch point in real time during the execution of the drag operation before controlling the interface element to return to the historical position in the movement trajectory based on the movement trajectory; when the pressure change of the touch point is detected to indicate that the pressure of the touch point decreases at a rate greater than a preset decrease rate threshold, the drag operation is determined to contain the erroneous operation.
[0012] In the above scheme, the operation processing device further includes: a rate determination module, used to determine the moment when the pressure drop rate of the contact point equals a preset drop rate threshold before the drag operation is released, and to record the position of the interface element at the moment when the pressure drop rate equals the preset drop rate threshold; the correction module is further used to control the interface element to revert to the position of the interface element at the moment when the pressure drop rate equals the preset drop rate threshold, based on the movement trajectory of the interface element.
[0013] In the above scheme, the operation processing method is executed by an electronic device, and the operation processing device further includes: a fourth misoperation determination module, used to detect whether a pressure sensor is provided in the electronic device before the real-time recording of the pressure change of the contact point during the execution of the drag operation; if the detection result indicates that a pressure sensor is provided in the electronic device, triggering the operation of real-time recording of the pressure change of the contact point during the execution of the drag operation; if the detection result indicates that a pressure sensor is not provided in the electronic device, recording the motion characteristics of the contact point, so as to identify whether the drag operation contains a misoperation based on the motion characteristics of the contact point.
[0014] In the above scheme, the operation processing device further includes: a third threshold determination module, used to acquire operation data during the execution of the drag operation; input the operation data into a pre-trained threshold determination model; and determine the first distance threshold and the second distance threshold based on the threshold determination model.
[0015] In the above scheme, the operation processing device further includes: a training module, used to acquire sample data, the sample data including operation data during the execution of the drag operation, and sample labels used to indicate whether the drag operation includes erroneous operation; and to train the threshold determination model based on the sample data to obtain the trained threshold determination model.
[0016] In the above scheme, the correction module is further configured to play a transition animation when the distance between the end position of the movement trajectory and the historical position is greater than a distance threshold, and control the interface elements to revert to the historical position in the movement trajectory according to the transition animation.
[0017] In the above scheme, the correction module is also used to control the interface element to instantly move to a historical position in the movement trajectory based on the movement trajectory of the interface element in a transitionless manner.
[0018] In the above scheme, the operation processing device further includes: an execution module, configured to, in response to the interface element returning to a historical position in the movement trajectory, perform at least one of the following: output haptic feedback, the haptic feedback being used to prompt the interface element to return to the historical position; display the interface element using a target display style, wherein the target display style is used to indicate that the interface element returns to the historical position.
[0019] In the above scheme, the operation processing device further includes: a first adjustment module, used to control the interface element to return to a historical position in the movement trajectory based on the movement trajectory, and in response to the number of times the interface element returns in the view interface within a preset time reaching a threshold, display sensitivity adjustment prompt information and corresponding sensitivity adjustment controls; wherein, the sensitivity adjustment prompt information is used to prompt adjustment of the trigger sensitivity of the erroneous operation.
[0020] In the above scheme, the operation processing device further includes: an activation module, used to display a misoperation correction switch that is in a closed state in the view interface; in response to an activation operation of the misoperation correction switch, to activate the misoperation correction switch; the correction module is further used to, in response to the release of the drag operation, when the misoperation correction switch is activated and the drag operation is detected to contain a misoperation, control the interface element to return to a historical position in the movement trajectory based on the movement trajectory of the interface element.
[0021] In the above scheme, the operation processing device further includes: a removal module, used to draw the movement trajectory of the interface element in real time in the view interface in response to the drag operation of the interface element; and to mark the corresponding retracement part of the movement trajectory as invalid or remove it from the movement trajectory in response to the interface element returning to a historical position in the movement trajectory.
[0022] In the above scheme, the operation processing device further includes: an undo module, used to display an undo control in the view interface in response to the interface element returning to a historical position in the movement trajectory; and to control the interface element to move to the endpoint position of the interface element when the drag operation is released in response to a trigger operation on the undo control.
[0023] In the above scheme, the operation processing device further includes: a second adjustment module, used to detect whether the touch point position of the drag operation is located in the edge area of the view interface before controlling the interface element to return to the historical position in the movement trajectory based on the movement trajectory of the interface element when the drag operation is released and a misoperation is detected in the drag operation; and to increase the judgment threshold for identifying the misoperation in response to the touch point position being located in the edge area.
[0024] In the above scheme, the operation processing device further includes: an interrupt module, used to interrupt the fallback process of the interface element in response to a touch operation performed in the view interface during the fallback process of the interface element.
[0025] In the above scheme, the operation processing device further includes: a playback module, used to play a prompt sound effect during the process of the interface element returning; wherein, the longer the distance of the interface element returning, the higher the pitch or the louder the volume of the prompt sound effect.
[0026] This application provides an electronic device, including: Memory is used to store executable instructions or computer programs. The processor, when executing computer-executable instructions or computer programs stored in the memory, implements the operation processing method provided in the embodiments of this application.
[0027] This application provides a computer-readable storage medium storing computer-executable instructions or computer programs, which, when executed by a processor, implement the operation processing method provided in this application.
[0028] This application provides a computer program product, including computer-executable instructions or a computer program, which, when executed by a processor, implements the operation processing method provided in this application.
[0029] The embodiments of this application have the following beneficial effects: This application directly controls the position of interface elements by moving them via touch points, clearly defining their expected target landing point. When the drag operation is released, to address the pain point of accidental operation, it identifies the accidental operation and reverts to the historical position based on the movement trajectory. Since the historical position is the stable position where the user has accurately positioned the target during the drag operation, this action can directly eliminate the unexpected landing point deviation caused by the accidental operation, correct the error in the drag operation, and ultimately ensure that the final landing point of the interface element is highly matched with the user's expected target position, significantly improving the accuracy of the operation. Attached Figure Description
[0030] Figure 1 This is a schematic diagram of the operation processing system provided in the embodiments of this application; Figure 2 This is a schematic diagram of the structure of the electronic device provided in the embodiments of this application; Figure 3 This is a first flowchart illustrating the operation processing method provided in the embodiments of this application; Figure 4 This is a schematic diagram of the operation process provided in the embodiments of this application. Figure 1 ; Figure 5 This is a schematic diagram of the operation process provided in the embodiments of this application. Figure 2 ; Figure 6 This is a schematic diagram of the operation process provided in the embodiments of this application. Figure 3 ; Figure 7 This is a schematic diagram of the operation process provided in the embodiments of this application. Figure 4 ; Figure 8 This is a schematic diagram of the operation process provided in the embodiments of this application. Figure 5 ; Figure 9 This is a schematic diagram of the operation process provided in the embodiments of this application. Figure 6 ; Figure 10 This is a schematic diagram of the operation process provided in the embodiments of this application. Figure 7 ; Figure 11 This is a schematic diagram of the operation process provided in the embodiments of this application. Figure 8 ; Figure 12 This is a second flowchart illustrating the operation processing method provided in the embodiments of this application. Detailed Implementation
[0031] To make the objectives, technical solutions, and advantages of this application clearer, the application will be further described in detail below with reference to the accompanying drawings. The described embodiments should not be regarded as limitations on this application. All other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0032] In the following description, references are made to “some embodiments,” which describe a subset of all possible embodiments. However, it is understood that “some embodiments” may be the same subset or different subsets of all possible embodiments and may be combined with each other without conflict.
[0033] In the following description, the terms "first, second, third" are used merely to distinguish similar objects and do not represent a specific ordering of objects. It is understood that "first, second, third" may be interchanged in a specific order or sequence where permitted, so that the embodiments of this application described herein can be implemented in an order other than that illustrated or described herein.
[0034] In the embodiments of this application, the terms "module" or "unit" refer to a computer program or part of a computer program that has a predetermined function and works with other related parts to achieve a predetermined goal, and can be implemented wholly or partially using software, hardware (such as processing circuitry or memory), or a combination thereof. Similarly, a processor (or multiple processors or memory) can be used to implement one or more modules or units. Furthermore, each module or unit can be part of an overall module or unit that includes the functionality of that module or unit.
[0035] Unless otherwise defined, all technical and scientific terms used in the embodiments of this application have the same meaning as commonly understood by one of ordinary skill in the art. The terminology used in the embodiments of this application is for the purpose of describing the embodiments of this application only and is not intended to limit this application.
[0036] In the implementation of this application, the collection and processing of relevant data should strictly comply with the requirements of relevant laws and regulations, obtain the informed consent or separate consent of the personal information subject, and carry out subsequent data use and processing within the scope of laws and regulations and the authorization of the personal information subject.
[0037] Before providing a further detailed description of the embodiments of this application, the nouns and terms involved in the embodiments of this application will be explained, and the nouns and terms involved in the embodiments of this application shall be interpreted as follows.
[0038] 1) In response to, used to indicate the conditions or states on which the operation performed depends. When the conditions or states on which it depends are met, one or more operations performed may be performed in real time or with a set delay. Unless otherwise specified, there is no restriction on the order in which the multiple operations are performed.
[0039] 2) Client, also known as user terminal, refers to the program that provides local services to users in contrast to the server. Except for some applications that can only run locally, it is generally installed on the terminal and needs to work in conjunction with the server. That is, there needs to be a corresponding server and service program on the network to provide the corresponding services. Thus, a specific communication connection needs to be established between the client and the server to ensure the normal operation of the application, such as virtual scene clients (such as game clients) and video clients.
[0040] During the research process, the inventors discovered the following technical problems in the relevant technology: In related technologies, the coordinates of the touch point at the instant the user's finger leaves the screen are directly defined as the final position of the drag operation. This does not take into account the objective operational deviations during the user's release process. When the user quickly lifts their finger to release the operation, factors such as finger inertia and uneven force can easily cause the touch point to undergo unexpected slight offset at the moment of release. This offset will directly cause the final landing point of the interface element to deviate from the user's pre-defined target position. It is impossible to identify the misoperation when releasing the finger, and there is no targeted correction method. It can only passively accept the landing point after the offset, which ultimately leads to a significant reduction in the accuracy of the drag operation's interactive control, making it difficult to meet the user's operational needs for precise positioning of interface elements.
[0041] Based on this, embodiments of this application provide an operation processing method, apparatus, electronic device, computer-readable storage medium, and computer program product, which improves the accuracy of operation.
[0042] The following describes the application scenarios of the operation processing method provided in the embodiments of this application. The embodiments of this application provide an operation processing method, device, electronic device, computer-readable storage medium, and computer program product, which can be applied to various scenarios. Examples are given below.
[0043] 1) In desktop interaction and layout management scenarios, when organizing desktop icons or laying out widgets, in response to the user's dragging of application icons to the target grid area, if a slight slip occurs when the user lifts their finger, causing the icon to deviate from the target grid, the system controls the icon to revert and snap back to the target grid position before the slip, based on the icon's movement trajectory during the hovering phase. This effectively solves the problem of icons moving around and failing to be accurately placed when organizing the desktop due to slipping fingers, requiring repeated attempts, thus improving the accuracy of the operation and enhancing interaction efficiency.
[0044] 2) In graphic image editing and design scenarios, when cropping images, editing videos, or designing posters via a touchscreen, the system responds to user dragging operations on selection boxes, sticker materials, or video track sliders. After the user releases the operation, if it detects that the touch point has undergone non-subjective displacement due to fingertip shaking, it accurately restores the material's position to the finely adjusted position before the user released the finger, based on the material's historical movement trajectory. This avoids "pixel-level" alignment failures caused by minor finger tremors when the finger leaves the screen, solving the technical problem of "difficulty in precise positioning during fine-grained image retouching and heavy reliance on magnified views for assistance."
[0045] 3) In e-sports games and entertainment scenarios, when running strategy games (such as auto chess and tower defense) or card games, in response to the user's dragging of game units (such as chess pieces and skill cards) to the designated battlefield, if the system detects that the user has made a mistake due to hand sweat or inertia during tense operation, it will backtrack the drag trajectory of the game unit to determine the user's true intention and place the unit in the effective tactical position before the deviation. This can prevent misoperations such as "skills being wasted" and "chess pieces being placed incorrectly" caused by accidental touches, thereby ensuring the fairness and smoothness of game operation and improving the player's gaming experience.
[0046] It should be noted that, in addition to the above-mentioned application scenarios, the operation and processing methods provided in this application can also be widely applied to other scenarios to meet the diverse needs of different user groups, and this application does not impose any restrictions.
[0047] See Figure 1 , Figure 1 This is a schematic diagram of the operation processing system provided in the embodiments of this application. Figure 1 The operation processing system 100 shown supports an operation processing application. The terminal 400 is connected to the server 200 through a network 300, which can be a wide area network, a local area network, or a combination of both.
[0048] Terminal 400 is used to display draggable interface elements in a view interface; in response to a drag operation on an interface element, it displays the process of the interface element moving along the touch point of the drag operation; in response to the release of the drag operation, when a misoperation is detected in the drag operation, it controls the interface element to return to the historical position in the movement trajectory based on the movement trajectory of the interface element, so as to correct the misoperation in the drag operation.
[0049] In some embodiments, server 200 may be a standalone physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server providing basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, content delivery networks (CDNs), and big data and artificial intelligence platforms. Terminal 400 may be a smartphone, tablet, laptop, desktop computer, set-top box, smart voice interaction device, smart home appliance, virtual reality device, vehicle terminal, aircraft, portable music player, personal digital assistant, dedicated messaging device, portable gaming device, smart speaker, and smartwatch, but is not limited thereto. Terminals and servers can be directly or indirectly connected via wired or wireless communication, which is not limited in this embodiment.
[0050] The electronic device implementing the operation processing method provided in the embodiments of this application will now be described. See also Figure 2 , Figure 2 This is a schematic diagram of the structure of the electronic device provided in the embodiments of this application. In practical applications, the electronic device can be implemented as various types of terminals such as laptops, tablets, desktop computers, smartphones, smart speakers, smartwatches, smart TVs, and vehicle terminals. It can also be implemented as a server or as a device cluster composed of servers and terminals. Figure 2 The illustrated electronic device includes at least one processor 510, a memory 550, at least one network interface 520, and a user interface 530. The various components of the electronic device are coupled together via a bus system 540. It is understood that the bus system 540 is used to implement communication between these components. In addition to a data bus, the bus system 540 also includes a power bus, a control bus, and a status signal bus. However, for clarity, in… Figure 2 The general labeled all buses as Bus System 540.
[0051] The processor 510 can be an integrated circuit chip with signal processing capabilities, such as a general-purpose processor, a digital signal processor (DSP), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor can be a microprocessor or any conventional processor, etc.
[0052] User interface 530 includes one or more output devices 531 that enable the presentation of media content, including one or more speakers and / or one or more visual displays. User interface 530 also includes one or more input devices 532, including user interface components that facilitate user input, such as a keyboard, mouse, microphone, touch screen display, camera, other input buttons and controls.
[0053] The memory 550 may be removable, non-removable, or a combination thereof. Exemplary hardware devices include solid-state storage, hard disk drives, optical disk drives, etc. The memory 550 may optionally include one or more storage devices physically located away from the processor 510.
[0054] The memory 550 may include volatile memory or non-volatile memory, or both. The non-volatile memory may be read-only memory (ROM), and the volatile memory may be random access memory (RAM). The memory 550 described in this application embodiment is intended to include any suitable type of memory.
[0055] In some embodiments, memory 550 is capable of storing data to support various operations, examples of which include programs, modules, and data structures or subsets or supersets thereof, as illustrated below.
[0056] Operating system 551 includes system programs for handling various basic system services and performing hardware-related tasks, such as the framework layer, core library layer, and driver layer, for implementing various basic business functions and handling hardware-based tasks.
[0057] The network communication module 552 is used to reach other electronic devices via one or more (wired or wireless) network interfaces 520, exemplary network interfaces 520 including Bluetooth, WiFi, and Universal Serial Bus (USB).
[0058] Presentation module 553 enables the presentation of information (e.g., a user interface for operating peripheral devices and displaying content and information) via one or more output devices 531 associated with user interface 530 (e.g., a display screen, a speaker, etc.).
[0059] The input processing module 554 is used to detect one or more user inputs or interactions from one or more input devices 532, and to translate the detected inputs or interactions.
[0060] In some embodiments, the operation processing apparatus provided in this application can be implemented in software. Figure 2 An operation processing device 555 stored in memory 550 is shown. This device can be software in the form of programs and plug-ins, and includes the following software modules: a display module 5551, a drag module 5552, and a correction module 5553. These modules are logically connected and can therefore be arbitrarily combined or further separated according to the functions they implement. The functions of each module will be described below.
[0061] In other embodiments, the apparatus provided in this application can be implemented in hardware. As an example, the operation processing apparatus provided in this application can be a processor in the form of a hardware decoding processor, which is programmed to execute the operation processing method provided in this application. For example, the processor in the form of a hardware decoding processor can be one or more application-specific integrated circuits (ASICs), DSPs, programmable logic devices (PLDs), complex programmable logic devices (CPLDs), field-programmable gate arrays (FPGAs), or other electronic components.
[0062] In some embodiments, the terminal or server can implement the operation processing method provided in the embodiments of this application by running a computer program. For example, the computer program can be a native program or software module in an operating system; it can be a native application (APP), i.e., a local client, i.e., a program that needs to be installed in the operating system to run, such as an instant messaging APP or a web browser APP; it can also be a mini-program, i.e., a program that only needs to be downloaded into a browser environment to run; or it can be a mini-program that can be embedded in any APP. In short, the above-mentioned computer program can be any form of client, module, or plugin.
[0063] Below, based on the electronic device and system provided in the embodiments of this application, the operation processing method provided in the embodiments of this application will be described.
[0064] See Figure 3 , Figure 3 This is a first flowchart illustrating the operation processing method provided in this application embodiment. In practical applications, this method can be implemented by the terminal or the server alone, or by the terminal and the server working together. The following example uses a terminal implementation and will be combined with... Figure 3The steps shown illustrate the operation processing method provided in the embodiments of this application.
[0065] In step 101, draggable interface elements are displayed in the view interface.
[0066] In practical applications, the terminal may have applications installed. These applications may include one or more of the following: desktop management applications, document editing applications, graphic design applications, and home screen management tools for mobile devices. All of these applications have the function of dragging and dropping interface elements. This application embodiment does not impose specific limitations on the applications.
[0067] In some embodiments, in response to a triggering operation on the application, the application's display interface can be displayed. This display interface can be a main interface, a view interface including draggable interface elements, or other interfaces, depending on actual usage requirements. When the main interface is displayed, in response to a display command for the view interface, the view interface can be displayed. When the view interface is displayed, draggable interface elements can be shown within it.
[0068] It should be noted that the view interface refers to the visual display area used to present the graphical user interface and to support human-computer interaction. It can be the system desktop occupying the entire screen, the function pages of applications, or a partial interactive area presented as a floating window, split screen, or pop-up. In the view interface, to meet the user's needs for adjusting the layout, order, or position, one or more interface elements are displayed that can respond to the user's touch commands and change position accordingly; that is, draggable interface elements are displayed in the view interface.
[0069] Interface elements, in this context, refer to independent components presented in the view interface that can interact with user objects. As objects that users drag and drop, interface elements can carry specific data or function entry points. In practical applications, the form of interface elements can vary depending on the application scenario: In a system desktop scenario, interface elements include application icons, desktop widgets, folders, shortcut icons, etc.; in document / graphics editing scenarios, interface elements include image assets, text boxes, layers, video track clips, canvas selection areas, etc.; in game scenarios, interface elements include skill buttons, virtual joysticks, equipment cards, chess pieces, game character models, etc.; in general application scenarios, interface elements also include controls such as floating balls, navigation bar buttons, progress bar sliders, etc.
[0070] For UI elements in a draggable state, they can be UI elements that are configured with draggable attributes, such as progress bars, sliders, and floating window handles, which can respond to dragging directly without additional activation steps; or they can be UI elements that have been unlocked based on specific trigger logic. In practical applications, in response to the state switching command for the UI element, the UI element is controlled to be in a draggable state, and the state flag of the UI element is switched from a fixed locked state to a draggable dynamic state that allows it to move with the touch point, thus entering a draggable interaction mode.
[0071] In step 102, in response to a drag operation on an interface element, the process of the interface element moving following the touch point of the drag operation is displayed.
[0072] Here, in response to the drag operation triggered by the user object, the terminal will collect the position coordinate changes of the user object's touch point in real time, and update the display position of the interface element synchronously according to the strategy of keeping the relative position of the touch point and the element unchanged or center-aligned, so as to visually present the dynamic effect of the interface element being attracted to the touch point and moving smoothly with it.
[0073] Dragging operations on interface elements refer to the interactive behavior of users adjusting the position of interface elements within the terminal's view interface. This involves a series of continuous interactive commands from the user using their finger or input device, such as a touchscreen or mouse, to interact with interface elements. Specifically, while selecting an interface element and maintaining contact, the user controls the touch point to continuously move within the view interface. This behavior is recognized by the terminal as a control signal that changes the spatial coordinates of the interface element or triggers related interactive logic. The touch point is the core location marker in the electronic device's view interface, establishing interactive relationships between the user and interface elements and transmitting dragging and other operation commands. It is a key reference point for locating the user's operation position and triggering subsequent interactive actions. In touchscreen devices, the touch point is the geometric center point of the contact area between the finger / stylus and the screen; in non-touchscreen devices, the touch point manifests as the real-time coordinates of the mouse cursor, trackball cursor, etc., on the screen.
[0074] It should be noted that there can be multiple interface elements, meaning that multiple elements move with multiple drag-and-drop touch points, and each interface element uses independent error detection logic.
[0075] In step 103, in response to the release of the drag operation, when a misoperation is detected in the drag operation, the interface element is controlled to return to its historical position in the movement trajectory based on the movement trajectory of the interface element in order to correct the misoperation in the drag operation.
[0076] It should be noted that a two-dimensional coordinate system is established in the view interface, for example, with the top left corner of the screen display area or the view interface as the origin. Under this reference, the current position of a draggable interface element can be uniquely determined by the coordinate values of its geometric center point or a preset specific vertex in the two-dimensional coordinate system, corresponding to the x and y coordinates (X, Y). The terminal will detect and record the sequence of coordinate value changes in real time according to a preset sampling frequency, and then confirm this series of coordinate points arranged in chronological order as the movement trajectory. The movement trajectory is not displayed before it is drawn in the view interface.
[0077] A drag operation being released refers to the technical determination point at which a user terminates their dragging interaction with a draggable interface element, thus dissolving the association between the touch point and the element. In touchscreen devices, a drag operation being released is manifested when the user completely removes their finger, stylus, or other device used for dragging from the screen. The capacitive sensor detects the disappearance of the physical contact signal between the touch point and the screen, thus determining a release. In non-touchscreen devices, it is manifested when the input device controlling the dragging operation terminates. For example, the left mouse button changes from pressed to released, the touchpad pressure drops to the system's threshold for no operation, or the trackball stops scrolling and no button is pressed. At this point, the drag control signal from the input device is detected to be interrupted, and the movement association between the touch point and the interface element is severed, thus determining a release.
[0078] Understandably, misoperation refers to an invalid trajectory segment or displacement deviation that does not conform to the user's expected goal during the release phase of a drag operation, caused by factors other than the user's subjective intention, such as finger tremors, friction when the finger leaves the screen, or operational inertia. This deviation is not the user's intention to actively adjust the element's position and directly causes the final landing point of the interface element to deviate from the user's pre-positioned target position, which is the core issue affecting the accuracy of drag operations. For example, in a list scrolling scenario, when a user quickly scrolls a long list and stops abruptly, the reverse scrolling displacement caused by the finger leaving the screen at the moment of release can lead to the list unexpectedly scrolling back; in an icon organization scenario, when a user drags an icon to the edge of the page and releases it, the icon may slide back to the original page instead of staying on the new page due to finger tremors; and in drawing or design software scenarios, the unexpected tail hook caused by the moment the pen tip is lifted after drawing can also occur.
[0079] In some embodiments, based on the movement trajectory of the interface element, before controlling the interface element to return to its historical position in the movement trajectory, a first movement distance of the interface element within a first time period before the drag operation is released, and a second movement distance of the interface element within a second time period before the drag operation is released are recorded; wherein, the first time period is longer than the second time period; in response to the distance difference between the first movement distance and the second movement distance being less than a preset first distance threshold and the second movement distance being less than the second distance threshold, it is determined that the drag operation contains an erroneous operation.
[0080] It should be noted that the difference between the first and second movement distances is used for judgment. This aims to accurately reconstruct the user's behavioral intent before the operation is released by comparing the displacement features of the two time windows. Specifically, if the difference between the first and second movement distances is less than the first distance threshold, it indicates that the user has significantly slowed down the movement speed of the interface elements before the drag operation is released. This can rule out intentional operations that actively accelerate and adjust the position, proving that the user intended to stop moving before stopping. In addition, if the second movement distance is less than the second distance threshold, it can further rule out intentional throwing or rapid sliding operations. This is consistent with the physical characteristics of unintended slippage caused by finger inertia and uneven force, indicating that the user's deviation before stopping was unintentional.
[0081] The second time period refers to the time window defined by the moment the drag operation is released and tracing back to the first preset duration. The second time period encompasses the physiological duration of the moment most users release their grip. The first time period refers to the time window defined by the start of the second time period and tracing back to the second preset duration. The first time period precisely covers the stage where the user intends to stop moving, specifically the process where the drag operation is approaching the target position and begins to slow down in preparation for stopping. For example, suppose a drag operation is released at the end of the 10th second. If the first preset duration is set to 2 seconds, then the second time period is the time window from the end of the 8th second to the end of the 10th second. If the second preset duration is set to 5 seconds, then the first time period is the time window defined by tracing back 5 seconds from the start of the second time period (i.e., the end of the 8th second), which is the time window from the end of the 3rd second to the end of the 8th second.
[0082] Correspondingly, the second movement distance refers to the spatial distance moved by the interface element within the second time period, that is, within a time window of the first preset duration preceding the release of the drag operation. The first movement distance refers to the spatial distance moved by the interface element within the first time period.
[0083] For example, see Figure 4 , Figure 4 This is a schematic diagram of the operation process provided in the embodiments of this application. Figure 1 The distance indicated by 401 is the first distance, and the distance indicated by 402 is the second distance.
[0084] In this way, by recording the movement distance of interface elements in the first and second time periods before the drag operation is released, and then judging the misoperation based on the difference between the first and second movement distances being less than a first threshold and the second movement distance being less than a second threshold, it is possible to accurately distinguish between the user's active operation intention and the unexpected offset when releasing the hand, which greatly reduces the probability of misjudgment and omission, significantly improves the interaction accuracy of drag operation, avoids unnecessary error correction interference, and ensures the smoothness of user operation.
[0085] In some embodiments, the first time period corresponds to the first trajectory segment in the movement trajectory, and the second time period corresponds to the second trajectory segment in the movement trajectory; the pause frequency of the touch point in the first trajectory segment and the second trajectory segment, the average acceleration between the second trajectory segment and the first trajectory segment, and the average movement speed of the touch point in the second trajectory segment are determined; the first contribution of the pause frequency to the first distance threshold, the second contribution of the average acceleration to the first distance threshold, the third contribution of the average movement speed to the first distance threshold, and the fourth contribution of the average movement speed to the second distance threshold are calculated; the first weighting coefficient corresponding to the first distance threshold is determined, and the first contribution, the second contribution, and the third contribution are weighted and summed based on the first weighting coefficient to obtain the first distance threshold; the second weighting coefficient corresponding to the second distance threshold is determined, and the first contribution, the second contribution, and the fourth contribution are weighted and summed based on the second weighting coefficient to obtain the second distance threshold.
[0086] It should be noted that the pause frequency refers to the number of times the touch point meets the preset pause judgment conditions within the first and second trajectory segments. The preset pause judgment conditions include that the movement distance of the interface element within the sampling time window is less than a preset pause distance threshold. For example, suppose the sampling time window is set to 50 milliseconds and the pause distance threshold is 2 pixels. When a user drags an application icon to put it into a folder, they slow down and make minor adjustments above the folder. During this process, continuous detection is performed: within the first 50 milliseconds, if the finger moves 1.5 pixels (less than 2 pixels), this is recorded as the first pause; within the next 50 milliseconds, if the finger moves 3 pixels (more than 2 pixels), it is not counted as a pause; within the following third 50 milliseconds, if the finger moves only 1 pixel (less than 2 pixels), this is recorded as the second pause.
[0087] Average acceleration refers to the ratio of the change in velocity to the change in time as an interface element moves from the first trajectory segment to the second trajectory segment. Specifically, the average velocity of the first trajectory segment (the ratio of the total length of the first trajectory segment to the duration of the first time period) and the average velocity of the second trajectory segment (the ratio of the total length of the second trajectory segment to the duration of the second time period) are obtained, along with the time interval between the first and second trajectory segments (the difference between the duration of the first and second time periods). The first velocity difference is determined as the difference between the average velocity of the second trajectory segment and the average velocity of the first trajectory segment. The ratio of the first velocity difference to the time interval is then calculated, and this ratio is the average acceleration.
[0088] The average movement speed is the average rate at which the interface element moves within the second trajectory segment. It is the ratio of the total length of the second trajectory segment to the duration of the second time period. For example, if the second trajectory segment lasts from 200 milliseconds before the user releases their finger to 50 milliseconds before the finger is released, taking a total of 150 milliseconds (0.15 seconds), and during this time, the interface element is detected to have moved a total of 12 pixels on the screen, then its average movement speed is calculated by dividing the total distance (12 pixels) by the total time (0.15 seconds), resulting in 80 pixels per second. This speed value reflects the average speed at which the user's finger moves when they are about to stop the operation.
[0089] In practical implementation, the first contribution of the pause frequency to the first distance threshold can be calculated in the following way: determine the pause frequency based on the pause frequency; obtain a preset pause scaling factor and a preset pause frequency, wherein the preset pause scaling factor is used to scale the logarithmic result calculated based on the pause frequency to control the overall numerical amplitude of the first contribution, so that it meets the requirements of the degree of impact of the pause frequency on the first distance threshold in the actual scenario, and the preset pause frequency serves as a reference benchmark for the pause frequency that may occur during user operation, and is used to compare with the actual calculated pause frequency and participate in the calculation of the logarithmic term of the first contribution; determine the first contribution based on the logarithmic function, the pause scaling factor, and the preset pause frequency. The calculation of the first contribution can be found in formula (1).
[0090] Formula (1) in, That is, the highest level of contribution; The pause scaling factor is a positive real number; The preset pause frequency is a positive real number; For the frequency of pauses, To prevent extremely small values where the denominator is 0, the value should be a very small positive real number, for example... .
[0091] In practical implementation, the second contribution of the average acceleration to the first distance threshold can be calculated as follows: obtain a preset acceleration benchmark value, a preset optimal acceleration, and a preset acceleration standard deviation; wherein, the preset acceleration benchmark value serves as the basic numerical reference for the second contribution, and is used to determine the overall numerical range of the second contribution by multiplying it with the Gaussian function result. The optimal acceleration represents the ideal average acceleration that makes the second contribution closer to the acceleration benchmark value. When the actual average acceleration is close to this value, the Gaussian function result is closer to 1, and the second contribution is higher. The acceleration standard deviation is used to control the rate at which the second contribution changes as the average acceleration deviates from the optimal acceleration; the second contribution is determined based on the Gaussian function, the acceleration benchmark value, the optimal acceleration, the acceleration standard deviation, and the average acceleration. The calculation of the second contribution can be found in formula (2).
[0092] Formula (2) in, That is, the second degree of contribution; The preset acceleration reference value is a positive real number; A is the average acceleration. The optimal acceleration is a real number. Let be the standard deviation of acceleration, which is a positive real number.
[0093] In practical implementation, the third contribution of average movement speed to the first distance threshold can be calculated in the following way: obtain the minimum and maximum values of the first distance threshold, the slope of the speed curve, and the base speed. The minimum and maximum values are preset to define the range of the first distance threshold. The maximum value is the upper limit of the contribution of average movement speed to the first distance threshold, and the minimum value is the lower limit of the contribution of average movement speed to the first distance threshold. The slope of the speed curve and the base speed are also preset. The slope of the speed curve is used to adjust the rate of change of the third contribution with the average movement speed and determine the sensitivity of the Sigmoid function (S-curve) to changes in the average movement speed. The base speed is the reference benchmark for the average movement speed. When the actual average movement speed is equal to this value, the third contribution will be at a critical transition position between the minimum and maximum values, which is the dividing point for the degree of influence of the average movement speed on the contribution. Based on the Sigmoid function (S-curve), the minimum value, the maximum value, the slope of the speed curve, the base speed, and the average movement speed, the third contribution is determined. The calculation of the third contribution can be found in formula (3).
[0094] Formula (3) in, That is, the third contribution level; The maximum value is greater than 1. real numbers; The minimum value is a positive real number. is the slope of the velocity curve, and is a positive real number; Average moving speed; Based on the base speed.
[0095] In practical implementation, the fourth contribution of average movement speed to the second distance threshold can be calculated in the following way: obtain the minimum and maximum values of the second distance threshold, the slope of the speed curve, and the base speed. The minimum and maximum values are preset to define the range of the second distance threshold. The maximum value is the upper limit of the contribution of average movement speed to the second distance threshold, and the minimum value is the lower limit of the contribution of average movement speed to the second distance threshold. The slope of the speed curve and the base speed are also preset. The slope of the speed curve is used to adjust the rate of change of the fourth contribution with the average movement speed, and to determine the sensitivity of the Sigmoid function (S-curve) to changes in the average movement speed. The base speed is the reference benchmark for the average movement speed. When the actual average movement speed is equal to this value, the fourth contribution will be at a critical transitional position between the minimum and maximum values, which is the dividing point for the degree of influence of the average movement speed on the contribution. Based on the Sigmoid function (S-curve), the minimum value, the maximum value, the slope of the speed curve, the base speed, and the average movement speed, the fourth contribution is determined. The calculation of the fourth contribution can be found in formula (4).
[0096] Formula (4) in, That is, the fourth contribution level; The maximum value is greater than 1. real numbers; The minimum value is a positive real number. is the slope of the velocity curve, and is a positive real number; Average moving speed; Based on the base speed.
[0097] It should be noted that the first weighting coefficient corresponding to the first distance threshold includes the first coefficient corresponding to the first contribution, the second coefficient corresponding to the second contribution, and the third coefficient corresponding to the third contribution. Accordingly, the first distance threshold is obtained by weighting and summing the first contribution, the second contribution, and the third contribution based on the first weighting coefficient. This can be achieved in the following way: calculate the product of the first coefficient and the first contribution to obtain the first initial contribution; calculate the product of the second coefficient and the second contribution to obtain the second initial contribution; calculate the product of the third coefficient and the third contribution to obtain the third initial contribution; and sum the first initial contribution, the second initial contribution, and the third initial contribution to obtain the first distance threshold. For example, the first weighting coefficients corresponding to the first distance threshold are as follows: the first coefficient corresponding to the first contribution is 0.5, the second coefficient corresponding to the second contribution is 0.3, and the third coefficient corresponding to the third contribution is 0.2. The currently calculated first contribution is 100, the second contribution is 20, and the third contribution is 50. When calculating in the above way, the first initial contribution is 50, the second initial contribution is 6, and the third initial contribution is 10. Then, the three are summed, and the first distance threshold is 66.
[0098] Similarly, the second weighted coefficients corresponding to the second distance threshold include the fourth coefficient corresponding to the first contribution, the fifth coefficient corresponding to the second contribution, and the sixth coefficient corresponding to the fourth contribution. Accordingly, the second distance threshold is obtained by weighting and summing the first contribution, the second contribution, and the fourth contribution based on the first weighted coefficients. This can be achieved as follows: calculate the product of the fourth coefficient and the first contribution to obtain the fourth initial contribution; calculate the product of the fifth coefficient and the second contribution to obtain the fifth initial contribution; calculate the product of the sixth coefficient and the fourth contribution to obtain the sixth initial contribution; and sum the fourth initial contribution, the fifth initial contribution, and the sixth initial contribution to obtain the second distance threshold. For example, the fourth coefficient corresponding to the first contribution is 0.2, the fifth coefficient corresponding to the second contribution is 0.3, and the sixth coefficient corresponding to the third contribution is 0.5. The currently calculated first contribution is 100, the second contribution is 20, and the fourth contribution is 50. When calculating in the above way, the initial fourth contribution is first obtained as 20, the initial fifth contribution is 6, and the initial sixth contribution is 25. Then, the three are summed, and the second distance threshold is 51.
[0099] In practice, the first weighting coefficient and the second weighting coefficient can be iteratively updated using the least squares method and the historical operation data of the user object. The historical operation data includes the pause frequency, average acceleration, and average movement speed of the user object during the historical drag operation.
[0100] In this way, by combining the frequency of pauses at the touch point, the average acceleration between the two trajectory segments, and the average moving speed of the second trajectory segment to calculate the contribution, and then assigning weighting coefficients according to the different judgment targets of the first and second distance thresholds, a dynamic threshold is finally obtained. This allows the threshold to accurately adapt to the actual operation characteristics of each drag, improves the accuracy of error judgment, effectively corrects unexpected offsets and ensures drag accuracy, and avoids unnecessary error correction interference, thus balancing operation accuracy and smoothness.
[0101] In some embodiments, when the interface element is an interface control, the control type to which the interface control belongs is determined; based on the control type, a first distance threshold and a second distance threshold corresponding to the interface control are determined.
[0102] It's important to note that in graphical user interfaces (GUIs), different UI controls have drastically different requirements for user input precision due to their varying functional roles. On one hand, for controls that require high precision and fine-grained input, users expect stable and accurate control. Therefore, a stricter threshold is needed to effectively filter out unintentional jitter or minor operational deviations caused by physiological limitations, thus ensuring accurate control. On the other hand, for controls primarily used for large-scale, overview-like movements, users prioritize smoothness and efficiency. In this case, a more lenient threshold should be used to provide a higher tolerance for operational errors, avoiding misinterpreting normal, rapid, and large-amplitude user actions as mistakes, and ensuring consistent interaction.
[0103] The control types can include adjustment, trigger, navigation, and selection controls. For example, adjustment controls (such as volume sliders, brightness sliders, and progress bars) are primarily used for precise numerical adjustments and have high precision requirements. The first distance threshold can be set to 8-12 pixels, and the second distance threshold to 5-8 pixels. Trigger controls (such as draggable floating buttons and function buttons) are used to trigger specific functions and have medium precision requirements. The first distance threshold can be set to 15-20 pixels, and the second distance threshold to 12-15 pixels. Navigation controls (such as page scrollbars and list scroll controls) are used to control the scrolling and positioning of the interface and have low precision requirements. The first distance threshold can be set to 20-25 pixels, and the second distance threshold to 15-20 pixels. Selection controls (such as draggable radio buttons and range selectors) are used to select specific options and have medium-to-high precision requirements. The first distance threshold can be set to 12-18 pixels, and the second distance threshold to 8-12 pixels. Each threshold matches its interaction precision requirements, balancing operational accuracy and smoothness.
[0104] In actual implementation, a setting interface can be displayed, and a first setting control for a first distance threshold and a second setting control for a second distance threshold can be displayed in the setting interface. In response to the setting operation based on the first setting control, the first distance threshold obtained by setting can be displayed, and the first distance threshold can be controlled to be the first distance threshold obtained by setting. In response to the setting operation based on the second setting control, the second distance threshold obtained by setting can be displayed, and the second distance threshold can be controlled to be the first distance threshold obtained by setting.
[0105] In this way, matching the corresponding first and second distance thresholds based on the type of interface control will prevent the misoperation of high-precision controls from being missed due to excessively wide thresholds, and will also prevent the frequent triggering of unnecessary error corrections for low-precision controls due to excessively strict thresholds. This will significantly improve the accuracy of misoperation judgment, while ensuring that the operation of different types of controls meets their respective precision requirements, and will not interfere with the smoothness of operation due to excessive error correction, ultimately optimizing the overall interactive experience.
[0106] In some embodiments, the second time period corresponds to the second trajectory segment in the movement trajectory; based on the movement trajectory of the interface element, controlling the interface element to return to the historical position in the movement trajectory can be achieved in the following way: based on the movement trajectory of the interface element, controlling the interface element to return to the starting position of the second trajectory segment in the movement trajectory.
[0107] Here, the second trajectory segment in the movement trajectory refers to the trajectory fragment in the complete movement trajectory of the interface element that completely overlaps with the second time period in terms of time range. The data of the second trajectory segment comes from the coordinate sequence of interface element positioning points (such as center point, preset vertex) collected at a preset sampling frequency during the second time period, and it is the associated carrier for error judgment and correction. When the difference between the first movement distance and the second movement distance is less than the preset first distance threshold, and the second movement distance is less than the second distance threshold, the second trajectory segment is the trajectory segment that includes the error.
[0108] Understandably, since the second trajectory segment itself represents an unexpected and invalid displacement, in order to accurately correct this erroneous operation, the interface element is rolled back to the starting position of the second trajectory segment. This starting position is precisely the end point of the user's valid intention and the starting point of the invalid operation. Rolling back to this position can accurately undo the erroneous operation, thereby restoring the interface element to the correct state.
[0109] As an example, see Figure 5 , Figure 5 This is a schematic diagram of the operation process provided in the embodiments of this application. Figure 2 The second trajectory segment corresponding to the second time period is the trajectory segment indicated by 501. Based on the movement trajectory of the interface element, the interface element is controlled to return to the starting position of the second trajectory in the movement trajectory, that is, the position indicated by 502.
[0110] In this way, returning the interface elements to the starting position of the second trajectory segment precisely meets the core requirement of correcting misoperations. The second trajectory segment corresponds to the instantaneous period before the drag operation is released, serving as the trajectory carrier of the misoperation. Its starting position is precisely the stable position that the user has actively dragged to before the misoperation occurred, perfectly matching the user's true operational intent. This reversal method can not only accurately eliminate the offset impact caused by misoperations within the second trajectory segment, avoiding functional deviations in adjustment controls due to offsets, but also completely preserve the operational results of the user's active dragging phase, ensuring operational continuity.
[0111] In some embodiments, in response to the distance difference between the first moving distance and the second moving distance being not less than a first distance threshold, or the second moving distance being not less than a second distance threshold, it is determined that the drag operation does not contain any erroneous operations.
[0112] For example, consider navigation controls (with a preset first distance threshold of 10 pixels and a second distance threshold of 8 pixels) and adjustment controls (with a preset first distance threshold of 8 pixels and a second distance threshold of 6 pixels): If a user drags the page scrollbar, the scrollbar moves 28 pixels (first movement distance) in the first period (0.8 seconds, reflecting the active dragging phase) before the drag is released, and 15 pixels (second movement distance) in the second period (0.1 seconds, the instant the user releases the scrollbar). The difference of 13 pixels is greater than the first distance threshold of 10 pixels, indicating that the user is still actively and quickly scrolling the page, and it is not an inertial offset after stopping the scroll. Therefore, the operation is considered to be without error. If a user drags the volume slider, the slider moves 9 pixels (second movement distance) in the second period before the volume is released, which is greater than the second distance threshold of 6 pixels. This indicates that the user is actively fine-tuning the volume (e.g., from 30% to 35%), rather than a slight offset caused by finger inertia. Similarly, the operation is considered to be without error, and neither case requires triggering the interface element backtracking correction.
[0113] In this way, by using the dual-condition judgment of the difference not being less than the first threshold and the second distance not being less than the second threshold, the user's valid input and non-intentional terminal jitter can be clearly distinguished. This significantly improves the accuracy of misoperation recognition while avoiding erroneous intervention in the user's true intention, thereby optimizing the accuracy and smoothness of human-computer interaction and providing a more reliable and intelligent user experience.
[0114] In some embodiments, based on the movement trajectory of the interface element, before controlling the interface element to return to the historical position in the movement trajectory, the pressure change of the touch point during the drag operation is recorded in real time; when the pressure change of the touch point is detected to be greater than the preset drop rate threshold, it is determined that the drag operation contains an error.
[0115] Here, when the drag operation is released normally, the user will subjectively control the force applied by the finger, and complete the operation by slowly reducing the pressure. The pressure reduction process is smooth and controllable. However, misoperation is an uncontrolled behavior that is not expected. The pressure will suddenly be lost in a short period of time. The reduction process is rapid and uncontrollable, and the rate of reduction is far beyond the normal range. Therefore, the rate of reduction of contact pressure can be used to identify whether the drag operation contains misoperation.
[0116] It should be noted that real-time recording of pressure changes at the touch point during dragging operations means that after the user triggers a dragging operation on an interface element, the device's pressure sensor continuously collects the pressure value applied to the interface at a preset sampling frequency and stores the dynamic data of pressure value changes over time in real time.
[0117] In actual implementation, the pressure sensor acquires the contact pressure values at different moments during the dragging process at a preset sampling frequency. The system acquires the first pressure value at the first moment and the second pressure value at the second moment, where the second moment is the next moment after the first moment, ordered sequentially. The pressure difference between the second and first pressure values is calculated to obtain the pressure difference value. The absolute value of the pressure difference is calculated to obtain the absolute pressure difference value. The time difference between the second and first moments is calculated to obtain the time difference value. The ratio of the absolute pressure difference value to the time difference is calculated to obtain the pressure drop rate. When the pressure drop rate exceeds a preset drop rate threshold, the interface element can be controlled to return to its position on the movement trajectory corresponding to the first moment.
[0118] The preset descent rate threshold is a critical value derived from statistical analysis of pressure changes based on a large amount of data from normal user release operations. This threshold is calculated by collecting pressure sensor data from users of different genders, ages, and usage habits under various scenarios, including normal drag-and-release and simulated accidental slippage. Statistical analysis, such as calculating a normal distribution and setting confidence intervals, yields an optimized value that can distinguish between two behavior patterns with high accuracy. The descent rate threshold can be fixed or dynamically adjustable. For example, it can be dynamically adjusted based on the current application scenario, the user's historical operating habits, or environmental factors to achieve a higher level of intelligent judgment. When the real-time descent rate exceeds the threshold, it indicates that the pressure change has deviated from the user's subjective control, consistent with the characteristics of misoperation.
[0119] For example, with a pressure drop rate threshold of 2 units per millisecond, the pressure sensor continuously detects the finger's contact pressure every 10 milliseconds (i.e., the preset sampling frequency). At the first sampling time t1 = 1500 milliseconds, the corresponding first pressure value P1 = 80 units. At the next sampling time, the second sampling time t2 = 1510 milliseconds, the second pressure value P2 = 50 units is obtained. At this time, the pressure difference is P2 - P1 = 50 - 80 = -30 units, with an absolute value of 30 units; the time difference is t2 - t1 = 1510 - 1500 = 10 milliseconds. Therefore, the pressure drop rate is calculated to be 30 / 10 = 3 units per millisecond. Since this rate exceeds the preset pressure drop rate threshold, this sudden pressure drop is determined to be a malfunction.
[0120] In this way, by recording the changes in contact pressure in real time, and judging erroneous operation by the rate of pressure drop exceeding a preset threshold, it is possible to accurately distinguish between normal and erroneous operation from the essence of the operation behavior, making up for the limitations of single distance judgment; improving the accuracy of erroneous operation identification, reducing misjudgment, and optimizing the accuracy of interface interaction and user experience.
[0121] In some embodiments, the moment when the pressure drop rate of the touch point equals a preset drop rate threshold before the drag operation is released is determined, and the position of the interface element at the moment when the pressure drop rate equals the preset drop rate threshold is recorded; correspondingly, based on the movement trajectory of the interface element, controlling the interface element to return to the historical position in the movement trajectory can be achieved in the following way: based on the movement trajectory of the interface element, controlling the interface element to return to the position of the interface element at the moment when the pressure drop rate equals the preset drop rate threshold.
[0122] It's important to note that the moment when the touch pressure drop rate equals the preset drop rate threshold is the critical juncture between the user's actively controllable operation and the uncontrolled deviation due to erroneous operation during dragging. Before this moment, the touch pressure drop rate is within the threshold range, allowing the user to control the movement of interface elements through subjective force. At this time, the position of the interface elements perfectly matches the user's active adjustment intention. After this moment, if the pressure drop rate exceeds the threshold, an erroneous operation judgment is triggered. The interface elements will undergo unexpected deviations due to factors such as accidental finger slippage or inertia, deviating from the user's actual operation target. The position of the interface element at this moment is the last stable position unaffected by erroneous operation during the user's active dragging process. Returning the interface element to this position can accurately eliminate the deviation caused by subsequent erroneous operations while fully preserving the user's previous active dragging results. This effectively avoids over-correction (returning to an earlier position) or incomplete correction (not completely eliminating the deviation), achieving precise and efficient correction of erroneous operations and further aligning with the user's interaction intention.
[0123] For example, the preset threshold for the rate of decrease in contact pressure is 2000 kPa / s, and pressure data is sampled at a frequency of 80 Hz. When a user drags an interface element, the pressure gradually decreases. At time t1, the rate of decrease in pressure is 1800 kPa / s (below the threshold). At time t2, the rate increases to 2200 kPa / s (above the threshold). The critical time t0 at which the rate equals 2000 kPa / s is calculated through interpolation. If this is determined to be a misoperation, the interface element is controlled to revert to time t0.
[0124] In this way, it can accurately lock the final effective position of the user's operation intention at the critical moment when the user loses control, and actively correct and eliminate subsequent invalid trajectory drift caused by physical factors such as hand slip, improve the fault tolerance and accuracy of drag operation, effectively avoid operation failure caused by misoperation, and thus bring users a smoother human-computer interaction experience.
[0125] In some embodiments, the operation processing method is executed by an electronic device. Before recording the pressure change of the contact point during the drag operation in real time, it detects whether a pressure sensor is provided in the electronic device. If the detection result indicates that a pressure sensor is provided in the electronic device, the operation of recording the pressure change of the contact point during the drag operation in real time is triggered. If the detection result indicates that a pressure sensor is not provided in the electronic device, the motion characteristics of the contact point are recorded to identify whether the drag operation contains a misoperation based on the motion characteristics of the contact point.
[0126] It should be noted that recording the motion characteristics of the touch points to identify whether the drag operation contains erroneous operations based on the motion characteristics of the touch points means recording the first movement distance of the interface element in the first time period before the drag operation is released, and the second movement distance of the interface element in the second time period before the drag operation is released; wherein, the first time period is longer than the second time period; in response to the distance difference between the first movement distance and the second movement distance being less than a preset first distance threshold, and the second movement distance being less than the second distance threshold, it is determined that the drag operation contains erroneous operations.
[0127] As can be understood, a pressure sensor is a hardware component capable of detecting and quantifying the physical pressure applied to the surface of an electronic device. It is used to acquire in real-time the magnitude of the force applied perpendicular to the screen surface by a user's touchpoint (such as a finger or stylus). By converting the sensed physical pressure into a processable electrical signal, the pressure sensor enables the device to not only identify the two-dimensional coordinates of the touchpoint but also sense its force in a third dimension. This provides direct and highly accurate quantitative evidence for distinguishing between subtle operational intentions such as intentional release and unintentional slippage.
[0128] In this way, by first checking whether the electronic device has a pressure sensor, and then selecting the data source for misoperation identification according to the situation, it can be adapted to devices with different hardware configurations, avoid functional failure due to the lack of a pressure sensor, enable devices with sensors to accurately identify misoperations through pressure data, and enable devices without sensors to identify them through motion characteristics, improve the versatility of the solution, and ensure that the misoperation identification function is effectively implemented on more devices.
[0129] In some embodiments, controlling the interface element to return to its historical position on the movement trajectory based on the movement trajectory can be achieved by the following method: when the distance between the end position of the movement trajectory and the historical position is greater than a distance threshold, a transition animation is played, and the interface element is controlled to return to its historical position on the movement trajectory according to the transition animation.
[0130] It's important to note that "historical position" refers to a key coordinate point within the entire dragging trajectory of an interface element, located before the final release point and representing the user's true intention to release. It's a stable anchor point found by backtracking and analyzing trajectory data after detecting a potential erroneous operation. The historical position can be a fixed point in time before the dragging operation ends, such as 0.1 seconds before release. This point represents the user's last stable state before the erroneous operation occurs. Alternatively, it can be the inflection point in the trajectory before a drastic change in speed or acceleration (i.e., exceeding a certain threshold), marking the boundary between smooth dragging and abnormal sliding. It can also be the position with the longest dwell time or a dwell time exceeding a preset duration, as the touch point typically pauses briefly when the user hesitates or prepares to release.
[0131] As can be understood, the endpoint position refers to the instantaneous coordinates of the user's finger or stylus when the drag operation is completed. The endpoint position constitutes the last data point of the recorded movement trajectory of the interface element, representing the original position where the interface element should have remained without any intervention.
[0132] The distance threshold is a preset value that defines the critical standard for determining whether a user operation is erroneous. Specifically, the distance threshold refers to the Euclidean distance between the endpoint and the historical position. When the distance between the endpoint and the historical position exceeds the distance threshold, a transition animation is triggered to avoid abrupt rewinding; otherwise, the user jumps directly to reduce redundant animation overhead.
[0133] It's important to note that to avoid the abrupt feeling of interface elements instantly teleporting back to their historical positions from the drag-and-drop point, and to allow users to intuitively perceive that the operation is being actively corrected, thus enhancing the user-friendliness and controllability of the interaction, interface elements are controlled to return to their historical positions along the movement trajectory using a transition animation. Controlling interface elements to return to their historical positions along the movement trajectory using a transition animation means, according to preset animation rules, driving the interface elements from the release point (the starting point of the return) after the drag operation ends, smoothly and gradually moving them to the historical position (the target of the return) that matches the user's actual operational intention, ensuring a visually continuous return process rather than an instantaneous jump. Transition animations can include various types, such as linear animation (elements move at a constant speed), gradual in / out animation (elements gradually speed up at the start and gradually slow down at the end, balancing smoothness and naturalness), and elastic damping animation (elements slightly bounce back and stabilize when approaching their historical positions, conveying gentle corrective feedback). Fade-in / fade-out effects can also be used to further enhance the visual recognition of the return.
[0134] In other embodiments, when the distance between the endpoint of the movement trajectory and the historical position is greater than a distance threshold, the interface elements are controlled to revert to the historical position in the movement trajectory, and the interface elements are highlighted during the reversion process.
[0135] In addition, it can display error message prompts and correction messages to indicate that an error has been detected in the drag operation.
[0136] In this way, the element can be controlled to fall back only when the distance between the end point of the movement trajectory and the historical position exceeds the threshold. This avoids the redundancy of animation for short-distance fallback and solves the abruptness of long-distance teleportation. By using smooth transition animation, the user interaction experience is improved in a visually coherent and guiding way, the system resource consumption is optimized, and the smoothness of the experience and performance efficiency are taken into account.
[0137] In some embodiments, controlling the interface element to return to its historical position within the movement trajectory based on the movement trajectory of the interface element can be achieved in the following way: based on the movement trajectory of the interface element, using a transition-free method, controlling the interface element to instantly move to its historical position within the movement trajectory.
[0138] In actual implementation, when the distance between the endpoint of the movement trajectory and the historical position is less than or equal to the distance threshold, a transitionless method is adopted to control the interface elements to instantly move to the historical position in the movement trajectory.
[0139] Understandably, to avoid operational delays or redundancy caused by transition animations during short-distance retracements, and to allow users to quickly return to the expected interface element position and maintain operational continuity, a transition-free approach is used to control the instantaneous movement of interface elements to their historical positions within the movement trajectory, based on the element's movement path. Using a transition-free approach to control the instantaneous movement of interface elements to their historical positions means that during the process of an interface element retrace from the endpoint of the drag operation to the target historical position, no transition animations, gradient effects, or intermediate movement steps are added; instead, the position switch is completed directly. In this way, controlling the instantaneous movement of interface elements to their historical positions without transitions eliminates redundant transition animations and avoids the sluggishness caused by animations during short-distance rollbacks, allowing users to quickly return to the expected positions of interface elements. At the same time, it reduces the resource consumption for animation rendering, ensuring operational continuity and adapting to low-performance devices, ensuring efficient rollback response under different hardware conditions.
[0140] In some embodiments, in response to an interface element returning to a historical position in a movement trajectory, at least one of the following is performed: outputting haptic feedback to prompt the interface element to return to a historical position; displaying the interface element with a target display style, wherein the target display style is used to indicate that the interface element has returned to a historical position.
[0141] It should be noted that outputting haptic feedback refers to the feedback method in which, after an interface element returns to its historical position on the movement trajectory, the electronic device transmits the result of the completed operation to the user in the form of tactile perception through physical vibration generated by its built-in vibration module (such as a linear motor or eccentric rotor motor). Haptic feedback provides a non-visual confirmation signal. Even if the user's attention is not fully focused on the screen, they can still perceive through their body's touch that the automatic correction operation has been successfully performed, thereby greatly enhancing the certainty of the operation and the realism of the physical world. For example, haptic feedback can include a single short vibration, 2-3 consecutive pulse vibrations, and vibrations with gradually varying intensity, etc. This application embodiment does not impose specific limitations on haptic feedback. Displaying interface elements using a target display style means displaying interface elements in a display style different from the default display style of interface elements, used to indicate that the interface elements have returned to their historical positions. For example, target display styles can include highlighting (the background or border color of an interface element briefly changes to a striking color), glow or outline effects (a soft halo or a sharp outline briefly appears around the edge of an interface element), pulse animation (the interface element performs a slight, elastic zoom-in and zoom-out animation), overlay confirmation icon (a small icon indicating successful rollback, such as a checkmark, briefly appears at the associated location of the interface element), and transparency blink (the transparency of the interface element changes rapidly once, creating a visual blink).
[0142] As an example, see Figure 6 , Figure 6 This is a schematic diagram of the operation process provided in the embodiments of this application. Figure 3 Taking the interface element indicated by 601 as an example, in response to the interface element returning to its historical position in the movement trajectory, the interface element 601 is displayed using the target display style.
[0143] In this way, after the interface element returns to its historical position in the movement trajectory, by performing at least one operation such as outputting haptic feedback or displaying the interface element with the target display style, the return completion signal can be accurately transmitted from the tactile or visual dimensions, avoiding users' misjudgment of the operation status and improving the credibility of the interaction.
[0144] In some embodiments, based on the movement trajectory of the interface element, after controlling the interface element to return to its historical position on the movement trajectory, in response to the number of times the interface element returns in the view interface within a preset time reaching a threshold, a sensitivity adjustment prompt message and a corresponding sensitivity adjustment control are displayed; wherein, the sensitivity adjustment prompt message is used to prompt for adjusting the trigger sensitivity of erroneous operation.
[0145] Understandably, if the number of times interface elements are rolled back within a preset time reaches a certain threshold, it indicates that the current trigger sensitivity for accidental operations may not match the user's actual operating habits. For example, if the sensitivity is too high, normal dragging may be frequently judged as accidental operations and trigger rollback, or if the sensitivity setting is inappropriate, the user may need to correct their operation multiple times, affecting the smoothness of the user's operation. Therefore, a sensitivity adjustment prompt and corresponding controls will be displayed to guide the user to adjust the trigger sensitivity for accidental operations according to their own operating habits, reduce unnecessary subsequent interface rollbacks, and optimize the interactive experience.
[0146] In actual implementation, in response to the adjustment command of the trigger sensitivity of the erroneous operation based on the sensitivity adjustment control, the trigger sensitivity of the erroneous operation is adjusted to the adjusted trigger sensitivity.
[0147] The preset time refers to a pre-defined time period used to count the number of times interface elements are rolled back, defining the time range for the count. For example, a preset time of 1 minute or 3 minutes is used, and its value should match the typical duration of a user's single operation session, such as when most users' continuous single operation sessions are concentrated between 1 and 5 minutes. The number of times an interface element is rolled back refers to the cumulative number of times all draggable interface elements in the same view interface trigger the "rollback to historical position in the movement trajectory" operation within the preset time. The number threshold refers to a preset critical number of times that triggers the "display sensitivity adjustment prompt information and control," which is a critical value for "user-perceived operation interference" derived from a large amount of user operation data statistics. For example, if most users roll back more than or equal to 5 times within 1 minute, they will clearly perceive a lack of smoothness in the operation. The sensitivity adjustment control refers to an interactive component that allows users to directly adjust the "sensitiveness triggered by accidental operation." The form of the sensitivity adjustment control can include sliders, drop-down menus, tiered buttons, etc. This application embodiment does not impose specific limitations on the form of the sensitivity adjustment control.
[0148] As an example, see Figure 7 , Figure 7 This is a schematic diagram of the operation process provided in the embodiments of this application. Figure 4 In response to the number of times the interface element in the view interface is rolled back within a preset time reaching a threshold, a sensitivity adjustment prompt message 701 and corresponding sensitivity adjustment controls 702 and 703 are displayed. The sensitivity adjustment control 702 is used to decrease the trigger sensitivity, and the sensitivity adjustment control 703 is used to increase the trigger sensitivity.
[0149] In this way, when the number of times an interface element in the view interface is rolled back reaches a threshold within a preset time, a sensitivity adjustment prompt and corresponding control are displayed. This can promptly capture the problem of "misoperation triggering sensitivity that does not match the user's operating habits" (such as frequent rollbacks interrupting normal operation), guiding the user to actively optimize the sensitivity. The technical effect is that the system has intelligent adaptation capabilities, which can meet the operating preferences of different users through intuitive controls, reduce unnecessary rollbacks, avoid users being troubled by unsuitable sensitivity for a long time, and significantly improve the smoothness and personalization of the interaction.
[0150] In some embodiments, a misoperation correction switch that is in a closed state is displayed in the view interface; in response to an operation to turn on the misoperation correction switch, the misoperation correction switch is turned on; correspondingly, in response to the release of a drag operation, when a misoperation is detected in the drag operation, the interface element is controlled to return to a historical position in the movement trajectory based on the movement trajectory of the interface element. This can be achieved in the following way: in response to the release of a drag operation, when the misoperation correction switch is turned on, when a misoperation is detected in the drag operation, the interface element is controlled to return to a historical position in the movement trajectory based on the movement trajectory of the interface element.
[0151] Here, in order to completely return the power to start and stop the misoperation correction function to the user and avoid the function being forcibly triggered, such as automatically reverting when the user wants to retain the result of manual dragging, thus undermining the user's autonomy, and allowing the user to flexibly choose whether to enable the function according to their own needs, the misoperation correction switch is first displayed in the view interface in a closed state. The function is activated after responding to the user's activation operation. Accordingly, only when the misoperation correction switch is turned on will the drag operation be released and the misoperation be detected, and the drag operation will be controlled to revert to the historical position based on the movement trajectory of the interface element.
[0152] The misoperation correction switch is an interactive control in the view interface used to control the activation and deactivation of the "misoperation correction function." When the misoperation correction switch is activated, if a drag operation contains a misoperation and the operation is released, it will control the interface element to return to the historical position of the movement trajectory. When deactivated, the correction action will not be performed, allowing the user to decide whether to enable the automatic misoperation correction function. The misoperation correction switch has an on and off state and can be a graphical toggle button, checkbox, option, or any other interactive element that allows the user to clearly express their intention to activate or deactivate it. This application embodiment does not impose specific limitations.
[0153] It should be noted that the activation operations for the error correction switch include: click operation, long press operation, swipe operation, touch operation, button operation, gesture operation, etc., and this application embodiment does not impose specific limitations.
[0154] As an example, see Figure 8 , Figure 8 This is a schematic diagram of the operation process provided in the embodiments of this application. Figure 5 The view interface displays the malfunction correction switch, which is in the off state as indicated by 801; in response to the opening operation of the malfunction correction switch indicated by 801, the malfunction correction switch is opened, as indicated by 802. When the malfunction correction switch is opened, if a malfunction is detected in the drag operation, the interface element is controlled to return to the historical position in the movement trajectory based on the movement trajectory of the interface element.
[0155] It should be noted that the specific location points in the accompanying drawings provided in this application embodiment are not displayed in the actual view interface, and the movement trajectory will not be displayed in the view interface before it is drawn. The location points and movement trajectory in the figure are only for illustration.
[0156] In this way, the error correction switch, which is off by default, is first displayed in the view interface. Only after the user turns it on will the interface elements be controlled to go back when the drag operation is released and the error is detected. This gives the user complete control over starting and stopping the error correction function, avoiding forced triggering of the function and interference with the user's autonomy. It can flexibly adapt to different user operating habits, and at the same time form a clear association between the switch status and the function's effectiveness, allowing users to clearly perceive whether the function is effective, reducing user confusion and improving the controllability of the interaction.
[0157] In some embodiments, in response to a drag operation on an interface element, the movement trajectory of the interface element is drawn in real time in the view interface; in response to the interface element returning to a historical position in the movement trajectory, the corresponding returned portion in the movement trajectory is marked as invalid or removed from the movement trajectory.
[0158] It should be noted that drawing the movement trajectory of interface elements in real time in the view interface refers to the process of capturing every coordinate change of the interface element in real time during the dragging process through touch event interface, mouse position detection, etc., when the user object performs a drag operation on the draggable interface element, and converting these continuous coordinate points into a visual path (such as a solid line, a line with nodes, etc.) and presenting it on the interface. In the end, the user object can intuitively see the complete movement path of the element from the initial position to the current drag position.
[0159] Marking the corresponding retracement portion in the movement trajectory as invalid means that after an interface element successfully retraces from its drag-and-release position to its historical position in the movement trajectory, the retracement path is visually differentiated. This could involve changing the color of the trajectory segment, switching the line from solid to dashed, or reducing its opacity; or displaying an invalid message at the associated location of the retracement portion to indicate that the retracement is invalid. Removing the corresponding retracement portion from the movement trajectory means that after an interface element successfully retraces from its drag-and-release position to its historical position in the movement trajectory, the coordinate data and visual representation of the retracement path are directly deleted. In other words, this retracement path caused by the erroneous operation will no longer be displayed in the view interface.
[0160] As an example, see Figure 9 , Figure 9 This is a schematic diagram of the operation process provided in the embodiments of this application. Figure 6 In response to a drag operation on interface element 901, the movement trajectory of interface element 901 is drawn in real time in the view interface; in response to the interface element returning to a historical position in the movement trajectory, the corresponding returned part in the movement trajectory is removed from the movement trajectory.
[0161] In this way, drawing the movement trajectory in real time when the user drags the interface element allows the user to intuitively see the actual movement path of the element, avoiding deviations and misjudgments caused by blind operation. After the element returns to the historical position, the corresponding return trajectory segment is marked as invalid or removed directly. This not only helps the user to control the operation process in real time and detect deviations in time, but also clearly defines the invalid path after correcting the misoperation, avoiding invalid trajectory from interfering with the user's understanding of the valid operation, and improving the clarity of the interaction and the efficiency of operation.
[0162] In some embodiments, in response to the interface element returning to a historical position in the movement trajectory, an undo control is displayed in the view interface; in response to a trigger operation on the undo control, the interface element is controlled to move to the endpoint position of the interface element when the drag operation is released.
[0163] It should be noted that after an interface element reverts to its historical position on the movement trajectory, users may perceive the revert as a miscorrection (e.g., the original intention was to drag the element to the endpoint when it was released, but it was judged as a misoperation and reverted), and may need to restore the state before the revert. Therefore, an undo control will be displayed in the view interface. When the user triggers this control, the interface element can be precisely moved to the endpoint when the drag operation was released, providing the user with a way to remedy the revert operation and avoiding operational inconvenience caused by irreversible reverts.
[0164] Among them, the triggering operation refers to the behavior of the user to trigger a certain function or event by interacting with the display interface of the terminal. The triggering operation can include one or more of the following: single click operation, double click operation, long press operation, drag operation, swipe operation, hover operation, shortcut key, voice control, and gesture operation. The triggering operations provided in the embodiments of this application can be referred to the above description, and will not be repeated hereafter.
[0165] As an example, see Figure 10 , Figure 10 This is a schematic diagram of the operation process provided in the embodiments of this application. Figure 7 In response to the interface element 1001 returning to its historical position on the movement trajectory indicated by 1002, the undo control 1003 is displayed in the view interface; in response to the trigger operation on the undo control 1003, the interface element is moved to the endpoint position of the interface element when the drag operation indicated by 1004 is released.
[0166] In this way, after the interface element returns to its historical position in the movement trajectory, the undo control is displayed, and triggering the control can restore the element to the endpoint position when it was dragged and released. This provides users with a way to recover from the undo operation, avoids operational confusion caused by misjudgment or subsequent changes in user intent, and makes the interaction more in line with the user's actual operation intent.
[0167] In some embodiments, in response to the release of the drag operation, when a erroneous operation is detected in the drag operation, before the interface element is controlled to return to a historical position in the movement trajectory based on the movement trajectory of the interface element, it is detected whether the touch point position of the drag operation is located in the edge area of the view interface; in response to the touch point position being located in the edge area, the judgment threshold for identifying erroneous operations is increased.
[0168] It should be noted that, due to the limited operating space in the edge areas of the view interface (e.g., fingers are easily obscured at the edges in touchscreen devices, and cursors near the boundaries in desktop devices are easily interfered with by system gestures), the probability of operation deviations such as touch point offset and pressure fluctuations is significantly higher in these areas than in non-edge areas. If the default misoperation judgment threshold is used, normal edge dragging operations are easily misjudged as misoperations, causing interface elements to be unnecessarily pushed back, affecting the continuity of operation. Therefore, it is necessary to first detect whether the touch point of the dragging operation is located in the edge area. If it is confirmed that the touch point is in the edge area, the misoperation judgment threshold should be increased to compensate for the slip operation caused by accidental touch at the edge. By increasing the tolerance for edge operation deviations, normal edge operations are avoided from being misjudged, while ensuring that the accuracy of misoperation recognition is maintained at the default threshold in non-edge areas, thus balancing operation fault tolerance and judgment accuracy.
[0169] In practice, determining whether the touch point of the drag operation is located in the edge area of the view interface can be done in the following way: obtain the position coordinates of the touch point of the drag operation. The position coordinates are determined based on a two-dimensional coordinate system. The two-dimensional coordinate system can be established with the top left corner of the screen display area or the view interface as the origin. Determine the coordinate range corresponding to the edge area of the view interface. When the position coordinates of the touch point are within the coordinate range, it is determined that the touch point of the drag operation is located in the edge area of the view interface.
[0170] For example, in the document editing interface (view interface) of a touchscreen tablet, the area of 8%-12% on the right side of the screen is set as the edge area. When the user drags the text selection slider in the document, the touch point is detected to be falling on the right edge area. At this time, the original 3px drag trajectory offset misjudgment threshold is increased to 6px. Even if the user's drag trajectory is accidentally offset by 4px due to the limited space for edge operation, it will not exceed the increased threshold and will not be misjudged as a misoperation, ensuring that the text selection slider can normally follow the drag to complete the selection adjustment.
[0171] In this way, by detecting whether the touch point of the drag operation is located in the edge area of the view interface, and increasing the error judgment threshold when it is confirmed to be in the edge area, the problem of deviation caused by space limitations in edge area operations can be specifically solved. This avoids the default threshold being too strict, which would cause normal edge dragging to be misjudged as an error operation. This not only improves the smoothness of edge area operations and reduces repeated operations caused by users backing up due to misjudgment, but also allows non-edge areas to maintain the default threshold to ensure the accuracy of error recognition, thus achieving a balance between operation fault tolerance and judgment accuracy.
[0172] In some embodiments, during the back navigation of an interface element, the back navigation process is interrupted in response to a touch operation performed in the view interface.
[0173] Here, when an interface element is dynamically reverting to its historical position due to a previous misoperation—for example, a volume slider moving back from its initial position to a correct one, or a scrollbar in a document sliding back from its misoperation location to a reasonable position—if the user performs any touch operation within the current view, such as clicking a blank area, swiping the screen, triggering an interface element, or interacting with another interface element, the system will capture this touch command in real time and respond immediately. It will then stop the element's reverting action, keeping the element at the point where the revert was interrupted, rather than continuing the remaining revert path. This allows the user to actively intervene during the revert process, avoiding operational confusion caused by automatic reverting not meeting actual needs, and giving the user greater control over the operation results.
[0174] For example, in the volume control interface of a mobile music app, the volume slider is being reverted from its current position to its correct historical position because the previous dragging was determined to be a mistake. At this moment, the user clicks the play button on the interface (a touch operation within the view interface), which immediately responds and interrupts the reversion process of the volume slider. The slider stops directly at the position at the moment the reversion is interrupted and does not continue to move back.
[0175] In this way, during the automatic back navigation of interface elements, users can interrupt the back navigation at any time through touch operations on the view interface, giving users the right to actively intervene in the back navigation process, avoiding the system from completing the back navigation according to preset logic, making the interaction more in line with the user's real intention, improving the flexibility and fault tolerance of operation, and avoiding experience lag or operation rework caused by the system forcibly completing the back navigation.
[0176] In some embodiments, a prompt sound effect is played during the back navigation of an interface element; wherein, the longer the back navigation distance of the interface element, the higher the pitch or the louder the volume of the prompt sound effect.
[0177] When an interface element is determined to have been misoperated and is in the process of dynamically reverting to its historical position in its movement trajectory, a prompt sound effect will be played simultaneously to allow the user to perceive the reverting action through auditory feedback. At the same time, the sound effect parameters will be adjusted according to the real-time reverting distance of the interface element. If the reverting distance from the current position to the target historical position is longer, the pitch of the prompt sound effect will rise accordingly (e.g., gradually transitioning from a low pitch to a high pitch), or the volume of the sound effect will increase accordingly (e.g., gradually increasing from a low volume).
[0178] In this way, users can intuitively perceive the extent of the interface element's backward movement through changes in the intensity and pitch of sound. Even if their eyes are not focused on the backward movement element, they can quickly judge the progress and range of the backward movement through sound effects, avoiding the perception delay or misjudgment that may result from relying solely on visual feedback.
[0179] In some embodiments, operation data during the drag operation is acquired; the operation data is input into a threshold determination model; wherein the threshold determination model includes a first threshold determination model and a second threshold determination model, the first threshold determination model is used to determine a first distance threshold, and the second threshold determination model is used to determine a second distance threshold; the first distance threshold is determined based on the first threshold determination model, and the second distance threshold is determined based on the second threshold determination model.
[0180] Here, the determination of the first distance threshold and the second distance threshold can be achieved by the corresponding dedicated sub-model in the threshold determination model. Specifically, the operation data during the drag operation is first obtained and input into the threshold determination model. The determination of the first distance threshold is achieved by the first threshold determination model in the model that is dedicated to processing the calculation of the first distance threshold, and the determination of the second distance threshold is achieved by the second threshold determination model in the model that is dedicated to processing the calculation of the second distance threshold.
[0181] It should be noted that the operation data during the drag operation process refers to various types of data that reflect the operation characteristics collected by the electronic device through sensors or system interfaces during the entire process of the user object dragging the interface element, including at least one of the following: real-time coordinates of the touch point during the drag process, the distance the touch point moves per unit time, the number of times the touch point pauses and the duration of each pause, the pressure change value of the touch point, and the average speed and average acceleration of the touch point movement.
[0182] In practice, the first threshold determination model can be a regression model. Feature extraction is performed on the operation data to obtain operation features. The operation features are then input into the regression model, and based on the regression model, nonlinear fitting is performed on the operation features to obtain a feature representation in high-dimensional space. Based on the feature weight coefficients determined during the training phase of the regression model, a weighted operation is performed on the feature representation in high-dimensional space to obtain the first distance threshold that is suitable for the current drag operation scenario.
[0183] Similarly, the second threshold determination model can be a regression model, which extracts features from the operation data to obtain operation features; inputs the operation features into the regression model, and performs nonlinear fitting on the operation features based on the regression model to obtain the feature representation in high-dimensional space; and performs weighted calculation on the feature representation in high-dimensional space based on the feature weight coefficients determined during the training phase of the regression model to obtain the second distance threshold that is suitable for the current drag operation scenario.
[0184] It should be noted that the first threshold determination model and the second threshold determination model here can also be decision tree model, random forest model, gradient boosting tree model or neural network model. All of them can determine the first distance threshold and the second distance threshold by receiving the operation data during the drag operation.
[0185] In this way, by using separate models to address the specific needs of determining different distance thresholds, we can avoid the parameter adaptation bias that may occur when a single model takes into account the calculation of two thresholds. This allows the calculation of the two types of distance thresholds to better align with their respective judgment logic in misoperation identification, thereby improving the accuracy of distance threshold determination and providing reliable threshold support for the subsequent accurate identification of misoperations in dragging operations.
[0186] In some embodiments, in response to the undoing of the back operation on the interface element within a preset time after the interface element is undone, a negative feedback sample is generated; the weight parameters in the threshold determination model are updated using the negative feedback sample.
[0187] Understandably, the occurrence of a rollback operation for a specific interface element within a preset time after the element is rolled back indicates a deviation in the previous determination of the required rollback based on the threshold-determined model output threshold. This means that the model's current weight parameters are not accurately adapted to this type of operation scenario. Therefore, by generating a corresponding negative feedback sample and substituting it into the parameter update process of the threshold-determined model, the weight parameters affecting the threshold calculation in the model are adjusted and optimized to improve the accuracy of the model's subsequent output distance threshold and reduce similar misjudgment rollbacks.
[0188] It should be noted that a rollback operation refers to an operation performed by the user within a preset time after an interface element has completed its rollback (such as returning from the current position to a previous position) in order to cancel the rollback action and restore the interface element to its previous state. Rollback operations may include displaying a rollback control and then triggering the rollback control to control the interface element to rollback; dragging the interface element to the position of the interface element when the drag operation was released; triggering rollback through a preset shortcut key, etc. As long as the operation is performed by the user within a preset time after the interface element has completed its rollback action in order to cancel the rollback action and restore the interface element to its previous state, it is a rollback operation. This application embodiment does not impose specific limitations on rollback operations.
[0189] In actual implementation, when an interface element completes the rollback, if an undo rollback operation is detected for that interface element within a preset time, the original operation data corresponding to this rollback and the distance threshold output by the model are captured as negative feedback samples. The negative feedback samples are input into the threshold to determine the model. Through the parameter adjustment logic built into the model, such as backpropagation and weight iteration optimization, the weight parameters in the model are corrected and updated to complete the optimization of the model parameters.
[0190] In this way, if a rollback operation is detected for an element within a preset time after the element is rolled back, a negative feedback sample is generated. This sample is then used to update the threshold and determine the model's weight parameters. This allows the model to promptly capture any deviations in the previous threshold judgment and continuously improve the accuracy of the model's calculation of the first and second distance thresholds through weight optimization. This reduces subsequent false rollbacks caused by inaccurate thresholds, ultimately improving the accuracy of the interface operation and the user interaction experience.
[0191] By applying the embodiments described above, the accuracy and fault tolerance of the interaction are greatly improved by intelligently identifying and automatically correcting user errors when dragging interface elements. It can dynamically judge errors not only by analyzing various data such as movement trajectory and touch pressure, but also adaptively adjust the judgment criteria based on element type and even through machine learning models, making the recognition both intelligent and reliable. Once an error is detected, the element is automatically returned to the position of the user's true intention, and clear and user-friendly feedback is provided through various means such as animation, sound effects, and haptic feedback. Furthermore, users can interrupt the return process at any time through new touch operations or undo the error correction results, and sensitivity adjustment options are provided, ultimately improving operational fault tolerance and interactive flexibility, and optimizing the overall user experience.
[0192] The following will describe an exemplary application of the embodiments of this application in a real-world application scenario.
[0193] In related technologies, solutions to the "slippery" problem (i.e., accidental operation) in swiping operations mainly fall into two categories. The first category is based on hardware filtering mechanisms. Its detection timing focuses on filtering signals during the period when the finger leaves the screen. During error correction, it discards relevant data after the finger is released. Although it can handle noise signals when the finger leaves the screen, such as finger tremors, it has obvious limitations: it cannot identify and process trajectory offsets before the finger is released, making it difficult to deal with accidental operations before the finger is released, and its effect on improving the slippery problem is limited; moreover, because it relies on high-precision capacitive sensors, the failure rate is high on devices with lower hardware configurations, and its adaptability is narrow. The second category is based on weighted algorithms, which use a weighted calculation method throughout the process. During error correction, it can only achieve trajectory smoothing but retains the offset. Although this type of solution does not require additional hardware support and can be deployed purely in software, its shortcomings are also prominent: not only can the weighted algorithm not completely eliminate the offset, resulting in residual errors in the slippery problem; continuous filtering throughout the process may also interfere with the user's fine operation and affect the accuracy of operation.
[0194] Based on this, this application provides an operation processing method. On the one hand, it has a precise operation feature recognition capability. By quantitatively analyzing the distance of touch point movement within two specific time windows, it can effectively distinguish between the user's "intentional operation" and the unexpected "slip-on" behavior, avoiding misjudging normal operation as "slip-on". On the other hand, it has a zero-deviation backtracking function. When the preset triggering conditions are met, it will automatically reset the final position of the touch point to the coordinates of the correct time (i.e., up to the history), eliminating the position offset caused by "slip-on" from the root.
[0195] The following section will continue to describe the operation and processing methods provided in the embodiments of this application from the product side.
[0196] See Figure 11 , Figure 11 This is a schematic diagram of the operation process provided in the embodiments of this application. Figure 8 The player first slides the touch point from its initial position P1 towards the preset target position P2. The distance the touch point moves during this initial phase is denoted as A (the first movement distance, the first trajectory segment), corresponding to the player's intentional action of actively moving towards the target. However, during the subsequent release, due to finger inertia or unintentional touch, the touch point may not remain stably at the target point P2, but instead continue moving to an unexpected position P3. This additional movement distance generated by the unintentional action is denoted as B (the second movement distance, the second trajectory segment). When this occurs, the system automatically identifies the movement of the touch point from P2 to P3 as an unintended "slip" action based on pre-set judgment rules. It then activates an error correction mechanism, reverting the final landing point of the touch point back to the player's original target position P2 (the starting position of the second trajectory segment), ensuring that the operation result matches the player's true intention and preventing "slip" actions from interfering with the operation effect.
[0197] The following section will continue to describe the operational processing methods provided in the embodiments of this application from a technical perspective.
[0198] See Figure 12 , Figure 12 This is a schematic diagram of the second process of the operation processing method provided in the embodiments of this application. The following will be combined with... Figure 12 The steps shown illustrate the operation processing method provided in the embodiments of this application.
[0199] In step 1201, the player makes an input.
[0200] This step is the starting point of the entire operation process. Specifically, it refers to the player actively swiping on the touch screen of the mobile device, that is, touching the screen with their finger and moving the touch point in the target direction. During this process, the movement of the touch point is dominated by the player's operation intention and is the basic operation behavior for subsequent trajectory recording and judgment.
[0201] In step 1202, the trajectory of the contact point within the most recent time period T1 is recorded.
[0202] In some embodiments, T1 is a preset total trajectory analysis time. During the player's swipe operation, the complete movement path of the touch point within the "most recent T1 time period" is captured and continuously recorded in real time, including the coordinate changes at every moment, so as to provide complete data support for the subsequent calculation of the total displacement distance of the touch point within this time period.
[0203] In step 1203, input is stopped.
[0204] In some embodiments, after a player completes a swipe in the target direction, they enter the release phase, where their finger gradually leaves the touchscreen. At this point, the touch point is no longer under the player's active control, and the player's active input behavior officially ends. However, during this phase, the touch point may move unexpectedly due to finger inertia or unintentional touch. This is the key phase for determining "slipping" later.
[0205] In step 1204, the movement distance A within T1 and the movement distance B within T2 are recorded.
[0206] In some embodiments, based on the trajectory data recorded in step 1202, two key distances are calculated: first, A is the total distance the touch point moves within the T1 time period (total trajectory analysis time), reflecting the overall amplitude of the player's active swipe operation; second, T2 is the "intent stabilization period" before the player releases their hand, that is, the stable phase from the accurate positioning of the target to the release of the hand, and B is the total distance the touch point moves within the T2 time period, mainly reflecting the small movement of the touch point before the release of the hand.
[0207] In step 1205, it is determined whether AB is less than X.
[0208] If yes, proceed to step 1206; otherwise, proceed to step 1207.
[0209] In some embodiments, X is a preset "stop intention determination threshold". The core purpose of this determination is to identify the operation trend of the player before releasing the hand: if AB is less than X (i.e., the first distance threshold), it means that the overall sliding amplitude in the T1 time period is small compared with the small movement in the T2 time period. This means that the player has actively slowed down the movement speed of the touch point before releasing the hand and has a clear intention to stop the movement of the touch point, providing the first key basis for subsequent "slip of the hand" judgment.
[0210] In step 1206, it is determined whether B is less than Y.
[0211] If yes, proceed to step 1208; otherwise, proceed to step 1207.
[0212] In some embodiments, Y is a preset "slip-on judgment threshold". This judgment focuses on whether the movement is reasonable within the T2 time period (intent stabilization period): if B is less than Y (i.e. the second distance threshold), it means that the movement of the touch point within this time period is extremely small, which is a small offset not actively controlled by the player, which is consistent with the characteristics of "slip-on" behavior and is the second key basis for judging "slip-on".
[0213] No processing is performed in step 1207.
[0214] In some embodiments, if either step 1205 or step 1206 is not met, it will be determined that the movement of the current touch point is the player's active operation and there is no "slip" situation - either the player has no obvious intention to stop before releasing the hand, or the movement in the T2 time period is an intentional adjustment. Therefore, there is no need to activate the error correction mechanism, keep the final position of the touch point unchanged, and avoid interfering with the player's normal operation.
[0215] In step 1208, the contact is traced back to the position at time T2.
[0216] In some embodiments, when both conditions in steps 1205 and 1206 are met simultaneously, it can be clearly determined that the movement of the touch point after T2 is a "slip of the hand" behavior. In order to match the player's true operation intention, a backtracking error correction mechanism will be activated to reset the final position of the touch point to the coordinates at time T2 (the intention stabilization period), completely eliminating the unexpected offset caused by "slip of the hand" and ensuring that the operation result is consistent with the player's goal.
[0217] Building upon the pure time-series backtracking scheme based on dual-level time windows (T1, T2) and threshold judgment (X, Y) mentioned above, to further improve the timeliness and accuracy of identifying accidental hand movements, while also considering the compatibility with devices of different hardware configurations, a pressure-time-series fusion backtracking scheme can be adopted. The core innovation of this scheme lies in adding pressure sensor data as a pre-judgment dimension for backtracking triggering: when the real-time detection shows that the rate of decrease in touch pressure exceeds a preset threshold (i.e., the rate of decrease in touch pressure is greater than the preset rate of decrease), it will quickly determine that the player is in the release phase of rapidly lifting their finger. At this time, it will immediately block subsequent touch input signals until the touch pressure rises again (such as when the player presses the screen again), thereby blocking the extra input caused by finger inertia or unintentional touch during the release process from the source, minimizing unexpected deviations; at the same time, the scheme also considers the actual scenarios of device hardware differences and designs a flexible avoidance mechanism—if it is detected that the current device is not equipped with a pressure sensor, it will automatically switch back to the pure time-series scheme mentioned above, ensuring that the hand movement correction function is not limited by hardware. This design also allows for comprehensive coverage of the solution's applicability, meeting the high requirements of hardware-enhanced devices equipped with pressure sensors as well as adapting to general-purpose touch devices without additional hardware. It ensures basic error correction capabilities through pure software rollback, achieving dual optimization of functionality and adaptability.
[0218] To further improve the accuracy of judging the player's swipe gesture intent, the judgment logic can be optimized by adding a prediction window, based on the original two-level time window of T1 (total trajectory analysis time) and T2 (intent stabilization period). On the one hand, a prediction window T3 is added between T1 and T2, which compares the swipe speed changes of the touch point in real time during the T1 to T3 time period. If a continuous decrease in speed is detected, it can be more clearly judged that the player has the tendency to stop moving the touch point, effectively reducing the intention misjudgment that may occur in single time window analysis, and making the "intent to stop moving the touch point" recognition more in line with the actual operation behavior. On the other hand, another prediction window T4 is added between T1 and the moment the player actually releases the touch. By analyzing whether the swipe speed decreases during the T1 to T4 time period, if the speed does decrease, it can be judged that the player no longer has the intention to actively adjust the touch point position, thereby more accurately identifying unexpected "slip-and-click input" and avoiding misjudging the player's active fine-tuning operation as a slip-and-click.
[0219] To adapt to the operational characteristics of different interface controls, the trigger threshold can be automatically adjusted according to the current interactive control: a dedicated stop intention threshold X and slip threshold Y are pre-configured for each interface control or area. When the player releases their hand, the interface control where the touch point is located is additionally detected, and the corresponding X / Y is used for judgment. For example, for moving the joystick, which requires precise control, a smaller X is used to improve accuracy; for adjusting the view control, which is more flexible, a larger Y is used to reduce misjudgments and ensure the accuracy of backtracking.
[0220] In practical implementation, the judgment threshold can be intelligently adjusted by integrating dynamic data such as speed, acceleration, and pause frequency during the sliding process. This allows the threshold size to adapt to the operation characteristics in real time: when the sliding speed and acceleration are large, the threshold will increase accordingly to allow for greater operational deviations; while when there are many pauses during the sliding process, the threshold will decrease to make the slip-hand judgment more stringent and improve accuracy. To achieve this dynamic adjustment mechanism, a dynamic threshold adjuster was designed, which presets a series of key parameters during the initialization phase. This includes weighting coefficients to control the influence of three factors—speed, acceleration, and pause—on X (the threshold for determining the intention to stop) and Y (the threshold for determining a slip of the hand). These coefficients can be continuously optimized through machine learning; for example, the weight of speed on X is set to 0.35, and the weight of pause on Y is set to 0.50. It also includes physical parameters such as a baseline speed (set to 50 pixels / second, i.e., the optimal operating speed), the slope of the speed curve (0.02, controlling how quickly speed affects the threshold), and the optimal acceleration (20 pixels / second², the most efficient acceleration value). It also specifies threshold range parameters, such as the minimum / maximum value of X (5 to 50) and the baseline contribution of acceleration to Y (0.8). Furthermore, it initializes the covariance matrix used for weight updates (initially a large-value identity matrix) and reserves variables to store the current threshold. The core function of the adjuster is to dynamically calculate the threshold. After inputting the current sliding speed, acceleration, and pause index (smaller values indicate more pauses), the system calculates the impact of each factor in three steps: Speed impact is derived from an S-curve, outputting an intermediate value when the speed is close to the baseline speed, and approaching the minimum or maximum value of X when it is far away; Acceleration impact is calculated using a bell curve, with the greatest impact when acceleration is close to the optimal value, and the smaller the impact as it deviates further; Pause impact is obtained using a logarithmic curve, with a greater impact for more pauses (smaller index values). Then, these three types of impact values are weighted and summed according to preset weights to obtain dynamic X and Y thresholds, ensuring they fall within a preset safety range.
[0221] Furthermore, the adjuster also possesses weight optimization capabilities based on user data. Using a recursive least squares algorithm, it first integrates the influence values of speed, acceleration, and pauses into a feature vector. Then, it calculates the Kalman gain and the error between the actual threshold and the optimal threshold reported by the user. Based on this error, it adjusts the weight coefficients of each factor and updates the covariance matrix simultaneously. This process allows the weights to continuously adapt to user operating habits, achieving dynamic optimization of the threshold adjustment mechanism.
[0222] By applying the above embodiments of this application, the touch trajectory analysis and historical coordinate backtracking mechanism of the two-level time window can not only eliminate the coordinate offset caused by hand slip, ensuring that the operation conforms to the user's true intention, but also activate error correction only when two conditions are met, avoiding interference with normal operation; at the same time, it preserves the user's fine operation ability, realizes imperceptible correction, and is compatible with all touch devices by relying on pure software design, comprehensively improving the accuracy and smoothness of swiping operation.
[0223] The following description continues to illustrate the exemplary structure of the operation processing device 555 provided in the embodiments of this application as a software module. In some embodiments, such as Figure 2 As shown, the software modules of the operation processing device 555 may include: a display module 5551, a drag module 5552, and a correction module 5553.
[0224] Display module 5551 is used to display draggable interface elements in the view interface; The drag module 5552 is used to respond to a drag operation on the interface element and display the process of the interface element moving following the touch point of the drag operation. The correction module 5553 is used to respond to the release of the drag operation and, when a misoperation is detected in the drag operation, control the interface element to return to a historical position in the movement trajectory based on the movement trajectory of the interface element, so as to correct the misoperation in the drag operation.
[0225] In some embodiments, the operation processing device further includes: a first erroneous operation determination module, configured to record a first movement distance of the interface element within a first time period before the drag operation is released, and a second movement distance of the interface element within a second time period before the drag operation is released, before controlling the interface element to return to a historical position in the movement trajectory based on the movement trajectory of the interface element; wherein the first time period is longer than the second time period; and in response to the distance difference between the first movement distance and the second movement distance being less than a preset first distance threshold and the second movement distance being less than a second distance threshold, the module determines that the drag operation includes the erroneous operation.
[0226] In some embodiments, the first time period corresponds to a first trajectory segment in the movement trajectory, and the second time period corresponds to a second trajectory segment in the movement trajectory; the operation processing device further includes: a first threshold determination module, configured to determine the pause frequency of the touch point in the first trajectory segment and the second trajectory segment, the average acceleration between the second trajectory segment and the first trajectory segment, and the average movement speed of the touch point in the second trajectory segment; calculate a first contribution of the pause frequency to the first distance threshold, a second contribution of the average acceleration to the first distance threshold, a third contribution of the average movement speed to the first distance threshold, and a fourth contribution of the average movement speed to the second distance threshold; determine a first weighting coefficient corresponding to the first distance threshold, and perform a weighted summation of the first contribution, the second contribution, and the third contribution based on the first weighting coefficient to obtain the first distance threshold; determine a second weighting coefficient corresponding to the second distance threshold, and perform a weighted summation of the first contribution, the second contribution, and the fourth contribution based on the second weighting coefficient to obtain the second distance threshold.
[0227] In some embodiments, the operation processing device further includes: a second threshold determination module, configured to determine the control type to which the interface control belongs when the interface element is an interface control; Based on the control type, determine the first distance threshold and the second distance threshold corresponding to the interface control.
[0228] In some embodiments, the second time period corresponds to the second trajectory segment in the movement trajectory; the first erroneous operation determination module is further configured to control the interface element to revert to the starting position of the second trajectory segment in the movement trajectory based on the movement trajectory of the interface element.
[0229] In some embodiments, the operation processing device further includes: a second erroneous operation determination module, configured to determine that the drag operation does not include the erroneous operation in response to the distance difference between the first moving distance and the second moving distance being not less than the first distance threshold, or the second moving distance being not less than the second distance threshold.
[0230] In some embodiments, the operation processing device further includes: a third erroneous operation determination module, used to record the pressure change of the touch point in real time during the execution of the drag operation before controlling the interface element to return to a historical position in the movement trajectory based on the movement trajectory of the interface element; when the pressure change of the touch point is detected to indicate that the pressure of the touch point decreases at a rate greater than a preset decrease rate threshold, the drag operation is determined to contain the erroneous operation.
[0231] In some embodiments, the operation processing device further includes: a rate determination module, configured to determine the moment when the pressure drop rate of the contact point equals a preset drop rate threshold before the drag operation is released, and to record the position of the interface element at the moment when the pressure drop rate equals the preset drop rate threshold; the correction module 5553 is further configured to control the interface element to revert to the position of the interface element at the moment when the pressure drop rate equals the preset drop rate threshold, based on the movement trajectory of the interface element.
[0232] In some embodiments, the operation processing method is performed by an electronic device, and the operation processing device further includes: a fourth erroneous operation determination module, configured to detect whether a pressure sensor is provided in the electronic device before the real-time recording of the pressure change of the contact point during the execution of the drag operation; if the detection result indicates that a pressure sensor is provided in the electronic device, triggering the operation of real-time recording of the pressure change of the contact point during the execution of the drag operation; if the detection result indicates that a pressure sensor is not provided in the electronic device, recording the motion characteristics of the contact point to identify whether the drag operation contains an erroneous operation based on the motion characteristics of the contact point.
[0233] In some embodiments, the operation processing device further includes: a third threshold determination module, configured to acquire operation data during the execution of the drag operation; input the operation data into a pre-trained threshold determination model; and determine the first distance threshold and the second distance threshold based on the threshold determination model.
[0234] In some embodiments, the operation processing device further includes: a training module, configured to acquire sample data, the sample data including operation data during the execution of a drag operation, and sample labels for indicating whether the drag operation includes erroneous operations; and to train the threshold determination model based on the sample data to obtain a trained threshold determination model.
[0235] In some embodiments, the correction module 5553 is further configured to play a transition animation when the distance between the end position of the movement trajectory and the historical position is greater than a distance threshold, and control the interface element to revert to the historical position in the movement trajectory according to the transition animation.
[0236] In some embodiments, the correction module 5553 is further configured to control the interface element to instantly move to a historical position in the movement trajectory based on the movement trajectory of the interface element, using a transition-free method.
[0237] In some embodiments, the operation processing apparatus further includes: an execution module, configured to, in response to the interface element returning to a historical position in the movement trajectory, perform at least one of the following: output haptic feedback, the haptic feedback being used to prompt the interface element to return to the historical position; display the interface element using a target display style, wherein the target display style is used to indicate that the interface element returns to the historical position.
[0238] In some embodiments, the operation processing device further includes: a first adjustment module, configured to, after controlling the interface element to return to a historical position in the movement trajectory based on the movement trajectory of the interface element, display sensitivity adjustment prompt information and corresponding sensitivity adjustment controls in response to the number of times the interface element returns in the view interface within a preset time reaching a threshold; wherein, the sensitivity adjustment prompt information is used to prompt adjustment of the trigger sensitivity of the erroneous operation.
[0239] In some embodiments, the operation processing device further includes: an activation module, configured to display a misoperation correction switch that is in a closed state in the view interface; and to activate the misoperation correction switch in response to an activation operation of the misoperation correction switch; the correction module 5553 is further configured to, in response to the release of the drag operation and, when the misoperation correction switch is activated, control the interface element to revert to a historical position in the movement trajectory based on the movement trajectory of the interface element when a misoperation is detected in the drag operation.
[0240] In some embodiments, the operation processing device further includes: a removal module, configured to draw the movement trajectory of the interface element in real time in the view interface in response to a drag operation on the interface element; and to mark the corresponding retracement portion of the movement trajectory as invalid or remove it from the movement trajectory in response to the interface element returning to a historical position in the movement trajectory.
[0241] In some embodiments, the operation processing device further includes: an undo module, configured to display an undo control in the view interface in response to the interface element returning to a historical position in the movement trajectory; and to control the interface element to move to the endpoint position of the interface element when the drag operation is released in response to a trigger operation on the undo control.
[0242] In some embodiments, the operation processing device further includes: a second adjustment module, configured to, in response to the release of the drag operation and when a misoperation is detected in the drag operation, detect whether the touch point position of the drag operation is located in the edge area of the view interface before controlling the interface element to return to a historical position in the movement trajectory based on the movement trajectory of the interface element; and in response to the touch point position being located in the edge area, increase the judgment threshold for identifying the misoperation.
[0243] In some embodiments, the operation processing device further includes an interrupt module, configured to interrupt the fallback process of the interface element in response to a touch operation performed in the view interface during the fallback process of the interface element.
[0244] In some embodiments, the operation processing device further includes a playback module, configured to play a prompt sound effect during the process of the interface element reverting; wherein, the longer the distance the interface element reverts, the higher the pitch or the louder the volume of the prompt sound effect.
[0245] This application provides a computer program product, which includes a computer program or computer-executable instructions. When the computer-executable instructions or the computer program are executed by a processor, the processor will perform the operation processing method provided in this application embodiment, for example, such as... Figure 3 The method is illustrated above. The processor of the electronic device reads the computer program or computer-executable instructions from a computer-readable storage medium, and executes the computer program or computer-executable instructions, causing the electronic device to perform the operation processing method described in the embodiments of this application.
[0246] This application provides a computer-readable storage medium storing computer-executable instructions or a computer program. When the computer-executable instructions or the computer program are executed by a processor, the processor will perform the operation processing method provided in this application embodiment. For example, ... Figure 3 The methods shown are as follows.
[0247] In some embodiments, the computer-readable storage medium may be a memory such as RAM, ROM, flash memory, magnetic surface memory, optical disk, or CD-ROM; or it may be a variety of devices including one or any combination of the above-mentioned memories.
[0248] In some embodiments, computer-executable instructions may take the form of programs, software, software modules, scripts, or code, written in any form of programming language (including compiled or interpreted languages, or declarative or procedural languages), and may be deployed in any form, including as stand-alone programs or as modules, components, subroutines, or other units suitable for use in a computing environment.
[0249] As an example, computer-executable instructions may, but do not necessarily, correspond to files in a file system. They may be stored as part of a file that holds other programs or data, for example, in one or more scripts in a Hyper Text Markup Language (HTML) document, in a single file dedicated to the program in question, or in multiple co-located files (e.g., files that store one or more modules, subroutines, or code sections).
[0250] As an example, computer-executable instructions can be deployed to execute on a single electronic device, or on multiple electronic devices located at one location, or on multiple electronic devices distributed across multiple locations and interconnected via a communication network.
[0251] In summary, by intelligently identifying and automatically correcting user errors when dragging interface elements, the accuracy and fault tolerance of the interaction are greatly improved. It can dynamically judge errors by analyzing various data such as movement trajectory and touch pressure, and can also adaptively adjust the judgment criteria based on element type and even through machine learning models, making the recognition both intelligent and reliable. Once an error is detected, the element is automatically reverted to the position of the user's true intention, and clear and user-friendly feedback is provided through animation, sound effects, haptic feedback, and other means. Furthermore, users can interrupt the revert at any time with a new touch operation or undo the error correction, and sensitivity adjustment options are provided, ultimately improving operational fault tolerance and interactive flexibility, and optimizing the overall user experience.
[0252] The above description is merely an embodiment of this application and is not intended to limit the scope of protection of this application. Any modifications, equivalent substitutions, and improvements made within the spirit and scope of this application are included within the scope of protection of this application.
Claims
1. A method of operating a process, characterized by, The method comprises: displaying an interface element in a view interface in a draggable state; in response to a dragging operation on the interface element, displaying a process in which the interface element moves following a touch point of the dragging operation; in response to the dragging operation being released, when an error operation is identified in the dragging operation, controlling the interface element to back up to a historical position in a movement trajectory of the interface element to correct the error operation in the dragging operation.
2. The method of claim 1, wherein, Before the controlling the interface element to back up to the historical position in the movement trajectory of the interface element, the method further comprises: recording a first movement distance of the interface element within a first time period before the dragging operation is released, and a second movement distance of the interface element within a second time period before the dragging operation is released; wherein the first time period is greater than the second time period; in response to a distance difference between the first movement distance and the second movement distance being less than a preset first distance threshold, and the second movement distance being less than a second distance threshold, determining that the error operation is included in the dragging operation.
3. The method of claim 2, wherein, The first time period corresponds to a first trajectory segment in the movement trajectory, and the second time period corresponds to a second trajectory segment in the movement trajectory; the method further comprises: determining a pause frequency of the touch point in the first trajectory segment and the second trajectory segment, an average acceleration between the second trajectory segment and the first trajectory segment, and an average movement speed of the touch point within the second trajectory segment; calculating a first contribution degree of the pause frequency to the first distance threshold, a second contribution degree of the average acceleration to the first distance threshold, a third contribution degree of the average movement speed to the first distance threshold, and a fourth contribution degree of the average movement speed to the second distance threshold; determining a first weighting coefficient corresponding to the first distance threshold, and performing weighted summation on the first contribution degree, the second contribution degree, and the third contribution degree based on the first weighting coefficient to obtain the first distance threshold; determining a second weighting coefficient corresponding to the second distance threshold, and performing weighted summation on the first contribution degree, the second contribution degree, and the fourth contribution degree based on the second weighting coefficient to obtain the second distance threshold.
4. The method of claim 2, wherein, The method further comprises: in a case where the interface element is an interface control, determining a control type to which the interface control belongs; based on the control type, determining the first distance threshold and the second distance threshold corresponding to the interface control.
5. The method of claim 2, wherein, The second time period corresponds to a second trajectory segment in the movement trajectory; The controlling the interface element to back up to the historical position in the movement trajectory of the interface element comprises: based on the movement trajectory of the interface element, controlling the interface element to back up to a starting position of the second trajectory segment in the movement trajectory.
6. The method of claim 2, wherein, The method further comprises: In response to a distance difference between the first movement distance and the second movement distance being not less than the first distance threshold value, or the second movement distance being not less than a second distance threshold value, it is determined that the drag operation does not include the misoperation.
7. The method of claim 1, wherein, The method further includes: real-time recording of pressure change of the touch point during execution of the drag operation; In response to identifying, based on the pressure change of the touch point, a case where a pressure drop rate of the touch point is greater than a preset pressure drop rate threshold value, it is determined that the drag operation includes the misoperation.
8. The method of claim 7, wherein, The method further includes: determining a time point at which the pressure drop rate of the touch point is equal to the preset pressure drop rate threshold value before the drag operation is released, and recording a position of the interface element at the time point at which the pressure drop rate is equal to the preset pressure drop rate threshold value; The method further includes: based on the movement trajectory of the interface element, controlling the interface element to rollback to a historical position in the movement trajectory, includes:
9. The method of claim 7, wherein, based on the movement trajectory of the interface element, controlling the interface element to rollback to the position of the interface element at the time point at which the pressure drop rate is equal to the preset pressure drop rate threshold value. The operation processing method is executed by an electronic device, and before the real-time recording of the pressure change of the touch point during the execution of the drag operation, the method further includes: detecting whether a pressure sensor is arranged in the electronic device; in a case where the detection result indicates that the pressure sensor is arranged in the electronic device, triggering the operation of real-time recording of the pressure change of the touch point during the execution of the drag operation; 10. The method of claim 2, wherein, in a case where the detection result indicates that the pressure sensor is not arranged in the electronic device, recording motion characteristics of the touch point, and identifying, based on the motion characteristics of the touch point, whether the drag operation includes a misoperation. The method further includes: obtaining operation data during execution of the drag operation; inputting the operation data into a threshold value determination model; The threshold value determination model includes a first threshold value determination model and a second threshold value determination model, the first threshold value determination model is used to determine the first distance threshold value, and the second threshold value determination model is used to determine the second distance threshold value.
11. The method of claim 10, wherein, The first distance threshold value is determined based on the first threshold value determination model, and the second distance threshold value is determined based on the second threshold value determination model. The method further includes: in response to a user triggering a rollback operation for the interface element within a preset time after the rollback of the interface element, generating a negative feedback sample; 12. The method according to any one of claims 1 to 11, characterized in that, updating a weight parameter in the threshold value determination model by using the negative feedback sample. The method further includes: in a case where a distance between an end position of the movement trajectory and the historical position is greater than a distance threshold value, playing a transition animation, and controlling the interface element to rollback to the historical position in the movement trajectory according to the transition animation.
13. The method according to any one of claims 1 to 11, characterized in that, The method further comprises: controlling the interface element to move back to a historical position in the movement track of the interface element based on the movement track of the interface element, including:
14. The method according to any one of claims 1 to 11, characterized in that, controlling the interface element to move back to a historical position in the movement track of the interface element based on the movement track of the interface element in a non-transition manner. The method further comprises: in response to the interface element moving back to the historical position in the movement track of the interface element, performing at least one of the following: outputting haptic feedback for prompting the interface element to move back to the historical position; 15. The method according to any one of claims 1 to 11, characterized in that, displaying the interface element in a target display style, wherein the target display style is used to indicate that the interface element moves back to the historical position. The method further comprises: after the interface element moves back to the historical position in the movement track of the interface element based on the movement track of the interface element, the method further comprises:
16. The method according to any one of claims 1 to 11, characterized in that, in response to the number of times of the interface element moving back in the view interface reaching a threshold number of times within a preset time, displaying sensitivity adjustment prompt information and a corresponding sensitivity adjustment control; wherein the sensitivity adjustment prompt information is used to prompt adjustment of the trigger sensitivity of the misoperation. The method further comprises: displaying a misoperation correction switch in a closed state in the view interface; in response to an opening operation of the misoperation correction switch, opening the misoperation correction switch.
17. The method according to any one of claims 1 to 11, characterized in that, The method further comprises: in response to the drag operation being released, when it is identified that the drag operation contains a misoperation, controlling the interface element to move back to a historical position in the movement track of the interface element based on the movement track of the interface element, including: in response to the drag operation being released, when it is identified that the drag operation contains a misoperation in a case where the misoperation correction switch is opened, controlling the interface element to move back to a historical position in the movement track of the interface element based on the movement track of the interface element.
18. The method according to any one of claims 1 to 11, characterized in that, The method further comprises: in response to a drag operation of the interface element, drawing the movement track of the interface element in the view interface in real time; in response to the interface element moving back to the historical position in the movement track of the interface element, marking the part of the movement track corresponding to the moving back as invalid or removing the part from the movement track.
19. The method according to any one of claims 1 to 11, characterized in that, The method further comprises: in response to the interface element moving back to the historical position in the movement track of the interface element, displaying a undo control in the view interface; in response to a trigger operation of the undo control, controlling the interface element to move to the end position of the interface element when the drag operation is released.
20. The method according to any one of claims 1 to 11, characterized in that, The method further comprises: before the method of controlling the interface element to move back to a historical position in the movement track of the interface element based on the movement track of the interface element when it is identified that the drag operation contains a misoperation in response to the drag operation being released, the method further comprises:
21. The method according to any one of claims 1 to 11, characterized in that, detecting whether a touch position of the drag operation is located at an edge area of the view interface; in response to the touch position being located at the edge area, increasing a judgment threshold for identifying the misoperation. The method further comprises: in the process of the interface element moving back, in response to a touch operation performed in the view interface, interrupting the moving back process of the interface element. The method further comprises: During the interface element backtracking, a prompt sound effect is played; The longer the distance of the interface element backtracking, the higher the pitch or the louder the volume of the prompt sound effect.
22. A processing device, comprising: The apparatus comprises: a display module configured to display an interface element in a draggable state in a view interface; a drag module configured to, in response to a drag operation on the interface element, display a process in which the interface element moves following a touch point of the drag operation; a correction module configured to, in response to the drag operation being released, when an error operation is identified in the drag operation, based on a movement track of the interface element, control the interface element to backtrack to a historical position in the movement track to correct the error operation in the drag operation.
23. An electronic device, comprising: The electronic device comprises: a memory configured to store computer executable instructions or computer programs; a processor configured to execute the computer executable instructions or computer programs stored in the memory to implement the operation processing method of any one of claims 1 to 21.
24. A computer-readable storage medium storing computer-executable instructions or a computer program, wherein the computer-executable instructions or the computer program comprise the steps of any one of claims 1-23. The computer executable instructions or computer programs are executed by the processor to implement the operation processing method of any one of claims 1 to 21.
25. A computer program product comprising computer-executable instructions or a computer program, characterized in that, The computer executable instructions or computer programs are executed by the processor to implement the operation processing method of any one of claims 1 to 21. The computer executable instructions or computer programs are executed by the processor to implement the operation processing method of any one of claims 1 to 21.