CN117519875A - Popup window processing method, popup window processing device, popup window processing equipment and popup window processing medium - Google Patents

Popup window processing method, popup window processing device, popup window processing equipment and popup window processing medium Download PDF

Info

Publication number
CN117519875A
CN117519875A CN202311517198.6A CN202311517198A CN117519875A CN 117519875 A CN117519875 A CN 117519875A CN 202311517198 A CN202311517198 A CN 202311517198A CN 117519875 A CN117519875 A CN 117519875A
Authority
CN
China
Prior art keywords
label
popup window
screen
movable object
popup
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
CN202311517198.6A
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.)
Beijing IQIYI Science and Technology Co Ltd
Original Assignee
Beijing IQIYI Science and 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 Beijing IQIYI Science and Technology Co Ltd filed Critical Beijing IQIYI Science and Technology Co Ltd
Priority to CN202311517198.6A priority Critical patent/CN117519875A/en
Publication of CN117519875A publication Critical patent/CN117519875A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/451Execution arrangements for user interfaces
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0481Interaction techniques based on graphical user interfaces [GUI] based on specific properties of the displayed interaction object or a metaphor-based environment, e.g. interaction with desktop elements like windows or icons, or assisted by a cursor's changing behaviour or appearance
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0484Interaction techniques based on graphical user interfaces [GUI] for the control of specific functions or operations, e.g. selecting or manipulating an object, an image or a displayed text element, setting a parameter value or selecting a range
    • G06F3/04847Interaction techniques to control parameter settings, e.g. interaction with sliders or dials
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/54Interprogram communication
    • G06F9/546Message passing systems or structures, e.g. queues
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

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

Abstract

The application relates to a popup window processing method, device, equipment and medium, wherein the method comprises the following steps: acquiring a current label of a target interface; when a returnable message of the movable object is detected, judging whether the movable object accords with a preset half-screen movable popup window condition; if the movable object accords with the half-screen movable popup window condition, sending a synchronous message corresponding to the movable object under the condition that the current tag is the same as the expected tag, and comparing the current tag with the expected tag in a popup window display callback of the synchronous message; if the label comparison result is the label non-same result, closing the movable object, and putting the movable object into the rebound window queue again; if the label comparison result is the same label result, the multi-label control in the target interface is set to be in a closed state, and the multi-label control is set to be in an open state when the popup window of the movable object is drawn on the screen, so that the problem that the semi-screen movable popup window is popup in disorder under the condition of a multi-Tab popup window queue is solved.

Description

Popup window processing method, popup window processing device, popup window processing equipment and popup window processing medium
Technical Field
The present disclosure relates to the field of application technologies, and in particular, to a method, an apparatus, a device, and a medium for processing a popup window.
Background
With the popularity of smart terminals, people increasingly rely on applications (apps) in smart terminals, such as mobile phones, for communication, social entertainment, and other activities.
Often, the top page of the App has a plurality of tags (tabs), and one Activity object (Activity) component carries different fragments (fragments) to implement Tab switching. At this time, there is a problem that the product expects to pop up the half-screen Activity type popup window on the fixed label, but the display of the half-screen Activity popup window on the expected label cannot be controlled when the label is switched rapidly.
Specifically, in the existing scheme, at the moment of pulling up the half-screen Activity, whether the label at present is consistent with the label expected by the half-screen Activity popup window is judged; if the existing label is consistent with the expected label of the half-screen Activity popup window, triggering the half-screen Activity popup window to pop up; if the existing label is inconsistent with the label expected by the half-screen Activity popup window, waiting to be awakened in the popup window queue. The scheme is invalid in the scene of rapidly switching Tabs, so that the half-screen Activity popup window is displayed on other Tabs which are not expected when the Tabs are rapidly switched, and the problem of disordered popup of the half-screen Activity popup window exists.
Disclosure of Invention
In view of this, the application provides a popup window processing method, device, equipment and medium, so as to solve the problem of popup of a semi-screen Activity popup window.
In a first aspect, the present application provides a popup window processing method, including:
acquiring a current label of a target interface;
when a returnable message of an active object is detected, judging whether the active object accords with a preset half-screen active popup window condition or not;
if the movable object accords with the half-screen movable popup window condition, sending a synchronous message corresponding to the movable object under the condition that the current label is the same as an expected label corresponding to the movable object;
comparing the current tag with the expected tag in a popup callback of the synchronous message to obtain a tag comparison result;
if the label comparison result is a label non-same result, closing the movable object, and putting the movable object into a rebound window queue again;
if the label comparison result is the same label result, setting the multi-label control in the target interface to be in a closed state, and setting the multi-label control to be in an open state when the popup window of the movable object is drawn on the screen.
Optionally, when detecting the returnable message of the active object, determining whether the active object meets a preset half-screen active popup window condition includes:
judging whether the class information of the movable object is half-screen movable object type information or not under the condition that the re-returning message is executed for the first time;
and if the class information is the type information of the half-screen movable object, determining that the movable object accords with the half-screen movable popup window condition.
Optionally, when detecting the returnable message of the active object, determining whether the active object meets a preset half-screen active popup window condition includes:
judging whether the class information of the active object is half-screen active object type information or not in the return callback of the active object;
and if the class information is the type information of the half-screen active object and the return message is the first execution return message, determining that the active object accords with the half-screen active popup window condition.
Optionally, the popup window processing method further includes:
calling an ending method of the movable object under the condition that the movable object accords with the half-screen movable popup window condition and the current label is different from the expected label;
And closing the movable object through the ending method.
Optionally, the sending the synchronization message corresponding to the active object when the current tag is the same as the expected tag corresponding to the active object includes:
calling a page display method under the condition that the current label is the same as the expected label;
and sending the synchronous message through the page display method.
Optionally, in the pop-window display callback of the synchronization message, comparing the current tag with the expected tag to obtain a tag comparison result, including:
judging whether the current tag is the same as the expected tag or not in the popup callback;
if the current label is the same as the expected label, generating the label same result;
and if the current label is different from the expected label, generating a label different result.
Optionally, setting a flag bit in a click event in response to the multi-label, where the flag bit includes an enabled state and a disabled state, and setting the multi-label control in the target interface to be in a closed state includes: setting the flag bit to the enabled state; the setting the multi-label control to an open state includes: the flag bit is set to the disabled state.
Optionally, the popup window processing method further includes: adding a frame callback operation in a preset dancer class; judging whether the number of frame callback times reaches a preset number of times or not; and if the frame callback times reach the preset times, indicating that the popup window of the movable object is drawn on a screen.
In a second aspect, the present application provides a popup window treatment apparatus comprising:
the current tag acquisition module is used for acquiring the current tag of the target interface;
the semi-screen movable popup judging module is used for judging whether the movable object accords with the preset semi-screen movable popup condition when the returnable message of the movable object is detected;
the synchronous message sending module is used for sending synchronous messages corresponding to the movable object when the movable object accords with the half-screen movable popup window condition and the current label is the same as the expected label corresponding to the movable object;
the callback display tag comparison module is used for comparing the current tag with the expected tag in the popup display callback of the synchronous message to obtain a tag comparison result;
the active object replay module is used for closing the active object and putting the active object into a rebound window queue again when the label comparison result is a label non-same result;
And the popup window display module is used for setting the multi-label control in the target interface to be in a closed state when the label comparison result is the same label result, and setting the multi-label control to be in an open state when the popup window of the movable object is drawn on the screen.
In a third aspect, the present application provides an electronic device, including: at least one communication interface; at least one bus connected to the at least one communication interface; at least one processor coupled to the at least one bus; at least one memory coupled to the at least one bus, wherein the processor is configured to: acquiring a current label of a target interface; when a returnable message of an active object is detected, judging whether the active object accords with a preset half-screen active popup window condition or not; if the movable object accords with the half-screen movable popup window condition, sending a synchronous message corresponding to the movable object under the condition that the current label is the same as an expected label corresponding to the movable object; comparing the current tag with the expected tag in a popup callback of the synchronous message to obtain a tag comparison result; if the label comparison result is a label non-same result, closing the movable object, and putting the movable object into a rebound window queue again; if the label comparison result is the same label result, setting the multi-label control in the target interface to be in a closed state, and setting the multi-label control to be in an open state when the popup window of the movable object is drawn on the screen.
In a fourth aspect, the present application further provides a computer storage medium storing a computer program which, when executed by a processor, implements the steps of a popup processing method according to any one of the above-mentioned aspects of the present application.
According to the technical scheme, the current label of the target interface is obtained, when the re-returning message of the movable object is detected, whether the movable object meets the preset half-screen movable popup window condition is judged, so that when the movable object meets the half-screen movable popup window condition and the current label is the same as the expected label corresponding to the movable object, the synchronous message corresponding to the movable object is sent, then the current label and the expected label are compared in the popup window showing callback notified by the synchronous message, the movable object is closed when the label comparison result is the label non-same result, the movable object is re-placed in the popup window queue, the popup window of the movable object is displayed at the next opportunity, the fact that the half-screen movable object popup window can be correctly displayed on the expected label is ensured, and when the label comparison result is the label same result, the multi-label control in the target interface is set to be in a closed state, so that a user can be blocked from clicking the multi-label control in time, and when the popup window of the movable object is drawn on the screen, the multi-label control is set to be in an open state, and the problem that when the popup window of the movable object is not yet completed, the user switches the multi-label popup window is displayed on the half-screen window, and the multi-label popup window is not messy, and the problem of the user is caused when the user switches the popup window is in the window is at the half-screen popup window is displayed.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the invention and together with the description, serve to explain the principles of the invention.
In order to more clearly illustrate the embodiments of the invention or the technical solutions of the prior art, the drawings which are used in the description of the embodiments or the prior art will be briefly described, and it will be obvious to a person skilled in the art that other drawings can be obtained from these drawings without inventive effort.
FIG. 1 is a diagram illustrating the execution of a message queue in the prior art;
FIG. 2 is a schematic diagram of a client communicating with an AMS through a binder in the related art;
fig. 3 is a schematic step flow diagram of a popup window processing method according to an embodiment of the present application;
fig. 4 is a schematic step flow diagram of a popup window processing method according to an alternative embodiment of the present application;
FIG. 5 is a schematic flow chart of a method for processing a popup window according to another alternative embodiment of the present disclosure;
FIG. 6 is an interactive schematic diagram of the system in the pop-up window processing method according to an example of the present application;
fig. 7 is a block diagram of a pop-up window processing device according to an embodiment of the present application;
Fig. 8 is a schematic structural diagram of an electronic device according to an embodiment of the present application.
Detailed Description
For the purposes of making the objects, technical solutions and advantages of the embodiments of the present application more clear, the technical solutions of the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is apparent that the described embodiments are some embodiments of the present application, but not all embodiments. All other embodiments, which can be made by one of ordinary skill in the art without undue burden from the present disclosure, are within the scope of the present application based on the embodiments herein.
Reference herein to "an embodiment" means that a particular feature, structure, or characteristic described in connection with the embodiment may be included in at least one embodiment of the present application. The appearances of such phrases in various places in the specification are not necessarily all referring to the same embodiment, nor are separate or alternative embodiments mutually exclusive of other embodiments. Those of skill in the art will explicitly and implicitly appreciate that the embodiments described herein may be combined with other embodiments.
First, terms of art to which the present application relates are explained.
Tab (Tab or label): tab is a common user interface element for switching different views or functions. It is typically located at the top or bottom of the screen and is presented in a horizontal arrangement. By clicking on a different Tab, the user can switch to the corresponding page or module.
Activity (Activity object): activity is a basic component in an Android application program for exposing user interfaces and responding to user interactions. An application is typically made up of a number of activities, each representing a separate user interface. The Activity may be initiated by other components, as well as other activities.
Dialog (Dialog or popup): dialogs are a floating user interface element for displaying short-term tasks, warnings, or other information that requires user confirmation. The dialog box may be displayed in a popup window over the current interface and may block other operations until the user responds. It typically contains text, buttons and other interactive elements for simple interaction with the user.
In an android system, a Message (Message) queue is arranged at the bottom layer to continuously execute messages to drive various events and execute code logic, as shown in fig. 1. For example, the half-screen Activity trigger logic is also Message driven when executed, such as Message-A in FIG. 1, to pull up the half-screen Activity during execution.
Specifically, the android internal design is a C/S structure, and a client communicates with an Activity management service (Activity Manager Service, AMS) through a binder, and transmits a life cycle related Message through an Activity thread class to manage the life cycle of an Activity, that is, pulls up the Activity through binder communication. After the Message-a is executed, as shown in fig. 2, the AMS sends three messages, namely onCreate, onStart, onresponse, through the binder communication, that is, callback Activity handling Activity onCreate, onCreate and onresponse, sends the corresponding Message to the Message queue through the Activity thread internal Message Handler (Handler) processing, finally creates a View root image object in the onresponse method, adds the View (View) to the Window (Window), and sends an immediately executed Message-C to the Message queue to notify the Window of the callback. Because when View to Window is added in the onResume method, finally, the method calls to the View RootImpl to trigger drawing of a Frame, namely, drawing of an Activity first Frame, the drawn Message is asynchronous Message-B, at this time, a synchronous barrier is added to a Message queue, only asynchronous messages are found to be executed after the Message-A is executed, and the asynchronous Message-B belongs to the type of asynchronous Message which is drawn and is executed preferentially. That is why a popup window would appear to be unexpectedly present on other Tabs. The user's click event is handled in the asynchronous Message, so the asynchronous Message-B may contain the user's Tab-cut click event, and the asynchronous Message is a Message that is self-handled inside the system, i.e. the Tab-click event in the asynchronous Message-B needs to be handled by the system, and the programmer cannot interfere with the handling. If the asynchronous Message-B contains a click event of a user to cut a Tab and does not go to processing in a subsequent Message, a problem that the half-screen Activity popup window finally displays on other tabs occurs.
Although the related art triggers the judging operation of the Tab when the scene of the Tab is switched rapidly, that is, judges whether the Tab is consistent with the Tab expected by the semi-screen Activity popup window at present when the moment of pulling up the semi-screen Activity is judged, if so, triggers popup, and if not, waits to be awakened in the popup window queue. However, the related technology is essentially the judgment performed at the moment of triggering the popup window, and because the asynchronous operation of the message queue is not completely completed at the moment of triggering the popup window, the phenomenon of random popup of the half-screen Activity popup window still occurs in the follow-up after the judgment of the moment of triggering the popup window.
In order to solve the technical problem of the disordered popup of the half-screen Activity popup, the application provides a popup processing method, which comprises the steps of acquiring a current tag of a target interface, and judging whether a movable object accords with a preset half-screen movable popup condition when a return message of the movable object is detected; if the movable object accords with the half-screen movable popup window condition, sending a synchronous message corresponding to the movable object under the condition that the current label is the same as an expected label corresponding to the movable object; in the popup window display callback of the synchronous message, comparing the current tag with the expected tag, setting a multi-tag control in the target interface to be in a closed state when the tag comparison result is the same tag result, so as to timely block a user from clicking the multi-tag control, and setting the multi-tag control to be in an open state when the popup window of the movable object is drawn on a screen, thereby avoiding the problem of popup disorder of the semi-screen movable popup window on the switched tag caused by the fact that the user clicks the multi-tag control to switch the tag when the popup window is not drawn yet; and when the label comparison result is the label non-same result, closing the movable object, and putting the movable object in a rebound window queue again to wait for the next opportunity to display the rebound window of the movable object, so as to ensure that the rebound window of the half-screen movable object can be correctly displayed on the expected label.
The popup window processing method provided in the present application is described in detail below. Fig. 3 is a schematic step flow diagram of a popup window processing method according to an embodiment of the present application. As shown in fig. 3, the method for processing a popup window according to the embodiment of the present application may specifically include the following steps:
step 310, a current label of the target interface is obtained.
The target interface may be an interface currently presented by an App, and specifically, may query a Tab where the target interface is currently located through an abstract interface, and obtain the Tab where the target interface is currently located, so as to serve as a current tag of the target interface. For example, the interface for querying the Tab where the target interface is currently located can be implemented by using the Activity object of the home page, and the Tab switching is processed in the multi-Tab control click event, so that the current label of the target interface is obtained. Specifically, the home page Activity object can be obtained through a static method in the home page Activity, and the Tab of the home page target interface can be queried through the home page Activity object to serve as the current tag of the target interface.
It should be noted that, when constructing, the Dialog type popup window needs to be imported into the Activity object, and the corresponding home page Activity object can be obtained in the Dialog, so that the label where the current interface is located can be queried through the Activity object in this embodiment.
Step 320, when detecting a returnable message of an active object, judging whether the active object accords with a preset half-screen active popup window condition;
in this embodiment, in order to solve the problem that when the Tab is quickly switched, the semi-screen Activity popup window is displayed on another Tab that is not in the expectation, when a returnal message of the active object is detected, that is, before the active object is pulled up, whether the returnal message of the active object is a returnal message executed for the first time may be determined, so that when the returnal message of the active object is the returnal message executed for the first time and the type information of the active object is the preset semi-screen active object type information, it is determined that the active object meets the preset semi-screen Activity popup window condition, and then step 330 may be skipped to execute; and in the case that the retuned message of the active object is not the retuned message of the first execution and/or the type information of the active object is not the preset half-screen active object type information, it may be determined that the active object does not meet the preset half-screen active popup condition.
Step 330, if the active object meets the half-screen active popup window condition, sending a synchronization message corresponding to the active object if the current tag is the same as an expected tag corresponding to the active object;
Specifically, before the active object is pulled up, in this embodiment, if it is determined that the active object meets a preset half-screen active popup condition, whether the current tag is the same as the expected tag corresponding to the active object may be determined, so that a synchronization message corresponding to the active object may be sent when the current tag is the same as the expected tag corresponding to the active object, so that a series of logic may be processed in the synchronization message to notify the popup to display a callback. It should be noted that, the popup callback may refer to a popup callback of the popup, such as an onshaw callback of dialogs.
Step 340, comparing the current tag with the expected tag in a popup callback of the synchronous message to obtain a tag comparison result;
specifically, the android bottom layer can execute asynchronous messages preferentially under the condition of having a synchronous barrier, and after the asynchronous messages are executed, synchronous dialogs are executed in the messages of the Onshaw callback. Therefore, in the popup window display callback of the synchronous message, the current tag is compared with the expected tag, so that the tag is judged again in the timing of the popup window display callback, the asynchronous operation is ensured to be completed, the phenomenon that popup windows are disordered due to the fact that Tab-cutting clicking events in the asynchronous message cannot be timely processed by the system is avoided, the display of the half-screen movable object type popup window on a proper page and under a proper condition is ensured, and the user experience is improved.
Step 350, if the label comparison result is a label non-identical result, closing the movable object, and putting the movable object in a rebound window queue again;
the method for closing the active object may be a method or a function for closing the active object, and the active object may be put back into a pop-up window queue again to wait for the next time to be displayed, i.e. the pop-up window required to be displayed by the active object waits for the next time to be displayed in the original pop-up window queue, if the current tag is inconsistent with the expected tag, i.e. if the tag comparison result is different from the tag result, the Finish method of Activity may be invoked to close the active object, and the pop-up window required to be displayed by the active object may be recovered into the pop-up window queue, so as to ensure that the pop-up window may be displayed again when the active object is switched to the corresponding tag next time.
And step 360, if the label comparison result is the same label result, setting the multi-label control in the target interface to be in a closed state, and setting the multi-label control to be in an open state when the popup window of the movable object is drawn on the screen.
Specifically, when the current label is the same as the expected label, considering that the multi-label control in the target interface needs to be set to be in a closed state when the popup window is not drawn yet, the embodiment sets the multi-label control in the target interface to be in the closed state when the comparison result of the label is the same as the label in the popup window callback, so that a user is blocked from clicking the multi-label control in time, and sets the multi-label control to be in an open state when the popup window of the active object is drawn on the screen, thereby avoiding label switching caused by clicking the multi-label control when the popup window is not drawn yet, and ensuring that the popup window of the half-screen active object can be correctly displayed on the expected label.
In summary, the embodiment of the application judges whether the movable object accords with the preset half-screen movable popup window condition or not by acquiring the current label of the target interface and when the returnable message of the movable object is detected, so as to judge whether the current label is the same as the expected label corresponding to the movable object or not under the condition that the movable object accords with the half-screen movable popup window condition; if the current label is different from the expected label corresponding to the active object, the active object can be closed, for example, a Finish method of the active object can be called to close the active object; under the condition that the movable object accords with the half-screen movable popup window condition and the current label is the same as the expected label corresponding to the movable object, a synchronous message corresponding to the movable object is sent, so that the current label and the expected label are compared in a popup window display callback of the synchronous message, the popup window is ensured to appear on the correct label, judgment at the moment of triggering the popup window to display can be avoided, and the problem of popup window mess caused by label cutting and clicking events of a user occurs again in the asynchronous message executing process due to the fact that the asynchronous message execution is not ensured to be completed.
In some optional embodiments, the popup window processing method provided in this embodiment may further include: calling an ending method of the movable object under the condition that the movable object accords with the half-screen movable popup window condition and the current label is different from the expected label; and closing the movable object through an ending method of the movable object. The method for ending the active object may be used to close the active object, for example, a Finish method of Activity, which is not particularly limited in this embodiment.
Referring to fig. 4, a flowchart of steps of a method for processing a popup window according to an alternative embodiment of the present application is shown. In an embodiment of the present application, the popup window processing method may include the following steps:
step 410, obtaining a current label of a target interface;
step 420, when a returnable message of an active object is detected, judging whether the active object accords with a preset half-screen active popup window condition;
specifically, in order to solve the problem that the half-screen Activity popup window is popup under the condition of the multi-Tab popup window queue, before the active object is pulled up, whether the returnable message of the active object is the first executed returnable message or not can be judged, that is, whether the returnable message of the active object is the first executed message is judged, and the type information of the active object is the preset half-screen active object type information is judged, so that when the returnable message of the active object is the first executed returnable message and the type information of the active object is the preset half-screen active object type information, the active object is determined to conform to the preset half-screen Activity popup window condition.
In some optional embodiments of the present application, when detecting a returnable message of an active object, determining whether the active object meets a preset half-screen active popup condition may specifically include the following sub-steps:
Sub-step 4211, in the case of executing the retum message for the first time, determining whether the class information of the active object is half-screen active object type information;
sub-step 4212, if the class information is the type information of the half-screen active object, determining that the active object meets the half-screen active popup condition.
Specifically, when the returnable message of the active object is detected, the embodiment can determine whether the returnable message of the active object is the first execution on resume method, that is, determine whether the returnable message of the active object is the first execution; if the returnable message of the active object is the first execution on resume method, judging whether the class information of the active object is half-screen active object type information, namely judging whether the class information of the active object is half-screen active object type information under the condition that the returnable message is executed for the first time, so that when the returnable message of the active object is executed for the first time, the type information of the active object is half-screen active object type information, and under the condition that the requirement of an expected label exists, determining that the active object meets the preset half-screen active popup window condition, and then jumping to step 430 for execution; and under the condition that the returnable message of the movable object is not executed for the first time and/or the type information of the movable object does not belong to the type information of the half-screen movable object, determining that the movable object does not accord with the preset half-screen movable popup window condition, namely that the movable object does not have the requirement of the expected label and is not the half-screen movable object popup window. For example, for the Activity inside the system, it may be determined whether the on response method is executed for the first time by rewriting the on response method in the on response method of the parent class BaseActivity, and whether the Activity is of the half-screen Activity type and has a requirement of the intended Tab, if so, it may be determined that the Activity meets the preset half-screen active popup condition, and then step 430 is skipped to execute to determine whether the intended Tab and the Tab where the target interface is located are consistent.
Considering that only the onResume method can be rewritten for the Activity inside the system, but the onResume method of the third party application cannot be rewritten for the Activity introduced by the third party application, the embodiment can add a callback by using the registration Activity lifecycle callback of the application object, so as to judge whether the name of the Activity is a preset half-screen Activity name in the callback returned by the Activity object, and judge whether the name is the first onResume in the callback, so that step 430 can be executed after the above condition is satisfied.
In other optional embodiments of the present application, when detecting a returnable message of an active object, determining whether the active object meets a preset half-screen active popup condition may specifically include: judging whether the class information of the active object is half-screen active object type information or not in the return callback of the active object; and if the class information is the type information of the half-screen active object and the return message is the first execution return message, determining that the active object accords with the half-screen active popup window condition. The re-returning callback of the active object may be used to determine whether class information of the active object is type information of the half-screen active object and determine that the re-returning message is a first execution re-returning message, for example, the re-returning callback of the active object may be an Activity-based oneactyresumed callback; the class information of the active object may be used to determine the type of the active object, for example, the class information of the active object may be a class name (className) of an Activity, and the className is used as a name of the Activity and may be used to determine the type of the Activity.
As an example of the Application, before the Activity is pulled up, a region Activity Life technologies method of the Application object may be called, and an onActivity resource callback of the newly created Activity is monitored to determine whether the onActivity resource callback is a first-time OnResume in the newly created onActivity resource callback of the Activity, and whether the class name of the Activity is consistent with the expected half-screen Activity name, so that when the onActivity resource callback is the first-time OnResume and the class name of the Activity is consistent with the expected half-screen Activity name, it may be determined that the Activity accords with the preset half-screen Activity popup window condition. It should be noted that, when a callback added by the register Activity Life technologies method of the Application object has all the callbacks of the life cycle of the newly created Activity, the present example determines whether the name of the Activity is the preset half-screen Activity in the register Activity callback, and determines whether the name is the first time of the Activity, so that when the register Activity callback is the first time of the Activity and the className of the Activity is consistent with the expected half-screen Activity name, it is determined that the Activity meets the preset half-screen Activity window condition, and then step 430 is executed to determine whether the existing Tab is consistent with the expected Tab.
Step 430, if the active object meets the half-screen active popup window condition, judging whether the current tag is the same as the expected tag corresponding to the active object;
step 440, calling an ending method of the active object and closing the active object when the current label is different from the expected label;
in this embodiment, after determining that the moving object meets the condition of the half-screen moving popup window, it may be determined whether the current tag is the same as the expected tag corresponding to the moving object, so as to determine whether the existing Tab is consistent with the expected Tab; if the existing Tab is inconsistent with the expected Tab, namely, if the mobile object is judged to be in accordance with the half-screen mobile popup window condition and the current label is different from the expected label, calling an ending method of the mobile object to close the mobile object through the called ending method, for example, calling a Finish method of the Activity when the existing Tab is inconsistent with the expected Tab, and closing the Activity; if the existing Tab is inconsistent with the expected Tab, i.e. if it is determined that the moving object meets the half-screen moving popup condition and the current tag is the same as the expected tag, the process goes to step 450 for execution.
Step 450, sending a synchronization message corresponding to the active object when the current tag is the same as the expected tag corresponding to the active object;
specifically, in this embodiment, when it is determined that the active object meets the condition of the semi-screen active popup window, and the current tag is the same as the expected tag corresponding to the active object, a synchronization message corresponding to the active object is sent, so that a series of logic is processed in the synchronization message, and a popup window is notified to display a callback. For example, for the internal Activity, before the Activity is pulled up, it is determined that the Activity meets the preset half-screen active window condition, and if the existing Tab is consistent with the expected Tab, a Message of the immediately executed handler may be sent as a synchronization Message corresponding to the Activity, such as Message-C in the Message queue shown in fig. 1, so as to later display a callback in the Message-C to determine whether the existing Tab is consistent with the expected Tab, that is, execute step 460.
In some optional embodiments of the present application, in a case where the current tag is the same as the expected tag corresponding to the active object, sending the synchronization message corresponding to the active object may specifically include: calling a page display method under the condition that the current label is the same as the expected label; and sending the synchronous message through the page display method. For example, before the Activity is pulled up, in combination with the above example, if it is determined that the Activity meets the condition of the semi-screen active popup window through the onactyResumed callback of the newly created Activity, when it is determined that the existing Tab is consistent with the expected Tab, a custom onShowHandler may be called as a page display method to send a message as a synchronization message corresponding to the active object through the page display method, and a series of logic is processed in the synchronization message to notify the popup window of the callback, and in the popup window of the popup window notified by the synchronization message, it is determined whether the existing Tab is consistent with the expected Tab, that is, step 460 is performed.
Step 460, in the pop-up window showing callback of the synchronization message, comparing the current tag with the expected tag to obtain a tag comparison result;
further, in the pop-up window display callback of the synchronization message, the embodiment compares the current tag with the expected tag to obtain a tag comparison result, which may specifically include: judging whether the current tag is the same as the expected tag or not in the popup callback; if the current label is the same as the expected label, generating the label same result; and if the current label is different from the expected label, generating a label different result.
And 470, if the label comparison result is a label non-same result, closing the movable object, and putting the movable object in a rebound window queue again to wait for the next opportunity to display the rebound window of the movable object.
And 480, setting the multi-label control in the target interface to be in a closed state if the label comparison result is the same label result, and setting the multi-label control to be in an open state when the popup window of the movable object is drawn on the screen.
In this embodiment, when the label comparison result is the label non-same result, the movable object may be closed, and the movable object may be put back into the pop-up window queue again, so as to wait for the pop-up window of the movable object to be displayed again at the next opportunity, so as to ensure that the pop-up window of the half-screen movable object can be correctly displayed on the expected label, and when the label comparison result is the label same result, the multi-label control in the target interface is set to be in a closed state, so that the user can be blocked from clicking the multi-label control in time, the user is prevented from switching the label, and the multi-label control is set to be in an open state when the pop-up window of the movable object is drawn on the screen, so that the problem that the half-screen movable pop-up window appears on the switched label due to the fact that the user clicks the multi-label control to switch the pop-up window is not yet drawn is avoided, and the problem of the half-screen movable pop-up window is solved.
In particular implementations, the visibility or disabled state of the multi-label control may be set to prevent the user from switching labels. Therefore, in order to conveniently and timely block the clicking of the multi-label, the embodiment can intercept in the clicking event of the response label, for example, a flag bit can be set in the clicking event of the response label, the flag bit comprises an enabling state and a disabling state, the flag bit is set to be in the enabling state true when the blocking is needed, namely, the enabling state, and the flag bit is set to be in the false disabling state when the blocking is not needed, so that the clicking control of the multi-label can be realized. In some optional embodiments of the present application, setting the multi-label control in the target interface to the closed state may specifically include: setting the marking bit to be in the starting state, and blocking clicking events of the multi-label in time; setting the multi-label control to an open state includes: and setting a mark bit set in a click event responding to the multi-label to be in a disabled state so as to realize click control on the multi-label.
In addition, the popup window of the half-screen active object type usually contains some important information or operation options, if the popup window is not drawn yet, the popup window can only display a part of the popup window content or the user cannot see the whole popup window content, so that when the popup window of the active object is drawn on the screen, the embodiment sets the flag bit set in the click event responding to the multiple labels to be in a disabled state, so as to wait for the popup window to be switched after being drawn, thereby ensuring that the popup window content is displayed completely to the user, providing better interaction experience, and avoiding interface flickering or inconformity, so that interface transition is smoother.
Considering the drawing mechanism of the android bottom layer, a certain frame number of data, such as three frames of data, is generally required to be cached, so that the half-screen Activity popup window can be truly displayed on a screen, therefore, the embodiment can set the multi-label control to be in an open state after the number of frame callback reaches the preset number of times by adding the operation of frame callback in the preset editor class, namely, the multi-label clicking is released after the number of frame callback reaches the preset number of times, so that the half-screen movable object popup window can be ensured to appear on the correct label. The android dancer class may include an application programming interface (Application Programming Interface, API) that may be used to add frame callback operations.
Optionally, the popup window processing method provided in this embodiment may further include: adding a frame callback operation in a preset dancer class; judging whether the number of frame callback times reaches a preset number of times or not; and if the frame callback times reach the preset times, indicating that the popup window of the movable object is drawn on a screen.
Referring to fig. 5, a flow chart of a popup window processing method according to another alternative embodiment of the present application is shown. As shown in fig. 5, the method for processing a popup window according to the embodiment of the present application may specifically include the following steps:
step 510, obtaining a current label of a target interface;
step 520, before the moving object is pulled up, judging whether the moving object accords with a preset half-screen moving popup window condition;
step 530, judging whether the current label is the same as the expected label corresponding to the movable object under the condition that the movable object accords with a half-screen movable popup window condition;
step 540, calling an ending method of the active object and closing the active object when the current label is different from the expected label;
step 550, calling a page display method and sending a synchronous message corresponding to the active object under the condition that the current label is the same as the expected label;
Step 560, comparing the current tag with the expected tag in a pop-up window showing callback of the synchronous message to obtain a tag comparison result;
step 570, if the label comparison result is a label non-identical result, closing the movable object, and putting the movable object back into a rebound window queue again, waiting for the next time display;
step 580, if the label comparison result is the same label result, setting the multi-label control in the target interface to be in a closed state, and adding a frame callback operation in a preset dancer class;
step 590, judging whether the number of frame callback times reaches a preset number of times;
and 600, if the number of frame callback times reaches the preset number of times, indicating that the popup window of the movable object is drawn on a screen, and setting the multi-label control to be in an open state.
Specifically, in the interface controller, a frame callback monitor can be set for the active object popup corresponding to the current tag, for example, in this embodiment, a class object can be set in the target popup class, and inherits the display monitor of the target popup class, and defines an onshowy callback method at the interface of the display callback, so that whether the number of frame callbacks reaches the preset number can be judged in the onshowy callback method; if the number of frame callback times reaches the preset number of times, indicating that the popup window corresponding to the current tag is drawn on the screen; if the number of frame callback times does not reach the preset number of times, the popup window corresponding to the current label is indicated to be not completely drawn on the screen.
It should be noted that, considering that not all dialogs set the showcase callback, in some embodiments of the present application, an interface for showcase callback is set in the target popup class, so that an onShow callback method is defined in the interface for showcase callback. Specifically, the class object class is set when the Dialog object is initialized, namely, a display callback interface is set in the target popup class, and the display callback interface is defined with an onShow method, so that each Dialog object is notified when executing the onShow callback, and therefore, the onShow method is triggered when popup display is performed, and therefore, whether the expected Tab is the same as the Tab currently located in the method can be judged in the method; if the expected Tab is different from the currently located Tab, a popup window vanishing method defined in the interface can be called, and the popup window of the currently active object is closed and put back into the popup window queue.
Specifically, in this embodiment, a target popup window class may be created in the popup window queue, and the target popup window class inherits popup windows in the popup window queue, and an interface name and a popup window display method showWindow and a popup window disappearance method dissswindow defined in the interface may be added in the target popup window class, so that when a current tag is different from an expected tag in a popup window display callback, the popup window disappearance method showWindow in the target popup window class is invoked, and a popup window of a half-screen active object type required to be displayed by a current active object is replaced in the popup window queue. The target window class may be a custom dialog class, and when creating the custom dialog class in the window queue, an interface custom dialog interface is created to define a window display method, a window method, and a window vanishing method, a dismiswindow method, for example. The expected Tab value is set through the setexpect Tab method, and the showWindow method is called at an appropriate time to display the popup window.
Therefore, in this embodiment, an onshowcallback interface inside a Dialog is implemented by creating a class, that is, a class object is set in the Dialog, which inherits a listener onshowlist of the Dialog itself, so that each time the Dialog callback onshows can callback to the newly created class object in the Dialog, so that all dialogs can compare an expected Tab with a truly displayed Tab acquired from an Activity object in the onshowmethod, thereby ensuring that a half-screen active object type popup appears on a correct tag, and solving the problem of popup of the half-screen active type popup under the condition of a multi-Tab popup queue.
The preset number of times may be 1 to 3 times, which is not particularly limited in this embodiment. Specifically, when the UI is drawn, the buffer mode of the android bottom layer includes a double buffer mechanism and a triple buffer mechanism. When the buffer mode of the android bottom layer is a dual buffer mechanism, the android bottom layer has two levels of buffer to store two frames of data, and the asynchronous Message such as Message-B in fig. 1 will put the frame of data with the dialogs into the buffer after the execution is completed, so that the Tab clicking event of one frame needs to be blocked again later, that is, when the buffer mode of the android bottom layer is the dual buffer mechanism, the preset times of 1 needs to be met, the clicking of multiple tabs is released again, and the dialogs can appear on the correct Tab. When the buffer mode of the android bottom layer is a triple buffer mechanism, since the android bottom layer has three-level buffer to store data of three frames, and a certain time is required for completing the Dialog drawing, the response time of the Tab clicking event is relatively fast, and therefore, in the triple buffer mechanism, the preset times can be 2 times or 3 times. Specifically, after the asynchronous Message such as Message-B in fig. 1 is executed, the frame data with the Dialog is put into the buffer, and then the Tab clicking event of two frames needs to be blocked again, that is, when the number of frame callback times reaches 2, the clicking of more tabs is released again, so that the situation that the half-screen active object type Dialog appears on the correct Tab can be ensured.
In addition, in the triple buffer mechanism, a certain time is required for completing the dialoging, and the response time of the Tab-cutting clicking event is relatively fast, so that the Tab-cutting clicking event can be released again when the next popup window draws the first frame, that is, the Tab-cutting clicking event of three frames is blocked after the asynchronous Message is executed as Message-B in fig. 1, that is, when the number of frame callback times reaches 3, the Tab-cutting clicking event is released, which is not limited in this embodiment.
The following exemplary description of the embodiments of the present application is provided, but it should be noted that the embodiments of the present application may have the features described below, and the following description should not be construed as limiting the scope of the embodiments of the present application.
As an example of the application, the home Activity may be used to switch Tab in a multi-Tab control click event, trigger a pop-up queue, as shown in fig. 6, and may perform a half-screen Activity display at the top of the pop-up queue. Specifically, before the Activity is pulled up, an Application object registration Activity lifecycle callback and Activity lifecycle method can be used, an Activity lifecycle callback and Activity lifecycle cyclecallback method can be added to judge whether the name of the Activity is a preset half-screen Activity name in the Activity callback and whether the name is a first time of the Activity in the Activity callback, namely whether the Activity is a first time of the callback in the Activity callback of the Activity object, so that an onShow message can be sent in the Activity callback and a series of logic can be processed in the Handler when the name of the Activity is consistent with the expected one, namely, a custom onShow is called as a page display method when the name of the Activity is consistent with the condition of the half-screen Activity popup window and the current label is consistent with the expected one. Specifically, a new Dialog of a Dialog inheritance system can be created in the pop-up queue, and a pop-up display method, a pop-up vanishing method and a pop-up vanishing method can be realized through interfaces; a class can be built in the newly created Dialog class to realize the onShow callback interface inside the Dialog, and inherit the onShow Listener of the Dialog itself, namely the customized Dialog onShow Listener, so that every pop-up callback presentation can callback to the newly built class object.
After receiving the popup display callback, inquiring the currently displayed Tab by the Activity of the first page so that the user-defined dialogonshawListener obtains the currently displayed Tab as the current tag of the target interface, and comparing and judging the currently displayed Tab with the expected Tab in the popup display callback; if the displayed Tab is consistent with the expected Tab, the Activity object of the home page is called to block the multi-Tab control clicking event, a doFrame callback of an android editor is added, namely the displayed Tab is consistent with the expected Tab, the doFrame callback is added to add the operation of the frame callback in a preset editor class, whether the doFrame callback number reaches the preset number of times is judged, namely whether the frame callback number reaches the preset number of times is judged, if the doFrame callback number meets the preset number of times range, for example, if the doFrame callback number exceeds twice in fig. 6, the doFrame callback number reaches the preset number of times can be determined, the multi-Tab control clicking event is released, and the multi-Tab control is set to be in an open state; if the displayed current Tab is inconsistent with the expected Tab, a popup window vanishing method is called, the half-screen movable object type popup window is closed, and the displayed Tab is put into a popup window queue again to wait for the next time display, so that the half-screen movable object popup window can be ensured to be correctly displayed on the expected label.
It should be noted that, for simplicity of description, the method embodiments are shown as a series of acts, but it should be understood by those skilled in the art that the embodiments are not limited by the order of acts described, as some steps may occur in other orders or concurrently in accordance with the embodiments.
As shown in fig. 7, an embodiment of the present application further provides a popup window processing device, including:
a current tag obtaining module 710, configured to obtain a current tag of the target interface;
the half-screen movable popup judging module 720 is configured to judge whether the movable object meets a preset half-screen movable popup condition when detecting a returnable message of the movable object;
a synchronous message sending module 730, configured to send a synchronous message corresponding to the active object when the active object meets the condition of the half-screen active popup window and the current tag is the same as an expected tag corresponding to the active object;
the display callback tag comparison module 740 is configured to compare the current tag with the expected tag in a popup display callback of the synchronization message, so as to obtain a tag comparison result;
The popup window display module 750 is configured to set a multi-label control in the target interface to a closed state when the label comparison result is the same label result, and set the multi-label control to an open state when a popup window of the movable object is drawn on a screen;
and the active object replay module 760 is configured to close the active object and put the active object back into the rebound window queue when the tag comparison result is a tag non-identical result.
Optionally, the half-screen active popup judging module 720 includes:
the active object type information judging sub-module is used for judging whether the class information of the active object is half-screen active object type information or not under the condition that the return message is executed for the first time;
and the first determining submodule is used for determining that the movable object accords with the half-screen movable popup condition when the class information is half-screen movable object type information.
Optionally, the half-screen active popup judging module 720 includes:
the type information judging sub-module is used for judging whether the type information of the movable object is the type information of the half-screen movable object in the return callback of the movable object;
And the second determining submodule is used for determining that the movable object accords with the half-screen movable popup condition under the condition that the class information is half-screen movable object type information and the re-return message is the first execution re-return message.
Optionally, the popup window processing device further includes the following modules:
an ending method calling module, configured to call an ending method of the active object when it is determined that the active object meets the half-screen active popup condition and the current tag is different from the expected tag;
and the movable object closing module is used for closing the movable object through the ending method.
Optionally, the synchronization message sending module 730 includes:
a display method calling sub-module, configured to call a page display method when the current tag is the same as the expected tag;
and the synchronous message sending sub-module is used for sending the synchronous message through the page display method.
Optionally, the presenting callback tag comparison module 740 includes:
the tag judging sub-module is used for judging whether the current tag is the same as the expected tag or not in the popup display callback;
A label identical result sub-module, configured to generate the label identical result when the current label is identical to the expected label;
and the label non-identical result submodule is used for generating a label non-identical result when the current label is not identical with the expected label.
Optionally, setting a flag bit in a click event in response to the multi-label, where the flag bit includes an enabled state and a disabled state, and setting the multi-label control in the target interface to be in a closed state includes: setting the flag bit to the enabled state; the setting the multi-label control to an open state includes: the flag bit is set to the disabled state. The pop-up display module may include the following sub-modules:
the marking bit enabling state sub-module is used for setting the marking bit to the enabling state, for example, when the label comparison result is the same label result, the marking bit set in the clicking event of the response multi-label is set to the enabling state, and the multi-label control in the target interface is set to the closing state;
the mark bit disabled state submodule is used for setting the mark bit to the disabled state, such as setting the mark bit set in a click event responding to the multi-label to be in the disabled state when a popup window of the active object is drawn on a screen, and setting the multi-label control in the target interface to be in an open state.
Optionally, the pop-up window processing device further includes:
the frame callback operation adding module is used for adding the operation of the frame callback in the preset dancer class;
the frame callback number judging module is used for judging whether the number of frame callback times reaches a preset number of times; and when the frame callback times reach the preset times, indicating that the popup window of the movable object is drawn on a screen.
It should be noted that, the popup window processing device provided in the embodiment of the present application may execute the popup window processing method provided in any embodiment of the present application, and has the corresponding functions and beneficial effects of executing the popup window processing method.
In a specific implementation, the popup window processing device can be integrated in an electronic device, so that the electronic device is used as the popup window processing device, and after the current label of the target interface is acquired, whether the movable object accords with the preset half-screen movable popup window condition can be judged by detecting the return message of the movable object; under the condition that the movable object accords with the condition of the half-screen movable popup window and the current label is the same as the expected label corresponding to the movable object, a synchronous message corresponding to the movable object is sent, then the current label is compared with the expected label in a popup window display callback notified by the synchronous message, so that the movable object is closed when the label comparison result is the label non-same result, the movable object is put back into a popup window queue again, the popup window of the movable object is displayed again at the next opportunity, the half-screen movable object popup window can be ensured to be correctly displayed on the expected label, and when the label comparison result is the same label result, the multi-label control in the target interface is set to be in a closed state, so that a user can be timely blocked from clicking the multi-label control, the multi-label control is set to be in an open state when the popup window of the movable object is drawn on the screen, the problem that the half-screen movable popup window appears on the switched label due to the fact that the user clicks the multi-label control to switch the label when the popup window is not drawn is finished is solved.
The embodiment also provides an electronic device, which comprises at least one communication interface; at least one bus connected to the at least one communication interface; at least one processor coupled to the at least one bus; at least one memory coupled to the at least one bus, wherein the processor is configured to: determining target speech; acquiring a video clip containing the target speech; determining material text information according to the characteristic information of the target speech; generating a material video fragment by adopting the material text information; and splicing the material video segments and the video segments to generate a target video.
It should be noted that, the electronic device provided in this embodiment may be configured by two or more physical entities, or may be configured by one physical entity, for example, the electronic device may be a personal computer (Personal Computer, PC), a computer, a server, or the like, which is not particularly limited in this embodiment of the present application.
For example, as shown in fig. 8, the embodiment of the present application provides an electronic device including a processor 111, a communication interface 112, a memory 113, and a communication bus 114, where the processor 111, the communication interface 112, and the memory 113 perform communication with each other through the communication bus 114,
A memory 113 for storing a computer program;
in one embodiment of the present application, the processor 111 is configured to implement the steps of the popup window processing method provided in any one of the foregoing method embodiments when executing the program stored in the memory 113, where the steps include: acquiring a current label of a target interface; when a returnable message of an active object is detected, judging whether the active object accords with a preset half-screen active popup window condition or not; if the movable object accords with the half-screen movable popup window condition, sending a synchronous message corresponding to the movable object under the condition that the current label is the same as an expected label corresponding to the movable object; comparing the current tag with the expected tag in a popup callback of the synchronous message to obtain a tag comparison result; if the label comparison result is a label non-same result, closing the movable object, and putting the movable object into a rebound window queue again; if the label comparison result is the same label result, setting the multi-label control in the target interface to be in a closed state, and setting the multi-label control to be in an open state when the popup window of the movable object is drawn on the screen.
The present application also provides a computer readable storage medium having stored thereon a computer program which, when executed by a processor, implements the steps of the pop-up processing method provided in any one of the method embodiments described above.
The apparatus embodiments described above are merely illustrative, wherein the elements illustrated as separate elements may or may not be physically separate, and the elements shown as elements may or may not be physical elements, may be located in one place, or may be distributed over a plurality of network elements. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
From the above description of embodiments, it will be apparent to those skilled in the art that the embodiments may be implemented by means of software plus a general purpose hardware platform, or may be implemented by hardware. Based on such understanding, the foregoing technical solution may be embodied essentially or in a part contributing to the related art in the form of a software product, which may be stored in a computer readable storage medium, such as ROM/RAM, a magnetic disk, an optical disk, etc., including several instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to perform the method described in the respective embodiments or some parts of the embodiments.
It is to be understood that the terminology used herein is for the purpose of describing particular example embodiments only, and is not intended to be limiting. As used herein, the singular forms "a", "an" and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise. The terms "comprises," "comprising," "includes," "including," and "having" are inclusive and therefore specify the presence of stated features, steps, and/or operations, but do not preclude the presence or addition of one or more other features, steps, operations, and/or groups thereof. The method steps, processes, and operations described herein are not to be construed as necessarily requiring their performance in the particular order described or illustrated, unless an order of performance is explicitly stated. It should also be appreciated that additional or alternative steps may be used.
The foregoing is only a specific embodiment of the invention to enable those skilled in the art to understand or practice the invention. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the generic principles defined herein may be applied to other embodiments without departing from the spirit or scope of the invention. Thus, the present invention is not intended to be limited to the embodiments shown herein but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.

Claims (10)

1. A method of popup window treatment comprising:
acquiring a current label of a target interface;
when a returnable message of an active object is detected, judging whether the active object accords with a preset half-screen active popup window condition or not;
if the movable object accords with the half-screen movable popup window condition, sending a synchronous message corresponding to the movable object under the condition that the current label is the same as an expected label corresponding to the movable object;
comparing the current tag with the expected tag in a popup callback of the synchronous message to obtain a tag comparison result;
if the label comparison result is a label non-same result, closing the movable object, and putting the movable object into a rebound window queue again;
if the label comparison result is the same label result, setting the multi-label control in the target interface to be in a closed state, and setting the multi-label control to be in an open state when the popup window of the movable object is drawn on the screen.
2. The method according to claim 1, wherein the determining whether the active object meets a preset half-screen active popup window condition when the retum message of the active object is detected comprises:
Judging whether the class information of the movable object is half-screen movable object type information or not under the condition that the re-returning message is executed for the first time;
and if the class information is the type information of the half-screen movable object, determining that the movable object accords with the half-screen movable popup window condition.
3. The method according to claim 1, wherein the determining whether the active object meets a preset half-screen active popup window condition when the retum message of the active object is detected comprises:
judging whether the class information of the active object is half-screen active object type information or not in the return callback of the active object;
and if the class information is the type information of the half-screen active object and the return message is the first execution return message, determining that the active object accords with the half-screen active popup window condition.
4. A method according to any one of claims 1 to 3, further comprising:
calling an ending method of the movable object under the condition that the movable object accords with the half-screen movable popup window condition and the current label is different from the expected label;
and closing the movable object through the ending method.
5. A method according to any one of claims 1 to 3, wherein, in the case that the current tag is the same as the expected tag corresponding to the active object, sending the synchronization message corresponding to the active object includes:
calling a page display method under the condition that the current label is the same as the expected label;
and sending the synchronous message through the page display method.
6. A method according to any one of claims 1 to 3, wherein comparing the current tag with the expected tag in the pop-up callback of the synchronization message to obtain a tag comparison result includes:
judging whether the current tag is the same as the expected tag or not in the popup callback;
if the current label is the same as the expected label, generating the label same result;
and if the current label is different from the expected label, generating a label different result.
7. A method according to any one of claims 1 to 3, further comprising:
adding a frame callback operation in a preset dancer class;
judging whether the number of frame callback times reaches a preset number of times or not;
And if the frame callback times reach the preset times, indicating that the popup window of the movable object is drawn on a screen.
8. A popup window treatment device comprising:
the current tag acquisition module is used for acquiring the current tag of the target interface;
the semi-screen movable popup judging module is used for judging whether the movable object accords with the preset semi-screen movable popup condition when the returnable message of the movable object is detected;
the synchronous message sending module is used for sending synchronous messages corresponding to the movable object when the movable object accords with the half-screen movable popup window condition and the current label is the same as the expected label corresponding to the movable object;
the callback display tag comparison module is used for comparing the current tag with the expected tag in the popup display callback of the synchronous message to obtain a tag comparison result;
the popup window display module is used for setting the multi-label control in the target interface to be in a closed state when the label comparison result is the same label result, and setting the multi-label control to be in an open state when the popup window of the movable object is drawn on a screen;
And the active object replay module is used for closing the active object and putting the active object in a rebound window queue again when the label comparison result is a label non-same result.
9. An electronic device comprising at least one communication interface; at least one bus connected to the at least one communication interface; at least one processor coupled to the at least one bus; at least one memory coupled to the at least one bus, wherein the processor is configured to: acquiring a current label of a target interface; when a returnable message of an active object is detected, judging whether the active object accords with a preset half-screen active popup window condition or not; if the movable object accords with the half-screen movable popup window condition, sending a synchronous message corresponding to the movable object under the condition that the current label is the same as an expected label corresponding to the movable object; comparing the current tag with the expected tag in a popup callback of the synchronous message to obtain a tag comparison result; if the label comparison result is a label non-same result, closing the movable object, and putting the movable object into a rebound window queue again; if the label comparison result is the same label result, setting the multi-label control in the target interface to be in a closed state, and setting the multi-label control to be in an open state when the popup window of the movable object is drawn on the screen.
10. A computer readable storage medium, on which a computer program is stored, characterized in that the computer program, when being executed by a processor, implements the steps of the popup processing method according to any one of claims 1-7.
CN202311517198.6A 2023-11-14 2023-11-14 Popup window processing method, popup window processing device, popup window processing equipment and popup window processing medium Pending CN117519875A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202311517198.6A CN117519875A (en) 2023-11-14 2023-11-14 Popup window processing method, popup window processing device, popup window processing equipment and popup window processing medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202311517198.6A CN117519875A (en) 2023-11-14 2023-11-14 Popup window processing method, popup window processing device, popup window processing equipment and popup window processing medium

Publications (1)

Publication Number Publication Date
CN117519875A true CN117519875A (en) 2024-02-06

Family

ID=89763911

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202311517198.6A Pending CN117519875A (en) 2023-11-14 2023-11-14 Popup window processing method, popup window processing device, popup window processing equipment and popup window processing medium

Country Status (1)

Country Link
CN (1) CN117519875A (en)

Similar Documents

Publication Publication Date Title
EP2763034B1 (en) Method and device for image-capturing application screen for use in mobile terminal
EP4087258A1 (en) Method and apparatus for displaying live broadcast data, and device and storage medium
CN107491315B (en) Message prompting method, device and terminal
CN106484509B (en) Output method and device of popup window and terminal
US8887082B2 (en) Method and system for realizing message interactions in a multi-tabs application
CN108803964B (en) Buoy display method, device, terminal and storage medium
CN108376094B (en) Notification message display method and device, computer equipment and storage medium
CN106547417B (en) Method and device for displaying background task message
CN106201409B (en) Processing method and system for application program operation interface
US10416994B2 (en) Control method
WO2019047728A1 (en) Method for opening shortcut function, device, mobile terminal, and storage medium
CN109361948B (en) Interface management method, intelligent terminal and readable storage medium
CN107168715B (en) Intelligent terminal menu theme GUI engine implementation method
US10768947B2 (en) Method for interface refresh synchronization,terminal device, and non-transitory computer-readable storage medium
CN107045546B (en) Webpage processing method and device and intelligent terminal
WO2019047183A1 (en) Key display method, apparatus, and terminal
WO2019024305A1 (en) Message processing method and apparatus, electronic device and computer readable storage medium
TW201826109A (en) Method and apparatus for page presentation
CN111813308A (en) Interface processing method and device, electronic equipment and storage medium
CN113778280A (en) Linux-compatible Android display message notification method and device
CN106874010B (en) Method for rapid page loading of ListView in Android system
CN117519875A (en) Popup window processing method, popup window processing device, popup window processing equipment and popup window processing medium
CN110659082A (en) Application program interface display method and device, terminal and storage medium
WO2022247473A1 (en) Cross-process information processing method, and controller, terminal and storage medium
CN109800044A (en) A kind of method, apparatus and electronic equipment of the application of HTML5 double screen

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