# US 2023/0054717 A1 · Ui control generation and trigger methods, and terminal

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 2023/0054717 A1
- Document ID: US20230054717A1
- Status: Published application
- Kind: A1
- Application number: 18/048,046
- Filed: 2022-10-20
- Published: 2023-02-23
- Earliest claimed: 2020-04-30
- Assignees: Huawei Technologies Co., Ltd.
- Applicants: Huawei Technologies Co., Ltd.
- Inventors: Xuanzhe Hou; Ruofei Han
- Web page: https://patentgrep.com/patent/US20230054717A1

## CPC

- G06F 3/04847: Interaction techniques to control parameter settings, e.g. interaction with sliders or dials
- G06F 3/0481: based on specific properties of the displayed interaction object or a metaphor-based environment, e.g. interaction with desktop elements like windows or icons, or assisted by a cursor's changing behaviour or appearance
- G06F 3/04817: using icons (graphical or visual programming using iconic symbols G06F8/34)
- G06F 3/0486: Drag-and-drop
- G06F 3/04886: by partitioning the display area of the touch-screen or the surface of the digitising tablet into independently controllable areas, e.g. virtual keyboards or menus
- G06F 8/34: Graphical or visual programming
- G06F 8/38: for implementing user interfaces
- G06F 9/451: Execution arrangements for user interfaces
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)

## Abstract

Embodiments of this application provide UI control generation and trigger methods and a terminal. In a method embodiment of a first terminal, detecting that a UI control template was dragged to a layout file editor using a drag operation and the drag operation was released. A UI control attribute of the UI control. The UI control is generated based on the UI control attribute of the UI control. In embodiments of this application, the developer can conveniently develop a GUI application that supports a plurality of input events and a plurality of presentation manners.

## Claims

### Claim 1

A user interface (UI) control generation method performed by a first terminal, the first terminal comprising an integrated development environment (IDE) and a UI framework, the IDE comprises a layout file editor and a control editor, the UI framework comprises a UI control template, the method comprising:
detecting that the UI control template was dragged to the layout file editor using a drag operation and the drag operation was released;
setting a UI control attribute of a UI control; and
generating the UI control based on the UI control attribute of the UI control after receiving an editing operation input by a developer to the control editor of the UI control template;
the UI control attribute of the UI control comprising a trigger attribute, a presentation attribute, and a response attribute, the trigger attribute comprising a plurality of input events supported by the UI control, the presentation attribute comprising a plurality of presentation manners supported by the UI control, and the response attribute comprises a plurality of response actions performed after the UI control is triggered.

### Claim 2 (depends on 1)

The method according to claim 1, wherein the control editor comprises a trigger attribute editing unit, a presentation attribute editing unit, and a response attribute editing unit; and
the setting the UI control attribute of the UI control and generating the UI control comprises:
after receiving a presentation editing operation input by the developer to the presentation attribute editing unit, setting the presentation attribute of the UI control;
after receiving a trigger editing operation input by the developer to the trigger attribute editing unit, setting the trigger attribute of the UI control;
after receiving a response editing operation input by the developer to the response attribute editing unit, setting the response attribute of the UI control; and
generating the UI control based on the presentation attribute, the trigger attribute, and the response attribute of the UI control.

### Claim 3 (depends on 1)

The method according to claim 1, wherein the UI control comprises at least one of a slider bar control, a selection control, a button control, a list control, or an input control.

### Claim 4 (depends on 1)

The method according to claim 1, wherein the input event comprises at least one of a voice event, an image event, a touch event, a mouse event, a keyboard event, a sensor event, or a remote input device event.

### Claim 5 (depends on 1)

The method according to claim 1, wherein the presentation manner comprises at least one of a text, a graphic, sound, a video, or lighting.

### Claim 6

A user interface (UI) control trigger method performed by a second terminal, the second terminal comprising a target application, a UI framework, and a system service, the method comprising:
invoking the UI framework to load a first interface of the target application when detecting a start operation performed by a user on the target application, the first interface comprising a UI control;
determining a trigger attribute input event corresponding to a trigger attribute of the UI control;
invoking the system service to obtain an input device input event using an input device and recognize the input device input event using the input device;
generating, when the input device input event matches the trigger attribute input event, a trigger request corresponding to the input event; and
finding, based on the input event carried in the trigger request, a UI control corresponding to the input event; and
triggering the UI control;
wherein a UI control attribute of the UI control comprises a trigger attribute, a presentation attribute, and a response attribute, the trigger attribute comprises a plurality of input events supported by the UI control, the presentation attribute comprises a plurality of presentation manners supported by the UI control, and the response attribute comprises a plurality of response actions performed after the UI control is triggered.

### Claim 7 (depends on 6)

The method according to claim 6, wherein after the determining the trigger attribute input event, and before the invoking the system service to obtain the input device input event, the method further comprising:
storing the trigger attribute input event;
after the generating the trigger request corresponding to the input event;
verifying the input event carried in the trigger request;
finding, based on the input event carried in the trigger request, the UI control corresponding to the input event when the verification succeeds; and
triggering the UI control.

### Claim 8 (depends on 7)

The method according to claim 7, wherein the verifying the input event carried in the trigger request comprises:
comparing the input event carried in the trigger request with the stored input event corresponding to the trigger attribute of the UI control;
determining the input event carried in the trigger request and the stored input event corresponding to the trigger attribute of the UI control are a same input event when the verification succeeds.

### Claim 9 (depends on 6)

The method according to claim 6, wherein the finding the UI control corresponding to the input event based on the input event carried in the trigger request, and triggering the UI control comprises:
finding, based on the input event carried in the trigger request and a preset correspondence between the input event and a control identifier of the UI control, the control identifier corresponding to the input event;
finding, based on the control identifier, the UI control corresponding to the control identifier; and
triggering the UI control.

### Claim 10 (depends on 6)

The method according to claim 6, wherein the invoking the UI framework to load the first interface of the target application comprises:
invoking the UI framework to load a page layout file of the first interface, the UI control, the trigger attribute of the UI control, the presentation attribute of the UI control, and the response attribute of the UI control when detecting the start operation performed by the user on the target application; and
determining the input event corresponding to the trigger attribute of the UI control.

### Claim 11 (depends on 6)

The method according to claim 6, wherein after the finding, based on the trigger request, the UI control corresponding to the input event and triggering the UI control, the method further comprises:
invoking the UI framework to load a second interface of the target application when a service operation performed by the user on the target application is detected, the second interface comprising the UI control;
determining the trigger attribute input event corresponding to the trigger attribute of the UI control; and
continuing the invoking of the system service to obtain the input device input event.

### Claim 12 (depends on 6)

The method according to claim 6, wherein the UI control comprises at least one of a slider bar control, a selection control, a button control, a list control, or an input control.

### Claim 13 (depends on 6)

The method according to claim 6, wherein the input event comprises at least one of a voice event, an image event, a touch event, a mouse event, a keyboard event, a sensor event, or a remote input device event.

### Claim 14 (depends on 6)

The method according to claim 6, wherein the presentation manner comprises at least one of a text, a graphic, sound, a video, or lighting.

### Claim 15 (depends on 6)

The method according to claim 6, wherein a recognition function of the system service comprises a voice recognition, body recognition, intent recognition, sentiment recognition, system environment monitoring, or conventional input recognition.

### Claim 16

A first terminal, comprising:
a display;
an integrated development environment (IDE) comprising a layout file editor and a control editor; and
a user interface (UI) framework comprising a UI control template;
a memory storing instructions; and
at least one processor in communication with the memory, the display, the IDE, and the UI framework, the at least one processor configured, upon execution of the instructions, to perform the following steps:
detecting that the UI control template was dragged to the layout file editor using a drag operation and the drag operation was released;
setting a UI control attribute of a UI control; and
generating the UI control based on the UI control attribute of the UI control after receiving an editing operation input by a developer to the control editor of the UI control template;
the UI control attribute of the UI control comprising a trigger attribute, a presentation attribute, and a response attribute, the trigger attribute comprising a plurality of input events supported by the UI control, the presentation attribute comprising a plurality of presentation manners supported by the UI control, and the response attribute comprising a plurality of response actions performed after the UI control is triggered.

### Claim 17 (depends on 16)

The first terminal according to claim 16, wherein the control editor comprises a trigger attribute editing unit, a presentation attribute editing unit, and a response attribute editing unit, wherein the setting the UI control attribute of the UI control and generating the UI control comprises:
setting the presentation attribute of the UI control after receiving a presentation editing operation input by the developer to the presentation attribute editing unit;
setting the trigger attribute of the UI control after receiving a trigger editing operation input by the developer to the trigger attribute editing unit;
setting the response attribute of the UI control after receiving a response editing operation input by the developer to the response attribute editing unit; and
generating the UI control based on the presentation attribute, the trigger attribute, and the response attribute of the UI control.

### Claim 18 (depends on 16)

The first terminal according to claim 16, wherein the UI control comprises at least one of a slider bar control, a selection control, a button control, a list control, or an input control.

### Claim 19 (depends on 16)

The first terminal according to claim 16, wherein the input event comprises at least one of a voice event, an image event, a touch event, a mouse event, a keyboard event, a sensor event, or a remote input device event.

### Claim 20 (depends on 14)

The first terminal according to claim 14, wherein the presentation manner comprises at least one of a word, a graphic, sound, a video, or lighting.
