CN115373564A - Function shortcut key self-defining method and device, software function control method and terminal - Google Patents

Function shortcut key self-defining method and device, software function control method and terminal Download PDF

Info

Publication number
CN115373564A
CN115373564A CN202210956264.9A CN202210956264A CN115373564A CN 115373564 A CN115373564 A CN 115373564A CN 202210956264 A CN202210956264 A CN 202210956264A CN 115373564 A CN115373564 A CN 115373564A
Authority
CN
China
Prior art keywords
control
interface
shortcut key
user
identification information
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.)
Pending
Application number
CN202210956264.9A
Other languages
Chinese (zh)
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.)
Xian Novastar Electronic Technology Co Ltd
Original Assignee
Xian Novastar Electronic Technology Co Ltd
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 Xian Novastar Electronic Technology Co Ltd filed Critical Xian Novastar Electronic Technology Co Ltd
Priority to CN202210956264.9A priority Critical patent/CN115373564A/en
Publication of CN115373564A publication Critical patent/CN115373564A/en
Pending legal-status Critical Current

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/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
    • 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/0489Interaction 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 dedicated keyboard keys or combinations thereof
    • 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

Landscapes

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

Abstract

The application is applicable to the technical field of computer software, and provides a method and a device for self-defining a function shortcut key, a software function control method and a terminal, wherein the method for self-defining the function shortcut key comprises the following steps: the method comprises the steps of firstly responding to the triggering operation of a user on a shortcut key configuration button, respectively displaying a mask control at the position of an interface control, secondly responding to the triggering operation of the user on the mask control, obtaining identification information of the interface control associated with the mask control, establishing a mapping relation between the identification information of the interface control and a user-defined shortcut key, and finally generating a shortcut key configuration file corresponding to a software function according to the identification information of all the interface controls and the mapping relation between the user-defined shortcut keys to complete the user-defined shortcut key function. According to the scheme, the flexibility and variability of the software function shortcut key are increased by customizing the shortcut key function by the user.

Description

Function shortcut key self-defining method and device, software function control method and terminal
Technical Field
The application belongs to the technical field of computer software, and particularly relates to a method and a device for self-defining a function shortcut key, a software function control method and a terminal.
Background
Along with the intelligent development of software, intelligent software has been widely popularized at present. Although the functions of the intelligent software interface are gradually enriched, for a user, common sense shortcut keys are usually added in the software for individual functions, for example, in the broadcast control software, copy is implemented on selected media data by using a shortcut key of Ctrl + c, ctrl + v is implemented to be pasted, delete is implemented to be deleted, and for other functions, functions such as video playing, pausing, program switching and the like need to be implemented by methods such as clicking an interface button.
The common functions of different users are different, and the method for uniformly setting the functions of the shortcut keys is not suitable for all users. Therefore, the shortcut key for defining software functions currently has the defects of fixation, monotony, inflexibility and the like.
Disclosure of Invention
The embodiment of the application provides a method and a device for customizing a function shortcut key, a software function control method and a terminal, wherein the function of the shortcut key can be customized by a user, and the flexibility and variability of the software function shortcut key are increased.
A first aspect of the embodiments of the present application provides a method for customizing a function shortcut key, where the method for customizing a function shortcut key includes:
responding to the triggering operation of a user on a shortcut key configuration button, and respectively displaying mask controls at the positions of interface controls, wherein the mask controls are used for triggering the associated interface controls to execute software functions;
for each mask control, responding to the trigger operation of the user on the mask control, and acquiring identification information of an interface control associated with the mask control;
based on the identification information of the interface control and the user-defined shortcut key, establishing a mapping relation between the identification information of the interface control and the user-defined shortcut key so that the interface control responds to the user-defined shortcut key and executes a related software function;
and generating a shortcut key configuration file corresponding to the software function according to the mapping relation between the identification information of all the interface controls and the user-defined shortcut key.
A second aspect of an embodiment of the present application provides a software function control method, including:
after software is detected to be started, if a shortcut key configuration file corresponding to a software function is detected, reading the shortcut key configuration file, wherein the shortcut key configuration file comprises identification information of an interface control and a mapping relation between self-defined shortcut keys;
based on the mapping relation between the identification information of the interface control and the user-defined shortcut key, assigning a character string generated based on the user-defined shortcut key to a mask control of the interface control corresponding to the identification information;
responding to a triggering operation of a keyboard key by a user, determining a target character string generated based on the keyboard key, wherein the target character string is broadcasted to each mask control by an interface parent control at the bottommost layer in a software interface;
and if the character string of the mask control is the same as the target character string, triggering the interface control associated with the mask control to respond, and executing the associated software function.
A third aspect of the embodiments of the present application provides a function shortcut key customization apparatus, including:
the configuration module is used for responding to the triggering operation of a user on the shortcut key configuration button and respectively displaying the mask control at the position of the interface control, wherein the mask control is used for triggering the associated interface control to execute the software function;
the identification acquisition module is used for responding to the triggering operation of the user on the mask control for each mask control and acquiring the identification information of the interface control associated with the mask control;
the mapping module is used for establishing a mapping relation between the identification information of the interface control and a user-defined shortcut key based on the identification information of the interface control and the user-defined shortcut key so that the interface control responds to the user-defined shortcut key and executes a related software function;
and the generation module is used for generating a shortcut key configuration file corresponding to the software function according to the mapping relation between the identification information of all the interface controls and the user-defined shortcut key.
A fourth aspect of the embodiments of the present application provides a software function control apparatus, including:
the file reading module is used for reading a shortcut key configuration file corresponding to a software function if the shortcut key configuration file is detected after software is detected to be started, wherein the shortcut key configuration file comprises identification information of an interface control and a mapping relation between self-defined shortcut keys;
the relation determining module is used for assigning a character string generated based on the user-defined shortcut key to a mask control of the interface control corresponding to the identification information based on the mapping relation between the identification information of the interface control and the user-defined shortcut key;
the target determining module is used for responding to the triggering operation of a keyboard key by a user, determining a target character string generated based on the keyboard key, wherein the target character string is broadcasted to each mask control by an interface parent control at the bottommost layer in a software interface;
and the function execution module is used for triggering the interface control response associated with the mask control and executing the associated software function if the character string of the mask control is the same as the target character string.
A fifth aspect of an embodiment of the present application provides a terminal, including: the system comprises a memory, a processor and a computer program which is stored in the memory and can run on the processor, wherein the processor implements the function shortcut key customization method of the first aspect or the software function control method of the second aspect when executing the computer program.
A sixth aspect of the embodiments of the present application provides a computer-readable storage medium, where a computer program is stored, and when the computer program is executed by a processor, the computer program implements the method for defining a function shortcut key according to the first aspect, or implements the method for controlling a software function according to the second aspect.
A seventh aspect of the embodiments of the present application provides a computer program product, which when running on a terminal, causes the terminal to execute the method for customizing a function shortcut key according to the first aspect, or to implement the method for controlling a software function according to the second aspect.
Compared with the prior art, the embodiment of the application has the beneficial effects that: according to the method and the device, after the trigger operation of the user on the shortcut key configuration button is responded, the mask controls are respectively displayed at the positions of the interface controls, and the mask controls can be used for triggering the associated interface controls to execute software functions; after a mask control is displayed on a software interface, in response to the triggering operation of a user on the mask control, identification information of the interface control associated with the mask control can be acquired, then based on the identification information and a user-defined shortcut key, a mapping relation between the identification information of the interface control and the user-defined shortcut key is established, so that the interface control executes an associated software function after responding to the corresponding shortcut key input by the user, and finally, according to the mapping relation between the identification information of all the interface controls and the user-defined shortcut key, a shortcut key configuration file corresponding to the software function is generated, so that the function shortcut key of the user-defined software interface is completed. The method realizes the user-defined shortcut key function based on the mask control on the interface control, and increases the flexibility and variability of the software function shortcut key.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings needed to be used in the embodiments or the prior art descriptions will be briefly described below, and it is obvious that the drawings in the following description are only some embodiments of the present application, and it is obvious for those skilled in the art to obtain other drawings without creative efforts.
Fig. 1 is a schematic flowchart of a method for self-defining a function shortcut key according to an embodiment of the present application;
fig. 2 is a schematic flowchart of a software function control method according to a second embodiment of the present application;
fig. 3 is a schematic structural diagram of a function shortcut key customizing device according to a third embodiment of the present application;
fig. 4 is a schematic structural diagram of a software function control apparatus according to a fourth embodiment of the present application;
fig. 5 is a schematic structural diagram of a terminal according to a fifth embodiment of the present application.
Detailed Description
In the following description, for purposes of explanation and not limitation, specific details are set forth, such as particular system structures, techniques, etc. in order to provide a thorough understanding of the embodiments of the present application. It will be apparent, however, to one skilled in the art that the present application may be practiced in other embodiments that depart from these specific details. In other instances, detailed descriptions of well-known systems, devices, circuits, and methods are omitted so as not to obscure the description of the present application with unnecessary detail.
It will be understood that the terms "comprises" and/or "comprising," when used in this specification and the appended claims, specify the presence of stated features, integers, steps, operations, elements, and/or components, but do not preclude the presence or addition of one or more other features, integers, steps, operations, elements, components, and/or groups thereof.
It should also be understood that the term "and/or" as used in this specification and the appended claims refers to and includes any and all possible combinations of one or more of the associated listed items.
As used in this specification and the appended claims, the term "if" may be interpreted contextually as "when", "upon" or "in response to" determining "or" in response to detecting ". Similarly, the phrase "if it is determined" or "if a [ described condition or event ] is detected" may be interpreted contextually to mean "upon determining" or "in response to determining" or "upon detecting [ described condition or event ]" or "in response to detecting [ described condition or event ]".
Furthermore, in the description of the present application and the appended claims, the terms "first," "second," "third," and the like are used for distinguishing between descriptions and not necessarily for describing a relative importance or importance.
Reference throughout this specification to "one embodiment" or "some embodiments," or the like, means that a particular feature, structure, or characteristic described in connection with the embodiment is included in one or more embodiments of the present application. Thus, appearances of the phrases "in one embodiment," "in some embodiments," "in other embodiments," or the like, in various places throughout this specification are not necessarily all referring to the same embodiment, but rather mean "one or more but not all embodiments" unless specifically stated otherwise. The terms "comprising," "including," "having," and variations thereof mean "including, but not limited to," unless otherwise specifically stated.
It should be understood that, the sequence numbers of the steps in this embodiment do not mean the execution sequence, and the execution sequence of each process should be determined by the function and the inherent logic of the process, and should not constitute any limitation to the implementation process of the embodiment of the present application.
In the prior art, a common sense shortcut is usually added to individual functions in software, for example, an information data is selected in a software interface, copying is realized by using a shortcut of Ctrl + c, ctrl + v is pasted, delete is realized, and the like. Therefore, the shortcuts defining software functions currently have the defects of being fixed, monotonous, inflexible and the like, and a method for customizing the shortcut keys corresponding to the software functions is urgently needed.
In order to overcome the defects, the application provides a method for self-defining the function shortcut key, firstly, after responding to the triggering operation of the user on the mask control, the mask control is displayed at the position of the interface control, secondly, the identification information of the interface control associated with the mask control is obtained in response to the triggering operation of the user on the mask control, the mapping relation between the identification information of the interface control and the self-defined shortcut key is established, the interface control responds to the self-defined shortcut key to execute the associated software function, and finally, a shortcut key configuration file corresponding to the software function is generated according to the mapping relation between the identification information of all the interface controls and the self-defined shortcut key to finish the self-defined shortcut key function. According to the scheme, the flexibility and variability of the software function shortcut key are increased by customizing the shortcut key function by the user.
In order to explain the technical means of the present application, the following description is given by way of specific examples.
Referring to fig. 1, a flowchart of a method for customizing a function shortcut key according to an embodiment of the present application is shown. As shown in fig. 1, the method for customizing a function shortcut key may include the following steps:
step 101, responding to the triggering operation of the user on the shortcut key configuration button, and respectively displaying the mask control at the position of the interface control.
In this embodiment of the present application, the shortcut key configuration button may be a configuration button located on the software interface, for example, a shortcut key configuration button exists in a setting group of the software interface, and a specific process of responding to a triggering operation of the shortcut key configuration button by a user may be that the user clicks the shortcut key configuration button through a mouse to generate a mouse event, and after receiving the mouse event, the terminal device parses the mouse event, and determines that the shortcut key configuration button is pressed.
In the embodiment of the application, the mask control can be added to the interface controls of all configurable custom shortcut keys before the user triggers the shortcut key configuration button, that is, when the broadcast control software is downloaded, the mask control is configured for each interface control of the configurable custom shortcut key; and after the user triggers the shortcut key configuration button, the terminal equipment generates a mask control and adds the mask control to all interfaces capable of configuring the user-defined shortcut key. Therefore, each interface control capable of configuring the user-defined shortcut key has a corresponding mask control, wherein the mask control is used for triggering the associated interface control to execute a software function, and the software function can be a function which can be realized by clicking a mouse on a software interface, such as video playing, pausing, stopping, program switching and the like in the playing and controlling software.
It should be understood that the interface control and the mask control are in a parent-child relationship, the interface control is a parent, and the mask control is a child. That is, the mask control is a child control of the interface control, and is configured to trigger the associated interface control to execute the software function, for example, if the associated interface control is a play button, the play function is executed; and if the associated interface control is a program switching button, executing a program switching function.
In the embodiment of the application, each mask control is respectively displayed at the position of an interface control in response to a triggering operation of a user on a shortcut key configuration button, that is, the mask control is displayed on the interface control capable of configuring a custom shortcut key, before the triggering operation of the user on the shortcut key configuration button is responded, the mask control is in a hidden (that is, not displayed) state, after the triggering operation of the user on the shortcut key configuration button is responded, the mask control is displayed at the position of the interface control on a software interface, the style of the mask control can be freely set by the user, for example and without limitation, the style of the mask control can be set to be a grey semitransparent image, and the mask control is displayed on the interface control, that is, the grey semitransparent image is displayed on the interface control in an overlaid manner, so that the user can see the mask control and the interface control overlaid under the mask control.
In a possible implementation manner, the method for customizing the function shortcut further includes:
packaging a mask control;
and respectively adding the mask control to the interface control of each configurable custom shortcut key.
In the embodiment of the application, the mask control may refer to a common mask control, that is, the processing procedures of UI display, message reception, and message analysis of the mask control added to each interface control of the configurable custom shortcut key are the same, and by using the common mask control, the interface control at the bottom layer of the software can uniformly process all the mask controls.
In the embodiment of the application, different packaging technologies, such as QT technology and QML technology for a Windows system, can be adopted according to different systems of the terminal when packaging a mask control; the IOS system can use IOS self-packaging, and the application does not limit the adopted packaging technology.
And 102, responding to the trigger operation of a user on the mask control for each mask control, and acquiring the identification information of the interface control associated with the mask control.
In the embodiment of the application, in order to facilitate storage of the user-defined shortcut key when the software is closed and analysis of the user-defined shortcut key when the software is started, the terminal needs to pre-allocate one-to-one corresponding identification information for each interface control. The specific process of responding to the trigger operation of the user on the mask control can be as follows: the terminal equipment responds to the operation of clicking the mask control by the user, generates a mouse event, analyzes the mouse event and determines that the mask control is clicked. After determining that the mask control is clicked, acquiring identification information of an interface control associated with the mask control.
In one possible implementation, before obtaining the identification information of the interface control associated with the mask control, the method further includes:
determining the category of the interface control associated with the mask control;
correspondingly, acquiring identification information of the interface control associated with the mask control, including:
and acquiring the identification information of the interface control according to the category of the interface control associated with the mask control.
In this embodiment, the types of the interface controls may include a fixed control and an additional control, that is, when the software is started, the interface control already existing on the software interface is the fixed control, and the additional interface control is the additional control in the use process of the software, for example, in the broadcast control software, in the use process of the software, an input picture control is added on a certain layer, and the output picture control is the additional control.
The identification information and the interface controls have a one-to-one correspondence relationship, but the corresponding identification information obtaining modes of the interface controls of different types are different.
In a possible implementation manner, in a case that the category to which the interface control associated with the mask control belongs is a fixed control, acquiring identification information of the interface control according to the category to which the interface control associated with the mask control belongs includes:
and respectively assigning a plurality of preset identification information to the interface control of which the category belongs to the fixed control.
In the embodiment of the application, for the fixed controls on the software interface, a plurality of pieces of identification information can be preset by the terminal, and the preset plurality of pieces of identification information are assigned to each fixed control in a one-to-one correspondence manner. For example, the playing control, the program switching control, and the mirror effect control on the playing control software interface are all fixed controls of the software interface, and a plurality of pieces of identification information are assigned to each fixed control one by one, and as an example and not by way of limitation, play1 may be assigned to the playing control, and cut1 may be assigned to the program switching control.
It should be understood that, there is a one-to-one correspondence relationship between the identification information and the interface control, where the identification information may be any type of data, for example, english characters or numeric characters, which is not limited in this application.
In a possible implementation manner, when the category to which the interface control associated with the mask control belongs is the newly added control, obtaining the identification information of the interface control according to the category to which the interface control associated with the mask control belongs includes:
and generating the identification information of the interface control according to the attribute state information and the identification information generation rule of the interface control.
In the embodiment of the application, the newly added control refers to a control which does not exist on the interface when the software is started, and usually, when the number of the interface controls of the software interface is insufficient, an interface control is newly added, and the interface control is the newly added control. The identification information generation rule may be a set of rules preset by the terminal for generating unique identification information and analyzing the unique identification, and the attribute state information is attribute information of an interface control required by the identification information generation rule for generating the identification information, and may refer to, for example, a position, a hierarchy, and a type of a newly added control. For example, a new program 5 is added on the layer a in the grouping area of a broadcast control software, it is known that the control corresponding to the program 5 is a new control, at this time, the position coordinate information, the level information (for example, the layer a), and the type (for example, new) of the new control may be obtained, and according to the identification information generation rule, the identification information of the new interface control may be generated as follows: layeraIndex5+ position coordinate information; and reversely analyzing which interface control on the software interface corresponding to the identification information according to the identification information generation rule, for example, obtaining the program 5 interface control on the layer A corresponding to the LayeraIndex5+ position coordinate information according to the LayeraIndex5+ position coordinate information and the identification information generation rule.
It should be understood that the attribute state information of the interface control and the identification information generation rule correspond to each other, and the attribute state information of the interface control required to be obtained by different identification information generation rules is different.
And 103, establishing a mapping relation between the identification information of the interface control and the user-defined shortcut key based on the identification information of the interface control and the user-defined shortcut key.
In the embodiment of the present application, in order to enable the interface control to respond to the user-defined shortcut key and execute the associated software function, a mapping relationship between the interface control and the user-defined shortcut key needs to be established. And establishing a mapping relation between the interface control and the user-defined shortcut key, namely establishing a mapping relation between the identification information of the interface control and the user-defined shortcut key.
For example, after the user clicks the mask control, the user may input a shortcut key, where the input mode may be directly pressing an upper shortcut key of the keyboard, and the terminal obtains an input signal of the shortcut key, or may also be pressing the shortcut key on the keyboard and displaying the location of the interface control on the software interface, for example, after the user clicks the mask control on the program switch, the terminal inputs o, and then the terminal establishes a mapping relationship between the identification information of the program switch and the user-defined shortcut key based on the identification information of the program switch and the user-defined shortcut key o.
It should be understood that after the user clicks the mask control, only one mask control is in the configuration process of the user-defined shortcut key at the same time, that is, only one mask control can be configured with the user-defined shortcut key at the same time.
In one possible implementation mode, in response to the triggering operation of the user on the mask control, the selected identification of the mask control is displayed on the mask control.
For example, after the user clicks the mask control, four corners may be displayed on the mask control to determine that the mask control is selected, and the shortcut key input at the current time is the shortcut key configured for the mask control.
And 104, generating a shortcut key configuration file corresponding to the software function according to the mapping relation between the identification information of all the interface controls and the user-defined shortcut key.
In this embodiment of the present application, after configuring the user-defined shortcut keys of all interface controls, the mapping relationship between the identification information of all interface controls and the user-defined shortcut keys may be saved as a configuration file, where the configuration file is a shortcut key configuration file corresponding to a software function, and the configuration file saves a configuration result of a user, so that when the software is started next time, an interface control corresponding to the user-defined shortcut key may be obtained according to the configuration file, further, the shortcut key configuration file may be found in a folder configured by the software, including but not limited to, an xml file type, and after the mapping relationship in the shortcut key configuration file is modified by the user, the corresponding relationship between the interface control of the corresponding software interface and the shortcut key may also be changed.
In the embodiment of the application, after responding to the triggering operation of a user on the shortcut key configuration button, each mask control is respectively displayed at the position of an interface control, and the mask control can be used for triggering the associated interface control to execute a software function; after a mask control is displayed on a software interface, responding to the triggering operation of a user on the mask control, establishing the mapping relation between the identification information of the interface control and a user-defined shortcut key based on the identification information and the user-defined shortcut key so that the interface control executes the associated software function after responding to the corresponding shortcut key input by the user, and finally generating a shortcut key configuration file corresponding to the software function according to the mapping relation between the identification information of all the interface controls and the user-defined shortcut key so as to finish the function shortcut key of the user-defined software interface. The method realizes the user-defined shortcut key function based on the mask control on the interface control, and increases the flexibility and variability of the software function shortcut key.
Referring to fig. 2, a flowchart of a software function control method provided in the second embodiment of the present application is shown. As shown in fig. 2, the software function control method may include the steps of:
step 201, after detecting that the software is started, if a shortcut key configuration file corresponding to a software function is detected, reading the shortcut key configuration file.
In the embodiment of the application, after the shortcut key configuration file corresponding to the software function is detected, the shortcut key configuration file can be read in a data writing mode.
The shortcut key configuration file comprises the identification information of the interface control and the mapping relation between the user-defined shortcut keys. The identification information of the interface control can be used for identifying the corresponding interface control, namely, the mapping relation between the identification information of the interface control and the user-defined shortcut key is obtained according to the shortcut key configuration file, however, the interface control corresponding to the identification information can be obtained according to the identification information of the interface control, and therefore, the mapping relation between the interface control and the user-defined shortcut key can be determined according to the shortcut key configuration file.
And 202, assigning a character string generated based on the user-defined shortcut key to a mask control of the interface control corresponding to the identification information based on the mapping relation between the identification information of the interface control and the user-defined shortcut key.
In the embodiment of the application, because the mapping relationship between the interface control and the user-defined shortcut key can be determined based on the mapping relationship between the identification information of the interface control and the user-defined shortcut key, the character string generated based on the user-defined shortcut key can be assigned to the mask control corresponding to the interface control based on the mapping relationship.
Step 203, responding to a triggering operation of a keyboard key by a user, and determining a target character string generated based on the keyboard key.
In this embodiment of the present application, the target character string is broadcasted to each mask control by the interface parent control at the bottom layer in the software interface, where the association relationship among the interface parent control, the interface control, and the mask control can be specifically known through the following description.
In the prior art, when the software function control is realized, a click event input by a user can be monitored through the interface control, a click signal corresponding to the click event is obtained, and the click signal can trigger the interface control to execute the software function corresponding to the click of the interface control.
On the basis of not changing original software, the same mask control can be added on each interface control for receiving the message forwarded by the father control and judging whether to trigger the associated interface control to respond to the keyboard event, so that the software function is controlled through a self-defined keyboard shortcut key.
The software interface structure comprises interface father controls and father controls which are arranged on the bottommost layer, and mask controls which are arranged on each interface control. All the interface controls displayed in the software interface are child controls of the interface parent control, the mask control is child controls of the interface control, the child controls can process the received events according to the authority of the child controls, if the authority of the child controls can process the received events, the events do not need to be transmitted to the corresponding parent control, and if the authority of the child controls cannot process the received events, the events need to be transmitted to the corresponding parent control until the events are transmitted to the bottommost parent control.
For example, a user clicks an interface control with a mouse, and assuming that the interface control is a video clip, the interface control may acquire a corresponding video clip signal when monitoring a mouse click event, and trigger the interface control to execute a video clip function. And because the software interface control does not need to process all self-defined keyboard events, the keyboard events can be transmitted to the interface parent control at the bottommost layer of the software layer by layer, the interface parent control at the bottommost layer analyzes the keyboard events and forwards the keyboard events to all the mask controls, and the interface parent control at the bottommost layer can be understood to analyze the keyboard events and forward the keyboard events to all the child controls at the topmost layer.
When a user presses a keyboard key, the bottommost father control analyzes the keyboard key to obtain a character string corresponding to the keyboard key, the character string is determined to be a target character string, and the target character string is broadcasted to each mask control by the interface father control of the software bottom interface.
And step 204, if the character string of the mask control is the same as the target character string, triggering an interface control associated with the mask control to respond, and executing the associated software function.
In the embodiment of the application, based on the mapping relationship between the identification information of the interface control and the user-defined shortcut key, the mask control of each interface control is assigned with the corresponding character string based on the user-defined shortcut key correspondingly set. Namely, each mask control configured with the interface control of the user-defined shortcut key has a corresponding character string. Therefore, after each mask control receives the target character string broadcasted by the interface parent control at the bottommost layer, the target character string is compared with the character string of the interface control associated with the mask control. If the character string of the mask control is the same as the target character string, triggering the associated interface control to respond, and executing the associated software function; if the character strings of all the mask controls are different from the target character string, all the interface controls do not respond, and the keyboard keys corresponding to the target character string are not the self-defined shortcut keys corresponding to the interface controls.
In the embodiment of the application, after software is detected to be started, if a shortcut key configuration file corresponding to a software function is detected, a mapping relation between identification information of an interface control and a user-defined shortcut key can be determined by reading the shortcut key configuration file, then a character string generated based on the user-defined shortcut key can be assigned to a mask control of the interface control corresponding to the identification information according to the mapping relation, a target character string generated based on the keyboard key is determined in response to the triggering operation of a user on the keyboard key, an interface father control at the bottommost layer of a software interface is broadcasted to each mask control, after the mask control receives the target character string, judgment is made based on the character string of the associated interface control, whether to trigger the response of the associated interface control is determined, and software function control is achieved through the user-defined shortcut key. The problem of fixed shortcut key that can only realize specific function among the prior art, and unsatisfied the function demand of configuration custom shortcut key is solved.
Referring to fig. 3, a schematic structural diagram of a function shortcut key customization apparatus provided in the third embodiment of the present application is shown, and for convenience of description, only the relevant portions of the third embodiment of the present application are shown.
The function shortcut key self-defining device specifically comprises the following modules:
the configuration module 301 is configured to respond to a triggering operation of a user on a shortcut key configuration button, and respectively display each mask control at a position where an interface control is located, where the mask control is used to trigger an associated interface control to execute a software function;
the identification acquisition module 302 is configured to, for each mask control, respond to a trigger operation of a user on the mask control, and acquire identification information of an interface control associated with the mask control;
the mapping module 303 is configured to establish a mapping relationship between the identification information of the interface control and the user-defined shortcut key based on the identification information of the interface control and the user-defined shortcut key, so that the interface control responds to the user-defined shortcut key and executes a related software function;
the generating module 304 is configured to generate a shortcut key configuration file corresponding to the software function according to the mapping relationship between the identification information of all the interface controls and the user-defined shortcut key.
In this embodiment, the configuration module 301 may specifically include the following sub-modules:
the packaging sub-module is used for packaging a mask control;
and the adding submodule is used for respectively adding the mask control to the interface control of each configurable custom shortcut key.
In this embodiment of the present application, the function shortcut key customizing device may further include the following modules:
the category determination module is used for determining the category of the interface control associated with the mask control;
correspondingly, the identifier obtaining module 302 may specifically include the following sub-modules:
and the information acquisition sub-module is used for acquiring the identification information of the interface control according to the category of the interface control associated with the mask control.
In this embodiment of the present application, in a case that the category of the interface control associated with the mask control is a fixed control, the information obtaining sub-module may specifically include the following units:
and the assignment unit is used for assigning the plurality of preset identification information to the interface control of which the category belongs to the fixed control respectively.
In this embodiment of the present application, when the category of the interface control associated with the mask control is the newly added control, the information obtaining sub-module may specifically include the following units:
and the identification generation unit is used for generating the identification information of the interface control according to the attribute state information of the interface control and the identification information generation rule, wherein the attribute state information is used for attribute information of the interface control required by the identification information generation rule for generating the identification information.
The function shortcut key customization apparatus provided in the embodiment of the present application may be applied to the first method embodiment, and for details, reference is made to the description of the first method embodiment, and details are not repeated here.
Referring to fig. 4, a schematic structural diagram of a software function control apparatus provided in the fourth embodiment of the present application is shown, and for convenience of description, only the portions related to the embodiment of the present application are shown.
The software function control device may specifically include the following modules:
the file reading module 401 is configured to, after detecting that software is started, read a shortcut key configuration file if the shortcut key configuration file corresponding to a software function is detected, where the shortcut key configuration file includes identification information of an interface control and a mapping relationship between user-defined shortcut keys;
the relation determining module 402 is configured to assign a character string generated based on the user-defined shortcut key to a mask control of the interface control corresponding to the identification information based on a mapping relation between the identification information of the interface control and the user-defined shortcut key;
a target determining module 403, configured to determine, in response to a user's trigger operation on a keyboard key, a target character string generated based on the keyboard key, where the target character string is broadcasted to each mask control by an interface parent control at a bottommost layer in the software interface;
and the function execution module 404 is configured to trigger an interface control response associated with a mask control and execute an associated software function if the character string of the mask control is the same as the target character string.
The software function control apparatus provided in the embodiment of the present application can be applied to the second method embodiment, and for details, reference is made to the description of the second method embodiment, and details are not repeated here.
Fig. 5 is a schematic structural diagram of a terminal according to a fifth embodiment of the present application. As shown in fig. 5, the terminal 500 of this embodiment includes: at least one processor 510 (only one shown in fig. 5), a memory 520, and a computer program 521 stored in the memory 520 and operable on the at least one processor 510, wherein the processor 510 executes the computer program 521 to implement the steps in the above-mentioned embodiment of the function shortcut customization method, or to implement the steps in the above-mentioned embodiment of the software function control method.
The terminal 500 may be a computing device such as a desktop computer, a notebook, a palm computer, and a cloud server. The terminal may include, but is not limited to, a processor 510, a memory 520. Those skilled in the art will appreciate that fig. 5 is only an example of a terminal 500 and does not constitute a limitation of terminal 500, and may include more or less components than those shown, or combine some components, or different components, such as input output devices, network access devices, etc.
The Processor 510 may be a Central Processing Unit (CPU), and the Processor 510 may be other general purpose Processor, a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), an off-the-shelf Programmable Gate Array (FPGA) or other Programmable logic device, discrete Gate or transistor logic, discrete hardware components, etc. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
The memory 520 may in some embodiments be an internal storage unit of the terminal 500, such as a hard disk or a memory of the terminal 500. The memory 520 may also be an external storage device of the terminal 500 in other embodiments, such as a plug-in hard disk, a Smart Media Card (SMC), a Secure Digital (SD) Card, a Flash memory Card (Flash Card), and the like, provided on the terminal 500. Further, the memory 520 may also include both an internal memory unit and an external memory device of the terminal 500. The memory 520 is used for storing an operating system, an application program, a BootLoader (BootLoader), data, and other programs, such as program codes of the computer programs. The memory 520 may also be used to temporarily store data that has been output or is to be output.
It should be clear to those skilled in the art that, for convenience and simplicity of description, the foregoing division of the functional units and modules is only used for illustration, and in practical applications, the above function distribution may be performed by different functional units and modules as needed, that is, the internal structure of the apparatus may be divided into different functional units or modules to perform all or part of the above described functions. Each functional unit and module in the embodiments may be integrated in one processing unit, or each unit may exist alone physically, or two or more units are integrated in one unit, and the integrated unit may be implemented in a form of hardware, or in a form of software functional unit. In addition, specific names of the functional units and modules are only for convenience of distinguishing from each other, and are not used for limiting the protection scope of the present application. For the specific working processes of the units and modules in the system, reference may be made to the corresponding processes in the foregoing method embodiments, which are not described herein again.
In the above embodiments, the descriptions of the respective embodiments have respective emphasis, and reference may be made to the related descriptions of other embodiments for parts that are not described or illustrated in a certain embodiment.
Those of ordinary skill in the art will appreciate that the various illustrative elements and algorithm steps described in connection with the embodiments disclosed herein may be implemented as electronic hardware or combinations of computer software and electronic hardware. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the technical solution. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present application.
In the embodiments provided in the present application, it should be understood that the disclosed apparatus/terminal and method may be implemented in other ways. For example, the above-described apparatus/terminal embodiments are merely illustrative, and for example, the division of the modules or units is only one logical division, and there may be other divisions when actually implemented, for example, a plurality of units or components may be combined or may be integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or units, and may be in an electrical, mechanical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one position, or may be distributed on multiple network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present application may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit may be implemented in the form of hardware, or may also be implemented in the form of a software functional unit.
The integrated modules/units, if implemented in the form of software functional units and sold or used as separate products, may be stored in a computer readable storage medium. Based on such understanding, all or part of the flow in the method of the embodiments described above can be realized by a computer program, which can be stored in a computer-readable storage medium and can realize the steps of the embodiments of the methods described above when the computer program is executed by a processor. Wherein the computer program comprises computer program code, which may be in the form of source code, object code, an executable file or some intermediate form, etc. The computer-readable medium may include: any entity or device capable of carrying the computer program code, recording medium, U.S. disk, removable hard disk, magnetic diskette, optical disk, computer Memory, read-Only Memory (ROM), random Access Memory (RAM), electrical carrier wave signal, telecommunications signal, and software distribution medium, etc. It should be noted that the computer readable medium may contain content that is subject to appropriate increase or decrease as required by legislation and patent practice in jurisdictions, for example, in some jurisdictions, computer readable media does not include electrical carrier signals and telecommunications signals as is required by legislation and patent practice.
When the computer program product runs on a terminal, the steps in the method embodiments can be implemented when the terminal executes the computer program product.
The above-mentioned embodiments are only used to illustrate the technical solutions of the present application, and not to limit the same. Although the present application has been described in detail with reference to the foregoing embodiments, it should be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; such modifications and substitutions do not depart from the spirit and scope of the embodiments of the present application, and they should be construed as being included in the present application.

Claims (10)

1. A method for self-defining a function shortcut key is characterized by comprising the following steps:
responding to the triggering operation of a user on the shortcut key configuration button, and respectively displaying mask controls at the positions of interface controls, wherein the mask controls are used for triggering the associated interface controls to execute software functions;
for each mask control, responding to the trigger operation of the user on the mask control, and acquiring identification information of an interface control associated with the mask control;
based on the identification information of the interface control and the user-defined shortcut key, establishing a mapping relation between the identification information of the interface control and the user-defined shortcut key so that the interface control responds to the user-defined shortcut key and executes the associated software function;
and generating a shortcut key configuration file corresponding to the software function according to the identification information of all the interface controls and the mapping relation between the user-defined shortcut keys.
2. The method of claim 1, wherein the method further comprises:
packaging a mask control;
and respectively adding the mask control to the interface control of each configurable custom shortcut key.
3. The method for customizing the function shortcut of claim 1, wherein before the obtaining the identification information of the interface control associated with the mask control, the method further comprises:
determining a category to which an interface control associated with the mask control belongs;
the obtaining of the identification information of the interface control associated with the mask control includes:
and acquiring the identification information of the interface control according to the category of the interface control associated with the mask control.
4. The method as claimed in claim 3, wherein, in a case that the category of the interface control associated with the mask control is a fixed control, the obtaining the identification information of the interface control according to the category of the interface control associated with the mask control comprises:
and respectively assigning a plurality of preset identification information to the interface control of which the category belongs to the fixed control.
5. The method as claimed in claim 3, wherein when the category of the interface control associated with the mask control is an added control, the obtaining the identification information of the interface control according to the category of the interface control associated with the mask control comprises:
and generating identification information of the interface control according to the attribute state information and the identification information generation rule of the interface control, wherein the attribute state information is the attribute information of the interface control required by the identification information generation rule.
6. A software function control method, comprising:
after software startup is detected, if a shortcut key configuration file corresponding to a software function is detected, reading the shortcut key configuration file, wherein the shortcut key configuration file comprises identification information of an interface control and a mapping relation between self-defined shortcut keys;
assigning a character string generated based on the user-defined shortcut key to a mask control of the interface control corresponding to the identification information based on the mapping relation between the identification information of the interface control and the user-defined shortcut key;
responding to a triggering operation of a keyboard key by a user, determining a target character string generated based on the keyboard key, wherein the target character string is broadcasted to each mask control by an interface father control at the bottommost layer in a software interface;
and if the character string of the mask control is the same as the target character string, triggering the interface control associated with the mask control to respond, and executing the associated software function.
7. A kind of function shortcut self-defining device, characterized by that, comprising:
the configuration module is used for responding to the triggering operation of a user on the shortcut key configuration button and respectively displaying the mask controls at the positions of the interface controls, wherein the mask controls are used for triggering the associated interface controls to execute software functions;
the identification acquisition module is used for responding to the triggering operation of the user on the mask control for each mask control, and acquiring the identification information of the interface control associated with the mask control;
the mapping module is used for establishing a mapping relation between the identification information of the interface control and a user-defined shortcut key based on the identification information of the interface control and the user-defined shortcut key so as to enable the interface control to respond to the user-defined shortcut key and execute a related software function;
and the generation module is used for generating a shortcut key configuration file corresponding to the software function according to the mapping relation between the identification information of all the interface controls and the user-defined shortcut key.
8. A software function control apparatus, comprising:
the file reading module is used for reading a shortcut key configuration file corresponding to a software function if the shortcut key configuration file is detected after software starting is detected, wherein the shortcut key configuration file comprises the identification information of an interface control and the mapping relation between self-defined shortcut keys;
the relation determining module is used for assigning a character string generated based on the user-defined shortcut key to a mask control of the interface control corresponding to the identification information based on the mapping relation between the identification information of the interface control and the user-defined shortcut key;
the target determining module is used for responding to the triggering operation of a keyboard key by a user, determining a target character string generated based on the keyboard key, wherein the target character string is broadcasted to each mask control by an interface parent control at the bottommost layer in a software interface;
and the function execution module is used for triggering the interface control response associated with the mask control and executing the associated software function if the character string of the mask control is the same as the target character string.
9. A terminal comprising a memory, a processor and a computer program stored in the memory and executable on the processor, characterized in that the processor implements the method according to any of claims 1 to 5 or implements the method according to claim 6 when executing the computer program.
10. A computer-readable storage medium, in which a computer program is stored which, when being executed by a processor, carries out the method of any one of claims 1 to 5, or carries out the method of claim 6.
CN202210956264.9A 2022-08-10 2022-08-10 Function shortcut key self-defining method and device, software function control method and terminal Pending CN115373564A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210956264.9A CN115373564A (en) 2022-08-10 2022-08-10 Function shortcut key self-defining method and device, software function control method and terminal

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210956264.9A CN115373564A (en) 2022-08-10 2022-08-10 Function shortcut key self-defining method and device, software function control method and terminal

Publications (1)

Publication Number Publication Date
CN115373564A true CN115373564A (en) 2022-11-22

Family

ID=84066074

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210956264.9A Pending CN115373564A (en) 2022-08-10 2022-08-10 Function shortcut key self-defining method and device, software function control method and terminal

Country Status (1)

Country Link
CN (1) CN115373564A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115834938A (en) * 2022-12-06 2023-03-21 深圳创维-Rgb电子有限公司 Shortcut key configuration method, device, equipment and medium

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115834938A (en) * 2022-12-06 2023-03-21 深圳创维-Rgb电子有限公司 Shortcut key configuration method, device, equipment and medium

Similar Documents

Publication Publication Date Title
CN108228169B (en) Chart making method, device, equipment and medium based on eCharts tool
CN109005283B (en) Method, device, terminal and storage medium for displaying notification message
US10810698B2 (en) Information processing method and client
CN109471626B (en) Page logic structure, page generation method, page data processing method and device
CN106484479B (en) A kind of management method, device and intelligent terminal for opening application more
CN108268147B (en) Input method based calculation processing method, device and equipment
CN112286416A (en) Information display method and device and electronic equipment
WO2021017853A1 (en) Method for recommending operation sequence, terminal, and computer readable medium
CN115373564A (en) Function shortcut key self-defining method and device, software function control method and terminal
US11567635B2 (en) Online collaborative document processing method and device
CN111831181A (en) Application switching display method and device and electronic equipment
CN115599363A (en) Configuration method, device and system of visual component
CN114415847A (en) Text information deleting method and device and electronic equipment
CN107239212B (en) Method and device for presenting segmentation selection view and user terminal
CN111736825B (en) Information display method, device, equipment and storage medium
CN106488020B (en) A kind of operation management method, device and intelligent terminal for opening application more
WO2023103901A1 (en) Application management method and apparatus, and electronic device
CN116301785A (en) Method and device for realizing custom text editor component
CN115037654B (en) Flow statistics method, device, electronic equipment and readable storage medium
US20230006952A1 (en) Information replying method, apparatus, electronic device, computer storage medium, and product
CN114296845B (en) Interface processing method, device, electronic device and storage medium
CN115270737A (en) Format modification method and device for target object
CN112068895B (en) Code configuration method, device, video playing equipment and storage medium
CN112433723A (en) Personalized list development method and device
CN112558853A (en) Session message processing method and device, electronic device and storage medium

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