CN112533013B - Control adjusting method and device, electronic equipment and storage medium - Google Patents

Control adjusting method and device, electronic equipment and storage medium Download PDF

Info

Publication number
CN112533013B
CN112533013B CN202011350221.3A CN202011350221A CN112533013B CN 112533013 B CN112533013 B CN 112533013B CN 202011350221 A CN202011350221 A CN 202011350221A CN 112533013 B CN112533013 B CN 112533013B
Authority
CN
China
Prior art keywords
control
information
determining
graphical user
user interface
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
CN202011350221.3A
Other languages
Chinese (zh)
Other versions
CN112533013A (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.)
Guangzhou Boguan Information Technology Co Ltd
Original Assignee
Guangzhou Boguan Information 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 Guangzhou Boguan Information Technology Co Ltd filed Critical Guangzhou Boguan Information Technology Co Ltd
Priority to CN202011350221.3A priority Critical patent/CN112533013B/en
Publication of CN112533013A publication Critical patent/CN112533013A/en
Application granted granted Critical
Publication of CN112533013B publication Critical patent/CN112533013B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/20Servers specifically adapted for the distribution of content, e.g. VOD servers; Operations thereof
    • H04N21/21Server components or server architectures
    • H04N21/218Source of audio or video content, e.g. local disk arrays
    • H04N21/2187Live feed
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/40Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
    • H04N21/43Processing of content or additional data, e.g. demultiplexing additional data from a digital video stream; Elementary client operations, e.g. monitoring of home network or synchronising decoder's clock; Client middleware
    • H04N21/431Generation of visual interfaces for content selection or interaction; Content or additional data rendering
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/40Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
    • H04N21/47End-user applications
    • H04N21/485End-user interface for client configuration

Abstract

The embodiment of the invention provides a method and a device for adjusting a control, electronic equipment and a storage medium, wherein the method comprises the following steps: responding to a display trigger event aiming at a second control, and determining the identification of the second control and the current attribute information of the second control; determining position control information aiming at the first control according to the identification of the second control and the current attribute information of the second control; and adjusting the display position of the first control on the graphical user interface according to the position control information. By the embodiment of the invention, the optimization of position conflict adjustment among the controls is realized, the position adjustment is carried out by dynamically responding the display trigger event of the second control through the first control, the adjustment logic is simplified, the generation of dependency among different controls is avoided, the code maintenance and problem tracking are facilitated, and the test regression time is reduced.

Description

Control adjusting method and device, electronic equipment and storage medium
Technical Field
The present invention relates to the field of internet technologies, and in particular, to a method and an apparatus for controlling a widget, an electronic device, and a storage medium.
Background
With the development and application of the live broadcast technology, various activities and playing contents in the live broadcast room are rich and diverse, and specific service information can be displayed for a user through controls displayed at different positions in the live broadcast room so as to carry out live broadcast room interaction. And the control of each service has strong competition for a specific display area on the terminal screen, for example, the right side of the video area is centered when the mobile phone is horizontally displayed, and the right side of the top of the video area when the mobile phone is vertically displayed.
However, in the prior art, for the situation of the display area conflict in the live broadcasting room, a mode of adjusting the service priority is usually adopted, which results in a strong dependency relationship between the controls of different services, when the number of service controls increases, service maintenance is not facilitated, and when the display of the controls is abnormal after adjustment, the problem of tracking is not facilitated.
Disclosure of Invention
In view of the above, it is proposed to provide a method and apparatus, an electronic device, and a storage medium for controlling adjustment, which overcome the above problems or at least partially solve the above problems, and include:
a method for adjusting controls, which provides a graphical user interface through a terminal, wherein the graphical user interface is provided with a first control, and comprises the following steps:
responding to a display trigger event aiming at a second control, and determining the identification of the second control and the current attribute information of the second control;
determining position control information aiming at the first control according to the identification of the second control and the current attribute information of the second control;
and adjusting the display position of the first control on the graphical user interface according to the position control information.
Optionally, the first control corresponds to a reference display area, and the display trigger event includes any one or more of the following items:
the control module is used for triggering the visibility change of the second control in the reference display area, triggering the size change of the second control in the reference display area, and triggering the position change of the second control in the reference display area.
Optionally, the determining, according to the identifier of the second control and the current attribute information of the second control, the position control information for the first control includes:
acquiring a preset mapping table; the preset mapping table stores the corresponding relation among the identification of the control, the attribute information of the control and the sub-position control information;
determining one or more pieces of sub-position control information from the preset mapping table according to the identifier of the second control and the current attribute information of the second control;
determining position control information for the first control from the one or more sub-position control information.
Optionally, before the adjusting the display position of the first control on the graphical user interface according to the position control information, the method further includes:
determining that the first control is in an active state.
Optionally, the adjusting, according to the position control information, the display position of the first control on the graphical user interface includes:
determining current position information of the first control;
and adjusting the display position of the first control on the graphical user interface according to the current position information and the position control information.
Optionally, the current attribute information includes any one or more of:
visibility information of the second control, size information of the second control, and position information of the second control.
Optionally, the graphical user interface is a live interface for a live application.
An apparatus for control adjustment, providing a graphical user interface through a terminal, the graphical user interface having a first control, the apparatus comprising:
the display trigger event response module is used for responding to a display trigger event aiming at a second control and determining the identification of the second control and the current attribute information of the second control;
the position control information determining module is used for determining the position control information aiming at the first control according to the identification of the second control and the current attribute information of the second control;
and the display position adjusting module is used for adjusting the display position of the first control on the graphical user interface according to the position control information.
An electronic device comprising a processor, a memory and a computer program stored on the memory and capable of running on the processor, the computer program when executed by the processor implementing the method of control adjustment as described above.
A computer-readable storage medium, on which a computer program is stored which, when executed by a processor, implements a method of control adjustment as described above.
The embodiment of the invention has the following advantages:
in the embodiment of the invention, the identification of the second control and the current attribute information of the second control are determined by responding to the display trigger event aiming at the second control, then the position control information aiming at the first control is determined according to the identification of the second control and the current attribute information of the second control, and the display position of the first control on the graphical user interface is adjusted according to the position control information, so that the optimization of the position conflict adjustment among the controls is realized, the display position adjustment is carried out by dynamically responding to the display trigger event of the second control through the first control, the adjustment logic is simplified, the generation of the dependency relationship among different controls is avoided, the code maintenance and the problem tracking are facilitated, and the test regression time is reduced.
Drawings
In order to more clearly illustrate the technical solution of the present invention, the drawings needed to be used in the description of the present invention will be briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without inventive exercise.
Fig. 1 is a flowchart illustrating steps of a method for adjusting a control according to an embodiment of the present invention;
FIG. 2 is a flowchart illustrating steps of another method for adjusting controls according to an embodiment of the present invention;
FIG. 3 is a flowchart illustrating steps of a method for adjusting a control according to another embodiment of the present invention;
fig. 4 is a schematic structural diagram of a device for adjusting a control according to an embodiment of the present invention.
Detailed Description
In order to make the aforementioned objects, features and advantages of the present invention comprehensible, embodiments accompanied with figures are described in further detail below. It is to be understood that the embodiments described are only a few embodiments of the present invention, and not all embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
Referring to fig. 1, a flowchart illustrating steps of a method for adjusting a control according to an embodiment of the present invention is shown, where a terminal may provide a graphical user interface, where the graphical user interface may have a first control, and the method specifically includes the following steps:
step 101, responding to a display trigger event aiming at a second control, and determining an identifier of the second control and current attribute information of the second control;
the live broadcast interface can be a live broadcast interface aiming at live broadcast application, the live broadcast interface can be provided with a first control piece of which the position is to be adjusted, the first control piece can correspond to a reference display area, the reference display area can be a preset initial display area of the first control piece in the live broadcast interface, for example, a service control piece can be arranged in the live broadcast interface aiming at a live broadcast room and displayed for a user, and the service control piece can be displayed in the live broadcast interface through the preset initial display area so as to realize interaction with the user.
As an example, the second control may be one or more controls having a position conflict with the first control, and the identifier of the second control may be a service identifier of the second control, for example, for a service control a in a live interface of a live broadcast room, in an initial display area of the service control a, there may be one or more other service controls having a position conflict with the service control a, and the service control may have a corresponding service ID.
In an embodiment of the invention, the display triggering event may include any one or more of:
the control module is used for controlling the display of the display area of the display device according to the visibility change of the second control in the reference display area, the size change of the second control in the reference display area and the position change of the second control in the reference display area.
For example, in a reference display area of a first control, a visibility change (such as a visible/invisible state change), a size change, a position change, and the like of a second control can be triggered by a display trigger event; the position change may include a position change in a part of the reference display area or a position change in the entire reference display area.
As an example, the current attribute information includes any one or more of:
visibility information of the second control, size information of the second control, and position information of the second control.
For example, a mapping relationship between the display trigger event and the identifier of the second control and the current attribute information of the second control may be preset, that is, when the display trigger event is detected, the identifier of the second control and the current attribute information of the second control corresponding to the display trigger event may be determined according to the display trigger event, so that when a change condition of the second control exists in the reference display area of the first control, the changed identifier of the second control and the current attribute information of the second control, such as specific information of the change condition, may be obtained for the change condition.
In the process of adjusting the position of the control, the detection may be performed on the reference display area of the first control, the display trigger event for the second control may be responded, and according to the mapping relationship between the display trigger event and the identifier of the second control and the current attribute information of the second control, the identifier of the second control and the current attribute information of the second control corresponding to the display trigger event may be further determined, so as to further adjust the position of the control on the first control.
In practical application, an initial display area of a service control a (i.e., a first control) in a live broadcast interface of a live broadcast room may be detected, when a display trigger event for a second control is detected, that is, when a change condition of one or more other service controls exists in the initial display area, it may be determined that one or more other service controls exist in the initial display area and a position of the service control a conflict, and further, a control position of the service control a may be further adjusted by determining a service ID and specific information of the change condition of the one or more other service controls.
102, determining position control information aiming at the first control according to the identification of the second control and the current attribute information of the second control;
the position control information may be used to adjust the position of the first control.
After the identification of the second control and the current attribute information of the second control are determined, the position control information for the first control can be further determined according to the identification of the second control and the current attribute information of the second control, so that the position control information is adopted to adjust the position of the first control.
Specifically, a mapping table may be preset for the first control, a corresponding relationship between the identifier of the second control, the attribute information of the plurality of second controls, and the to-be-moved distance of the first control may be predefined in the mapping table, and then, according to the mapping table, the to-be-moved distance of the one or more first controls may be obtained for the identifier of the second control corresponding to the display trigger event and the current attribute information of the second control, and the position control information for the first control may be obtained through a sum of the to-be-moved distances of the one or more first controls.
And 103, adjusting the display position of the first control on the graphical user interface according to the position control information.
After the position control information is obtained, the position of the first control may be adjusted according to the position control information to adjust the actual display position of the first control in the graphical user interface, for example, the position control information may be represented by coordinate values (x, y), and then the coordinate values for performing position adjustment on the first control may be determined according to the position control information to adjust the actual display position of the first control in the graphical user interface.
In the embodiment of the invention, the identification of the second control and the current attribute information of the second control are determined by responding to the display trigger event aiming at the second control, then the position control information aiming at the first control is determined according to the identification of the second control and the current attribute information of the second control, and the display position of the first control on the graphical user interface is adjusted according to the position control information, so that the optimization of the position conflict adjustment among the controls is realized, the display position adjustment is carried out by dynamically responding to the display trigger event of the second control through the first control, the adjustment logic is simplified, the generation of the dependency relationship among different controls is avoided, the code maintenance and the problem tracking are facilitated, and the test regression time is reduced.
Referring to fig. 2, a flowchart illustrating steps of another method for adjusting a control according to an embodiment of the present invention is shown, which may specifically include the following steps:
step 201, responding to a display trigger event aiming at a second control, and determining an identifier of the second control and current attribute information of the second control;
step 202, determining position control information for the first control according to the identifier of the second control and the current attribute information of the second control;
in an embodiment of the present invention, step 202 may include the following sub-steps:
acquiring a preset mapping table; the preset mapping table stores the corresponding relation among the identification of the control, the attribute information of the control and the sub-position control information; determining one or more pieces of sub-position control information from the preset mapping table according to the identifier of the second control and the current attribute information of the second control; determining position control information for the first control from the one or more sub-position control information.
In a specific implementation, a preset mapping table for a first control may be obtained, where the preset mapping table may store a correspondence between an identifier of the control, attribute information of the control, and sub-position control information (for example, an identifier of a second control, attribute information of a plurality of second controls, and a distance to be moved of the first control), and then one or more sub-position control information (for example, a distance to be moved of the first control) may be determined from the preset mapping table according to the identifier of the second control and current attribute information of the second control, so that the position control information for the first control may be obtained through a sum of the one or more sub-position control information.
For example, a moving distance mapping table (i.e., a preset mapping table) for a control a (i.e., a first control) may be established in advance, where IDs (i.e., identifications of second controls) of other services may be regarded as keys, a distance to be moved of the control a may be regarded as a value, and then a moving distance mapping table for the control a including one or more other service controls may be obtained, where the value may be a positive value or a negative value, and may represent distances in different directions, for example, when the key is a service ID of the control B, and the value is 15, the key-value may be represented as a service ID =15 of the control B.
In an example, the identifiers of other business controls, attribute information (such as size change, position change, visibility change, and other change conditions) of the controls, and sub-position control information (such as value values) may be stored in the moving distance mapping table, and when one or more other business controls have size change, position change, and visibility change, the sub-position control information corresponding to the identifiers of the other business controls may be determined for the change conditions of the other business controls according to the moving distance mapping table for control a.
For example, for one or more other service controls having a position conflict with the control a, the value values corresponding to the service IDs of the other service controls may be determined according to the change conditions of the other service controls, and then the value values determined by the one or more other service controls having a position conflict with the control a may be counted, so as to perform control position adjustment on the first control by using the counted value values.
Step 203, determining that the first control is in an active state;
in specific implementation, whether the first control is in an active state or not can be judged for the first control, and then according to a judgment result, when the first control is determined to be in the active state, the position of the first control is adjusted by adopting the position control information.
For example, when the live interface of the live broadcast room is started, or when the user starts to operate on the live interface, it may be determined that the first control is in an active state, and then position control information may be used to adjust the position of the first control.
In an example, the state to be displayed can be presented through a graphical user interface provided by the terminal, the graphical user interface can be displayed to a user after the live broadcast interface of the live broadcast room is started, and then the related service control of the live broadcast room can be presented to the user through the graphical user interface.
In yet another example, when one or more other business controls are changed in size, position and visibility, value values corresponding to business IDs of the other business controls may be determined, value values determined by the one or more other business controls having position conflicts with control a may be counted, and a counted value sum value (i.e. position control information) may be recorded, so that when the first control is determined to be in an active state, the control position adjustment is performed on the first control using the value sum value, and thus, by recording the counted value sum value in response to a display trigger event for the other business controls, relevant data of the other business controls affecting the position adjustment of control a may be made explicitly searchable, and data tracing is facilitated.
And 204, adjusting the display position of the first control on the graphical user interface according to the position control information.
In the embodiment of the invention, the identification of the second control and the current attribute information of the second control are determined by responding to the display trigger event aiming at the second control, then the position control information aiming at the first control is determined according to the identification of the second control and the current attribute information of the second control, the first control is further determined to be in an active state, the display position of the first control on the graphical user interface is adjusted according to the position control information, the optimization of position conflict adjustment among the controls is realized, and the display position of the first control is adjusted according to the position control information when the first control is in the active state, so that the adjustment logic is simplified, the refreshing times of the control position are reduced, and the test return time is reduced.
Referring to fig. 3, a flowchart illustrating steps of another method for adjusting a control according to an embodiment of the present invention is shown, which may specifically include the following steps:
step 301, responding to a display trigger event for a second control, and determining an identifier of the second control and current attribute information of the second control;
step 302, determining position control information for the first control according to the identifier of the second control and the current attribute information of the second control;
step 303, determining current position information of the first control;
the current position information may be information of a current position of the first control in the graphical user interface, for example, coordinate information of the current position of the first control in the graphical user interface may be obtained, and the coordinate information may be obtained by obtaining a translation value (translation value) in LiveData.
LiveData can be an observable data holding class, which can have a life cycle perception capability, and when data held by LiveData for a plurality of business controls changes and the business controls are in an active state, the LiveData can send data change conditions to inform observers.
For an observer mode (Publish/Subscribe), it may provide a one-to-many dependency relationship, that is, multiple observer objects may monitor a topic object at the same time, and when the status of the topic object changes, all the monitored observer objects may be notified, so that all the observer objects can perform data update based on the status change of the topic object.
The observer may be an object subscribed to change for the target object data, and when the state of the target object changes, the observer object may obtain a corresponding notification, so that the coupling degree between the objects may be reduced, and in the process of notifying the observer object, the target object does not need to know the subscribed observer object information, for example, for a reference display area of the control a, when other business controls change, the control a may obtain a notification of the change situation, and may update the display position of the data adjustment control a, and other businesses do not need to know the related information of the control a.
In a specific implementation, the current position information of the first control may be acquired for the first control, so as to further perform control position adjustment on the first control according to the current position information and the position control information, and change an actual display position of the first control in the graphical user interface.
In an example, when the state of an application component observer (e.g., the control a) is STARTED or restored, that is, when the live interface of the live broadcast room is STARTED completely, or when a user can start operating on the live interface, it can be determined that the component is in the active state through the LiveData, and then when the control a is in the active state, the live data can be monitored, so as to further adjust the actual display position of the control a on the graphical user interface according to the panning value of the LiveData.
Step 304, adjusting the display position of the first control on the graphical user interface according to the current position information and the position control information.
After the current position information of the first control is obtained, the position of the first control can be adjusted by using the current position information and the position control information, so as to adjust the actual display position of the first control in the graphical user interface.
For example, after obtaining the coordinate information (i.e., the current position information) of the current position of the control a (i.e., the first control) and the value sum value (i.e., the position control information) counted for the control a, the coordinate information and the value sum value to be moved for the control a may be combined to obtain a translation value (e.g., the coordinate information) to be moved for the control a, so as to adjust the actual display position of the control a in the graphical user interface.
Specifically, by counting the value sum value for one or more other business controls, and then matching the counted value sum value with the translation value in the LiveData for control a, the translation value in the LiveData for control a can be updated when there is no match.
When the control A conflicts with one or more other service controls at the same time, due to the influence of different service controls on the position of the control A, matching can occur, namely the statistical value sum value is equal to the translation value in the LiveData for the control A, so that the position of the control A can be confirmed to be unchanged, and further the translation in the LiveData for the control A does not need to be updated.
In an example, the translation value in the LiveData for the control a may be a value for controlling the control a to translate, that is, may move in the X axis or the Y axis, which may be represented as a translation value for the control a, and the translation value may be a distance between a coordinate of a position to be moved by the control a in the graphical user interface and an initial position, for example, the initial position coordinate of the control a may be (0,0), and the coordinate of the position to be moved by the control a after the shift may be (X, Y), (X, Y) may be determined according to a sum value counted by value values for one or more other business controls.
Through a mode of directly injecting other service controls (namely, second controls), according to a preset mapping table aiming at the control A (namely, the first control), the mapping relation between the IDs of the other service controls and the distance to be moved of the control A can be obtained, so that the state of the control A does not need to be concerned when the other service controls are changed, the logic of adjusting the position relation among the service controls can be simplified, and the maintenance and the expansion aiming at the service controls are convenient; and when the control A is in an active state, refreshing according to a final translation value in LiveData, so that the refreshing frequency of the position of the control A is reduced, code maintenance and problem tracking are facilitated through centralized management of data, and test regression time is reduced.
In the embodiment of the invention, the identification of the second control and the current attribute information of the second control are determined by responding to the display trigger event aiming at the second control, then the position control information aiming at the first control is determined according to the identification of the second control and the current attribute information of the second control, further the current position information of the first control is determined, the display position of the first control on a graphical user interface is adjusted according to the current position information and the position control information, the optimization of position conflict adjustment among the controls is realized, the position adjustment is carried out according to the current position information and the position control information by the dynamic response of the first control, the logic of the position relationship adjustment among the service controls can be simplified, the generation of a dependency relationship among different controls is avoided, and the code maintenance and the problem tracking are facilitated.
It should be noted that, for simplicity of description, the method embodiments are described as a series of acts or combination of acts, but those skilled in the art will recognize that the present invention is not limited by the illustrated order of acts, as some steps may occur in other orders or concurrently in accordance with the embodiments of the present invention. Further, those skilled in the art will appreciate that the embodiments described in the specification are presently preferred and that no particular act is required to implement the invention.
Referring to fig. 4, which is a schematic structural diagram illustrating an apparatus for adjusting a control according to an embodiment of the present invention, a terminal may provide a graphical user interface, where the graphical user interface may have a first control, and the apparatus may specifically include the following modules:
a display trigger event response module 401, configured to respond to a display trigger event for a second control, and determine an identifier of the second control and current attribute information of the second control;
a position control information determining module 402, configured to determine, according to the identifier of the second control and the current attribute information of the second control, position control information for the first control;
and a display position adjusting module 403, configured to adjust a display position of the first control on the graphical user interface according to the position control information.
In an embodiment of the present invention, the first control corresponds to a reference display area, and the display trigger event includes any one or more of the following items:
the event triggering the visibility change of the second control in the reference display area, the event triggering the size change of the second control on the reference display area, and the event triggering the position change of the second control in the reference display area.
In an embodiment of the present invention, the position control information determining module 402 includes:
the mapping table obtaining submodule is used for obtaining a preset mapping table; the preset mapping table stores the corresponding relation among the identification of the control, the attribute information of the control and the sub-position control information;
the sub-position control information determining submodule is used for determining one or more pieces of sub-position control information from the preset mapping table according to the identification of the second control and the current attribute information of the second control;
and the position control information determining submodule is used for determining the position control information aiming at the first control according to the one or more pieces of sub-position control information.
In an embodiment of the present invention, the apparatus further includes:
and the active state determining module is used for determining that the first control is in an active state.
In an embodiment of the present invention, the display position adjusting module 403 includes:
a current position information determining submodule, configured to determine current position information of the first control;
and the display position adjusting submodule is used for adjusting the display position of the first control on the graphical user interface according to the current position information and the position control information.
In an embodiment of the present invention, the current attribute information includes any one or more of the following items:
visibility information of the second control, size information of the second control, and position information of the second control.
In an embodiment of the present invention, the graphical user interface is a live interface for a live application.
In the embodiment of the invention, when the trigger event aiming at the reference display area is detected, the identifier of the second control and the current attribute information of the second control corresponding to the trigger event are determined, then the position control information aiming at the first control is determined according to the identifier of the second control and the current attribute information of the second control, and further the position of the first control is controlled according to the position control information, so that the optimization of position conflict adjustment among the controls is realized, the position control is carried out by dynamically responding the change condition of the second control through the first control, the adjustment logic is simplified, the generation of a dependency relationship among different controls is avoided, the code maintenance and the problem tracking are facilitated, and the test regression time is reduced.
An embodiment of the present invention further provides an electronic device, which may include a processor, a memory, and a computer program stored in the memory and capable of running on the processor, where the computer program, when executed by the processor, implements the method for adjusting the above control.
An embodiment of the present invention further provides a computer-readable storage medium, on which a computer program is stored, where the computer program, when executed by a processor, implements the method for adjusting the above control.
For the apparatus embodiment, since it is substantially similar to the method embodiment, the description is relatively simple, and reference may be made to the partial description of the method embodiment for relevant points.
The embodiments in the present specification are all described in a progressive manner, and each embodiment focuses on differences from other embodiments, and portions that are the same and similar between the embodiments may be referred to each other.
As will be appreciated by one skilled in the art, embodiments of the present invention may be provided as a method, apparatus, or computer program product. Accordingly, embodiments of the present invention may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, embodiments of the present invention may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
Embodiments of the present invention are described with reference to flowchart illustrations and/or block diagrams of methods, terminal devices (systems), and computer program products according to embodiments of the invention. It will be understood that each flow and/or block of the flowchart illustrations and/or block diagrams, and combinations of flows and/or blocks in the flowchart illustrations and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing terminal to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing terminal, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing terminal to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing terminal to cause a series of operational steps to be performed on the computer or other programmable terminal to produce a computer implemented process such that the instructions which execute on the computer or other programmable terminal provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
While preferred embodiments of the present invention have been described, additional variations and modifications of these embodiments may occur to those skilled in the art once they learn of the basic inventive concepts. Therefore, it is intended that the appended claims be interpreted as including preferred embodiments and all such alterations and modifications as fall within the scope of the embodiments of the invention.
Finally, it should also be noted that, herein, relational terms such as first and second, and the like may be used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or terminal that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or terminal. Without further limitation, an element defined by the phrase "comprising a … …" does not exclude the presence of another identical element in a process, method, article, or terminal apparatus that comprises the element.
The method and apparatus for controlling adjustment, the electronic device, and the storage medium provided above are introduced in detail, and a specific example is applied in this document to explain the principle and the implementation of the present invention, and the description of the above embodiment is only used to help understand the method and the core idea of the present invention; meanwhile, for a person skilled in the art, according to the idea of the present invention, there may be variations in the specific embodiments and the application scope, and in summary, the content of the present specification should not be construed as a limitation to the present invention.

Claims (8)

1. A method for adjusting a control is characterized in that a terminal provides a graphical user interface, the graphical user interface is a live broadcast interface for live broadcast application, the graphical user interface is provided with a first control, the first control can correspond to a reference display area and is displayed in the live broadcast interface through the reference display area, and the method comprises the following steps:
responding to a display trigger event aiming at a second control, and determining the identifier of the second control and the current attribute information of the second control when the change condition of the second control exists in a reference display area of the first control; the second control is a control with position conflict with the first control;
determining position control information aiming at the first control according to the identification of the second control and the current attribute information of the second control;
adjusting the display position of the first control on the graphical user interface according to the position control information;
wherein the determining the position control information for the first control according to the identifier of the second control and the current attribute information of the second control comprises:
acquiring a preset mapping table; the preset mapping table stores the corresponding relation among the identification of the control, the attribute information of the control and the sub-position control information;
determining one or more pieces of sub-position control information from the preset mapping table according to the identifier of the second control and the current attribute information of the second control;
determining position control information for the first control from the one or more sub-position control information.
2. The method of claim 1, wherein the first control corresponds to a reference display area, and the display trigger event comprises any one or more of:
the control module is used for triggering the visibility change of the second control in the reference display area, triggering the size change of the second control in the reference display area, and triggering the position change of the second control in the reference display area.
3. The method of claim 1, wherein prior to said adjusting the display position of the first control on the graphical user interface in accordance with the position control information, further comprising:
determining that the first control is in an active state.
4. The method of claim 1, wherein said adjusting a display position of the first control on the graphical user interface according to the position control information comprises:
determining current position information of the first control;
and adjusting the display position of the first control on the graphical user interface according to the current position information and the position control information.
5. The method of claim 1, wherein the current attribute information comprises any one or more of:
visibility information of the second control, size information of the second control, and position information of the second control.
6. The utility model provides a device of control adjustment, its characterized in that provides graphical user interface through the terminal, graphical user interface is the live broadcast interface to live broadcast class application, graphical user interface has first control, first control can correspond a benchmark display area, and passes through benchmark display area shows in live broadcast interface, the device includes:
the display trigger event response module is used for responding to a display trigger event aiming at a second control, and determining the identifier of the second control and the current attribute information of the second control when the change condition of the second control exists in the reference display area of the first control; the second control is a control with position conflict with the first control;
the position control information determining module is used for determining the position control information aiming at the first control according to the identification of the second control and the current attribute information of the second control;
the display position adjusting module is used for adjusting the display position of the first control on the graphical user interface according to the position control information;
wherein the position control information determination module includes:
a mapping table obtaining sub-module for obtaining the mapping table, the mapping table is used for acquiring a preset mapping table; the preset mapping table stores the corresponding relation among the identification of the control, the attribute information of the control and the sub-position control information;
the sub-position control information determining sub-module is used for determining one or more sub-position control information from the preset mapping table according to the identifier of the second control and the current attribute information of the second control;
and the position control information determining submodule is used for determining the position control information aiming at the first control according to the one or more pieces of sub-position control information.
7. An electronic device comprising a processor, a memory, and a computer program stored on the memory and executable on the processor, the computer program when executed by the processor implementing the method of control adjustment of any of claims 1 to 5.
8. A computer-readable storage medium, on which a computer program is stored which, when executed by a processor, implements a method of control adjustment as claimed in any of claims 1 to 5.
CN202011350221.3A 2020-11-26 2020-11-26 Control adjusting method and device, electronic equipment and storage medium Active CN112533013B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011350221.3A CN112533013B (en) 2020-11-26 2020-11-26 Control adjusting method and device, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011350221.3A CN112533013B (en) 2020-11-26 2020-11-26 Control adjusting method and device, electronic equipment and storage medium

Publications (2)

Publication Number Publication Date
CN112533013A CN112533013A (en) 2021-03-19
CN112533013B true CN112533013B (en) 2023-04-07

Family

ID=74993802

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011350221.3A Active CN112533013B (en) 2020-11-26 2020-11-26 Control adjusting method and device, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN112533013B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113552992A (en) * 2021-08-03 2021-10-26 网易(杭州)网络有限公司 Control display control method, device, equipment and medium

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR100791286B1 (en) * 2005-11-16 2008-01-04 삼성전자주식회사 Method and apparatus for providing user interface
CN106708477A (en) * 2015-07-20 2017-05-24 鸿合科技有限公司 Inductive control moving method and apparatus
CN109144385A (en) * 2018-07-27 2019-01-04 北京小米移动软件有限公司 The moving method and device of suspension ball
CN111182345B (en) * 2019-12-20 2022-10-25 海信视像科技股份有限公司 Display method and display equipment of control

Also Published As

Publication number Publication date
CN112533013A (en) 2021-03-19

Similar Documents

Publication Publication Date Title
US20220248077A1 (en) Video projection method, apparatus and device, and storage medium
US20160277242A1 (en) Conducting online meetings using user behavior models based on predictive analytics
CN106354571B (en) Message reminding method and device
CN103577658A (en) Method and system for evaluating intelligent terminal hardware
WO2017067218A1 (en) Method, device, server, and system for synchronizing member benefits among multiple devices
CN112533013B (en) Control adjusting method and device, electronic equipment and storage medium
CN108495169A (en) Information displaying method and device
CN105635254A (en) Method and device for downloading multimedia resource
CN111221612A (en) Method, device and medium for positioning user interface element
EP3142357A1 (en) Operation instruction method and device for remote controller of smart television
CN106528247B (en) Data refreshing method and device
CN116701356A (en) Data migration method, device, terminal equipment and storage medium
CN103957514A (en) Method and device for prompting user
CN107038051B (en) BIOS configuration item recommendation method and device
CN116132630A (en) Video processing method, device, equipment and storage medium
CN108536506A (en) A kind of application state management method and device
CN114117178A (en) Information processing method and device and electronic equipment
CN115237490A (en) Task batch modification method and device, electronic equipment and storage medium
CN112153478B (en) Video processing method and video playing method
CN113971191A (en) Data import method and device and computer readable storage medium
CN115904572B (en) Template creation method, calling method, program product, system and device
CN113805910B (en) Method and system for sharing data in application
CN114265323B (en) Prompt processing method, device, equipment and medium for household appliance
CN115357519B (en) Test method, device, equipment and medium
CN114827690B (en) Network resource display method, device and system

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