Display method, electronic device, computer-readable storage medium, and program product

CN123011093APending Publication Date: 2026-10-30HONOR DEVICE CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510558261.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-04-28
Publication Date
2026-10-30

AI Technical Summary

Technical Problem

[0003]然而,现有技术中,在专注模式下,在焦点切换的场景中,可能出现高亮显示闪烁的问题,影响人机交互的体验

Benefits of technology

[0033]可以理解地,上述提供的第二方面的电子设备,第三方面的芯片系统,第四方面的计算机可读存储介质,第五方面的计算机程序产品所能达到的有益效果,可参考第一方面及其任一种可能的设计方式中的有益效果,此处不再赘述。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123011093A_ABST
    Figure CN123011093A_ABST
Patent Text Reader

Abstract

A display method, an electronic device, a computer readable storage medium and a program product, relate to the technical field of terminals. The method comprises: displaying a first interface, the first interface comprising a first window, the first window comprising a first icon and a second icon. In response to a triggering operation on the first icon, a second interface is displayed, the second interface comprising the first window and a second window highlighted, the second window being a window of a first application. At a first time, a triggering operation on the second icon is received. In a first time interval, the focus is on the first window, and the second interface is displayed. After a second time, the focus is on a third window, and a third interface is displayed, the third interface comprising the first window, the second window and a third window highlighted, the third window being a window of a second application. In this way, in the scenario of starting the second application, the highlight is adjusted only after the focus is switched to the third window of the second application, thereby avoiding flickering of the highlight.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of terminal technology, and in particular to a display method, electronic device, computer-readable storage medium, and program product. Background Technology

[0002] Focus mode is available on electronic devices such as tablets and laptops. In focus mode, the device highlights the active window, allowing the user to focus on it. Furthermore, the active window may change as focus shifts, and the device can adjust the highlighted window to ensure it remains always active. For example, after launching an application, the active window becomes the window of that launched application, and the device can highlight that application's window.

[0003] However, in existing technologies, during focus mode and focus switching scenarios, there may be issues with highlighting and flickering, which can negatively impact the human-computer interaction experience. Summary of the Invention

[0004] This application provides a display method, electronic device, computer-readable storage medium, and program product that can adjust the highlighted window based on input events from a mouse, keyboard, etc., after the focus switch is completed to match the input event, thereby ensuring that the highlighted display matches the input event, avoiding flickering problems, and improving the human-computer interaction experience.

[0005] To achieve the above objectives, this application adopts the following technical solution:

[0006] In a first aspect, a display method is provided, comprising the following steps: displaying a first interface, the first interface including a first window (such as a desktop window), the first window including a first icon and a second icon, the first icon being an application icon for a first application, and the second icon being an application icon for a second application. Responding to a trigger operation on the first icon, a second interface is displayed, the second interface including the first window and the second window, the second window being the window of the first application. In the second interface, the display brightness of the second window is higher than the display brightness of the display portion of the first window, which can be understood as highlighting the second window. At a first moment, a trigger operation on the second icon is received. During a first time interval, the focus is on the first window, and the second interface is displayed, the first time interval being after the first moment. It can be seen that after receiving a trigger operation on the second icon, the focus is switched to the first window where the second icon is located; however, for a period of time, the second interface remains displayed, and the highlighting adjustment does not occur due to the focus switching to the first window. Subsequently, after the second moment, the focus is on a third window, and a third interface is displayed, the third interface including the first window, the second window, and the third window, the third window being the window of the second application. In the third interface, the display brightness of the third window is higher than that of the first window and also higher than that of the second window; this can be interpreted as highlighting the third window. It is evident that the highlighting adjustment only occurs after the focus shifts from the first window to the third window of the second application.

[0007] In summary, by employing this application, in scenarios where the second window of the first application is highlighted, and a trigger operation on the second icon is received, triggering the launch of the second application, the highlighting is only adjusted after the focus switches to the third window of the second application. Furthermore, for the intermediate focus switch between the second and first windows that occurs between receiving the trigger operation on the second icon and the focus switching to the third window, the focus will not be adjusted to full-screen highlighting based on the first window not using focus mode. This prevents brief flickering of full-screen highlighting between the second and third windows, thus ensuring the accuracy of the highlighting and improving the human-computer interaction experience.

[0008] In one possible design of the first aspect, after displaying the third interface, the method further includes: in response to a trigger operation on the first window, displaying a fourth interface, the fourth interface including the first window, the second window, and the third window, with the first, second, and third windows having the same display brightness. It is evident that after receiving a trigger operation on the first window, the focus is switched to the first window, which can be adjusted to full-screen highlight display. At the third moment, receiving a trigger operation on the close button in the third window can trigger the closure of the third application. In the second time interval, the focus is on the third window, and the fourth interface is displayed; the second time interval is after the third moment. It is evident that after receiving a trigger operation on the close button of the third window, the focus is switched to the third window; however, for a period of time, the fourth interface remains displayed without any adjustment to highlight display due to the focus switching to the third window. Subsequently, after the fourth moment, the focus is on the second window, and a fifth interface is displayed, the fifth interface including the first and second windows, with the second window having a higher display brightness than the areas of the fifth interface excluding the second window; this can be understood as highlighting the second window. It is evident that the highlight adjustment only occurred after the focus shifted from the third window to the second window of the first application.

[0009] In other words, using this design, under the premise of full-screen highlighting, when a trigger operation of the close button on the third window is received, triggering the closure of the second application, the highlighting is only adjusted after the focus switches to the second window due to the cancellation of the third window's display. Furthermore, for the intermediate focus switch between the first and third windows that occurs between receiving the trigger operation of the close button on the third window and the focus switching to the second window, the focus will not switch from full-screen highlighting to highlighting the third window, thus preventing any brief flickering of the third window's highlighting during the transition from full-screen highlighting to highlighting the second window. This further ensures the accuracy of the highlighting and improves the human-computer interaction experience.

[0010] In one possible design of the first aspect, after displaying the third interface, the method further includes: at a fifth moment, receiving a trigger operation on the second window, which can trigger switching the active window to the second window. At a sixth moment, which follows the fifth moment, a sixth interface is displayed, comprising the first window and the second window. In the sixth interface, the display brightness of the second window is higher than the display brightness of the first window's display portion and higher than the display brightness of the third window's display portion; this can be understood as highlighting the second window.

[0011] In other words, using this design, in scenarios where the active window is switched from the third window to the second window, the focus is directly switched from the third window to the second window, without any intermediate focus switching. The focus can be switched directly from the third window highlighted on the third interface to the second window highlighted on the sixth interface.

[0012] In one possible design approach of the first aspect, displaying the second interface during the first time interval includes: displaying the second interface during the first time interval based on the absence of a first identifier. Displaying the third interface after the second time interval includes: displaying the third interface after the second time interval based on the presence of a first identifier. The first identifier is recorded after the third window is created. It can be understood that after the third window is created, it is to be displayed, and the focus is switched to the third window. Therefore, the presence of the first identifier indicates that the focus has switched to the third window, and the first identifier can indicate a focus switch that matches the triggering operation on the second icon.

[0013] In other words, using this design approach, if the first identifier is absent, it is assumed that no focus switch has occurred matching the trigger operation on the second icon; that is, the focus has not yet switched to the third window. Therefore, the highlight display does not need to be adjusted, and the second interface continues to be displayed, thus avoiding highlight flickering. If the first identifier is present, it is assumed that a focus switch has occurred matching the trigger operation on the second icon; that is, the focus has switched to the third window. In this case, the highlight display can be adjusted to show the third interface, thus highlighting the third window of the launched second application.

[0014] In one possible design approach of the first aspect, after receiving the trigger operation on the second icon, the method further includes: after waiting for a first duration after the first moment, if a process is detected to have been created within the first duration, it indicates that the trigger operation on the second icon is an input event that triggers the application launch; after waiting for another second duration, the window should be created; and the first identifier is recorded at the seventh moment. In this way, for the input event that triggers the application launch, it can be guaranteed that the first identifier is recorded after the window is created. The existence of the first identifier indicates that the focus has switched to the third window. Each time a preset event indicating a focus switch is detected, the first identifier is queried, specifically including the following two cases:

[0015] The first method is to not adjust the highlight if the first identifier is not found. Specifically, at the eighth moment, which is between the first and seventh moments, the first preset event is detected. In response to the first preset event, if the first identifier is not found, it indicates that the preset event was generated when the focus was switched to the first window, rather than when the focus was switched to the third window. Subsequently, during the first time interval, the second interface is kept displayed, that is, the second window is kept highlighted.

[0016] The second method involves checking if the first identifier is found, then adjusting the highlight display. Specifically, at the ninth moment, which is after the seventh moment, a second preset event is detected. In response to the second preset event, if the first identifier is found, it indicates that the preset event was generated by switching the focus to the third window. Subsequently, after the second moment, the third interface is displayed, that is, the third window is switched to be highlighted.

[0017] In one possible design approach of the first aspect, displaying the fourth interface during the second time interval includes: displaying the fourth interface during the second time interval based on the absence of a first identifier. Displaying the fifth interface after the fourth time interval includes: displaying the fifth interface after the fourth time interval based on the presence of the first identifier. The first identifier is recorded after the third window is destroyed. It can be understood that after the third window is destroyed, it is no longer displayed, and the focus is switched to the second window. Therefore, the presence of the first identifier indicates that the focus has switched to the second window, and the first identifier can indicate a focus switch that matches the trigger operation of the close button on the third window.

[0018] In other words, using this design approach, if the first indicator is absent, it is assumed that no focus switch has occurred matching the trigger operation of the close button on the third window; that is, the focus has not yet switched to the second window. Therefore, the highlight display can remain unchanged, and the fourth interface can continue to be displayed, thus avoiding highlight flickering. If the first indicator is present, it is assumed that a focus switch has occurred matching the trigger operation of the close button on the third window; that is, the focus has switched to the second window. In this case, the highlight display can be adjusted to show the fifth interface, thereby highlighting the second window.

[0019] In one possible design approach of the first aspect, after receiving a trigger operation on the close button in the third window, the method further includes: waiting for a first duration after the third moment; if it is detected that the process has been destroyed within the first duration, it indicates that the trigger operation on the close button of the third window is an input event that triggers the closing of the application; then waiting for a second duration, the window should be completely destroyed; and recording the first identifier at the tenth moment. In this way, for the input event that triggers the closing of the application, it can be guaranteed that the first identifier is recorded after the window is destroyed. The existence of the first identifier indicates that the focus has switched from the destroyed third window to the second window. After each detection of a preset event indicating a focus switch, the first identifier is queried, specifically including the following two cases:

[0020] The first method is to not adjust the highlight display if the first identifier is not found. Specifically, at the eleventh moment, which is between the third and tenth moments, the third preset event is detected. In response to the third preset event, if the first identifier is not found, it indicates that the preset event was generated when the focus was switched to the third window, rather than when the focus was switched to the second window. Subsequently, in the second time interval, the fourth interface is kept displayed, that is, the full-screen highlight display is maintained.

[0021] The second method involves checking if the first identifier is found, then adjusting the highlight display. Specifically, at the twelfth moment, which is after the tenth moment, the fourth preset event is detected. In response to the fourth preset event, if the first identifier is found, it indicates that the preset event was generated by switching the focus to the second window. Subsequently, after the fourth moment, the fifth interface is displayed, that is, the second window is switched to be highlighted.

[0022] In one possible design approach of the first aspect, after receiving the trigger operation on the second window at the fifth moment, the method further includes: waiting for a first duration after the fifth moment; if it is detected that neither a process is created nor destroyed within the first duration, it indicates that the trigger operation on the second window is neither an input event to start the application nor an input event to close the application, but rather an input event to switch applications. In this case, the focus can quickly switch from the third window to the second window, so there is no need to wait for the second duration, and the first identifier can be recorded at the thirteenth moment. Subsequently, at the fourteenth moment, which is after the thirteenth moment, a fifth preset event is detected. In response to the fifth preset event, the existence of the first identifier is found, and the fifth preset event indicates a focus switch. The above-mentioned display of the sixth interface after the sixth moment includes: displaying the sixth interface after the sixth moment based on the existence of the first identifier.

[0023] In one possible design approach of the first aspect, after the existence of the first identifier is found, the method further includes deleting the first identifier. Each time the first identifier is found, the highlight is adjusted based on its existence. Deleting the first identifier prevents the reuse of the previously recorded first identifier to trigger highlight adjustment when a new preset event is detected, thus avoiding the reuse of the first identifier from the same record and preventing highlight adjustment without a focus switch matching the input event.

[0024] In one possible design approach of the first aspect, the method further includes: deleting the first identifier after receiving an input event. It can be understood that the first identifier is generated based on the input event. After receiving an input event, the corresponding first identifier can be recorded. Deleting the previously recorded first identifier after each received input event ensures that even if the previously recorded first identifier is not queried and triggers an adjustment of the highlight display, it can still be deleted, thereby preventing the previously recorded first identifier from affecting subsequent triggering of the adjustment of the highlight display.

[0025] In one possible design approach in the first aspect, the first duration is shorter than the second duration. Typically, the time required to create and destroy a process is less than the time required to create and destroy a window. Therefore, configuring the first duration to be shorter than the second duration allows for a shorter time to wait for process creation and destruction, and a longer time to wait for window creation and destruction, making the waiting time more reasonable.

[0026] In one possible design approach of the first aspect, the first duration is greater than or equal to the third duration, and greater than or equal to the fourth duration. The third duration is the time between detecting the input event that triggers application startup and completing process creation, and the fourth duration is the time between detecting the input event that triggers application shutdown and completing process destruction. This allows for sufficient waiting time before further detection of process creation and destruction, ensuring that process creation can be detected in the application startup scenario and process destruction can be detected in the application shutdown scenario.

[0027] In one possible design approach of the first aspect, the first duration is less than the eighth duration, where the eighth duration is the time between detecting the input event that triggers application switching and the focus switching to the window of the switched application. Specifically, for the input event that triggers application switching, after waiting for the first duration, if no process creation or destruction is detected, the first identifier can be recorded without waiting for the second duration. Therefore, by recording the first identifier after waiting for the first duration for the input event that triggers application switching, setting the first duration to be less than the eighth duration ensures that the first identifier is recorded before the focus switches to the window of the switched application. This way, when the focus switches to the window of the switched application and a preset event is triggered, the highlight can be adjusted based on the first identifier.

[0028] In one possible design approach of the first aspect, the second duration is greater than or equal to the fifth duration, and greater than or equal to the sixth duration. The fifth duration is the time between process creation and window creation during application startup, and the sixth duration is the time between process destruction and window destruction during application shutdown. This allows for sufficient waiting time to record the first identifier after window creation and destruction are complete.

[0029] Secondly, this application provides an electronic device including a display screen, a memory, and one or more processors. The display screen, memory, and processors are coupled. The memory stores computer program code, including computer instructions, which, when executed by the processor, cause the electronic device to perform the method described in the first aspect and any of its possible design embodiments.

[0030] Thirdly, this application provides a chip system applied to an electronic device including a display panel and a memory; the chip system includes one or more interface circuits and one or more processors; the interface circuits and processors are interconnected via lines; the interface circuits are used to receive signals from the memory of the electronic device and send signals to the processor, the signals including computer instructions stored in the memory; when the processor executes the computer instructions, the electronic device performs the method as described in the first aspect and any of its possible design embodiments.

[0031] Fourthly, this application provides a computer-readable storage medium including computer instructions that, when executed on an electronic device, cause the electronic device to perform a method as described in the first aspect and any of its possible design embodiments.

[0032] Fifthly, this application provides a computer program product that, when run on an electronic device, causes the electronic device to perform the method as described in the first aspect and any possible design thereof.

[0033] Understandably, the beneficial effects achieved by the electronic device of the second aspect, the chip system of the third aspect, the computer-readable storage medium of the fourth aspect, and the computer program product of the fifth aspect provided above can be referred to the beneficial effects of the first aspect and any of its possible design embodiments, which will not be repeated here. Attached Figure Description

[0034] Figure 1 An interface diagram of the highlighted display window provided in an embodiment of this application;

[0035] Figure 2 An interface diagram illustrating a highlighted window in a focus switching scenario provided in this application embodiment;

[0036] Figure 3 An interface diagram showing a highlighted window in another focus switching scenario provided in this application embodiment;

[0037] Figure 4 A flowchart illustrating the display method provided in the embodiments of this application;

[0038] Figure 5 A schematic diagram illustrating the implementation principle of highlighting display in an embodiment of this application;

[0039] Figure 6 A flowchart illustrating the highlighting of an active window is provided in an embodiment of this application;

[0040] Figure 7 A schematic diagram illustrating the principle of highlighting a window in a focus switching scenario, as provided in an embodiment of this application.

[0041] Figure 8 A schematic diagram of a highlighted window in another focus switching scenario provided in this application embodiment;

[0042] Figure 9 A schematic diagram illustrating the principle of highlighting a window in another focus switching scenario provided in this application embodiment;

[0043] Figure 10 A schematic diagram illustrating the principle of highlighting a window in another focus switching scenario provided in this application embodiment;

[0044] Figure 11 A hardware structure diagram of a laptop computer provided in an embodiment of this application;

[0045] Figure 12 A software architecture diagram of a laptop computer provided for an embodiment of this application;

[0046] Figure 13 This is a timing interaction diagram of a display method provided in an embodiment of this application. Detailed Implementation

[0047] The technical solutions of the embodiments of this application are described below with reference to the accompanying drawings. In the description of the embodiments of this application, the terminology used in the following embodiments is for the purpose of describing specific embodiments only and is not intended to limit the application. As used in the specification and appended claims of this application, the singular expressions "a," "the," "the," "the," and "this" are intended to also include expressions such as "one or more," unless the context clearly indicates otherwise. It should also be understood that in the following embodiments of this application, "at least one" and "one or more" refer to one or more (including two). The term "and / or" is used to describe the relationship between related objects, indicating that three relationships can exist; for example, A and / or B can represent: A alone, A and B simultaneously, or B alone, where A and B can be singular or plural. The character " / " generally indicates that the preceding and following related objects are in an "or" relationship.

[0048] References to "one embodiment" or "some embodiments" in this specification mean that one or more embodiments of this application include a specific feature, structure, or characteristic described in connection with that embodiment. Therefore, the phrases "in one embodiment," "in some embodiments," "in other embodiments," "in still other embodiments," etc., appearing in different parts of this specification do not necessarily refer to the same embodiment, but rather mean "one or more, but not all, embodiments," unless otherwise specifically emphasized. The terms "comprising," "including," "having," and variations thereof mean "including but not limited to," unless otherwise specifically emphasized. The term "connection" includes direct connections and indirect connections, unless otherwise stated. "First" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of technical features indicated.

[0049] In the embodiments of this application, the words "exemplarily" or "for example" are used to indicate examples, illustrations, or explanations. Any embodiment or design described as "exemplarily" or "for example" in the embodiments of this application should not be construed as being more preferred or advantageous than other embodiments or design solutions. Specifically, the use of the words "exemplarily" or "for example" is intended to present the relevant concepts in a specific manner.

[0050] Before introducing the embodiments of this application, a brief introduction to the relevant terms used in this application will be given:

[0051] First, the focus window.

[0052] The focus window is the window that receives focus. For example, if a dialog box contains a button, then the button becomes the focus window when it receives focus.

[0053] Second, the top-level window.

[0054] A top-level window, also known as a top-level window, is the window at the highest level in the window hierarchy. It exists independently of other windows. Top-level windows typically have their own title bar, border, and system menu, and can be moved, resized, minimized, maximized, or closed independently.

[0055] A top-level window can contain multiple child windows or buttons, any of which may become the focus window.

[0056] Third, the active window.

[0057] The top-level window of the focused window is the active window. Note that the top-level window itself can also be the focused window; in this case, the active window is the top-level window itself.

[0058] The display method provided in this application embodiment can be applied to the focus mode provided by an electronic device. In focus mode, the electronic device can highlight the active window, allowing the user to focus on the active window. It is understood that focus mode is only an exemplary name, and optionally, focus mode can also be called focus display mode, focus feature, focus display characteristic, attention mode, window highlighting mode, etc., and this application embodiment does not specifically limit it in this way.

[0059] For example, the electronic device in this application embodiment may be a mobile phone, tablet computer, desktop computer, laptop computer, handheld computer, notebook computer, ultra-mobile personal computer (UMPC), netbook, as well as cellular phone, personal digital assistant (PDA), artificial intelligence (AI) device, wearable device, in-vehicle device, smart home device and / or smart city device, etc., which are devices with display functions. This application embodiment does not impose special limitations on the specific form of the electronic device. In the following description, a laptop computer is mainly used as an example.

[0060] The following is combined with Figure 1 An example illustrating the display format in focus mode. See also Figure 1 The laptop can display desktop 101 (also known as the first window, or the interface where desktop 101 is located, or the first interface). In focus mode, after launching a video application (also known as the first application), if the video application is launched in response to a click on the application icon 1011 (also known as the first icon) of the video application on desktop 101, the laptop can display interface 102 (also known as the second interface). Interface 102 includes desktop 101 and video playback window 1021 (also known as the second window). If the focus is on video playback window 1021, then video playback window 1021 is highlighted, and desktop 101 is not highlighted.

[0061] It should be noted that in the diagrams of this article, areas not obscured by diagonal lines are considered highlighted, which can also be understood as having a higher brightness than other areas. For example, if the video playback window 1021 in interface 102 is not obscured by diagonal lines, then the video playback window 1021 in interface 102 is highlighted. Conversely, areas obscured by diagonal lines are not highlighted. For example, if the desktop 101 in interface 102 is obscured by diagonal lines, then the desktop 101 in interface 102 is not highlighted.

[0062] Furthermore, as the focus switches, the active window may also change accordingly. The laptop can adjust the highlighted window, such as highlighting the window of a new application after it is launched.

[0063] Therefore, it should be noted that this application does not specifically limit the method of enabling focus mode. In actual implementation, those skilled in the art can flexibly configure the method of enabling focus mode according to actual needs. For example, a laptop computer can provide an entry point for enabling focus mode in its settings application. Another example is that a laptop computer can be configured to enable focus mode via voice control. Yet another example is that a laptop computer can be configured to automatically enable focus mode in specific scenarios, such as watching TV series or playing games.

[0064] However, in Focus Mode, in scenarios involving focus switching, such as when launching or closing an application triggers a focus switch, a flickering highlight may occur. Analysis revealed that this phenomenon primarily arises because user actions result in intermediate focus switches, which can trigger the laptop to adjust the highlighted window, leading to the flickering highlight. The following sections illustrate this flickering highlight phenomenon using two specific scenarios and provide an illustrative analysis of its causes.

[0065] Scenario 1: Application startup.

[0066] See Figure 2When the laptop is displaying interface 102, i.e., with the video playback window 1021 highlighted, in response to the user's click on the application icon 1022 (or second icon) of the chat application (also known as the second application) on the desktop 101 in interface 102, the laptop can launch the chat application. However, the laptop may first display interface 201, with the entire interface 201 highlighted, and then display interface 202 (also known as the third interface), with the chat window 2021 (also known as the third window) in interface 202 highlighted. Clearly, the laptop does not directly switch from the highlighted video playback window 1021 shown in interface 102 to the highlighted chat window 2021 shown in interface 202; instead, a full-screen highlighted state occurs in between, resulting in a flickering full-screen highlight.

[0067] In scenario 1 above, after receiving a user's click on the application icon 1022, the laptop can detect the focus shifting from the video playback window 1021 to the desktop 101. Simultaneously, the desktop 101 is not on the focus mode whitelist, so the laptop will initially display normally, resulting in the highlighted state shown in interface 201. Subsequently, after the chat application finishes launching and displays the conversation window 2021, the laptop can detect the focus shifting from the desktop 101 to the conversation window 2021, thus displaying the highlighted state of the conversation window 2021 as shown in interface 202.

[0068] As can be seen, in scenario 1, the main reason for the flickering of the full-screen highlight is that the focus shifted from the video playback window 1021 to the desktop 101, which triggered the laptop to perform a highlight adjustment, resulting in the flickering of the full-screen highlight.

[0069] Scenario 2: Application closed.

[0070] See Figure 3When the laptop is displaying interface 202, i.e., with the dialog window 2021 highlighted, in response to the user's click on desktop 101 in interface 202, the focus switches to desktop 101, thus changing the focus window. Simultaneously, desktop 101 is not in the focus mode whitelist, and the laptop can display interface 301 (also known as the fourth interface), which is entirely highlighted. Subsequently, in response to the user's click on the close button 3011 in dialog window 2021 in interface 301, the laptop may first display interface 302, which is not highlighted, and then display interface 102 (also known as the fifth interface). Clearly, the laptop does not directly switch from the full-screen highlighted state shown in interface 301 to the highlighted video playback window 1021 shown in interface 102; instead, a full-screen non-highlighted state occurs in between, resulting in a flickering full-screen non-highlighted display.

[0071] In scenario 2 above, after receiving a user's click on the close button 3011 in the dialog window 2021, the laptop can detect the focus shifting from the desktop 101 to the dialog window 2021. Therefore, the laptop can highlight the dialog window 2021. However, the dialog window 2021 is quickly closed, and the highlighted area disappears. Thus, at the moment of closing, the screen appears in a full-screen, non-highlighted state as shown in interface 302. After the dialog window 2021 is closed, the laptop can detect the focus shifting from the dialog window 2021 to the video playback window 1021, so the laptop can display the highlighted video playback window 1021 as shown in interface 102.

[0072] As can be seen, in scenario 2, the main reason for the flickering of the full-screen non-highlighted display is that the focus shifted from desktop 101 to dialog window 2021, which triggered the laptop to perform a highlight adjustment.

[0073] Based on the above problems, this application provides a display method in which, after receiving an input event, the laptop can skip the adjustment of the highlight display triggered by the focus switch in the intermediate state, and then adjust the highlight display after determining that the focus switch matching the input event has occurred.

[0074] Input events include actions such as clicking, long pressing, dragging, and swiping. These events can trigger applications to launch, close, or switch between them. The focus switch corresponding to an input event refers to the final focus change that occurs during that event.

[0075] For example, in the scenario of launching an application, the input event could be a click event on the application icon on the desktop, and the matching focus switch would be the focus switching to the window of the launched application. For example, in the above... Figure 2 In the example of Scenario 1 shown, the input events include a click event on the application icon 1022 of the chat application in interface 102. The matching focus switch is a focus switch to the chat window 2021. Thus, after receiving the user's click on the application icon 1022, the laptop only detects the focus switch to the chat window 2021 after the chat application is launched and the chat window 2021 is displayed. That is, it detects a matching focus switch, and at this time, the laptop can display the highlighted chat window 2021 as shown in interface 202. In addition, after receiving the user's click on the application icon 1022, but before launching the chat application and displaying the chat window 2021, the laptop detects a focus switch to the desktop 101. However, since this is not a matching focus switch, the laptop will not adjust the highlight, and can maintain the highlighted video playback window 1021 as shown in interface 102.

[0076] For example, in the scenario of closing an application, the input event could be a click event on the close button of a window, and the matching focus switch would be the focus switching to the topmost window among the remaining windows. For example, in the above... Figure 3 In the example of scenario 2 shown, the input event includes a click event on the close button 3011 in the chat window 2021 of interface 301. The matching focus switch is a focus switch to the video playback window 1021. Thus, after receiving the user's click on the close button 3011, the laptop only detects the focus switch to the video playback window 1021 after the chat application and chat window 2021 are closed. At this point, the laptop can display the highlighted video playback window 1021 as shown in interface 102. Alternatively, after receiving the user's click on the close button 3011, before closing the chat application and chat window 2021, the laptop detects a focus switch to the chat window 2021, but since it is not a matching focus switch, the laptop will not adjust the highlight, maintaining the full-screen highlighted state shown in interface 301.

[0077] In summary, by adopting the embodiments of this application, the laptop adjusts the highlight display only after detecting a focus window switch that matches the input event, instead of triggering the adjustment of the highlight display after each focus switch. This avoids adjusting the highlight display when an intermediate focus switch occurs, thus avoiding the flickering problem, ensuring that the adjustment of the highlight display matches the input event, and improving the human-computer interaction experience.

[0078] In some embodiments, the laptop computer can use a first identifier to indicate a focus switch matching an input event, and upon detecting a focus switch, queries the first identifier. If the first identifier is found, the highlighted window is adjusted, thereby achieving adjustment of the highlighted window after determining that a focus switch matching an input event has occurred. Specifically, see [link to documentation]. Figure 4 In this embodiment, the display method includes the following steps:

[0079] S401. Detect preset events. Preset events can indicate the occurrence of focus switching.

[0080] The laptop can initially determine whether a focus switch has occurred by detecting preset events. Specifically, if a preset event is detected, it indicates that a focus switch has occurred or may occur, and the laptop can check whether to adjust the highlight display, such as by performing S402 and subsequent steps described below. If no preset event is detected, it indicates that a focus switch will not occur, and the laptop can continue to detect preset events.

[0081] The preset events include the Focus Window Changed Event. The laptop can detect this event after the focus window changes. Therefore, the laptop's detection of the Focus Window Changed Event indicates that a focus switch has occurred.

[0082] For example, after launching application A, the laptop will display the window of application A, and the focus will switch to the window of application A. At this time, the laptop can detect the focus window change event.

[0083] For example, after closing application B, the laptop will close the window of application B, the window of application B will disappear, and the focus will switch to another window displayed in the foreground. At this time, the laptop can also detect the focus window change event.

[0084] For example, if the windows of application C and application D are displayed in the foreground, and the focus is on the window of application D, when a click operation is received on the window of application C, the focus will switch to the window of application C, and the laptop can detect the focus window change event.

[0085] In some embodiments, the preset events also include an object move event. The laptop can detect an object move event after an object such as a cursor, window, or control has moved.

[0086] For example, when a user operates the mouse or touches the touchpad on the keyboard, causing the cursor to move, the laptop can detect the object movement event.

[0087] For example, a laptop can detect object movement events after a window's position has changed.

[0088] In some scenarios, focus changes occur, but the laptop may not detect the focus window change event. In other words, the focus window change event may not apply to some windows. For example, on a laptop, in response to a user's right-click on the Start icon in the bottom taskbar (such as the icon to the left of the search box in Desktop 101), the laptop can display a window with shortcut menus, indicating a focus change. However, in practice, some laptops may not detect this focus window change event. Therefore, laptops can detect object movement events. Typically, an object movement event occurs before a focus change, and the laptop can detect this event. For example, the cursor must first be moved to the position of the Start icon in the bottom taskbar before a right-click can be performed, and only then will the focus change occur. In this way, if the laptop detects an object movement event, it indicates that a focus change may have occurred, thus avoiding missing some focus change scenarios.

[0089] In other embodiments, the preset events also include an object destruction event. The laptop can detect the object destruction event after objects such as windows, controls, and processes are destroyed.

[0090] For example, in response to a user clicking the close button of a window, the laptop will destroy the application process corresponding to the window and the window itself. After destruction, the laptop can detect the object destruction event.

[0091] In some scenarios, the focus switches after a window is closed, but the laptop may not detect the focus window change event. This means that the focus window change event may not apply to the closing of some windows. Therefore, laptops can detect object destruction events. Typically, closing a window is accompanied by the destruction of the window and its process, and the laptop can detect object destruction events. Thus, if the laptop detects an object destruction event, it indicates that a focus window switch may have occurred, thereby avoiding missing some focus switching scenarios.

[0092] It is understandable that after the focus mode is turned on, the laptop can start executing S401, and the laptop can detect preset events in real time, thus detecting each preset event.

[0093] S402. After detecting a preset event, check if a first identifier exists, which indicates a focus switch that matches the input event. If yes, proceed to S408; otherwise, continue with S401 and its subsequent steps.

[0094] If no first identifier is found, it indicates that no input event matching the focus switch has occurred. This may be a case where a preset event was detected during an intermediate focus switch. The laptop will not adjust the highlighted window to avoid flickering, but can continue to detect preset events.

[0095] If the first identifier is found, it indicates that a focus switch matching the input event has occurred. This is a case where a preset event is detected when a focus switch matching the input event occurs. The laptop can adjust the highlighted window, such as by executing S408 below, so that the highlighted window matches the input event.

[0096] In other words, after detecting a preset event, the laptop can query the first identifier and only trigger the adjustment of the highlighted window after confirming that a focus switch matching the input event has occurred, rather than adjusting the highlighted window during an intermediate focus switch.

[0097] In one specific implementation, the laptop computer can generate the first identifier via the following steps S403-S407:

[0098] S403. Detect input events, including at least one of the following: events that trigger the launch of an application, events that trigger the closure of an application, and events that trigger the switching of applications.

[0099] If an input event is detected, it indicates that user input has occurred, which may trigger a focus switch. The laptop can execute S404 and subsequent steps to generate a first identifier after a focus switch matching the input event occurs.

[0100] If no input event is detected, it indicates that there is no user input. In this case, the user has no need to switch focus, and there is no focus switch that matches the input event. The laptop can skip the subsequent step of generating the first identifier and continue to detect input events.

[0101] Input events can be mouse input events, keyboard input events, touch screen input events, etc., and this application embodiment does not specifically limit them.

[0102] Among these, events that trigger application launch include those that launch application A even when application A's process does not exist. For example, events that trigger application launch could be clicks on application A's icon or clicks on application A's links.

[0103] Among these, events that trigger closing the application include those that close the application while the application B process is still running. For example, an event that triggers closing the application B could be a click event on the close button in the application B window.

[0104] The events that trigger application switching include those that bring application C to the foreground or background when application C is running in the process of running. For example, bringing application C to the foreground could be triggered by clicking the application C window, or by clicking the application icon of application C in the taskbar when the application C window is not displayed. Similarly, bringing application C to the background could be triggered by clicking the minimize button in the application C window, or by clicking the application icon of application C in the taskbar when the application C window is displayed.

[0105] Of course, input events may not trigger applications to launch, close, or switch applications. For example, an input event could be a left-click event on an empty area of ​​the desktop.

[0106] It is understandable that after the focus mode is turned on, the laptop can start executing S403, and the laptop can detect input events in real time, thus detecting each input event.

[0107] S404. After detecting an input event, wait for the first duration.

[0108] Typically, a laptop can quickly detect input events after a user enters information, but the response time can be relatively long. For example, a laptop can quickly detect a click on an application icon, but creating the application process in response to that click can take a considerable amount of time. Similarly, a laptop can quickly detect a click on a window's close button, but destroying the application process in response to that click can take a considerable amount of time.

[0109] Based on this, after detecting an input event, the laptop can wait for a first duration to obtain the laptop's response to the input event, which is used to determine when to generate the first identifier.

[0110] The first duration is greater than or equal to the third duration, and the fourth duration is greater than or equal to the fourth duration. The third duration is the time between detecting the input event that triggers application launch and completing process creation. This third duration can be obtained by analyzing historical data from multiple application launches; for example, it could be the longest or average duration between detecting the input event and completing process creation across multiple application launches. Similarly, the fourth duration is the time between detecting the input event that triggers application closure and completing process destruction. This fourth duration can also be obtained by analyzing historical data from multiple application closures; for example, it could be the longest or average duration between detecting the input event and completing process destruction across multiple application closures. For instance, if the third duration is 190ms and the fourth duration is 150ms, then the first duration can be 200ms. Thus, after waiting for the first duration, the laptop will have completed the process creation or destruction response, allowing for accurate acquisition of the specific response.

[0111] S405. Check if any processes have been created or destroyed. If yes, execute S406 and S407; otherwise, execute S407.

[0112] After waiting for the first duration, the laptop can detect whether a process has been created or destroyed, that is, detect the laptop's response to input events.

[0113] If process creation is detected, it indicates that an input event triggered the application launch. Further window creation is required, and once the window is created, the laptop can display it, at which point a focus switch will occur matching the input event. In this case, the laptop can record the first identifier after window creation, as shown in S406 and S407 below.

[0114] If process destruction is detected, it indicates that the input event triggered the application closure, and the window will be further destroyed. After the window is destroyed, the laptop will not display the window, and a focus switch will occur matching the input event. To handle this situation, the laptop can record the first identifier after the window is destroyed, as shown in S406 and S407 below.

[0115] If no process creation or destruction is detected, it indicates that the input event may trigger application switching. Subsequent window creation and destruction are unnecessary, allowing for a faster focus switch. In this case, the laptop can record the first identifier without waiting for the window to complete creation or destruction, as shown in S407 below.

[0116] In other words, a laptop can determine the type of input event based on its response to the input event, thereby determining when to generate the first identifier. The types of input events include triggering application launch, triggering application closure, and others, with "others" including triggering application switching.

[0117] In other embodiments, after detecting an input event, the laptop computer can also determine the type of the input event based on the parameters of the input event, thereby determining when to generate the first identifier. The parameters of the input event include the position on the display screen to which the input is directed, the element displayed at that position, and so on.

[0118] For example, if the input event is directed to a location on the desktop where an application icon is displayed and no process for that application is currently running on the laptop, the laptop can determine that the type of input event is the type that triggers the launch of an application, and then execute S406 and S407 to record the first identifier.

[0119] For example, if the input event is directed to a location in a window where the close button is displayed, the laptop can determine that the type of input event is one that triggers the closing of the application, and then execute S406 and S407 to record the first identifier.

[0120] For another example, if the input event is directed at a window that is not the window with focus, the laptop can determine that the type of input event is switching applications, and then execute S407 to record the first identifier.

[0121] S406, Waiting for the second duration.

[0122] If a process creation is detected, the laptop can wait for a second period of time until the window is created. Similarly, if a process destruction is detected, the laptop can wait for a second period of time until the window is destroyed.

[0123] The second duration is greater than or equal to the fifth duration, and the second duration is greater than or equal to the sixth duration. The fifth duration is the time between process creation and window creation. This fifth duration can be obtained by analyzing historical data from multiple application launches, such as the longest or average time between process creation and window creation when launching the application multiple times. The sixth duration is the time between process destruction and window destruction. This sixth duration can be obtained by analyzing historical data from multiple application closures, such as the longest or average time between process destruction and window destruction when closing the application multiple times. For example, if the fifth duration is 480ms and the sixth duration is 300ms, then the second duration can be 500ms. Thus, after waiting for the second duration, the laptop will have completed window creation or destruction.

[0124] In other embodiments, the laptop can wait for different second durations depending on whether a process is created or destroyed. Specifically, for the process creation scenario, the second duration the laptop waits for can be greater than or equal to a fifth duration. For the process destruction scenario, the second duration the laptop waits for can be greater than or equal to a sixth duration. This allows the laptop to record the first identifier at more appropriate times for both process creation and process destruction scenarios.

[0125] In other embodiments, after detecting the creation of a process, the laptop can also detect whether the window corresponding to the created process has been created. If the window creation is detected as complete, the laptop executes step S407 as described below; otherwise, the detection continues until the window creation is detected as complete. Similarly, after detecting the destruction of a process, the laptop can also detect whether the window corresponding to the destroyed process has been destroyed. If the window destruction is detected as complete, the laptop executes step S407 as described below; otherwise, the detection continues until the window destruction is detected as complete. In this way, the laptop can accurately record the first identifier after the window creation or destruction is complete.

[0126] S407. Record the first identifier, which indicates the focus window switch that occurred when the input event matched.

[0127] After the window is created, the window of the launched application will be displayed on the screen, triggering a focus switch that matches the application launch, with focus shifting to the launched application's window. Based on this, the laptop records a first identifier after window creation, ensuring that the first identifier is recorded just before the focus switch matching the input event occurs. Thus, when the laptop detects a preset event indicating a focus switch, it can retrieve the first identifier and trigger an adjustment to the highlight display.

[0128] After the window has been destroyed, it is no longer displayed, triggering a focus switch that matches the application closing event. Focus then shifts to the topmost window among the remaining windows. Based on this, the laptop records a first identifier after the window is destroyed, ensuring that the first identifier is recorded just before a focus switch matching an input event occurs. This way, when the laptop detects a preset event indicating a focus switch, it can retrieve the first identifier and trigger an adjustment to the highlight display.

[0129] In addition, if no process creation or destruction is detected in S405, the laptop can skip S406 and execute S407 to record the first identifier, thus enabling timely recording of the first identifier in scenarios that may trigger application switching.

[0130] After steps S403-S407, the first identifier can be recorded. Afterward, once the laptop retrieves the first identifier, it can delete it to prevent repeated retrieval of the same recorded first identifier, thus avoiding repeated triggering of the highlight adjustment window. Furthermore, deleting the first identifier after retrieval ensures that even if a preset event is detected without input, the laptop will not further adjust the highlight based on the undeleted first identifier, preventing erroneous highlight adjustments in the absence of input.

[0131] In some scenarios, input events may not trigger focus switching, object movement, or object destruction; consequently, the laptop will not detect the preset event. For example, if a user clicks on an empty area on the desktop, causing focus to switch to the desktop, and then clicks the same empty area again, the laptop can detect the input event corresponding to this second click. However, this input event neither causes focus switching nor object movement or destruction, and the laptop will not detect the preset event. As explained above, after detecting an input event, the laptop executes steps S404-S407, recording a first identifier. Since no preset event is detected, the laptop will not execute step S402 to query the first identifier, nor will it further delete the first identifier. Therefore, in some embodiments, the laptop can delete the first identifier again after each new input event is detected. This way, even if the previous input event did not trigger the detection of a preset event, the laptop can delete the first identifier after a new input event arrives, avoiding repeatedly querying the same first identifier recorded previously.

[0132] During the execution of S404-S407, the laptop may detect a new input event. For example, after a user clicks an application icon, the laptop can detect the input event and execute S404-S407. If the user clicks another application icon within a very short interval, the laptop can detect another new input event. Because the interval between the two clicks is very short, less than the duration of S404-S407 (e.g., 100ms, 150ms, etc.), the laptop may not have finished executing S404-S407 when it detects the new input event. To address this scenario, in some embodiments, the laptop can discard the new input event. After discarding the new input event, the laptop does not need to wait for the currently executing S404-S407 to complete before re-executing S404-S407 for the new input event. It is understood that waiting for the currently executing S404-S407 to complete takes time, which will result in a higher latency in executing S404-S407 for subsequent new input events, thus leading to a higher response delay for new input events. It is evident that discarding new input events can prevent excessive delays in responding to new input events from negatively impacting the user experience, such as delays in highlighting adjustments caused by generating the first identifier too late.

[0133] It should be noted that the execution order of S401-S402 and S403-S407 is not limited by their numerical values. In actual implementation, after activating Focus Mode, the laptop can execute S401 and S403. On the one hand, after S401 detects a preset event, it continues to execute S402. On the other hand, after S403 detects an input event, it continues to execute S404 and its subsequent steps.

[0134] S408. Obtain the active window and adjust its highlight.

[0135] After retrieving the first identifier in S402, the laptop can obtain and highlight the active window, thus highlighting the active window after a focus switch. For example, after launching an application, the laptop can highlight the window of the launched application.

[0136] In some embodiments, the laptop computer can set a mask with a certain degree of transparency under the active window to cover windows outside the active window, thereby highlighting the active window.

[0137] See Figure 5The display shows windows 501, 502, and 503, arranged hierarchically from top to bottom. Window 501 is on top, window 503 is on the bottom, and window 502 is between windows 501 and 503. The laptop identifies window 501 as the active window and can then place a mask 504 below window 501 and above window 502. Mask 504 can be a gray or black window with some transparency. In this way, mask 504 covers windows 502 and 503 but not window 501. Therefore, the brightness of the area outside window 501 is reduced, creating the effect of highlighting window 501.

[0138] For example, the preceding text Figure 2 Substitute the various windows in interface 202 shown Figure 5 In the diagram, the correspondence is as follows: dialog window 2021 corresponds to window 501, video playback window 1021 corresponds to window 502, desktop 101 corresponds to window 503, and the window containing the diagonal line corresponds to mask 504. Figure 2 In the interface 202 shown, by covering the video playback window 1021 and the desktop 101 with the window containing the diagonal line, the effect of highlighting the dialog window 2021 can be achieved.

[0139] certainly, Figure 5 The number, size, and shape of the front-end windows shown are merely illustrative and are not limited to in actual implementation.

[0140] Furthermore, the method of highlighting is not limited to setting a mask as described above. In other embodiments, the laptop can also reduce the screen brightness of areas other than the active window to achieve highlighting of the active window. The following explanation will primarily focus on setting a mask.

[0141] In one specific implementation, see Figure 6 S408 includes the following steps:

[0142] S4080, Get the focus window.

[0143] Laptops can acquire the focused window and then use that window to determine the active window.

[0144] S4081. Check if the time interval between the two most recent triggers of adjusting the highlight display exceeds the seventh time period. If yes, execute S4082; otherwise, do not adjust the mask.

[0145] The time interval between the two most recent triggers for adjusting the highlight display can be the time interval between the two most recent queries of the first identifier, or the time interval between the two most recent acquisitions of the focus window.

[0146] If the time interval between the two most recent triggers of highlight adjustment does not exceed the seventh time period, such as 500ms, it indicates that some frequent preset events and input events may be triggering the highlight adjustment continuously. The laptop can avoid adjusting the mask to avoid continuous invalid adjustments, such as ensuring that the highlight effect is the same before and after adjustment.

[0147] For example, the preset events include object movement events, such as when a user slides the mouse and clicks continuously on a blank area of ​​the desktop. The laptop can frequently detect input events and record the first identifier, and can also frequently detect object movement events and query the first identifier, thereby frequently triggering adjustments to the highlight display and the window to be focused. In this scenario, S4081 can be used to detect that the time interval between the two most recent windows to be focused does not exceed the seventh time period, so the highlight display will not be adjusted frequently.

[0148] If the time interval between the two most recent triggers of highlight adjustment exceeds the seventh time period, it indicates that the highlight adjustment is being triggered normally, and the laptop can further perform the highlight adjustment steps, such as performing S4082 and subsequent steps as described below.

[0149] S4082. Check if the process corresponding to the focused window is in the whitelist of focus mode. If yes, execute S4083 and S4084; otherwise, execute S4085.

[0150] Laptops can use Focus Mode for some processes (or applications) and not for others. For example, Focus Mode may not be used for processes such as the desktop and the bottom taskbar. Based on this, laptops can maintain a whitelist for Focus Mode. If the process corresponding to the focused window is in the whitelist, it can be highlighted, and the laptop can execute steps S4803 and S4804 to perform the highlighting operation. If the process corresponding to the focused window is not in the whitelist, such as if the focused window's process is the desktop process, it does not need to be highlighted, and the laptop can execute step S4805 to disable highlighting.

[0151] In some embodiments, the laptop can also be configured with a blacklist for Focus Mode. Accordingly, S4082 above can be replaced by: detecting whether the process corresponding to the focused window is in the blacklist of Focus Mode. If yes, then execute S4085; if no, then execute S4083 and S4084.

[0152] In other embodiments, the laptop computer can also be configured with a whitelist and a blacklist for the focus mode. Accordingly, S4082 above can be replaced with: detecting whether the process corresponding to the focus window is in the whitelist or blacklist. Further, the three detection results and processing methods are as follows:

[0153] (1) If the process corresponding to the focus window is detected to be in the whitelist, then execute S4083 and S4084.

[0154] (2) If the process corresponding to the focus window is detected to be in the blacklist, then execute S4085.

[0155] (3) If the process corresponding to the focused window is not detected in the whitelist or blacklist, no processing is required this time; neither S4083 nor S4084 nor S4085 will be executed. In this way, for some newly emerging processes, such as the process of a newly installed application, if it is unclear whether the process can use focus mode, the laptop can not adjust the highlight display, thus avoiding unreasonable highlight adjustment.

[0156] Furthermore, regarding point (3) above, after confirming (e.g., confirmation by the configuration personnel) that the process corresponding to the focus window can use focus mode, the process corresponding to the focus window can be added to the whitelist; or, after confirming that the process corresponding to the focus window does not use focus mode, the process corresponding to the focus window can be added to the blacklist. In this way, newly appearing processes can also be added to the whitelist or blacklist. Subsequently, when the process corresponding to the focus window is detected again, the response can be based on whether it is in the whitelist or the blacklist, allowing for accurate adjustment of the highlight display for newly appearing processes.

[0157] It should be noted that S4081 and / or S4082 can be omitted, or the order of S4081 and S4082 can be interchanged.

[0158] S4803: Enumerate windows to get the top-level window to which the focused window belongs.

[0159] If the process corresponding to the focused window is in the whitelist, the laptop can enumerate all windows, find the top-level window and its child windows and buttons, and thus determine the top-level window of the focused window. For example, if the focused window is child window X, and the top-level window of child window X is top-level window Y, the laptop can determine that the top-level window of the focused window is top-level window Y.

[0160] Furthermore, as mentioned in the preceding introduction, the top-level window of the focused window is the active window. Therefore, obtaining the top-level window of the focused window is equivalent to obtaining the active window.

[0161] S4084. Set a mask below the top-level window of the focused window. That is, set a mask below the active window. For details on the principle, please refer to the previous text. Figure 5 The details of that will not be repeated here.

[0162] S4085, Hide Mask.

[0163] If the process corresponding to the focused window is not in the whitelist, the laptop can hide the mask, thus restoring the full-screen highlighted state instead of only highlighting the active window.

[0164] To facilitate understanding of the embodiments described above, the implementation and effects of these embodiments will be further introduced below in conjunction with several specific scenarios.

[0165] Scenario 3: Launch the application.

[0166] See Figure 7 The laptop displays interface 102 with focus on the video playback window 1021, which is then highlighted. The user clicks the application icon 1022 of the chat application on the desktop 101 in interface 102, triggering the laptop to launch the chat application.

[0167] At time t1, when the laptop executes S403, it detects a click event on application icon 1022 and begins executing S404 and subsequent steps. During S405, the laptop detects process creation, then executes S406, waits for a second duration, and at time t3, the window is created, executing S407 to record the first identifier.

[0168] After receiving a user click on application icon 1022, the laptop switches the focus from the video playback window 1021 to the desktop 101. At time t2, when the laptop executes S401, it can detect the preset event corresponding to the focus switching from the video playback window 1021 to the desktop 101, and then executes S402. However, since the first identifier is recorded only at time t3 after time t2, and the first identifier does not exist at time t2, S402 cannot find the first identifier, and S408, which adjusts the highlighted window, will not be executed. Therefore, the window will not be highlighted in full screen after the focus switches to the desktop 101.

[0169] After the chat application's dialog window 2021 is created and displayed, the laptop switches its focus from desktop 101 to dialog window 2021. At time t4, when the laptop executes S401, it detects the preset event corresponding to the focus switching from desktop 101 to dialog window 2021, then executes S402. Since the first identifier was recorded at time t3, it exists and can be found in S402. Then, at time t5, the laptop executes S408, highlighting dialog window 2021.

[0170] The time interval from t1 to t4 can also be called the first time interval, and t5 can also be called the second time interval. t3 can also be called the seventh time interval, t2 can also be called the eighth time interval, and t4 can also be called the ninth time interval.

[0171] In the above Figure 7 In scenario 3, two focus switches occur: from the video playback window 1021 to the desktop 101, and from the desktop 101 to the chat window 2021. The laptop can detect these two preset events. However, when the focus switch occurs from the video playback window 1021 to the desktop 101, there is no first identifier, and the laptop will not adjust the highlighted window, nor will there be any flickering of full-screen highlighting. Furthermore, when the focus switch occurs from the desktop 101 to the chat window 2021, there is a first identifier. Based on this first identifier, the laptop can highlight the chat window 2021, and thus adjust the highlight only after the chat application is launched and the focus is switched to the chat window 2021.

[0172] Scenario 4: Close the application.

[0173] See Figure 8 The laptop displays interface 301 with the focus on desktop 101, and the laptop is displayed in full-screen mode. The user clicks the close button 3011 on the chat window 2021 in interface 301, triggering the laptop to close the chat application.

[0174] At time t6, when the laptop executes S403, it detects a click event on the close button 3011 and begins executing S404 and subsequent steps. During S405, the laptop can detect that a process has been destroyed, so it can proceed to S406, wait for the second duration, wait until time t8, when the window is destroyed, execute S407, and record the first identifier.

[0175] After receiving a user's click on the close button 3011, the laptop can switch the focus from the desktop 101 to the dialog window 2021. At time t7, when the laptop executes S401, it detects the preset event corresponding to the focus switching from the desktop 101 to the dialog window 2021, and then executes S402. However, since the first identifier is only recorded at time t8 after time t7, and the first identifier does not exist at time t7, it cannot be found in S402, and S408 will not be executed to adjust the highlighted window. Therefore, the dialog window 2021 will not be highlighted after the focus is switched to it.

[0176] After dialog window 2021 is destroyed and no longer displayed, the laptop switches focus from dialog window 2021 to video playback window 1021. At time t9, when the laptop executes S401, it can detect the preset event corresponding to the focus switching from dialog window 2021 to video playback window 1021, and then executes S402. Since the first identifier was recorded at time t8, the first identifier exists and can be queried in S402. Then, at time t10, the laptop executes S408, highlighting video playback window 1021.

[0177] The time interval t6 can also be called the third time interval, the time interval from t7 to t9 can also be called the second time interval, and t10 can also be called the fourth time interval. t8 can also be called the tenth time interval, t7 can also be called the eleventh time interval, and t9 can also be called the twelfth time interval.

[0178] In scenario 4 above, two focus switches occur: one from desktop 101 to chat window 2021, and the other from chat window 2021 to video playback window 1021. The laptop can detect these two corresponding preset events. However, when the focus switch occurs from desktop 101 to chat window 2021, there is no first identifier, so the laptop will not adjust the highlighted window, and there will be no full-screen non-highlighted flickering. Furthermore, when the focus switch occurs from chat window 2021 to video playback window 1021, there is a first identifier. Based on this first identifier, the laptop highlights video playback window 1021, thus adjusting the highlight only after the chat application is closed and the focus is switched to video playback window 1021.

[0179] Scenario 5: Switching applications.

[0180] See Figure 9The laptop displays interface 202 with focus on dialog window 2021, which is then highlighted. When the user clicks on video playback window 1021 in interface 202, the laptop switches video playback window 1021 to the active window.

[0181] At time t11, the laptop executes S403, detects a click event on the video playback window 1021, and begins executing S404 and subsequent steps. During S405, the laptop detects that no processes are being created or destroyed, so it skips S406 and proceeds to S407. At time t12, S407 is completed, and the first identifier is recorded. This demonstrates that in application switching scenarios, the laptop can quickly record the first identifier.

[0182] After receiving a user's click on the video playback window 1021, the laptop can switch the focus from the dialog window 2021 to the video playback window 1021. At time t13, when the laptop executes S401, it can detect the preset event corresponding to the focus switching from the dialog window 2021 to the video playback window 1021, and then executes S402. Since the first identifier was recorded at time t12, the first identifier exists and can be queried in S402. Then, at time t14, the laptop executes S408, displaying interface 901 (also known as the sixth interface), in which the video playback window 1021 is highlighted.

[0183] The time t11 mentioned above can also be called the fifth time, and the time t14 can also be called the sixth time. The time t12 can also be called the thirteenth time, and the time t13 can also be called the fourteenth time.

[0184] In scenario 5 above, a focus switch occurs from dialog window 2021 to video playback window 1021. The laptop can detect the corresponding preset event. Furthermore, since it is an application switching scenario, the laptop can quickly record the first identifier after detecting the input event without waiting for a second duration. This allows the laptop to highlight the video playback window 1021 based on the first identifier after detecting the preset event, thereby highlighting the active window after the switch.

[0185] Therefore, it should be noted that the first waiting time is shorter than the eighth waiting time. The eighth waiting time is the time interval between detecting an input event and detecting a preset event corresponding to a focus switch matching the input event in the application switching scenario. The eighth waiting time can be obtained by statistically analyzing historical data from multiple application switching sessions; for example, the eighth waiting time can be the shortest or average time between detecting an input event and detecting a preset event corresponding to a focus switch matching the input event during multiple application switching sessions. Thus, recording the first identifier after the first waiting time allows the first identifier to be recorded before detecting a focus switch matching the input event in the application switching scenario. Figure 9 As shown, the first identifier is recorded at time t12, which is before time t13.

[0186] Scenario 6: Two applications are launched consecutively at different time intervals.

[0187] See Figure 10 The laptop displays desktop 101, with focus on desktop 101. The user sequentially clicks the video application icon 1011 and the chat application icon 1022 on desktop 101, as shown in the diagram (① and ② indicating the click order). This sequentially launches the video application and the chat application on the laptop. The time interval between clicks ① and ② is very short, within 100ms.

[0188] The laptop executes S403, first detecting the input event corresponding to ①, then executing S404-S407 to record the first identifier. Subsequently, the laptop executes S401, which can detect the preset event corresponding to the focus switching to the video playback window 1021, then executes S402, finds and deletes the first identifier, and then executes S408, which can present the effect of highlighting the video playback window 1021 as shown in interface 102.

[0189] After detecting the input event corresponding to ①, the laptop executes S403. It can also detect the input event corresponding to ②, but since the time interval between ① and ② is very short, and the laptop is still executing S404-S407, the laptop can discard the input event corresponding to ② and will not record the first identifier. Subsequently, the laptop executes S401 and can detect the preset event corresponding to the focus switching to dialog window 2021. Then it executes S402, but cannot find the first identifier, so it will not execute S408 and will not adjust the highlight. If the mask is still placed below the video playback window 1021, the laptop can present the effect of highlighting both the video playback window 1021 and the dialog window 2021 as shown in interface 1001, without switching to highlighting the dialog window 2021 alone.

[0190] See also Figure 10 The user can click the application icon 10011 of the browser application on the desktop 101 in interface 1001, indicated by ③ in the diagram. The time interval between the two clicks ② and ③ is relatively long, exceeding the duration of the ninth step. Afterwards, the laptop can execute S401-S408, ultimately presenting the effect of highlighting the browser window 10021 as shown in interface 1002. This process is similar to the process of launching the chat application in scenario 3 above, and will not be described again here.

[0191] In scenario 6 above, the video application, chat application, and browser application were launched sequentially. The time interval between launching the video and chat applications was very short; within the ninth time period, the laptop only highlighted the video playback window 1021 after the video application launched, but did not further highlight it after the chat application launched. Conversely, the time interval between launching the chat and browser applications was longer, exceeding the ninth time period; the laptop only highlighted the browser window 10021 after the browser application launched.

[0192] In other scenarios (such as scenario 7), the time interval between triggering the launch of video and chat applications is longer, exceeding the ninth time interval. In this scenario, the laptop can sequentially highlight the video playback window and the chat window, as shown in interfaces 102 and 202 above.

[0193] The preceding text mainly used a laptop computer as the execution subject to introduce the embodiments of this application. The following text will further describe the embodiments of this application in detail, taking into account the hardware and software configuration of a laptop computer.

[0194] Figure 11 This is a hardware structure diagram of a laptop computer provided as an embodiment of this application. Figure 11 As shown, a laptop computer may include a processor 110, an external storage interface 120, an internal storage 121, a universal serial bus (USB) connector 130, a charging management module 140, a power management module 141, a battery 142, a communication module 150, an audio module 170, a sensor module 180, a keyboard 190, a display screen 194, etc.

[0195] It is understood that the structures illustrated in the embodiments of this application do not constitute a specific limitation on the laptop computer. In other embodiments of this application, the laptop computer may include more or fewer components than illustrated, or combine some components, or split some components, or have different component arrangements. The illustrated components may be implemented in hardware, software, or a combination of software and hardware.

[0196] Processor 110 may include one or more processing units, such as application processors (APs), modem processors, graphics processing units (GPUs), image signal processors (ISPs), controllers, video codecs, digital signal processors (DSPs), baseband processors, and / or neural network processing units (NPUs). These different processing units may be independent devices or integrated into one or more processors.

[0197] The processor 110 may also include a memory for storing instructions and data. In some embodiments, the memory in the processor 110 may be a cache memory. This memory can store instructions or data that the processor 110 has used or that are used frequently. If the processor 110 needs to use the instruction or data, it can directly retrieve it from this memory. This avoids repeated accesses, reduces the waiting time of the processor 110, and thus improves the efficiency of the system.

[0198] In some embodiments, the processor 110 may include one or more interfaces for connecting modules such as an audio module, a communication module, and a display screen.

[0199] It is understood that the interface connection relationships between the modules illustrated in the embodiments of this application are merely illustrative and do not constitute a limitation on the structure of the laptop computer. In other embodiments of this application, the laptop computer may also employ different interface connection methods or combinations of multiple interface connection methods as described in the above embodiments.

[0200] The USB connector 130 is a USB standard-compliant interface used to connect laptops and peripheral devices. Specific types include Mini USB, Micro USB, and USB Type-C connectors. The USB connector 130 can be used to connect a charger to charge the laptop, or to connect other electronic devices to enable data transfer between the laptop and other electronic devices.

[0201] In this embodiment, the USB connector 130 can also be used to connect devices such as a mouse and an external keyboard, enabling the laptop to receive input events from the mouse and external keyboard. It should be noted that the external keyboard and the laptop's built-in keyboard 190 are two different keyboards, and the laptop can also receive input events from the keyboard 190.

[0202] The charging management module 140 receives charging input from a charger. The charger can be a wireless charger or a wired charger. In some wired charging embodiments, the charging management module 140 receives charging input from the wired charger via a USB connector 130. In some wireless charging embodiments, the charging management module 140 receives wireless charging input via the wireless charging coil of a laptop computer. While charging the battery 142, the charging management module 140 can also supply power to the electronic device via the power management module 141.

[0203] The power management module 141 is used to connect the battery 142, the charging management module 140, and the processor 110. The power management module 141 receives input from the battery 142 and / or the charging management module 140 to supply power to the processor 110, internal memory 121, display screen 194, communication module 150, etc.

[0204] The communication functions of a laptop computer can be implemented through the communication module 150. The communication module 150 can provide wireless communication solutions for laptop computers, including 2G / 3G / 4G / 5G. The wireless communication module 150 can also provide wireless communication solutions for laptop computers, including wireless local area networks (WLAN) (such as wireless fidelity (Wi-Fi) networks), Bluetooth (BT), Bluetooth Low Energy (BLE), ultra-wideband (UWB), global navigation satellite system (GNSS), frequency modulation (FM), near-field communication (NFC), and infrared (IR) technologies.

[0205] A laptop computer can achieve display functionality through a GPU, a display screen 194, and an application processor. The GPU is a microprocessor for image processing, connecting the display screen 194 and the application processor. The GPU is used to perform mathematical and geometric calculations for graphics rendering. The processor 110 may include one or more GPUs, which execute program instructions to generate or modify display information.

[0206] The display screen 194 is used to display images, videos, etc. In this embodiment, in focus mode, the display screen 194 can be used to highlight the focus window.

[0207] The external storage interface 120 can be used to connect an external storage card, such as a Micro SD card, to expand the storage capacity of the laptop. The external storage card communicates with the processor 110 through the external storage interface 120 to perform data storage functions. For example, it can save music, video, and other files to the external storage card, or transfer music, video, and other files from the electronic device to the external storage card.

[0208] Internal memory 121 can be used to store executable program code, including instructions. Internal memory 121 may include a program storage area and a data storage area. The program storage area may store the operating system, applications required for at least one function (such as sound playback, image playback, etc.), etc. The data storage area may store data created during the use of the laptop (such as audio data, phonebook, etc.). Furthermore, internal memory 121 may include high-speed random access memory and may also include non-volatile memory, such as at least one disk storage device, flash memory device, universal flash storage (UFS), etc. Processor 110 executes various functional methods or data processing of the laptop by running instructions stored in internal memory 121 and / or instructions stored in memory disposed within the processor.

[0209] In some embodiments, sensor module 180 includes a touch sensor disposed on display screen 194. The touch sensor and display screen 194 together form a touchscreen, also known as a "touchscreen". The touch sensor is used to detect touch operations performed on or near it. The touch sensor can transmit the detected touch operation to the application processor to determine the type of touch event (i.e., touchscreen input event).

[0210] Laptops can implement audio functions through audio modules (170), such as speakers, receivers, microphones, headphone jacks, and application processors. Examples include music playback and recording.

[0211] Laptop computer software systems can adopt layered architecture, event-driven architecture, microkernel architecture, microservice architecture, or cloud architecture. This application uses a layered Windows system as an example to illustrate the software structure of a laptop computer.

[0212] Figure 12 This is a software architecture diagram of a laptop computer provided in an embodiment of this application. The layered architecture divides the software into several layers, each with a clear role and function. Layers communicate with each other through software interfaces. In some embodiments, the Windows system is divided into an application layer, an operating system (OS) layer, and a peripheral layer.

[0213] Understandable. Figure 12 This is merely an exemplary hierarchical division; in actual implementation, it may include more... Figure 12 The embodiments of this application do not specifically limit the number of layers shown, such as application framework layer, hardware abstraction layer, kernel layer, etc.

[0214] The application layer can include a range of applications, such as desktop applications, video applications, chat applications, email applications, music applications, etc.

[0215] In some embodiments, the application layer may also include a manager application. The manager application can be used to obtain the focused window.

[0216] In this embodiment, the highlighted focus window of the laptop can be the window of any of the above-mentioned applications, such as the window of a chat application, the window of a video application, etc.

[0217] In some embodiments, the application layer may also include a mask application. The mask application can be used to set a mask so that the focus window can be highlighted. Specifically, the mask application can set a mask below the focus window. By covering the focus window with the mask, the brightness of the area outside the focus window is reduced, thereby highlighting the focus window. The set mask can be understood as a window, and the mask can cover the entire display area of ​​the screen.

[0218] The operating system layer can provide system services. This layer may include process management modules and window management modules.

[0219] The process management module can be used to create and destroy processes. For example, after starting the application, the process management module can create the application process. Conversely, after closing the application, the process management module can destroy the application process.

[0220] The window management module can be used to detect preset events. Preset events may trigger a switch in the focus window. For example, preset events include focus window change events, object movement events, object destruction events, etc.

[0221] The peripheral layer manages various external devices connected to the laptop, such as mice and keyboards. It can include drivers and interfaces for these devices, as shown in the diagram for mouse and keyboard drivers. The drivers enable the corresponding external devices and facilitate communication between them and other modules within the laptop. The interfaces allow for connecting external devices.

[0222] The display method provided in this application embodiment can be executed in a laptop computer with the above-described hardware and software structure. See also Figure 13The display methods include:

[0223] S1300, the manager application registers a listener for preset events with the window management module. The preset events can indicate when a focus switch occurs.

[0224] For example, a management application can register listeners for preset events through Windows HOOK operations.

[0225] After registering a listener for a preset event, the management application will notify the management application when the preset event is detected.

[0226] In one specific implementation, after enabling focus mode, the manager application can register listeners for preset events.

[0227] S1301, The management application detects input events. Please refer to the previous section on S403 for details.

[0228] After the management application detects the input event, it can trigger the subsequent process of generating the first identifier, as shown in S1307-S1310 below.

[0229] In one specific implementation, after the focus mode is enabled, the manager application can continuously execute S1301, such as periodically triggering the execution of S1301, thereby continuously detecting user input.

[0230] S1302, the window management module detects preset events. See the previous section on S401 for details.

[0231] After the window management module detects the preset event, it can trigger the subsequent process of adjusting the highlighted window, as shown in S1311-S1318 below.

[0232] In one specific implementation, after the window management module is started, S1302 can be executed continuously, such as periodically repeating S1302, so as to continuously detect the switching of the focus window.

[0233] S1303, Input driver receives input signals.

[0234] The input driver includes, but is not limited to, at least one of the following: the driver for an external keyboard (such as...). Figure 12 The peripheral layer includes the keyboard driver, mouse driver, built-in keyboard driver, and touchscreen driver.

[0235] After the user operates the input device, the input device can generate an input signal and transmit it to the input driver.

[0236] S1304, The input driver sends input signals to the window management module.

[0237] After receiving an input signal, the input driver can send an input event to the window management module, enabling the window management module to respond to user input.

[0238] S1305, The input driver sends input signals to the management application.

[0239] After receiving an input signal, the input driver can also send an input signal to the management application, allowing the management application to obtain each input.

[0240] After receiving an input signal, the window management module can execute the following S1306.

[0241] S1306 The window management module identifies and responds to input events corresponding to input signals.

[0242] In some embodiments, the window management module interacts with the process management module, applications, etc., to respond to input events.

[0243] For example, when the input event is detected as a click on an application icon on the desktop, the window management module can notify the process management module to create a process for the application, and the window management module can create a window for the application to launch the application.

[0244] For example, when the input event is detected as a click operation on the close button of the focused window, the window management module can send a close notification to the corresponding application. After the application confirms the close, it can notify the process management module to destroy the process and notify the window management module to destroy the window.

[0245] After receiving the input signal, the management application can execute the following steps S1307-S1301 to generate the first identifier.

[0246] S1307: The management application receives an input signal, detects an input event, and waits for the first duration. See the previous section on S404 for details.

[0247] Receiving an input signal means that an input event has occurred, and the management application can detect the input event.

[0248] The initial waiting period allows sufficient time to respond to input events, such as process creation and process destruction.

[0249] S1308: The management application checks if any processes have been created or destroyed; if so, executes S1309 and S1310; otherwise, executes S1310. See the previous section on S405 for details.

[0250] In one specific implementation, the management application can query the process management module to see if any processes have been created or destroyed, such as querying whether any processes have been created or destroyed between receiving an input signal and waiting for the first duration.

[0251] If a process is created or destroyed, that is, if the window management module creates or destroys a process in response to an input event in S1306, the manager application must wait until the window is created or destroyed before recording the first identifier, that is, executing S1309 and S1310 below.

[0252] If no process is created or destroyed, meaning that the window management module does not create or destroy a process in response to the input event in S1306, the manager application can record the first identifier without waiting for the window to be created or destroyed, and thus execute the following S1310.

[0253] In other words, the management application can determine when to generate the first identifier based on the response to input events (including process creation or destruction), so that the first identifier is recorded before a focus switch that matches the input event is about to occur.

[0254] S1309, Waiting time for the management application is now set for the second time. Please refer to the previous section on S406 for details.

[0255] For cases where a process is being created, waiting for a second duration allows sufficient time to create the window.

[0256] In cases where processes are being destroyed, waiting for a second duration allows for a sufficient window of time for the destruction process.

[0257] S1310, the administrator application records the first identifier, which indicates a focus switch that matches an input event. See the description of S407 above for details.

[0258] The window management module can detect preset events. Specifically, during or after responding to an input event, the focus window may switch, and the window management module may detect the preset event. After detecting the preset event, the following steps S1311-S1312 can be executed to determine whether to adjust the highlighted window.

[0259] S1311. After detecting a preset event, the window management module sends a first notification to the manager application.

[0260] The first notification instructs the management application to determine whether a focus switch matching an input event has occurred.

[0261] S1312: The management application checks if the first identifier exists. If yes, proceed to S1313; otherwise, continue checking for preset events. See the previous section on S402 for details.

[0262] If no first identifier is found, it indicates that no focus switch matching the input event has occurred, and it may only be an intermediate focus window switch. In this case, the highlighted window will not be adjusted to avoid flickering.

[0263] If the first identifier is found, it indicates that a focus switch has occurred due to an input event matching. The highlighted window can be adjusted as shown in S1313-S1318 below.

[0264] S1313, The manager app sends a second notification to the masked app.

[0265] The second notification can instruct the mask application to set a mask, thereby adjusting the highlighted window.

[0266] S1314, Mask application gains focus window. See the previous section on S4080 for details.

[0267] In one specific implementation, the window management module can acquire the focus window after detecting a preset event. The mask application can then acquire the focus window from the window management module.

[0268] S1315: The mask application checks whether the time interval between the two most recent triggers of highlight adjustment exceeds the seventh time period. If yes, then execute S1316; otherwise, the mask is not adjusted. See the previous description of S4081 for details.

[0269] S1316: The mask application checks whether the process corresponding to the focused window is in the whitelist of focus mode. If yes, execute S1317 and S1318; otherwise, execute S1319. See the previous description of S4082 for details.

[0270] S1317: Apply a mask to the enumerated window to obtain the top-level window of the focused window. See the previous section on S4083 for details.

[0271] S1318. A mask is applied to the layer below the top-level window of the focused window. See the previous section on S4084 for details.

[0272] S1319, Hide Mask. See the previous section on S4085 for details.

[0273] This application also provides an electronic device, which may include a memory and one or more processors (such as a CPU, GPU, NPU, etc.). The memory and processor are coupled. The memory is used to store computer program code, which includes computer instructions. When the processor executes the computer instructions, the electronic device can perform various functions or steps performed by the device in the above method embodiments.

[0274] This application also provides a chip system including at least one processor and at least one interface circuit. The processor and the interface circuit are interconnected via lines. For example, the interface circuit can be used to receive signals from other devices (e.g., the memory of an electronic device). As another example, the interface circuit can be used to send signals to other devices (e.g., the processor). Exemplarily, the interface circuit can read instructions stored in the memory and send the instructions to the processor. When the instructions are executed by the processor, the electronic device can perform the steps in the above embodiments. Of course, the chip system may also include other discrete devices, and this application does not specifically limit this.

[0275] This embodiment also provides a computer storage medium storing computer instructions. When the computer instructions are executed on an electronic device, the electronic device performs the aforementioned method steps to implement the image processing method described above.

[0276] This embodiment also provides a computer program product that, when run on a computer, causes the computer to perform the aforementioned steps to implement the image processing method described above.

[0277] In addition, embodiments of this application also provide an apparatus, which may specifically be a chip, component, or module. The apparatus may include a connected processor and a memory; wherein the memory is used to store computer execution instructions, and when the apparatus is running, the processor may execute the computer execution instructions stored in the memory to cause the chip to execute the image processing methods in the above-described method embodiments.

[0278] In this embodiment, the electronic device, computer storage medium, computer program product or chip are all used to execute the corresponding method provided above. Therefore, the beneficial effects that can be achieved can be referred to the beneficial effects of the corresponding method provided above, and will not be repeated here.

[0279] Through the above description of the embodiments, those skilled in the art can clearly understand that, for the sake of convenience and brevity, only the division of the above functional modules is used as an example. In actual applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the device can be divided into different functional modules to complete all or part of the functions described above.

[0280] In the several embodiments provided in this application, it should be understood that the disclosed apparatus and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative. For instance, the division of modules or units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another device, or some features may be ignored or not executed. Furthermore, the mutual coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between devices or units may be electrical, mechanical, or other forms.

[0281] The unit described as a separate component may or may not be physically separate. The component shown as a unit can be one physical unit or multiple physical units, that is, it can be located in one place or distributed in multiple different places. Some or all of the units can be selected to achieve the purpose of the solution in this embodiment according to actual needs.

[0282] Furthermore, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.

[0283] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a readable storage medium. Based on this understanding, the technical solutions of the embodiments of this application, essentially or in other words, the parts that contribute to the prior art, or all or part of the technical solutions, can be embodied in the form of a software product. This software product is stored in a storage medium and includes several instructions to cause a device (which may be a microcontroller, chip, etc.) or processor to execute all or part of the steps of the methods of the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0284] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of this application and are not intended to limit it. Although this application has been described in detail with reference to preferred embodiments, those skilled in the art should understand that modifications or equivalent substitutions can be made to the technical solutions of this application without departing from the spirit and scope of the technical solutions of this application.

Claims

1. A display method, characterized in that, include: The first interface is displayed, the first interface includes a first window, the first window includes a first icon and a second icon, the first icon is the application icon of a first application, and the second icon is the application icon of a second application; In response to a trigger operation on the first icon, a second interface is displayed, the second interface including a first window and a second window, the second window being the window of the first application; In the second interface, the display brightness of the second window is higher than the display brightness of the display portion of the first window; At the first moment, receive the trigger operation on the second icon; The second interface is displayed during a first time interval, which is located after the first moment. After the second time interval, a third interface is displayed, which includes the first window, the second window, and the third window, which is the window of the second application; in the third interface, the display brightness of the third window is higher than the display brightness of the display portion of the first window and higher than the display brightness of the display portion of the second window; the second time interval is after the first time interval. Specifically, during the first time interval, the focus is located in the first window, and after the second time interval, the focus is located in the third window.

2. The method according to claim 1, characterized in that, After displaying the third interface, the method further includes: In response to a trigger operation on the first window, a fourth interface is displayed, the fourth interface including the first window, the second window and the third window, the first window, the second window and the third window having the same display brightness; At the third moment, a trigger operation is received on the close button in the third window; The fourth interface is displayed during the second time interval, which is after the third time interval. After the fourth moment, a fifth interface is displayed, which includes the first window and the second window. The display brightness of the second window is higher than the display brightness of the area in the fifth interface other than the second window. The fourth moment is located after the second time interval. Specifically, during the second time interval, the focus is located in the third window, and after the fourth time interval, the focus is located in the second window.

3. The method according to claim 1 or 2, characterized in that, After displaying the third interface, the method further includes: At the fifth moment, a trigger operation on the second window is received; After the sixth moment, a sixth interface is displayed, which includes the first window and the second window; in the sixth interface, the display brightness of the second window is higher than the display brightness of the display portion of the first window, and higher than the display brightness of the display portion of the third window; the sixth moment is located after the fifth moment.

4. The method according to any one of claims 1-3, characterized in that, Displaying the second interface during the first time interval includes: Based on the absence of the first identifier, the second interface is displayed during the first time interval; The third interface is displayed after the second time point, including: Based on the presence of the first identifier, the third interface is displayed after the second time point; The first identifier is recorded after the third window is created.

5. The method according to claim 4, characterized in that, After receiving the trigger operation on the second icon, the method further includes: After waiting for a first duration after the first moment, it is detected that a process was created within the first duration. After waiting for a second duration, the first identifier is recorded at the seventh moment. Before displaying the second interface during the first time interval based on the absence of the first identifier, the method further includes: At the eighth moment, a first preset event is detected. In response to the first preset event, it is found that the first identifier does not exist. The eighth moment is located between the first moment and the seventh moment. Before displaying the third interface after the second time step based on the presence of the first identifier, the method further includes: At the ninth moment, a second preset event is detected. In response to the second preset event, the existence of the first identifier is found. The ninth moment is after the seventh moment. The first preset event and the second preset event indicate focus switching.

6. The method according to claim 2, characterized in that, The display of the fourth interface during the second time interval includes: Based on the absence of the first identifier, the fourth interface is displayed during the second time interval; The display of the fifth interface after the fourth time step includes: Based on the presence of the first identifier, the fifth interface is displayed after the fourth time step; The first identifier is recorded after the third window is destroyed.

7. The method according to claim 6, characterized in that, After receiving the trigger operation on the close button in the third window, the method further includes: After the third time, wait for a first duration, detect that the process was destroyed within the first duration, wait for a second duration, and record the first identifier at the tenth time. Before displaying the fourth interface in the second time interval based on the absence of the first identifier, the method further includes: At the eleventh moment, a third preset event is detected. In response to the third preset event, it is found that the first identifier does not exist. The eleventh moment is located between the third moment and the tenth moment. Before displaying the fifth interface after the fourth time step based on the presence of the first identifier, the method further includes: At the twelfth moment, a fourth preset event is detected. In response to the fourth preset event, the existence of the first identifier is found. The twelfth moment is after the tenth moment. The third preset event and the fourth preset event indicate focus switching.

8. The method according to claim 3, characterized in that, At the fifth moment, after receiving a trigger operation on the second window, the method further includes: After the fifth time, wait for the first duration, and record the first identifier at the thirteenth time; At the fourteenth moment, a fifth preset event is detected. In response to the fifth preset event, the existence of the first identifier is found. The fourteenth moment is after the thirteenth moment. The fifth preset event indicates a focus switch. The step of displaying the sixth interface after the sixth time point includes: Based on the presence of the first identifier, the sixth interface is displayed after the sixth time.

9. The method according to claim 5, 7 or 8, characterized in that, After the first identifier is found to exist, the method further includes: Delete the first identifier.

10. The method according to claim 9, characterized in that, The method further includes: Upon receiving an input event, delete the first identifier.

11. The method according to claim 5 or 7, characterized in that, The first duration is shorter than the second duration.

12. The method according to claim 5, 7 or 8, characterized in that, The first duration is greater than or equal to the third duration, and greater than or equal to the fourth duration; The third duration is the time between detecting the input event that triggers the application to start and completing the process creation, and the fourth duration is the time between detecting the input event that triggers the application to close and completing the process destruction.

13. The method according to claim 12, characterized in that, The first duration is less than the eighth duration, which is the duration between detecting the input event that triggers the application switching and the focus switching to the window of the switched application.

14. The method according to claim 5 or 7, characterized in that, The second duration is greater than or equal to the fifth duration, and greater than or equal to the sixth duration; The fifth duration is the time between the completion of process creation and the completion of window creation during the application startup process, and the sixth duration is the time between the completion of process destruction and the completion of window destruction during the application shutdown process.

15. An electronic device, characterized in that, include: A display panel, one or more processors, and one or more memories; the one or more processors are coupled to the display panel and the one or more memories; the one or more memories are used to store computer program code, the computer program code including computer instructions that, when the one or more processors execute the computer instructions, cause the electronic device to perform the method as described in any one of claims 1-14.

16. A computer-readable storage medium storing computer instructions thereon, characterized in that, When the computer instructions are executed on an electronic device, the electronic device causes the electronic device to perform the method as described in any one of claims 1-14.

17. A computer program product comprising computer instructions, characterized in that, When a computer program product is run on an electronic device, it causes the electronic device to perform the method as described in any one of claims 1-14.