CN114153536B - Web page focus control method and system compatible with physical keys of touch screen - Google Patents

Web page focus control method and system compatible with physical keys of touch screen Download PDF

Info

Publication number
CN114153536B
CN114153536B CN202111339543.2A CN202111339543A CN114153536B CN 114153536 B CN114153536 B CN 114153536B CN 202111339543 A CN202111339543 A CN 202111339543A CN 114153536 B CN114153536 B CN 114153536B
Authority
CN
China
Prior art keywords
focus
focusable
elements
navigation
aligned
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202111339543.2A
Other languages
Chinese (zh)
Other versions
CN114153536A (en
Inventor
陈爽
李青淋
麦秀青
高元钧
徐冬晨
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
CETC 32 Research Institute
Original Assignee
CETC 32 Research Institute
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 CETC 32 Research Institute filed Critical CETC 32 Research Institute
Priority to CN202111339543.2A priority Critical patent/CN114153536B/en
Publication of CN114153536A publication Critical patent/CN114153536A/en
Application granted granted Critical
Publication of CN114153536B publication Critical patent/CN114153536B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • 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/44Arrangements for executing specific programs
    • G06F9/451Execution arrangements for user interfaces
    • 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

Landscapes

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

Abstract

The invention provides a web page focus control method and a system compatible with physical keys of a touch screen, and relates to the technical field of computers, wherein the method comprises the following steps: step S1: searching for a focusable area in the current page; step S2: according to the searched focusable area, focusable elements in the focusable area are found; step S3: setting a default focusable element as a starting focus controlled by a physical keyboard, acquiring a current focus after receiving a click event, and analogizing; step S4: the rules followed by the focus movement are determined. The invention enables the mobile operating system to be simultaneously adapted to the equipment only comprising the touch screen, the equipment only comprising the physical key and the equipment simultaneously comprising the touch screen and the physical key, achieves the effect of one-time development and the adaptation of various hardware equipment, and greatly improves the efficiency of transplanting development.

Description

Web page focus control method and system compatible with physical keys of touch screen
Technical Field
The invention relates to the technical field of computers, in particular to a web page focus control method and a web page focus control system compatible with physical keys of a touch screen.
Background
In the past, the military mobile terminal hardware is not provided with a touch screen, and the functions are limited to simple functions such as dialing, short message and the like. With the progress of technology and the development of demands, military mobile terminals become more intelligent and human-machine interface friendly. Therefore, higher requirements are put on the adaptation of physical keys, and in the process of controlling the focus of an operation interface, two input devices, namely a touch screen and a physical keyboard, are required to be compatible.
Military mobile terminals are equipped with both touch screens and physical keyboards in order to simplify operation while accommodating extreme environments. In the focus control process of the operation interface, the driving of the touch screen and the driving of the physical keys are not compatible, and the two input devices are alternately used, so that the operation interface is difficult to use.
The invention patent with publication number CN107295414A discloses a method and a device for controlling the focus of a Web page, wherein the Web page is divided into at least one HTML label container; determining tag attributes of the HTML tag container; determining the focal attribute of the Web page in the appointed field of the tag attribute; and determining the focus of the Web page according to the focus attribute.
The invention patent with publication number of CN103297854B discloses a web page focus control method, wherein the area where the current focus is located is judged through the moving coordinates of an input device in a display interface, and the current focus is displayed according to the information of each area. When the focus is switched among elements in the same area, the corresponding elements are covered by frames with the same size, and a walking animation is generated on the frames; when the focus moves to different areas, the functional area where the current focus is positioned is judged according to the moving coordinates, and a display mode suitable for the area is selected according to the functional area. The above patent fails to address the compatibility problem that arises when there are two input modes of touch screen and physical keyboard at the same time.
Disclosure of Invention
Aiming at the defects in the prior art, the invention provides a web page focus control method and a system compatible with physical keys of a touch screen.
According to the web page focus control method and system compatible with the physical keys of the touch screen, the scheme is as follows:
in a first aspect, a web page focus control method compatible with physical keys of a touch screen is provided, the method comprising:
step S1: searching for a focusable area in the current page;
step S2: according to the searched focusable area, focusable elements in the focusable area are found;
step S3: setting a default focusable element as a starting focus controlled by a physical keyboard, acquiring a current focus after receiving a click event, and analogizing;
step S4: the rules followed by the focus movement are determined.
Preferably, the initial focus in the step S3 is used to search the origin of the next target focus, which is an element or a point.
Preferably, the step S3 specifically includes: entering a page, initializing a physical keyboard, and confirming a focus as an initial focus; monitoring a screen clicking event, and acquiring a current focus after receiving the clicking event, wherein the current focus is a starting focus controlled by a next keyboard.
Preferably, the step S4 includes: when the focus is positioned in the scrolling container and the user triggers space navigation, judging whether the focus is requested to be moved to the scrolling container direction or the document should be scrolled to the scrolling container direction;
if there are visible focusable elements in the requested direction within the scrolling container, focus to the most aligned element in the navigation direction;
otherwise, the scroll container will scroll in the direction of the request.
Preferably, focusing on the most aligned element in the navigation direction in the step S4 includes:
if the navigation direction has a plurality of aligned candidates, selecting an element with the closest on-axis distance corresponding to the navigation direction; if the distances of the elements are the same, selecting the element with the smallest alignment amount;
otherwise, if there are no aligned candidate elements in the given direction, selecting an element closest along an axis distance corresponding to the navigation direction; if the distances of the plurality of elements are the same, the element having the smallest distance along the axis orthogonal to the navigation is selected.
In a second aspect, a web page focus control system compatible with physical keys of a touch screen is provided, the system comprising:
module M1: searching for a focusable area in the current page;
module M2: according to the searched focusable area, focusable elements in the focusable area are found;
module M3: setting a default focusable element as a starting focus controlled by a physical keyboard, acquiring a current focus after receiving a click event, and analogizing;
module M4: the rules followed by the focus movement are determined.
Preferably, the initial focus in the module M3 is an element or point for searching for the origin of the next target focus.
Preferably, the module M3 specifically includes: entering a page, initializing a physical keyboard, and confirming a focus as an initial focus; monitoring a screen clicking event, and acquiring a current focus after receiving the clicking event, wherein the current focus is a starting focus controlled by a next keyboard.
Preferably, the module M4 includes: when the focus is positioned in the scrolling container and the user triggers space navigation, judging whether the focus is requested to be moved to the scrolling container direction or the document should be scrolled to the scrolling container direction;
if there are visible focusable elements in the requested direction within the scrolling container, focus to the most aligned element in the navigation direction;
otherwise, the scroll container will scroll in the direction of the request.
Preferably, the most aligned elements focused to the navigation direction in the module M4 include:
if the navigation direction has a plurality of aligned candidates, selecting an element with the closest on-axis distance corresponding to the navigation direction; if the distances of the elements are the same, selecting the element with the smallest alignment amount;
otherwise, if there are no aligned candidate elements in the given direction, selecting an element closest along an axis distance corresponding to the navigation direction; if the distances of the plurality of elements are the same, the element having the smallest distance along the axis orthogonal to the navigation is selected.
Compared with the prior art, the invention has the following beneficial effects:
the invention enables the mobile operating system to be simultaneously adapted to the equipment only comprising the touch screen, the equipment only comprising the physical key and the equipment simultaneously comprising the touch screen and the physical key, achieves the effect of one-time development and the adaptation of various hardware equipment, and greatly improves the efficiency of transplanting development.
Drawings
Other features, objects and advantages of the present invention will become more apparent upon reading of the detailed description of non-limiting embodiments, given with reference to the accompanying drawings in which:
FIG. 1 is a technical scheme flow chart;
fig. 2 is a focus movement rule example.
Detailed Description
The present invention will be described in detail with reference to specific examples. The following examples will assist those skilled in the art in further understanding the present invention, but are not intended to limit the invention in any way. It should be noted that variations and modifications could be made by those skilled in the art without departing from the inventive concept. These are all within the scope of the present invention.
The embodiment of the invention provides a web page focus control method compatible with physical keys of a touch screen, which aims to solve the problem that an operation interface is difficult to use when two input devices are used simultaneously. Referring to fig. 1, the method specifically includes the following steps:
step S1: finding a focusable area in a current page includes: a spatial navigation container is found, and the region in which the regions can be aggregated is found recursively.
Step S2: according to the searched focusable area, focusable elements in the focusable area are found; comprising the following steps: labels in the page are visible elements such as buttons, text boxes, links, and the like.
Step S3: setting a default focusable element as a starting focus controlled by a physical keyboard, comprising: the default focusable element refers to the DOM anchor in the focusable area of the current top level page.
Top level pages refer to a page that is not a sub-page.
DOM anchors refer to links used to create another document or to create bookmarks within a document.
The initial focus includes: the origin for searching for the next target focus may be an element or a point.
In order to solve the problem that the operation interface is difficult to use when the device has a touch screen and a physical keyboard at the same time, a default focusable element is set, and the method as an initial focus controlled by the physical keyboard further comprises: entering a page, initializing a physical keyboard, and confirming a focus as an initial focus; monitoring a screen clicking event, acquiring a current focus after receiving the clicking event, and the current focus is a starting focus controlled by a next keyboard, and the like.
Step S4: determining the rule followed by the focus movement includes: it is first clear whether, when the focus is within the scroll container and the user triggers spatial navigation, it is requested to move the focus in that direction or the document should scroll in that direction. If there are focusable elements visible in the requested direction within the scroll container, focus is on the most aligned element in the navigation direction. Otherwise, the scroll container will scroll in the direction of the request.
Focusing on the most aligned element in the navigation direction includes: if there are multiple aligned candidates for the navigation direction, an element closest to the on-axis corresponding to the navigation direction is selected. If the distances of the plurality of elements are the same, the element with the smallest alignment amount is selected.
Otherwise, if there are no aligned candidate elements in a given direction, the element closest along the axis corresponding to the navigation direction is selected. If the distances of the plurality of elements are the same, the element having the smallest distance along the axis orthogonal to the navigation is selected. As shown in fig. 2, let element a be the initial focus, when the user clicks the physical button DOWN, the candidate focus element is element C because the alignment amount of element C and element a is large.
The invention also provides a web page focus control system compatible with the physical keys of the touch screen, which comprises:
module M1: searching for a focusable area in the current page; comprising the following steps: a spatial navigation container is found, and the region in which the regions can be aggregated is found recursively.
Module M2: according to the searched focusable area, focusable elements in the focusable area are found; comprising the following steps: labels in the page are visible elements such as buttons, text boxes, links, and the like.
Module M3: setting a default focusable element as a starting focus controlled by a physical keyboard; comprising the following steps: the default focusable element refers to the DOM anchor in the focusable area of the current top level page.
Top level pages refer to a page that is not a sub-page.
DOM anchors refer to links used to create another document or to create bookmarks within a document.
Specifically, the starting focus in module M3 is used to search for the origin of the next target focus, which may be an element or a point.
The focusable element, as the initial focus controlled by the physical keyboard, further comprises: entering a page, initializing a physical keyboard, and confirming a focus as an initial focus; monitoring a screen clicking event, and acquiring a current focus after receiving the clicking event, wherein the current focus is a starting focus controlled by a next keyboard.
Module M4: the rules followed by the focus movement are determined. Comprising the following steps: when the focus is positioned in the scrolling container and the user triggers space navigation, judging whether the focus is requested to be moved to the scrolling container direction or the document should be scrolled to the scrolling container direction; if there are visible focusable elements in the requested direction within the scrolling container, focus to the most aligned element in the navigation direction; otherwise, the scroll container will scroll in the direction of the request.
Focusing on the most aligned elements in the navigation direction includes: if the navigation direction has a plurality of aligned candidates, selecting an element with the closest on-axis distance corresponding to the navigation direction; if the distances of the elements are the same, selecting the element with the smallest alignment amount; otherwise, if there are no aligned candidate elements in the given direction, selecting an element closest along an axis distance corresponding to the navigation direction; if the distances of the plurality of elements are the same, the element having the smallest distance along the axis orthogonal to the navigation is selected. As shown in fig. 2, let element a be the initial focus, when the user clicks the physical button DOWN, the candidate focus element is element C because the alignment amount of element C and element a is large.
The embodiment of the invention provides a web page focus control method and a web page focus control system compatible with physical keys of a touch screen, so that a mobile operating system can be simultaneously adapted to equipment only comprising the touch screen, equipment only comprising the physical keys and equipment simultaneously comprising the touch screen and the physical keys, one-time development is achieved, the adaptation effect of various hardware equipment is achieved, and the transplanting development efficiency is greatly improved.
Those skilled in the art will appreciate that the invention provides a system and its individual devices, modules, units, etc. that can be implemented entirely by logic programming of method steps, in addition to being implemented as pure computer readable program code, in the form of logic gates, switches, application specific integrated circuits, programmable logic controllers, embedded microcontrollers, etc. Therefore, the system and various devices, modules and units thereof provided by the invention can be regarded as a hardware component, and the devices, modules and units for realizing various functions included in the system can also be regarded as structures in the hardware component; means, modules, and units for implementing the various functions may also be considered as either software modules for implementing the methods or structures within hardware components.
The foregoing describes specific embodiments of the present invention. It is to be understood that the invention is not limited to the particular embodiments described above, and that various changes or modifications may be made by those skilled in the art within the scope of the appended claims without affecting the spirit of the invention. The embodiments of the present application and features in the embodiments may be combined with each other arbitrarily without conflict.

Claims (2)

1. A web page focus control method compatible with physical keys of a touch screen is characterized by comprising the following steps:
step S1: searching for a focusable area in the current page;
step S2: according to the searched focusable area, focusable elements in the focusable area are found;
step S3: setting a default focusable element as a starting focus controlled by a physical keyboard, entering a page, initializing the physical keyboard, and confirming a focus as the starting focus; monitoring a screen clicking event, acquiring a current focus after receiving the clicking event, and analogizing the current focus as a starting focus for the next keyboard control;
the initial focus is used for searching the origin of the next target focus and is an element or a point;
step S4: determining a rule followed by the focus movement;
the step S4 includes: when the focus is positioned in the scrolling container and the user triggers space navigation, judging whether the focus is requested to be moved to the scrolling container direction or the document should be scrolled to the scrolling container direction;
if there are visible focusable elements in the requested direction within the scrolling container, focus to the most aligned element in the navigation direction;
otherwise, the rolling container will roll in the requested direction;
the focusing on the most aligned element in the navigation direction in step S4 includes:
if the navigation direction has a plurality of aligned candidates, selecting an element with the closest on-axis distance corresponding to the navigation direction; if the distances of the elements are the same, selecting the element with the smallest alignment amount;
otherwise, if there are no aligned candidate elements in the given direction, selecting an element closest along an axis distance corresponding to the navigation direction; if the distances of the plurality of elements are the same, the element having the smallest distance along the axis orthogonal to the navigation is selected.
2. A web page focus control system compatible with physical keys of a touch screen, comprising:
module M1: searching for a focusable area in the current page;
module M2: according to the searched focusable area, focusable elements in the focusable area are found;
module M3: setting a default focusable element as a starting focus controlled by a physical keyboard, entering a page, initializing the physical keyboard, and confirming a focus as the starting focus; monitoring a screen clicking event, acquiring a current focus after receiving the clicking event, and analogizing the current focus as a starting focus for the next keyboard control;
the initial focus is used for searching the origin of the next target focus and is an element or a point;
module M4: determining a rule followed by the focus movement;
the module M4 includes: when the focus is positioned in the scrolling container and the user triggers space navigation, judging whether the focus is requested to be moved to the scrolling container direction or the document should be scrolled to the scrolling container direction;
if there are visible focusable elements in the requested direction within the scrolling container, focus to the most aligned element in the navigation direction;
otherwise, the rolling container will roll in the requested direction;
the most aligned elements in the module M4 focused to the navigation direction include:
if the navigation direction has a plurality of aligned candidates, selecting an element with the closest on-axis distance corresponding to the navigation direction;
if the distances of the elements are the same, selecting the element with the smallest alignment amount;
otherwise, if there are no aligned candidate elements in the given direction, selecting an element closest along an axis distance corresponding to the navigation direction; if the distances of the plurality of elements are the same, the element having the smallest distance along the axis orthogonal to the navigation is selected.
CN202111339543.2A 2021-11-12 2021-11-12 Web page focus control method and system compatible with physical keys of touch screen Active CN114153536B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111339543.2A CN114153536B (en) 2021-11-12 2021-11-12 Web page focus control method and system compatible with physical keys of touch screen

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111339543.2A CN114153536B (en) 2021-11-12 2021-11-12 Web page focus control method and system compatible with physical keys of touch screen

Publications (2)

Publication Number Publication Date
CN114153536A CN114153536A (en) 2022-03-08
CN114153536B true CN114153536B (en) 2024-04-09

Family

ID=80460243

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111339543.2A Active CN114153536B (en) 2021-11-12 2021-11-12 Web page focus control method and system compatible with physical keys of touch screen

Country Status (1)

Country Link
CN (1) CN114153536B (en)

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102007773A (en) * 2008-02-21 2011-04-06 活动视频网络有限公司 Using triggers with video for interactive content identification
CN102566916A (en) * 2010-12-17 2012-07-11 微软公司 Creation, editing and navigation of diagrams
CN102857823A (en) * 2012-08-24 2013-01-02 乐视网信息技术(北京)股份有限公司 Web page focus control method based on television
EP2846240A1 (en) * 2013-09-09 2015-03-11 Swisscom AG Graphical user interface for browsing a list of visual elements
CN107306308A (en) * 2016-04-20 2017-10-31 中兴通讯股份有限公司 Page response method and device
CN109426409A (en) * 2017-09-04 2019-03-05 中兴通讯股份有限公司 A kind of method, apparatus of operation display, mobile terminal and storage medium
CN113051495A (en) * 2019-12-27 2021-06-29 成都鼎桥通信技术有限公司 Web page focus navigation method and device
CN113194345A (en) * 2021-05-19 2021-07-30 南京炫佳网络科技有限公司 Signal processing method and device, set top box and storage medium

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102007773A (en) * 2008-02-21 2011-04-06 活动视频网络有限公司 Using triggers with video for interactive content identification
CN102566916A (en) * 2010-12-17 2012-07-11 微软公司 Creation, editing and navigation of diagrams
CN102857823A (en) * 2012-08-24 2013-01-02 乐视网信息技术(北京)股份有限公司 Web page focus control method based on television
EP2846240A1 (en) * 2013-09-09 2015-03-11 Swisscom AG Graphical user interface for browsing a list of visual elements
CN107306308A (en) * 2016-04-20 2017-10-31 中兴通讯股份有限公司 Page response method and device
CN109426409A (en) * 2017-09-04 2019-03-05 中兴通讯股份有限公司 A kind of method, apparatus of operation display, mobile terminal and storage medium
CN113051495A (en) * 2019-12-27 2021-06-29 成都鼎桥通信技术有限公司 Web page focus navigation method and device
CN113194345A (en) * 2021-05-19 2021-07-30 南京炫佳网络科技有限公司 Signal processing method and device, set top box and storage medium

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
"AVS IPTV数字电视机顶盒浏览器的设计";李双全等;《计算机工程》;20080120;第245-247页 *
"基于移动端网页界面的设计与实现";肖萌;《中国优秀硕士学位论文全文数据库 信息科技辑》;20190515;I139-165 *
"Web Service Applying Moving Target Defense";Zhang Jingzhe等;《2018 IEEE Third International Conference on Data Science in Cyberspace (DSC)》;20180719;全文 *

Also Published As

Publication number Publication date
CN114153536A (en) 2022-03-08

Similar Documents

Publication Publication Date Title
US8756516B2 (en) Methods, systems, and computer program products for interacting simultaneously with multiple application programs
US9405452B2 (en) Apparatus and method of searching for contents in touch screen device
US8482522B2 (en) Method and system for navigating within an image
JP5882492B2 (en) Providing keyboard shortcuts mapped to the keyboard
EP3822828A2 (en) Method, apparatus, device and storage medium for determining page theme and computer program product
CN104205098A (en) Navigating among content items in a browser using an array mode
JP2010530561A (en) Context-sensitive prediction and learning using universal reentrant predictive text input software component
CN102460362A (en) Glyph entry on computing device
CN101281443A (en) Page switching method, system as well as mobile communication terminal
JP2003523562A (en) pointing device
JP2002062966A (en) Information processor and control method thereof
EP2328070B1 (en) Information processing device and program
KR20090102727A (en) Method and device for controlling screen size of display device
KR20090053776A (en) Apparatus and method for inputting command or data based on movement of touch position and change in direction thereof
KR20150057138A (en) Terminal and method of controlling the same
CN106371715B (en) Method and device for realizing multi-item switching
CN103488424A (en) Method and device for displaying information
CN113407075B (en) Icon sorting method and device and electronic equipment
US7113168B2 (en) Compact information terminal apparatus, method for controlling such apparatus and medium
CN114153536B (en) Web page focus control method and system compatible with physical keys of touch screen
CN111831177B (en) Application icon display method and device and electronic equipment
CN113253883A (en) Application interface display method and device and electronic equipment
CN112698734B (en) Candidate word display method and device and electronic equipment
EP3065032A1 (en) Word prediction input method and terminal
JP2009140152A (en) Character input device and character-character type selection method

Legal Events

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