WO2019134542A1 - 移动终端点击事件的识别方法和装置 - Google Patents

移动终端点击事件的识别方法和装置 Download PDF

Info

Publication number
WO2019134542A1
WO2019134542A1 PCT/CN2018/123026 CN2018123026W WO2019134542A1 WO 2019134542 A1 WO2019134542 A1 WO 2019134542A1 CN 2018123026 W CN2018123026 W CN 2018123026W WO 2019134542 A1 WO2019134542 A1 WO 2019134542A1
Authority
WO
WIPO (PCT)
Prior art keywords
event
scroll
touch
touchstart
touchend
Prior art date
Application number
PCT/CN2018/123026
Other languages
English (en)
French (fr)
Inventor
郁森
Original Assignee
阿里巴巴集团控股有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 阿里巴巴集团控股有限公司 filed Critical 阿里巴巴集团控股有限公司
Priority to SG11202006180YA priority Critical patent/SG11202006180YA/en
Priority to EP18898910.7A priority patent/EP3719625A4/en
Publication of WO2019134542A1 publication Critical patent/WO2019134542A1/zh
Priority to US16/882,685 priority patent/US10852943B2/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0487Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser
    • G06F3/0488Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser using a touch-screen or digitiser, e.g. input of commands through traced gestures
    • G06F3/04883Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser using a touch-screen or digitiser, e.g. input of commands through traced gestures for inputting data by handwriting, e.g. gesture or text
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0487Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser
    • G06F3/0488Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser using a touch-screen or digitiser, e.g. input of commands through traced gestures
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0484Interaction techniques based on graphical user interfaces [GUI] for the control of specific functions or operations, e.g. selecting or manipulating an object, an image or a displayed text element, setting a parameter value or selecting a range
    • G06F3/0485Scrolling or panning
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0484Interaction techniques based on graphical user interfaces [GUI] for the control of specific functions or operations, e.g. selecting or manipulating an object, an image or a displayed text element, setting a parameter value or selecting a range
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/54Interprogram communication
    • G06F9/542Event management; Broadcasting; Multicasting; Notifications

Definitions

  • the present specification relates to the field of terminal technologies, and in particular, to a method and an apparatus for identifying a click event of a mobile terminal.
  • browser controls can be configured in the application software (Application, APP) of the terminal device to implement functions such as web browsing.
  • APP Application, APP
  • functions such as web browsing.
  • how to effectively and accurately identify the click event plays a vital role in the user's browsing experience.
  • the present specification provides a method and apparatus for identifying a click event of a mobile terminal.
  • a method for identifying a click event of a mobile terminal includes:
  • a device for identifying a click event of a mobile terminal comprising:
  • An event recording unit that records a touch event detected by the mobile terminal touching the screen
  • a scrolling determining unit when the click event is triggered, determining, according to the recorded touch event, whether a triggering time of the click event is in a process of page scrolling;
  • a device for identifying a click event of a mobile terminal comprising:
  • a memory for storing machine executable instructions
  • the processor is caused to:
  • the present specification may determine, according to the recorded touch event, whether the triggering time of the click event is in the process of page scrolling when the click event is triggered, and is in the page scrolling when the click event is triggered. In the process of the process, the click event is cancelled, the misjudgment of the user's operation intention is prevented, and the accuracy of the click event recognition is improved.
  • FIG. 1 is a schematic flow chart of a method for identifying a click event of a mobile terminal according to an exemplary embodiment of the present disclosure.
  • FIG. 2 is a schematic flow chart of another method for identifying a click event of a mobile terminal according to an exemplary embodiment of the present disclosure.
  • FIG. 3 is a schematic flow chart of a method for recording a touch event according to an exemplary embodiment of the present specification.
  • FIG. 4 is a schematic structural diagram of an apparatus for identifying a click event of a mobile terminal according to an exemplary embodiment of the present specification.
  • FIG. 5 is a block diagram of an apparatus for identifying a click event of a mobile terminal according to an exemplary embodiment of the present specification.
  • first, second, third, etc. may be used in this specification to describe various information, such information should not be limited to these terms. These terms are only used to distinguish the same type of information from each other.
  • first information may also be referred to as the second information without departing from the scope of the present description.
  • second information may also be referred to as the first information.
  • word "if” as used herein may be interpreted as "when” or “when” or “in response to a determination.”
  • FIG. 1 is a schematic flow chart of a method for identifying a click event of a mobile terminal according to an exemplary embodiment of the present disclosure.
  • the method for identifying the click event of the mobile terminal can be applied to the mobile terminal, for example, a tablet computer, a mobile phone, a PDA (Personal Digital Assistant, etc.), and the present specification does not specifically limit this.
  • the method for identifying a click event of a mobile terminal may include the following steps:
  • Step 102 Record a touch event detected by the mobile terminal touching the screen.
  • the touch event may include: a touchstart event, a touchmove event, a touchend event, a touchcancel event, a scroll event, and the like.
  • the event name of the touch event and the time stamp of the touch event may be recorded according to the relevant rule, and the time stamp is usually the time point at which the touch event occurs.
  • Step 104 When the click event is triggered, determine whether the triggering time of the click event is in the process of page scrolling according to the recorded touch event.
  • the click event may be independently detected by a third-party control, and the detection manner of the click event may refer to related technologies, and the specification does not specifically limit this.
  • the click event When it is detected that the click event is triggered, it may be determined according to the recorded touch event whether the triggering time of the click event is in the process of page scrolling, that is, whether the user triggers the click event during the page scrolling process.
  • Step 106 If the triggering time of the click event is in the process of page scrolling, cancel the click event.
  • the click event is used to stop the page scrolling, instead of the browsing instruction input for a certain content of the page, , the click event can be canceled to prevent page jumps.
  • the present specification may determine, according to the recorded touch event, whether the triggering time of the click event is in the process of page scrolling when the click event is triggered, and is in the page scrolling when the click event is triggered. In the process of the process, the click event is cancelled, the misjudgment of the user's operation intention is prevented, and the accuracy of the click event recognition is improved.
  • FIG. 2 is a schematic flow chart of another method for identifying a click event of a mobile terminal according to an exemplary embodiment of the present disclosure.
  • the method for identifying a click event of a mobile terminal may include the following steps:
  • Step 202 When the browser control of the mobile terminal is a UIWebView control, record a touch event detected by the mobile terminal touching the screen.
  • the browser control includes various categories, for example, the UIWebView control of the iOS system, the WKWebView control of the iOS system, the UC3 kernel of the Android system, and the UC4 kernel of the Android.
  • the browser control category of the mobile terminal may be first determined. If the browser control category is a UIWebView control, a subsequent step may be performed to record the touch event detected by the mobile terminal touching the screen. If the browser control category is not a UIWebView control, then no further steps can be performed.
  • the process of recording a touch event may include the following steps:
  • Step 2021 When the touch event is detected, determine whether the touch event is a touch event of a specified category.
  • the touch event may include: a touchstart event, a touchmove event, a touchend event, a touchcancel event, a scroll event, and the like.
  • a touchstart event a touchmove event
  • a touchend event a touchcancel event
  • a scroll event a scroll event
  • the specified category of touch events can be set by the developer in advance.
  • the specified category of touch events can be set to: touchcancel event, scroll event, and the like.
  • step 2022 may be performed.
  • step 2023 may be performed.
  • Step 2022 If the touch event is a touch event of the specified category, perform event name modification on the touch event, and record the modified event name and a time stamp corresponding to the touch event.
  • the recording touch event generally refers to an event name that records a touch event and a time stamp corresponding to the touch event, and the time stamp is usually a time point at which the touch event is triggered.
  • the time stamp is usually a time point at which the touch event is triggered.
  • other information of the touch event such as attribute information of the touch event, may also be recorded, which is not specifically limited in this specification.
  • the event name of the touch event may be modified, and then the modified event name and the time stamp corresponding to the touch event are recorded.
  • the event name of the touchcancel event can be modified to touchend, and then the correspondence between the touchend and the timestamp of the touchcancel event is saved.
  • the scroll event when the detected touch event is a scroll event, the scroll event may be first determined to be a global page scroll or a region page scroll according to the attribute information of the scroll event. Specifically, the return value of the current active node event.target may be obtained first. If the return value is document, the scroll event may be determined to be global page scrolling. If the return value is not document, the scroll event may be determined to be an area. Page scrolling means that an area in the page is scrolling, not the entire page is scrolling.
  • the event name of the scroll event may be modified to scroll:window; when the scroll event is a region page scrolling, the event name of the scroll event is modified to scroll:target.
  • the event name can also be modified to other event names, as long as the global page scrolling and the area page scrolling can be distinguished, and the specification does not specifically limit this.
  • Step 2023 If the touch event is not a touch event of the specified category, record an event name of the touch event and a time stamp corresponding to the touch event.
  • the event name of the touch event and the time stamp corresponding to the touch event may be directly recorded.
  • the correspondence between touchstart and its timestamp can be recorded.
  • the correspondence between the touchmove and its timestamp can be recorded.
  • the correspondence between the touchend and its timestamp can be recorded.
  • step 2024 after recording a new set of touchstart-touchend events, it is determined whether the number of recorded touchstart-touchend groups exceeds N.
  • a set of touchstart-touchend events usually refers to touchstart events, *, touchend events, "*" can represent [0, infinity) touchmove events, scroll: window events or scroll: target events. That is, a set of touchstart-touchend events usually refers to a set of event records beginning with touchstart and ending with touchend. Specifically, the determination may be made after the recorded touch event is a touchend event.
  • Table 1 and Table 2 show two different sets of touchstart-touchend events.
  • Table 1 and Table 2 are merely exemplary descriptions. In practical applications, a set of touchstart-touchend events may have other various expressions, and the description is not repeated here.
  • N is a natural number greater than or equal to 1, and the specific value can be set by a developer, for example, N is equal to 2.
  • touch events can be recorded between two sets of touchstart-touchend events adjacent to each other, for example, scroll:target, scroll:window, etc., which are not specifically limited in this specification.
  • step 2025 if the number of recorded touchstart-touchend groups exceeds N, the touch events recorded before the most recent N sets of touchstart-touchend events are deleted according to the timestamp, where N is a natural number greater than or equal to 1.
  • the touch events recorded before the most recent N sets of touchstart-touchend events are deleted according to the timestamp, that is, only the most recent N sets of touchstart-touchend events are retained.
  • Step 204 When the click event is triggered, determine whether the triggering time of the click event is in the process of page scrolling according to the recorded touch event.
  • a click event click event
  • the triggering time of the click event may be determined. In the process of page scrolling. If the above conditions are not met, it may be determined that the triggering time of the click event is not in the process of page scrolling.
  • the first set of touchstart-touchend events usually refers to a set of touchstart-touchend events with relatively early timestamps.
  • the second set of touchstart-touchend events usually refers to a set of touchstart-touchend events with relatively late timestamps. .
  • the first set of touchstart-touchend events refers to the entries with sequence numbers 1-3
  • the second set of touchstart-touchend events refers to the entries with sequence numbers 4-7.
  • there is no scroll:window event between the first set of touchstart-touchend events and the second set of touchstart-touchend events there is a scroll:window event in the second set of touchstart-touchend events (Table 3
  • the sixth item shown in the figure) can determine that the triggering time of the click event is in the process of page scrolling.
  • the first set of touchstart-touchend events refers to the entries with sequence numbers 1-3
  • the second set of touchstart-touchend events refers to the entries with sequence numbers 5-8.
  • there is a scroll:window event (the fourth item shown in Table 4) between the first set of touchstart-touchend events and the second set of touchstart-touchend events, and the click event can be determined.
  • the trigger timing is not in the process of page scrolling.
  • N 2
  • the recorded touch event is a region page scrolling, that is, when the recorded scroll event is scroll:target
  • the scroll:target event does not exist in the first group of touchstart-touchend events, and the scroll:target event exists in the second group of touchstart-touchend events, it may be determined that the triggering time of the click event is in the process of page scrolling.
  • the scroll:target event does not exist in the first group of touchstart-touchend events, and the scroll:target event exists after the second group of touchstart-touchend events, it may also be determined that the triggering time of the click event is in the process of page scrolling. . If the above conditions are not met, it may be determined that the triggering time of the click event is not in the process of page scrolling.
  • the first set of touchstart-touchend events refers to the entries with sequence numbers 1-3
  • the second set of touchstart-touchend events refers to the entries with sequence numbers 4-7.
  • there is no scroll:target event in the first set of touchstart-touchend events and there is a scroll:target event in the second set of touchstart-touchend events (the sixth entry in Table 5). Then, it can be determined that the triggering time of the click event is in the process of page scrolling.
  • the first set of touchstart-touchend events refers to the entries with sequence numbers 1-4
  • the second set of touchstart-touchend events refers to the entries with sequence numbers 5-7.
  • the scroll:target event (the third entry shown in Table 6) exists in the first set of touchstart-touchend events, and it can be determined that the triggering time of the click event is not in the process of page scrolling. in.
  • the trigger event of the record may be other forms, and the judgment may be made according to the above rules, and the description is not repeated here.
  • the developer can set the corresponding judgment rule according to the value of N, and this specification does not specifically limit this.
  • Step 206 If the triggering time of the click event is in the process of page scrolling, cancel the click event.
  • the click event is used to stop the page scrolling, instead of the browsing instruction input for a certain content of the page, , the click event can be canceled to prevent page jumps.
  • Step 208 If the triggering time of the click event is not in the process of page scrolling, the click event is allowed to be issued.
  • the click event is generally used to browse a specified link, and therefore, the click event may be allowed to be issued.
  • the present specification may determine, according to the recorded touch event, whether the triggering time of the click event is in the process of page scrolling when the click event is triggered, and is in the page scrolling when the click event is triggered. In the process of the process, the click event is cancelled, the misjudgment of the user's operation intention is prevented, and the accuracy of the click event recognition is improved.
  • the present specification also provides an embodiment of an apparatus for identifying a click event of a mobile terminal.
  • the embodiment of the identification device for the mobile terminal click event of the present specification can be applied to the mobile terminal.
  • the device embodiment may be implemented by software, or may be implemented by hardware or a combination of hardware and software.
  • the processor of the mobile terminal in which it is located reads the corresponding computer program instructions in the non-volatile memory into the memory.
  • FIG. 4 a hardware structure diagram of the mobile terminal where the identification device of the mobile terminal click event is located in this specification, except for the processor, the memory, the network interface, and the nonvolatile memory shown in FIG.
  • the mobile terminal in which the device is located in the embodiment may also include other hardware according to the actual function of the mobile terminal, and details are not described herein.
  • FIG. 5 is a block diagram of an apparatus for identifying a click event of a mobile terminal according to an exemplary embodiment of the present specification.
  • the mobile terminal click event identification device 400 can be applied to the mobile terminal shown in FIG. 4, and includes an event recording unit 401, a scroll determination unit 402, a click cancellation unit 403, and a click permission unit 404. .
  • the event recording unit 401 records a touch event detected by the mobile terminal touching the screen;
  • the scroll determining unit 402 determines, when the click event is triggered, whether the triggering time of the click event is in the process of page scrolling according to the recorded touch event;
  • Clicking the permission unit 404 allows the click event to be issued if the triggering time of the click event is not in the process of page scrolling.
  • the event recording unit 401 records, when the browser control of the mobile terminal is a UIWebView control, a touch event detected by the mobile terminal touching the screen.
  • the event recording unit 401 when the detected touch event is a touch event of a specified category, performing an event name modification on the touch event, and recording the modified event name and a time stamp corresponding to the touch event. ;
  • N is a natural number greater than or equal to 1.
  • the event recording unit 401 modifies the event name of the touchcancel event to touchend;
  • the event recording unit 401 determines, according to the attribute information of the scroll event, whether the scroll event is a global page scroll or a region page scroll; when the scroll event is a global page scrolling Change the event name of the scroll event to scroll:window; when the scroll event is the area page scrolling, change the event name of the scroll event to scroll:target.
  • the scroll determining unit 402 when N is equal to 2, the scroll determining unit 402:
  • the device embodiment since it basically corresponds to the method embodiment, reference may be made to the partial description of the method embodiment.
  • the device embodiments described above are merely illustrative, wherein the units described as separate components may or may not be physically separate, and the components displayed as units may or may not be physical units, ie may be located A place, or it can be distributed to multiple network units. Some or all of the modules may be selected according to actual needs to achieve the objectives of the present specification. Those of ordinary skill in the art can understand and implement without any creative effort.
  • the system, device, module or unit illustrated in the above embodiments may be implemented by a computer chip or an entity, or by a product having a certain function.
  • a typical implementation device is a computer, and the specific form of the computer may be a personal computer, a laptop computer, a cellular phone, a camera phone, a smart phone, a personal digital assistant, a media player, a navigation device, an email transceiver, and a game control.
  • the present specification further provides a device for identifying a click event of a mobile terminal, the device for identifying a click event of the mobile terminal comprising: a processor and a device for storing machine executable instructions Memory.
  • the processor and the memory are usually connected to each other by an internal bus.
  • the device may also include an external interface to enable communication with other devices or components.
  • the processor by reading and executing the machine-executable instructions stored in the memory corresponding to the identification logic of the mobile terminal click event, the processor is caused to:
  • the processor is further caused to:
  • the click event is allowed to be issued.
  • the processor when recording a touch event detected by the mobile terminal touching the screen, the processor is caused to:
  • the browser control of the mobile terminal is a UIWebView control
  • the touch event detected by the mobile terminal touch screen is recorded.
  • the processor when recording a touch event detected by the mobile terminal touching the screen, the processor is caused to:
  • the detected touch event is a touch event of a specified category, performing an event name modification on the touch event, and recording the modified event name and a time stamp corresponding to the touch event;
  • N is a natural number greater than or equal to 1.
  • performing the event name modification on the touch event includes: modifying an event name of the touchcancel event to a touchend;
  • the event name modification for the touch event includes:
  • the processor in determining whether the triggering time of the click event is in the process of page scrolling according to the recorded touch event, the processor is caused to:
  • the present specification further provides a computer readable storage medium having a computer program stored thereon, the program implementing the following steps when executed by the processor :
  • it also includes:
  • the click event is allowed to be issued.
  • the recording, by the mobile terminal, the touch event detected by the touch screen includes:
  • the browser control of the mobile terminal is a UIWebView control
  • the touch event detected by the mobile terminal touch screen is recorded.
  • the recording, by the mobile terminal, the touch event detected by the touch screen includes:
  • the detected touch event is a touch event of a specified category, performing an event name modification on the touch event, and recording the modified event name and a time stamp corresponding to the touch event;
  • N is a natural number greater than or equal to 1.
  • performing the event name modification on the touch event includes: modifying an event name of the touchcancel event to a touchend;
  • the event name modification for the touch event includes:
  • determining, according to the recorded touch event, whether the triggering time of the click event is in a process of page scrolling including:

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Human Computer Interaction (AREA)
  • Software Systems (AREA)
  • Multimedia (AREA)
  • User Interface Of Digital Computer (AREA)

Abstract

一种移动终端点击事件的识别方法和装置。该方法包括:记录移动终端触摸屏幕检测到的触摸事件(S102);当点击事件被触发时,根据记录的所述触摸事件判断所述点击事件的触发时机是否处于页面滚动的过程中(S104);若所述点击事件的触发时机处于页面滚动的过程中,则取消所述点击事件(S106)。

Description

移动终端点击事件的识别方法和装置 技术领域
本说明书涉及终端技术领域,尤其涉及一种移动终端点击事件的识别方法和装置。
背景技术
随着互联网技术的快速发展,可在终端设备的应用软件(Application,APP)中配置浏览器控件,以实现网页浏览等功能。在使用浏览器控件浏览网页的过程中,如何有效、准确的识别点击事件对用户的浏览体验起着至关重要的作用。
发明内容
有鉴于此,本说明书提供一种移动终端点击事件的识别方法和装置。
具体地,本说明书是通过如下技术方案实现的:
一种移动终端点击事件的识别方法,包括:
记录移动终端触摸屏幕检测到的触摸事件;
当点击事件被触发时,根据记录的所述触摸事件判断所述点击事件的触发时机是否处于页面滚动的过程中;
若所述点击事件的触发时机处于页面滚动的过程中,则取消所述点击事件。
一种移动终端点击事件的识别装置,包括:
事件记录单元,记录移动终端触摸屏幕检测到的触摸事件;
滚动判断单元,当点击事件被触发时,根据记录的所述触摸事件判断所述点击事件的触发时机是否处于页面滚动的过程中;
点击取消单元,若所述点击事件的触发时机处于页面滚动的过程中,则取消所述点击事件。
一种移动终端点击事件的识别装置,包括:
处理器;
用于存储机器可执行指令的存储器;
其中,通过读取并执行所述存储器存储的与**逻辑对应的机器可执行指令,所述处理器被促使:
记录移动终端触摸屏幕检测到的触摸事件;
当点击事件被触发时,根据记录的所述触摸事件判断所述点击事件的触发时机是否处于页面滚动的过程中;
若所述点击事件的触发时机处于页面滚动的过程中,则取消所述点击事件。
由以上描述可以看出,本说明书可在点击事件被触发时,根据记录的触摸事件判断所述点击事件的触发时机是否处于页面滚动的过程中,并在所述点击事件的触发时机处于页面滚动的过程中时,取消所述点击事件,防止对用户操作意图的误判,提升点击事件识别的准确率。
附图说明
图1是本说明书一示例性实施例示出的一种移动终端点击事件的识别方法的流程示意图。
图2是本说明书一示例性实施例示出的另一种移动终端点击事件的识别方法的流程示意图。
图3是本说明书一示例性实施例示出的一种记录触摸事件的方法的流程示意图。
图4是本说明书一示例性实施例示出的一种用于移动终端点击事件的识别装置的一结构示意图。
图5是本说明书一示例性实施例示出的一种移动终端点击事件的识别装置的框图。
具体实施方式
这里将详细地对示例性实施例进行说明,其示例表示在附图中。下面的描述涉及附图时,除非另有表示,不同附图中的相同数字表示相同或相似的要素。以下示例性实施例中所描述的实施方式并不代表与本说明书相一致的所有实施方式。相反,它们仅是与如所附权利要求书中所详述的、本说明书的一些方面相一致的装置和方法的例子。
在本说明书使用的术语是仅仅出于描述特定实施例的目的,而非旨在限制本说明书。在本说明书和所附权利要求书中所使用的单数形式的“一种”、“所述”和“该”也旨 在包括多数形式,除非上下文清楚地表示其他含义。还应当理解,本文中使用的术语“和/或”是指并包含一个或多个相关联的列出项目的任何或所有可能组合。
应当理解,尽管在本说明书可能采用术语第一、第二、第三等来描述各种信息,但这些信息不应限于这些术语。这些术语仅用来将同一类型的信息彼此区分开。例如,在不脱离本说明书范围的情况下,第一信息也可以被称为第二信息,类似地,第二信息也可以被称为第一信息。取决于语境,如在此所使用的词语“如果”可以被解释成为“在……时”或“当……时”或“响应于确定”。
图1是本说明书一示例性实施例示出的一种移动终端点击事件的识别方法的流程示意图。
所述移动终端点击事件的识别方法可以应用在移动终端中,例如,平板电脑、手机、PDA(Personal Digital Assistant,掌上电脑)等,本说明书对此不作特殊限制。
请参考图1,所述移动终端点击事件的识别方法可以包括以下步骤:
步骤102,记录移动终端触摸屏幕检测到的触摸事件。
在本实施例中,所述触摸事件可以包括:touchstart事件、touchmove事件、touchend事件、touchcancel事件、scroll事件等。
在本实施例中,可以根据相关规则记录触摸事件的事件名和触摸事件的时间戳,所述时间戳通常是所述触摸事件发生的时间点。
步骤104,当点击事件被触发时,根据记录的所述触摸事件判断所述点击事件的触发时机是否处于页面滚动的过程中。
在本实施例中,所述点击事件可由第三方控件独立检测,所述点击事件的检测方式可以参照相关技术,本说明书对此不作特殊限制。
当检测到点击事件被触发时,可以根据记录的触摸事件判断所述点击事件的触发时机是否处于页面滚动的过程中,即判断用户是否在页面滚动的过程中触发该点击事件。
步骤106,若所述点击事件的触发时机处于页面滚动的过程中,则取消所述点击事件。
基于前述步骤104的判断结果,若所述点击事件的触发时机处于页面滚动的过程中,则可说明所述点击事件用于停止页面滚动,而非针对页面的某个内容输入的浏览指令,因此,可取消所述点击事件,防止页面跳转。
由以上描述可以看出,本说明书可在点击事件被触发时,根据记录的触摸事件判断所述点击事件的触发时机是否处于页面滚动的过程中,并在所述点击事件的触发时机处于页面滚动的过程中时,取消所述点击事件,防止对用户操作意图的误判,提升点击事件识别的准确率。
图2是本说明书一示例性实施例示出的另一种移动终端点击事件的识别方法的流程示意图。
请参考图2,所述移动终端点击事件的识别方法可以包括以下步骤:
步骤202,当移动终端的浏览器控件是UIWebView控件时,记录移动终端触摸屏幕检测到的触摸事件。
在本实施例中,浏览器控件包括多种类别,例如,iOS系统的UIWebView控件,iOS系统的WKWebView控件,Android系统的UC3内核,Android的UC4内核等。
在上述浏览器控件中,WKWebView控件、UC3内核、UC4内核通常都可以较为准确的识别点击事件。因此,在本实施例中,可先判断移动终端的浏览器控件类别,若浏览器控件类别是UIWebView控件,则可以执行后续步骤,记录移动终端触摸屏幕检测到的触摸事件。若浏览器控件类别不是UIWebView控件,则可不执行后续步骤。
在本实施例中,请参考图3,记录触摸事件的过程可以包括以下步骤:
步骤2021,当检测到的触摸事件时,判断所述触摸事件是否为指定类别的触摸事件。
在本实施例中,所述触摸事件可以包括:touchstart事件、touchmove事件、touchend事件、touchcancel事件、scroll事件等。其中,各种触摸事件的触发时机可参照相关技术,本说明书在此不再一一赘述。
所述指定类别的触摸事件可由开发人员预先进行设置。例如,可将所述指定类别的触摸事件设置为:touchcancel事件、scroll事件等。
在本实施例中,若检测到的触摸事件是touchcancel事件或scroll事件,则可以执行步骤2022。
若检测到的触摸事件是touchstart事件、touchmove事件或touchend事件,则可以执行步骤2023。
步骤2022,若所述触摸事件是所述指定类别的触摸事件,则对所述触摸事件进行事件名修改,并记录修改后的事件名和所述触摸事件对应的时间戳。
在本实施例中,记录触摸事件通常是指记录触摸事件的事件名和所述触摸事件对应的时间戳,所述时间戳通常是所述触摸事件被触发的时间点。当然,还可以记录所述触摸事件的其他信息,例如,触摸事件的属性信息等,本说明书对此不作特殊限制。
基于前述步骤2021的判断结果,当检测到的触摸事件是所述指定类别的触摸事件时,可对该触摸事件的事件名进行修改,然后记录修改后的事件名和该触摸事件对应的时间戳。
例如,当检测到的触摸事件是touchcancel事件时,可将touchcancel事件的事件名修改为touchend,然后保存touchend和所述touchcancel事件的时间戳之间的对应关系。
又例如,当检测到的触摸事件是scroll事件时,可先根据所述scroll事件的属性信息判断所述scroll事件是全局页面滚动还是区域页面滚动。具体而言,可先获取当前作用节点event.target的返回值,若返回值是document,则可确定所述scroll事件是全局页面滚动,若返回值不是document,则可确定所述scroll事件是区域页面滚动,即是页面中某个区域在滚动,而非整个页面在滚动。
当所述scroll事件是全局页面滚动时,可将scroll事件的事件名修改为scroll:window;当所述scroll事件是区域页面滚动时,将scroll事件的事件名修改为scroll:target。
当然,根据scroll事件的不同情形,也可以将其事件名修改为其他事件名,只要能区分全局页面滚动和区域页面滚动即可,本说明书对此不作特殊限制。
步骤2023,若所述触摸事件不是所述指定类别的触摸事件,则记录所述触摸事件的事件名和所述触摸事件对应的时间戳。
基于前述步骤2021的判断结果,当检测到的触摸事件不是所述指定类别的触摸事件时,可直接记录所述触摸事件的事件名和所述触摸事件对应的时间戳。
例如,当检测到的触摸事件是touchstart事件时,可记录touchstart和其时间戳之间的对应关系。
又例如,当检测到的触摸事件是touchmove事件时,可记录touchmove和其时间戳之间的对应关系。
再例如,当检测到的触摸事件是touchend事件时,可记录touchend和其时间戳之间的对应关系。
步骤2024,当记录下新的一组touchstart-touchend事件后,判断已记录的 touchstart-touchend组数是否超过N。
在本实施例中,当记录一条新的触摸事件后,可判断是否刚记录下新的一组touchstart-touchend事件。其中,一组touchstart-touchend事件通常是指touchstart事件、*、touchend事件,“*”号可代表[0,无穷)个touchmove事件、scroll:window事件或scroll:target事件。即,一组touchstart-touchend事件通常是指由touchstart开头,由touchend结尾的一组事件记录。具体而言,可在记录的触摸事件是touchend事件后进行判断。
序号 事件名 时间戳
1 touchstart T1
2 touchmove T2
3 touchend T3
表1
序号 事件名 时间戳
1 touchstart T11
2 touchmove T12
3 scroll:target T13
4 touchend T14
表2
请参考表1和表2,表1和表2分别出示了两组不同的touchstart-touchend事件。当然,表1和表2仅为示例性的说明,在实际应用中,一组touchstart-touchend事件还可能有其他各种表现形式,本说明书在此不再一一赘述。
在本实施例中,当记录下新的一组touchstart-touchend事件后,可判断当前已记录的touchstart-touchend组数是否超过N。其中,N为大于等于1的自然数,其具体取值可以由开发人员进行设置,例如,N等于2。
值得注意的是,在时间相邻的两组touchstart-touchend事件之间还可以记录有其他触摸事件,例如,scroll:target、scroll:window等,本说明书对此不作特殊限制。
步骤2025,若已记录的touchstart-touchend组数超过N,则根据时间戳删除最近N组touchstart-touchend事件之前记录的触摸事件,其中,N为大于等于1的自然数。
基于前述步骤2024的判断结果,若确定已记录的touchstart-touchend组数超过N,根据时间戳删除最近N组touchstart-touchend事件之前记录的触摸事件,即仅保留最近 N组touchstart-touchend事件。
以N的取值等于2为例,可仅保留最近2组touchstart-touchend事件。假设最近两组touchstart-touchend事件分别如表1和表2,其中,时间戳T1早于时间戳T11,则可以删除时间戳早于T1的所有记录。
当然,在实际应用中,T3和T11之间还可能存在其他触摸事件的记录,这部分触摸事件的时间戳晚于T1,因此也需要保留。
步骤204,当点击事件被触发时,根据记录的所述触摸事件判断所述点击事件的触发时机是否处于页面滚动的过程中。
在本实施例中,当点击事件(click事件)被触发时,可根据当前记录的触摸事件判断该点击事件是否是在页面滚动的过程中被触发。由于页面滚动可分别全局页面滚动和区域页面滚动,因此可以分别进行判断。
仍以N的取值等于2为例,当记录的触摸事件是全局页面滚动时,即当记录的滚动事件是scroll:window时,可判断第一组touchstart-touchend事件和第二组touchstart-touchend事件之间是否存在scroll:window事件,并且判断第二组touchstart-touchend事件中是否存在scroll:window事件。
若第一组touchstart-touchend事件和第二组touchstart-touchend事件之间不存在scroll:window事件,且第二组touchstart-touchend事件中存在scroll:window事件,则可确定所述点击事件的触发时机处于页面滚动的过程中。若不满足上述条件,则可以确定所述点击事件的触发时机未处于页面滚动的过程中。
其中,第一组touchstart-touchend事件通常是指时间戳相对较早的一组touchstart-touchend事件,相应的,第二组touchstart-touchend事件通常是指时间戳相对较晚的一组touchstart-touchend事件。
序号 事件名 时间戳
1 touchstart T21
2 touchmove T22
3 touchend T23
4 touchstart T24
5 touchmove T25
6 scroll:window T26
7 touchend T27
表3
请参考表3所示的记录,第一组touchstart-touchend事件指的是序号为1-3的表项,第二组touchstart-touchend事件指的是序号为4-7的表项。在表3所示的记录中,第一组touchstart-touchend事件和第二组touchstart-touchend事件之间不存在scroll:window事件、且第二组touchstart-touchend事件中存在scroll:window事件(表3所示第6条表项),则可以确定所述点击事件的触发时机处于页面滚动的过程中。
序号 事件名 时间戳
1 touchstart T31
2 touchmove T32
3 touchend T33
4 scroll:window T34
5 touchstart T35
6 touchmove T36
7 scroll:window T37
8 touchend T38
表4
请参考表4所示的记录,第一组touchstart-touchend事件指的是序号为1-3的表项,第二组touchstart-touchend事件指的是序号为5-8的表项。在表4所示的记录中,第一组touchstart-touchend事件和第二组touchstart-touchend事件之间存在scroll:window事件(表4所示第4条表项),则可以确定所述点击事件的触发时机未处于页面滚动的过程中。
仍以N的取值等于2为例,当记录的触摸事件是区域页面滚动时,即当记录的滚动事件是scroll:target时,可判断第一组touchstart-touchend事件中是否存在scroll:target事件,并且判断第二组touchstart-touchend事件中是否存在scroll:target事件,以及判断 第二组touchstart-touchend事件后是否存在scroll:target事件。
若第一组touchstart-touchend事件中不存在scroll:target事件,且第二组touchstart-touchend事件中存在scroll:target事件,则可确定所述点击事件的触发时机处于页面滚动的过程中。或者,若第一组touchstart-touchend事件中不存在scroll:target事件,且第二组touchstart-touchend事件后存在scroll:target事件,则也可以确定所述点击事件的触发时机处于页面滚动的过程中。若不满足上述条件,则可以确定所述点击事件的触发时机未处于页面滚动的过程中。
序号 事件名 时间戳
1 touchstart T41
2 touchmove T42
3 touchend T43
4 touchstart T44
5 touchmove T45
6 scroll:target T46
7 touchend T47
表5
请参考表5所示的记录,第一组touchstart-touchend事件指的是序号为1-3的表项,第二组touchstart-touchend事件指的是序号为4-7的表项。在表5所示的记录中,第一组touchstart-touchend事件中不存在scroll:target事件,且第二组touchstart-touchend事件中存在scroll:target事件(表5所示第6条表项),则可以确定所述点击事件的触发时机处于页面滚动的过程中。
序号 事件名 时间戳
1 touchstart T51
2 touchmove T52
3 scroll:target T53
4 touchend T54
5 touchstart T55
6 scroll:target T56
7 touchend T57
表6
请参考表6所示的记录,第一组touchstart-touchend事件指的是序号为1-4的表项, 第二组touchstart-touchend事件指的是序号为5-7的表项。在表6所示的记录中,第一组touchstart-touchend事件中存在scroll:target事件(表6所示第3条表项),则可以确定所述点击事件的触发时机未处于页面滚动的过程中。
当然,在实际应用中,记录的触发事件还可能是其他形式的,依据上述规则进行判断即可,本说明书在此不再一一赘述。
此外,当N的取值为其他数值时,开发人员可以根据N的取值设置相应的判断规则,本说明书对此不作特殊限制。
步骤206,若所述点击事件的触发时机处于页面滚动的过程中,则取消所述点击事件。
基于前述步骤204的判断结果,若所述点击事件的触发时机处于页面滚动的过程中,则可说明所述点击事件用于停止页面滚动,而非针对页面的某个内容输入的浏览指令,因此,可取消所述点击事件,防止页面跳转。
步骤208,若所述点击事件的触发时机未处于页面滚动的过程中,则允许发出所述点击事件。
基于前述步骤204的判断结果,若所述点击事件的触发时机未处于页面滚动的过程中,则可说明所述点击事件通常是用于浏览指定的链接,因此,可允许发出所述点击事件。
由以上描述可以看出,本说明书可在点击事件被触发时,根据记录的触摸事件判断所述点击事件的触发时机是否处于页面滚动的过程中,并在所述点击事件的触发时机处于页面滚动的过程中时,取消所述点击事件,防止对用户操作意图的误判,提升点击事件识别的准确率。
需要说明的是,在实际应用中,也可以归纳未处于页面滚动过程中的触摸事件规则,以进行判断,本说明书对此不作特殊限制。
与前述移动终端点击事件的识别方法的实施例相对应,本说明书还提供了移动终端点击事件的识别装置的实施例。
本说明书移动终端点击事件的识别装置的实施例可以应用在移动终端上。装置实施例可以通过软件实现,也可以通过硬件或者软硬件结合的方式实现。以软件实现为例,作为一个逻辑意义上的装置,是通过其所在移动终端的处理器将非易失性存储器中对应 的计算机程序指令读取到内存中运行形成的。从硬件层面而言,如图4所示,为本说明书移动终端点击事件的识别装置所在移动终端的一种硬件结构图,除了图4所示的处理器、内存、网络接口、以及非易失性存储器之外,实施例中装置所在的移动终端通常根据该移动终端的实际功能,还可以包括其他硬件,对此不再赘述。
图5是本说明书一示例性实施例示出的一种移动终端点击事件的识别装置的框图。
请参考图5,所述移动终端点击事件的识别装置400可以应用在前述图4所示的移动终端中,包括有:事件记录单元401、滚动判断单元402、点击取消单元403以及点击允许单元404。
其中,事件记录单元401,记录移动终端触摸屏幕检测到的触摸事件;
滚动判断单元402,当点击事件被触发时,根据记录的所述触摸事件判断所述点击事件的触发时机是否处于页面滚动的过程中;
点击取消单元403,若所述点击事件的触发时机处于页面滚动的过程中,则取消所述点击事件。
点击允许单元404,若所述点击事件的触发时机未处于页面滚动的过程中,则允许发出所述点击事件。
可选的,所述事件记录单元401,当移动终端的浏览器控件是UIWebView控件时,记录移动终端触摸屏幕检测到的触摸事件。
可选的,所述事件记录单元401,当检测到的触摸事件是指定类别的触摸事件时,对所述触摸事件进行事件名修改,并记录修改后的事件名和所述触摸事件对应的时间戳;
当检测到的触摸事件不是所述指定类别的触摸事件时,记录所述触摸事件的事件名和所述触摸事件对应的时间戳;
当记录下新的一组touchstart-touchend事件后,判断已记录的touchstart-touchend组数是否超过N;
若已记录的touchstart-touchend组数超过N,则根据时间戳删除最近N组touchstart-touchend事件之前记录的触摸事件,其中,N为大于等于1的自然数。
可选的,当所述指定类别的触摸事件是touchcancel事件时,所述事件记录单元401,将touchcancel事件的事件名修改为touchend;
当所述指定类别的触摸事件是scroll事件时,所述事件记录单元401,根据scroll事件的属性信息判断所述scroll事件是全局页面滚动还是区域页面滚动;当所述scroll事件是全局页面滚动时,将scroll事件的事件名修改为scroll:window;当所述scroll事件是区域页面滚动时,将scroll事件的事件名修改为scroll:target。
可选的,当N等于2时,所述滚动判断单元402:
当记录的触摸事件是全局页面滚动时,若第一组touchstart-touchend事件和第二组touchstart-touchend事件之间不存在scroll:window事件,且第二组touchstart-touchend事件中存在scroll:window事件,则确定所述点击事件的触发时机处于页面滚动的过程中;
当记录的触摸事件是区域页面滚动时,若第一组touchstart-touchend事件中不存在scroll:target事件,且第二组touchstart-touchend事件中或者第二组touchstart-touchend事件后存在scroll:target事件,则确定所述点击事件的触发时机处于页面滚动的过程中。
上述装置中各个单元的功能和作用的实现过程具体详见上述方法中对应步骤的实现过程,在此不再赘述。
对于装置实施例而言,由于其基本对应于方法实施例,所以相关之处参见方法实施例的部分说明即可。以上所描述的装置实施例仅仅是示意性的,其中所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部模块来实现本说明书方案的目的。本领域普通技术人员在不付出创造性劳动的情况下,即可以理解并实施。
上述实施例阐明的系统、装置、模块或单元,具体可以由计算机芯片或实体实现,或者由具有某种功能的产品来实现。一种典型的实现设备为计算机,计算机的具体形式可以是个人计算机、膝上型计算机、蜂窝电话、相机电话、智能电话、个人数字助理、媒体播放器、导航设备、电子邮件收发设备、游戏控制台、平板计算机、可穿戴设备或者这些设备中的任意几种设备的组合。
与前述移动终端点击事件的识别方法的实施例相对应,本说明书还提供一种移动终端点击事件的识别装置,该移动终端点击事件的识别装置包括:处理器以及用于存储机器可执行指令的存储器。其中,处理器和存储器通常借由内部总线相互连接。在其他可能的实现方式中,所述设备还可能包括外部接口,以能够与其他设备或者部件进行 通信。
在本实施例中,通过读取并执行所述存储器存储的与移动终端点击事件的识别逻辑对应的机器可执行指令,所述处理器被促使:
记录移动终端触摸屏幕检测到的触摸事件;
当点击事件被触发时,根据记录的所述触摸事件判断所述点击事件的触发时机是否处于页面滚动的过程中;
若所述点击事件的触发时机处于页面滚动的过程中,则取消所述点击事件。
可选的,通过读取并执行所述存储器存储的与移动终端点击事件的识别逻辑对应的机器可执行指令,所述处理器还被促使:
若所述点击事件的触发时机未处于页面滚动的过程中,则允许发出所述点击事件。
可选的,在记录移动终端触摸屏幕检测到的触摸事件时,所述处理器被促使:
当移动终端的浏览器控件是UIWebView控件时,记录移动终端触摸屏幕检测到的触摸事件。
可选的,在记录移动终端触摸屏幕检测到的触摸事件时,所述处理器被促使:
当检测到的触摸事件是指定类别的触摸事件时,对所述触摸事件进行事件名修改,并记录修改后的事件名和所述触摸事件对应的时间戳;
当检测到的触摸事件不是所述指定类别的触摸事件时,记录所述触摸事件的事件名和所述触摸事件对应的时间戳;
当记录下新的一组touchstart-touchend事件后,判断已记录的touchstart-touchend组数是否超过N;
若已记录的touchstart-touchend组数超过N,则根据时间戳删除最近N组touchstart-touchend事件之前记录的触摸事件,其中,N为大于等于1的自然数。
可选的,当所述指定类别的触摸事件是touchcancel事件时,所述对所述触摸事件进行事件名修改包括:将touchcancel事件的事件名修改为touchend;
当所述指定类别的触摸事件是scroll事件时,所述对所述触摸事件进行事件名修改包括:
根据scroll事件的属性信息判断所述scroll事件是全局页面滚动还是区域页面滚动;
当所述scroll事件是全局页面滚动时,将scroll事件的事件名修改为scroll:window;
当所述scroll事件是区域页面滚动时,将scroll事件的事件名修改为scroll:target。
可选的,当N等于2时,在根据记录的所述触摸事件判断所述点击事件的触发时机是否处于页面滚动的过程中,所述处理器被促使:
当记录的触摸事件是全局页面滚动时,若第一组touchstart-touchend事件和第二组touchstart-touchend事件之间不存在scroll:window事件,且第二组touchstart-touchend事件中存在scroll:window事件,则确定所述点击事件的触发时机处于页面滚动的过程中;
当记录的触摸事件是区域页面滚动时,若第一组touchstart-touchend事件中不存在scroll:target事件,且第二组touchstart-touchend事件中或者第二组touchstart-touchend事件后存在scroll:target事件,则确定所述点击事件的触发时机处于页面滚动的过程中。
与前述移动终端点击事件的识别方法的实施例相对应,本说明书还提供一种计算机可读存储介质,所述计算机可读存储介质上存储有计算机程序,该程序被处理器执行时实现以下步骤:
记录移动终端触摸屏幕检测到的触摸事件;
当点击事件被触发时,根据记录的所述触摸事件判断所述点击事件的触发时机是否处于页面滚动的过程中;
若所述点击事件的触发时机处于页面滚动的过程中,则取消所述点击事件。
可选的,还包括:
若所述点击事件的触发时机未处于页面滚动的过程中,则允许发出所述点击事件。
可选的,所述记录移动终端触摸屏幕检测到的触摸事件,包括:
当移动终端的浏览器控件是UIWebView控件时,记录移动终端触摸屏幕检测到的触摸事件。
可选的,所述记录移动终端触摸屏幕检测到的触摸事件,包括:
当检测到的触摸事件是指定类别的触摸事件时,对所述触摸事件进行事件名修改,并记录修改后的事件名和所述触摸事件对应的时间戳;
当检测到的触摸事件不是所述指定类别的触摸事件时,记录所述触摸事件的事件名和所述触摸事件对应的时间戳;
当记录下新的一组touchstart-touchend事件后,判断已记录的touchstart-touchend组数是否超过N;
若已记录的touchstart-touchend组数超过N,则根据时间戳删除最近N组touchstart-touchend事件之前记录的触摸事件,其中,N为大于等于1的自然数。
可选的,当所述指定类别的触摸事件是touchcancel事件时,所述对所述触摸事件进行事件名修改包括:将touchcancel事件的事件名修改为touchend;
当所述指定类别的触摸事件是scroll事件时,所述对所述触摸事件进行事件名修改包括:
根据scroll事件的属性信息判断所述scroll事件是全局页面滚动还是区域页面滚动;
当所述scroll事件是全局页面滚动时,将scroll事件的事件名修改为scroll:window;
当所述scroll事件是区域页面滚动时,将scroll事件的事件名修改为scroll:target。
可选的,当N等于2时,所述根据记录的所述触摸事件判断所述点击事件的触发时机是否处于页面滚动的过程中,包括:
当记录的触摸事件是全局页面滚动时,若第一组touchstart-touchend事件和第二组touchstart-touchend事件之间不存在scroll:window事件,且第二组touchstart-touchend事件中存在scroll:window事件,则确定所述点击事件的触发时机处于页面滚动的过程中;
当记录的触摸事件是区域页面滚动时,若第一组touchstart-touchend事件中不存在scroll:target事件,且第二组touchstart-touchend事件中或者第二组touchstart-touchend事件后存在scroll:target事件,则确定所述点击事件的触发时机处于页面滚动的过程中。
上述对本说明书特定实施例进行了描述。其它实施例在所附权利要求书的范围 内。在一些情况下,在权利要求书中记载的动作或步骤可以按照不同于实施例中的顺序来执行并且仍然可以实现期望的结果。另外,在附图中描绘的过程不一定要求示出的特定顺序或者连续顺序才能实现期望的结果。在某些实施方式中,多任务处理和并行处理也是可以的或者可能是有利的。
以上所述仅为本说明书的较佳实施例而已,并不用以限制本说明书,凡在本说明书的精神和原则之内,所做的任何修改、等同替换、改进等,均应包含在本说明书保护的范围之内。

Claims (13)

  1. 一种移动终端点击事件的识别方法,包括:
    记录移动终端触摸屏幕检测到的触摸事件;
    当点击事件被触发时,根据记录的所述触摸事件判断所述点击事件的触发时机是否处于页面滚动的过程中;
    若所述点击事件的触发时机处于页面滚动的过程中,则取消所述点击事件。
  2. 根据权利要求1所述的方法,还包括:
    若所述点击事件的触发时机未处于页面滚动的过程中,则允许发出所述点击事件。
  3. 根据权利要求1所述的方法,所述记录移动终端触摸屏幕检测到的触摸事件,包括:
    当移动终端的浏览器控件是UIWebView控件时,记录移动终端触摸屏幕检测到的触摸事件。
  4. 根据权利要求1所述的方法,所述记录移动终端触摸屏幕检测到的触摸事件,包括:
    当检测到的触摸事件是指定类别的触摸事件时,对所述触摸事件进行事件名修改,并记录修改后的事件名和所述触摸事件对应的时间戳;
    当检测到的触摸事件不是所述指定类别的触摸事件时,记录所述触摸事件的事件名和所述触摸事件对应的时间戳;
    当记录下新的一组touchstart-touchend事件后,判断已记录的touchstart-touchend组数是否超过N;
    若已记录的touchstart-touchend组数超过N,则根据时间戳删除最近N组touchstart-touchend事件之前记录的触摸事件,其中,N为大于等于1的自然数。
  5. 根据权利要求4所述的方法,
    当所述指定类别的触摸事件是touchcancel事件时,所述对所述触摸事件进行事件名修改包括:将touchcancel事件的事件名修改为touchend;
    当所述指定类别的触摸事件是scroll事件时,所述对所述触摸事件进行事件名修改包括:
    根据scroll事件的属性信息判断所述scroll事件是全局页面滚动还是区域页面滚动;
    当所述scroll事件是全局页面滚动时,将scroll事件的事件名修改为scroll:window;
    当所述scroll事件是区域页面滚动时,将scroll事件的事件名修改为scroll:target。
  6. 根据权利要求5所述的方法,当N等于2时,所述根据记录的所述触摸事件判 断所述点击事件的触发时机是否处于页面滚动的过程中,包括:
    当记录的触摸事件是全局页面滚动时,若第一组touchstart-touchend事件和第二组touchstart-touchend事件之间不存在scroll:window事件,且第二组touchstart-touchend事件中存在scroll:window事件,则确定所述点击事件的触发时机处于页面滚动的过程中;
    当记录的触摸事件是区域页面滚动时,若第一组touchstart-touchend事件中不存在scroll:target事件,且第二组touchstart-touchend事件中或者第二组touchstart-touchend事件后存在scroll:target事件,则确定所述点击事件的触发时机处于页面滚动的过程中。
  7. 一种移动终端点击事件的识别装置,包括:
    事件记录单元,记录移动终端触摸屏幕检测到的触摸事件;
    滚动判断单元,当点击事件被触发时,根据记录的所述触摸事件判断所述点击事件的触发时机是否处于页面滚动的过程中;
    点击取消单元,若所述点击事件的触发时机处于页面滚动的过程中,则取消所述点击事件。
  8. 根据权利要求7所述的装置,还包括:
    点击允许单元,若所述点击事件的触发时机未处于页面滚动的过程中,则允许发出所述点击事件。
  9. 根据权利要求7所述的装置,
    所述事件记录单元,当移动终端的浏览器控件是UIWebView控件时,记录移动终端触摸屏幕检测到的触摸事件。
  10. 根据权利要求7所述的装置,所述事件记录单元:
    当检测到的触摸事件是指定类别的触摸事件时,对所述触摸事件进行事件名修改,并记录修改后的事件名和所述触摸事件对应的时间戳;
    当检测到的触摸事件不是所述指定类别的触摸事件时,记录所述触摸事件的事件名和所述触摸事件对应的时间戳;
    当记录下新的一组touchstart-touchend事件后,判断已记录的touchstart-touchend组数是否超过N;
    若已记录的touchstart-touchend组数超过N,则根据时间戳删除最近N组touchstart-touchend事件之前记录的触摸事件,其中,N为大于等于1的自然数。
  11. 根据权利要求10所述的装置,
    当所述指定类别的触摸事件是touchcancel事件时,所述事件记录单元,将touchcancel事件的事件名修改为touchend;
    当所述指定类别的触摸事件是scroll事件时,所述事件记录单元,根据scroll事件的属性信息判断所述scroll事件是全局页面滚动还是区域页面滚动;当所述scroll事件是全局页面滚动时,将scroll事件的事件名修改为scroll:window;当所述scroll事件是区域页面滚动时,将scroll事件的事件名修改为scroll:target。
  12. 根据权利要求11所述的装置,当N等于2时,所述滚动判断单元:
    当记录的触摸事件是全局页面滚动时,若第一组touchstart-touchend事件和第二组touchstart-touchend事件之间不存在scroll:window事件,且第二组touchstart-touchend事件中存在scroll:window事件,则确定所述点击事件的触发时机处于页面滚动的过程中;
    当记录的触摸事件是区域页面滚动时,若第一组touchstart-touchend事件中不存在scroll:target事件,且第二组touchstart-touchend事件中或者第二组touchstart-touchend事件后存在scroll:target事件,则确定所述点击事件的触发时机处于页面滚动的过程中。
  13. 一种移动终端点击事件的识别装置,包括:
    处理器;
    用于存储机器可执行指令的存储器;
    其中,通过读取并执行所述存储器存储的与**逻辑对应的机器可执行指令,所述处理器被促使:
    记录移动终端触摸屏幕检测到的触摸事件;
    当点击事件被触发时,根据记录的所述触摸事件判断所述点击事件的触发时机是否处于页面滚动的过程中;
    若所述点击事件的触发时机处于页面滚动的过程中,则取消所述点击事件。
PCT/CN2018/123026 2018-01-02 2018-12-24 移动终端点击事件的识别方法和装置 WO2019134542A1 (zh)

Priority Applications (3)

Application Number Priority Date Filing Date Title
SG11202006180YA SG11202006180YA (en) 2018-01-02 2018-12-24 Mobile terminal click event recognition method and apparatus
EP18898910.7A EP3719625A4 (en) 2018-01-02 2018-12-24 MOBILE TERMINAL CLICK EVENT RECOGNITION METHOD AND APPARATUS
US16/882,685 US10852943B2 (en) 2018-01-02 2020-05-25 Mobile terminal click event recognition method and apparatus

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201810001504.3 2018-01-02
CN201810001504.3A CN108388393B (zh) 2018-01-02 2018-01-02 移动终端点击事件的识别方法和装置

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US16/882,685 Continuation US10852943B2 (en) 2018-01-02 2020-05-25 Mobile terminal click event recognition method and apparatus

Publications (1)

Publication Number Publication Date
WO2019134542A1 true WO2019134542A1 (zh) 2019-07-11

Family

ID=63076926

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2018/123026 WO2019134542A1 (zh) 2018-01-02 2018-12-24 移动终端点击事件的识别方法和装置

Country Status (6)

Country Link
US (1) US10852943B2 (zh)
EP (1) EP3719625A4 (zh)
CN (1) CN108388393B (zh)
SG (1) SG11202006180YA (zh)
TW (1) TWI694373B (zh)
WO (1) WO2019134542A1 (zh)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108388393B (zh) * 2018-01-02 2020-08-28 阿里巴巴集团控股有限公司 移动终端点击事件的识别方法和装置
CN109491746A (zh) * 2018-11-07 2019-03-19 沈文策 一种触屏终端点透解决方法、装置、触屏终端及存储介质
CN110267090B (zh) * 2019-07-18 2021-09-17 北京字节跳动网络技术有限公司 视频播放的控制方法、装置、电子设备、及存储介质
CN111782122B (zh) * 2020-05-21 2021-09-10 北京达佳互联信息技术有限公司 一种响应用户操作的方法、装置、终端及存储介质

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103365588A (zh) * 2012-04-11 2013-10-23 华为终端有限公司 一种触屏操作的处理方法及触控设备
CN103488303A (zh) * 2012-06-11 2014-01-01 联想(北京)有限公司 一种电子设备及电子设备的操作方法
CN104111785A (zh) * 2013-04-17 2014-10-22 腾讯科技(深圳)有限公司 触摸手势的响应方法及装置
CN105892894A (zh) * 2015-09-09 2016-08-24 北京奇虎科技有限公司 一种滑屏事件冲突的处理方法及装置
CN108388393A (zh) * 2018-01-02 2018-08-10 阿里巴巴集团控股有限公司 移动终端点击事件的识别方法和装置

Family Cites Families (28)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6610917B2 (en) 1998-05-15 2003-08-26 Lester F. Ludwig Activity indication, external source, and processing loop provisions for driven vibrating-element environments
US20090006543A1 (en) * 2001-08-20 2009-01-01 Masterobjects System and method for asynchronous retrieval of information based on incremental user input
US7487461B2 (en) 2005-05-04 2009-02-03 International Business Machines Corporation System and method for issuing commands based on pen motions on a graphical keyboard
US9395905B2 (en) 2006-04-05 2016-07-19 Synaptics Incorporated Graphical scroll wheel
US7877707B2 (en) 2007-01-06 2011-01-25 Apple Inc. Detecting and interpreting real-world and security gestures on touch and hover sensitive devices
US9785330B1 (en) * 2008-02-13 2017-10-10 Apple Inc. Systems for and methods of providing inertial scrolling and navigation using a fingerprint sensor calculating swiping speed and length
US8717305B2 (en) * 2008-03-04 2014-05-06 Apple Inc. Touch event model for web pages
US8390577B2 (en) 2008-07-25 2013-03-05 Intuilab Continuous recognition of multi-touch gestures
US8451236B2 (en) 2008-12-22 2013-05-28 Hewlett-Packard Development Company L.P. Touch-sensitive display screen with absolute and relative input modes
US8224392B2 (en) 2009-04-29 2012-07-17 Lg Electronics Inc. Mobile terminal capable of recognizing fingernail touch and method of controlling the operation thereof
US9189500B2 (en) 2009-12-31 2015-11-17 Verizon Patent And Licensing Inc. Graphical flash view of documents for data navigation on a touch-screen device
US9104308B2 (en) 2010-12-17 2015-08-11 The Hong Kong University Of Science And Technology Multi-touch finger registration and its applications
KR101754908B1 (ko) 2010-12-20 2017-07-07 애플 인크. 이벤트 인식
CN203287883U (zh) * 2010-12-20 2013-11-13 苹果公司 电子设备及其信息处理装置
JP5797580B2 (ja) * 2012-02-16 2015-10-21 シャープ株式会社 入力制御装置、電子機器、入力制御方法、プログラムおよび記録媒体
KR101886753B1 (ko) 2012-04-05 2018-08-08 엘지전자 주식회사 이동 단말기 및 그것의 제어 방법
KR20140111497A (ko) 2013-03-11 2014-09-19 삼성전자주식회사 터치 스크린의 화면에 표시된 아이템을 삭제하는 방법, 저장 매체 및 휴대 단말
CN104239302B (zh) * 2013-06-07 2017-10-03 腾讯科技(深圳)有限公司 页面内容获取方法、装置及应用设备与移动终端
JP6120731B2 (ja) * 2013-08-28 2017-04-26 京セラ株式会社 電子機器および電子機器の制御方法
KR102224483B1 (ko) 2014-07-07 2021-03-08 엘지전자 주식회사 터치 스크린을 포함하는 이동 단말기 및 그 제어 방법
KR102264444B1 (ko) 2014-09-04 2021-06-15 삼성전자주식회사 전자 장치에서 기능 실행 방법 및 장치
CN105824606B (zh) * 2015-01-05 2020-02-11 腾讯科技(深圳)有限公司 一种滚动输入方法及终端
US10074344B2 (en) 2015-04-30 2018-09-11 Lg Display Co., Ltd. Touch recognition enabled display device with asymmetric black matrix pattern
CN106547454A (zh) * 2015-09-16 2017-03-29 阿里巴巴集团控股有限公司 显示方法及装置
CN105892871B (zh) * 2016-03-31 2018-03-20 维沃移动通信有限公司 一种滚动页面的方法和电子设备
WO2018142609A1 (ja) * 2017-02-06 2018-08-09 三菱電機株式会社 グラフィカルユーザインタフェース制御装置およびグラフィカルユーザインタフェース制御方法
CN107203315B (zh) * 2017-05-25 2020-02-07 北京小米移动软件有限公司 点击事件的处理方法、装置及终端
JP6973025B2 (ja) * 2017-12-20 2021-11-24 コニカミノルタ株式会社 表示装置、画像処理装置及びプログラム

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103365588A (zh) * 2012-04-11 2013-10-23 华为终端有限公司 一种触屏操作的处理方法及触控设备
CN103488303A (zh) * 2012-06-11 2014-01-01 联想(北京)有限公司 一种电子设备及电子设备的操作方法
CN104111785A (zh) * 2013-04-17 2014-10-22 腾讯科技(深圳)有限公司 触摸手势的响应方法及装置
CN105892894A (zh) * 2015-09-09 2016-08-24 北京奇虎科技有限公司 一种滑屏事件冲突的处理方法及装置
CN108388393A (zh) * 2018-01-02 2018-08-10 阿里巴巴集团控股有限公司 移动终端点击事件的识别方法和装置

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
See also references of EP3719625A4 *

Also Published As

Publication number Publication date
CN108388393B (zh) 2020-08-28
EP3719625A4 (en) 2021-02-17
TWI694373B (zh) 2020-05-21
SG11202006180YA (en) 2020-07-29
US20200285382A1 (en) 2020-09-10
EP3719625A1 (en) 2020-10-07
CN108388393A (zh) 2018-08-10
US10852943B2 (en) 2020-12-01
TW201931099A (zh) 2019-08-01

Similar Documents

Publication Publication Date Title
WO2019134542A1 (zh) 移动终端点击事件的识别方法和装置
US10699061B2 (en) Application page quick access
US9743251B2 (en) Adding location names using private frequent location data
EP3451193B1 (en) Electronic device and file data journaling method of electronic device
US10565064B2 (en) Effective data change based rule to enable backup for specific VMware virtual machine
JP6726285B2 (ja) クライアント側アクティビティ監視
CN110659256B (zh) 多机房同步方法、计算设备及计算机存储介质
WO2017219524A1 (zh) 一种页面保存的方法及电子设备
US20140379631A1 (en) Transactional key-value database with searchable indexes
WO2018121277A1 (zh) 一种页面访问方法、装置、计算设备及存储介质
CN107678872A (zh) 电子白板的处理方法及装置
US20140082527A1 (en) Method and device for processing tabbed-page
CN111159160B (zh) 一种版本回滚方法、装置、电子设备及存储介质
TWI566165B (zh) 適應性呼叫應用程式的方法及其電子裝置
US20180024723A1 (en) Synchronizing user input with a user interface
US8726101B2 (en) Apparatus and method for tracing memory access information
CN103927355A (zh) 广告拦截方法、装置及系统
US20100287331A1 (en) Electronic device and method for recording power-on time thereof
US11010332B2 (en) Set-based mutual exclusion using object metadata tags in a storage appliance
CN108021464B (zh) 一种应用程序响应数据的兜底处理的方法以及装置
US10416923B1 (en) Fast backup solution for cluster shared volumes shared across a cluster of nodes using extent sets as parallel save streams
WO2017071210A1 (zh) 联系人的创建方法及装置
WO2018137170A1 (zh) 用户信息记录方法、装置及电子设备
CN112685329A (zh) 用于处理数据的方法及相关装置
US11947415B2 (en) System and method for efficient real time log export and view in a micro services system

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 18898910

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

ENP Entry into the national phase

Ref document number: 2018898910

Country of ref document: EP

Effective date: 20200629