Display device and display style control method
By introducing attribute validity identifiers and focus attribute adjustments in the display device, the problem that the display style does not meet user expectations when the remote control cursor is moved into and out of the control is solved, and the user experience is improved.
Patent Information
- Application Number
- CN202510571965.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-30
- Publication Date
- 2025-07-25
AI Technical Summary
In existing display devices, when the remote control cursor is moved in or out of the control, the display style of the control does not meet user expectations, resulting in poor user experience.
By introducing attribute validity marks in the display device, adjust the focus attributes and display style of the control according to the cursor's movement state, ensuring that the display style of the control matches the user's interaction behavior. For example, when the cursor is moved out of focus but not moved into other controls, keep the focus attributes of the control in the upper focus but the display style is out of focus.
It improves users' experience of display devices, makes the display style of the control more in line with user expectations, and the visual effects are more consistent and concise.
Smart Images

Figure CN120378676A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the technical field of display devices, and in particular, to a display device and a display style control method. Background Art
[0002] With the rapid development of display devices, the functions that display devices can provide for users are becoming increasingly rich. Remote controls are also gradually becoming intelligent. When the remote control has a pointing function and the pointing function is turned on, a cursor corresponding to the remote control will be displayed on the user interface. Currently, when the user controls the cursor corresponding to the remote control to move into or out of a control, the change in the display style of the control does not meet the user's expectations, resulting in a poor user experience. Summary of the Invention
[0003] This application provides a display device and a display style control method to solve the problem that the change in the display style of the control better meets the user's expectations.
[0004] In a first aspect, some embodiments provide a display device, including: a display configured to: display a user interface, the user interface including at least one control; the user interface further having a cursor, the position of the cursor on the user interface being determined by the position pointed to by the remote control in a three-dimensional space;
[0005] a processor configured to:
[0006] The control is provided with a focus attribute and an attribute validity flag; the focus attribute includes a focus-on attribute and a focus-off attribute;
[0007] Draw the display style of the control based on a first preset value or a second preset value of the attribute validity flag; wherein, setting the attribute validity flag to the first preset value is used to indicate that the control draws the corresponding display style according to the current focus attribute; setting the attribute validity flag to the second preset value is used to indicate that the control draws the corresponding display style according to the focus-off attribute;
[0008] Wherein, when it is detected that the cursor moves into the control, the focus attribute of the control is set to the focus-on attribute, and the attribute validity flag is set to the first preset value; and the display style corresponding to the focus-on attribute is drawn on the control based on the first preset value;
[0009] When it is detected that the cursor moves out of the control, the focus attribute of the control is maintained as the focus-on attribute, and the attribute validity flag of the control is set to the second preset value; and the display style corresponding to the focus-off attribute is drawn on the control based on the second preset value.
[0010] The above solution proposes the setting of the attribute validity flag. When the user performs an interaction behavior, the display device can control the display style of the control by changing the value of the attribute validity flag, so that the presentation of the control display style is visually matched with the interaction behavior performed by the user. For example, when the cursor moves out of a certain control but has not moved into another control, although the focus attribute of the control is still the previous focus attribute, the display style of the control changes to the display style corresponding to the out-of-focus attribute. Such a presentation is more in line with the user's expectations and improves the user experience of using the display device.
[0011] In some embodiments, the processor is configured to set the focus attribute of the control to the previous focus attribute, and set the attribute validity flag to a first preset value; and draw the display style corresponding to the previous focus attribute on the control based on the first preset value, and is further configured to: determine whether the current focus attribute of the control is the previous focus attribute; if it is not the previous focus attribute, set the focus attribute of the control to the previous focus attribute, and set the attribute validity flag to a first preset value; and draw the display style corresponding to the previous focus attribute on the control based on the first preset value; if it is the previous focus attribute, directly set the attribute validity flag to a first preset value; and draw the display style corresponding to the previous focus attribute on the control based on the first preset value.
[0012] In the above solution, when it is detected that the cursor moves into the control, an operation of judging the focus attribute of the control is added. When the focus attribute is not the previous focus attribute, the operation of setting the focus attribute to the previous focus attribute is performed, and when the focus attribute is the previous focus attribute, this operation is no longer performed, which can avoid repeated setting of the focus attribute.
[0013] In some embodiments, the control is a parent control, and the parent control includes at least one child control; the processor is configured to draw the display style corresponding to the previous focus attribute on the control based on the first preset value, and is further configured to: draw the display style corresponding to the previous focus attribute on the parent control and the at least one child control based on the first preset value; the processor is configured to draw the display style corresponding to the out-of-focus attribute on the control based on the second preset value, and is further configured to: draw the display style corresponding to the out-of-focus attribute on the parent control and the at least one child control based on the second preset value.
[0014] In the above solution, when the control includes at least one child control, drawing is synchronously performed on the parent control and the child controls, so that the parent control and the child controls as a whole present the previous focus effect or the out-of-focus effect, which is closer to the expected effect of the user and further improves the user experience.
[0015] In a second aspect, some embodiments further provide a display style control method, including:
[0016] When it is detected that the cursor moves into the control, set the focus attribute of the control to the top focus attribute, and set the attribute validity identifier of the control to the first preset value; and draw the display style corresponding to the top focus attribute on the control based on the first preset value.
[0017] When it is detected that the cursor moves out of the control, keep the focus attribute of the control as the top focus attribute, and set the attribute validity identifier of the control to the second preset value; and draw the display style corresponding to the out-of-focus attribute on the control based on the second preset value.
[0018] The above method proposes the setting of the attribute validity identifier. In the case where the user performs an interaction behavior, the display device can control the display style of the control by changing the value of the attribute validity identifier, so that the presentation of the control display style is visually matched with the interaction behavior performed by the user. For example, when the cursor moves out of a certain control but has not moved into another control, although the focus attribute of the control is still the top focus attribute, the display style of the control becomes the display style corresponding to the out-of-focus attribute. Such a presentation is more in line with the user's expectations and improves the user experience of using the display device. Description of the Drawings
[0019] In order to more clearly illustrate the technical solutions in the embodiments of the present application or the prior art, the following will briefly introduce the drawings required for use in the description of the embodiments or the prior art. Obviously, the drawings in the following description are only some embodiments of the present application. For those of ordinary skill in the art, without creative efforts, other drawings can also be obtained based on these drawings.
[0020] Figure 1 Schematic diagram of the operation scenario between the display device and the control device provided by some embodiments of the present application;
[0021] Figure 2 Schematic diagram of the hardware configuration of the display device provided by some embodiments of the present application;
[0022] Figure 3 Schematic diagram of the hardware configuration of the control device provided by some embodiments of the present application;
[0023] Figure 4 Schematic diagram of the software configuration of the display device provided by some embodiments of the present application;
[0024] Figure 5 Schematic diagram of cursor hovering provided by some embodiments of the present application;
[0025] Figure 6 Schematic diagram of a point press provided by some embodiments of the present application;
[0026] Figure 7 Selection schematic diagram provided for some embodiments of the present application;
[0027] Figure 8 Drag-and-select multiple schematic diagram provided for some embodiments of the present application;
[0028] Figure 9 Drag schematic diagram provided for some embodiments of the present application;
[0029] Figure 10 Swipe schematic diagram provided for some embodiments of the present application;
[0030] Figure 11 Continuous swipe schematic diagram provided for some embodiments of the present application;
[0031] Figure 12 Continuous reverse swipe schematic diagram provided for some embodiments of the present application;
[0032] Figure 13 Display style schematic provided for some embodiments of the present application Figure 1 ;
[0033] Figure 14 Display style schematic provided for some embodiments of the present application Figure 2 ;
[0034] Figure 15 Flow chart of the display style control method provided for some embodiments of the present application Figure 1
[0035] Figure 16 Schematic diagram of display style change provided for some embodiments of the present application;
[0036] Figure 17 Flow chart of the display style control method provided for some embodiments of the present application Figure 2 ;
[0037] Figure 18 Interaction schematic diagram between the pointing remote control and the display device provided for some embodiments of the present application. Detailed implementation manners
[0038] The embodiments will be described in detail below, and the examples are shown in the drawings. When the following description refers to the drawings, unless otherwise indicated, the same numbers in different drawings represent the same or similar elements. The implementation manners described in the following embodiments do not represent all implementation manners consistent with the present application. They are only examples of systems and methods consistent with some aspects of the present application detailed in the claims.
[0039] It should be noted that the brief description of terms in this application is only for the convenience of understanding the following described embodiments, rather than intending to limit the embodiments of this application. Unless otherwise specified, these terms should be understood in their ordinary and common meanings.
[0040] In this application, terms such as "first", "second", "third", etc. in the specification, claims and the above-mentioned drawings are used to distinguish similar or like objects or entities, and do not necessarily mean to limit a specific order or sequence, unless otherwise noted. It should be understood that such terms can be interchanged under appropriate circumstances.
[0041] The terms "comprising" and "having" and any variations thereof are intended to cover but not exclusively include. For example, a product or device comprising a series of components does not necessarily have to be limited to all the clearly listed components, but may include other components that are not clearly listed or are inherent to these products or devices.
[0042] The term "module" refers to any known or later developed hardware, software, firmware, artificial intelligence, fuzzy logic or a combination of hardware or / and software code that can perform functions related to that element.
[0043] In the embodiments of this application, the display device 200 generally refers to a device with the ability to display images and process data. For example, the display device 200 includes but is not limited to smart TVs, mobile terminals, computers, monitors, advertising screens, wearable devices, virtual reality devices, augmented reality devices, etc.
[0044] Figure 1 It is a schematic diagram of the operation scenario between the display device and the control device provided for some embodiments of this application. As Figure 1 shown, the user can operate the display device 200 through touch operations, the mobile terminal 300 and the control device 100. For example, the control device 100 can be a remote control, a stylus, a handle, etc.
[0045] The mobile terminal 300 can be used as a control device for performing human-computer interaction between the user and the display device 200. The mobile terminal 300 can also be used as a communication device for establishing a communication connection with the display device 200 and performing data interaction. In some embodiments, the mobile terminal 300 and the display device 200 can install software applications and achieve connection communication through network communication protocols to achieve the purpose of one-to-one control operations and data communication. It is also possible to transmit the audio and video content displayed on the mobile terminal 300 to the display device 200 to achieve the synchronous display function.
[0046] As Figure 1It is also shown that the display device 200 also communicates with the server 400 for data communication through various communication methods. The display device 200 is allowed to communicate and connect through a local area network (LAN), a wireless local area network (WLAN), and other networks.
[0047] The display device 200 can provide a broadcast receiving television function, and can also additionally provide an intelligent network television function with computer support functions, including but not limited to, network television, smart television, Internet Protocol Television (IPTV), etc.
[0048] Figure 2 For some embodiments of this application Figure 1 The hardware configuration block diagram of the display device 200 in
[0049] In some embodiments, the display device 200 may include at least one of a tuner demodulator 210, a communication device 220, a detector 230, a device interface 240, a controller 250, a display 260, an audio output device 270, a memory, a power supply, and a user input interface.
[0050] In some embodiments, the detector 230 is used to collect signals from the external environment or interact with the outside. For example, the detector 230 includes a light receiver, a sensor for collecting the intensity of ambient light; or, the detector 230 includes an image collector, such as a camera, which can be used to collect external environmental scenes, user attributes, or user interaction gestures. Or, the detector 230 includes a sound collector, such as a microphone, etc., for receiving external sounds.
[0051] In some embodiments, the display 260 includes a display function component for presenting a picture and a driving component for driving image display. The display 260 is used to receive the image signal output from the controller 250 for display. For example, the display 260 can be used to display video content, image content, components of a menu manipulation interface, and a user manipulation UI interface, etc.
[0052] In some embodiments, the communication device 220 is a component for communicating with external devices or the server 400 according to various communication protocol types. The display device 200 can be provided with a plurality of communication devices 220 according to different supported communication methods. For example, when the display device 200 supports wireless network communication, the display device 200 can be provided with a communication device 220 including a WiFi function. When the display device 200 supports Bluetooth connection communication, the display device 200 needs to be provided with a communication device 220 including a Bluetooth function.
[0053] The communication device 220 can enable the display device 200 to communicate with an external device or a server 400 through a wireless or wired connection. Among them, for the wired connection, the display device 200 can be connected to the external device through components such as a data cable and an interface. For the wireless connection, the display device 200 can be connected to the external device through a wireless signal or a wireless network. The display device 200 can directly establish a connection relationship with the external device, or can indirectly establish a connection relationship through a gateway, a router, a connection device, etc.
[0054] In some embodiments, the controller 250 may include at least one of a central processing unit, a video processor, an audio processor, a graphics processor, and a power processor, and first to nth interfaces for input / output. The controller 250 controls the operation of the display device and responds to user operations through various software control programs stored in the memory. The controller 250 controls the overall operation of the display device 200.
[0055] In some embodiments, the controller 250 and the tuner demodulator 210 may be located in different separate devices, that is, the tuner demodulator 210 may also be in an external device of the main device where the controller 250 is located, such as an external set-top box, etc.
[0056] In some embodiments, if a user inputs a user command on a graphical user interface (GUI) displayed on the display 260, the user input interface receives the user input command through the graphical user interface (GUI).
[0057] In some embodiments, the audio output device 270 may be a built-in speaker of the display device 200, or may be an external audio output device connected to the display device 200. Among them, for the external audio output device connected to the display device 200, the display device 200 may also be provided with an external audio output terminal, and the audio output device can be connected to the display device 200 through the external audio output terminal to output the sound of the display device 200.
[0058] In some embodiments, the user input interface 280 can be used to receive instructions input by a user.
[0059] Figure 3 For some embodiments provided in this application Figure 1 is a block diagram of the hardware configuration of the control device. As Figure 3 shown, the control device 100 may include: a controller 110, a communication interface 130, a user input / output interface, a memory, and a power supply.
[0060] The control device 100 is configured to control the display device 200, receive input operation instructions from the user, and convert the operation instructions into instructions recognizable and responsive by the display device 200, serving as an interaction intermediary between the user and the display device 200.
[0061] In some embodiments, the control device 100 can be an intelligent device. For example, the control device 100 can install various applications for controlling the display device 200 according to user needs.
[0062] In some embodiments, as Figure 1 shown, after installing the application for controlling the display device 200, the mobile terminal 300 or other intelligent electronic devices can perform functions similar to those of the control device 100.
[0063] The controller 110 includes a processor 112, a RAM 113, a ROM 114, a communication interface 130, and a communication bus. The controller 110 is used to control the operation and operation of the control device 100, as well as the communication and cooperation between internal components and the data processing functions between the external and internal.
[0064] Under the control of the controller 110, the communication interface 130 realizes the communication of control signals and data signals with the display device 200. The communication interface 130 can include at least one of a WiFi chip 131, a Bluetooth module 132, an NFC module 133, and other near-field communication modules.
[0065] The user input / output interface 140, where the input interface includes at least one of a microphone 141, a touchpad 142, a sensor 143, a button 144, and other input interfaces.
[0066] In some embodiments, the control device 100 includes at least one of the communication interface 130 and the input / output interface 140. The communication interface 130 is configured in the control device 100. For example, modules such as WiFi, Bluetooth, and NFC can encode the user input instructions through the WiFi protocol, or the Bluetooth protocol, or the NFC protocol and send them to the display device 200.
[0067] The memory 190 is used to store various operating programs, data, and applications for driving and controlling the control device 100 under the control of the controller. The memory 190 can store various control signal instructions input by the user.
[0068] The power supply 180 is used to provide operating power support for each component of the control device 100 under the control of the controller.
[0069] In order to perform user interaction, in some embodiments, the display device 200 may run an operating system. The operating system is a computer program for managing and controlling hardware resources and software resources in the display device 200. The operating system may provide a user interface (control the display device), allow the user to interact with the display device 200, and support the running of various application programs.
[0070] It should be noted that the operating system may be a native operating system based on a specific operating platform, or a third-party operating system deeply customized based on a specific operating platform, or an independent operating system specially developed for the display device.
[0071] The operating system can be divided into different modules or layers according to the functions implemented, such as Figure 4 As shown, in some embodiments, the system is divided into four layers, from top to bottom, namely, the application layer (Applications) layer (referred to as "application layer"), the application framework layer (Application Framework) layer (referred to as "framework layer"), the system library layer and the kernel layer.
[0072] In some embodiments, the application layer is used to provide services and interfaces for applications so that the display device 200 can run applications and interact with users based on the applications. At least one application can be run in the application layer, and these applications can be window programs, system settings programs, clock programs, etc. that come with the operating system; they can also be applications developed by third-party developers. In specific implementations, the application packages in the application layer are not limited to the above examples.
[0073] The framework layer provides application programming interfaces (APIs) and programming frameworks for applications. The application framework layer includes some predefined functions. The application framework layer is equivalent to a processing center that determines the actions that applications in the application layer take. Through the API interface, applications can access system resources and obtain system services during execution.
[0074] like Figure 4As shown, in the embodiment of the present application, the application framework layer includes a view system, managers, a content provider, etc. Among them, the view system can design and implement the interface and interaction of the application. The view system includes lists, grids, text boxes, buttons, etc. The managers include at least one of the following modules: The Activity Manager is used to interact with all the activities running in the system; the Location Manager is used to provide access to the system location service for system services or applications; the Package Manager is used to retrieve various information related to the application packages currently installed on the device; the Notification Manager is used to control the display and clearing of notification messages; the Window Manager is used to manage icons, windows, toolbars, wallpapers, and desktop widgets on the user interface.
[0075] In some embodiments, the Activity Manager is used to manage the life cycle of each application and the general navigation back function, such as controlling the exit, opening, and back of the application. The Window Manager is used to manage all window programs, such as obtaining the display screen size, determining whether there is a status bar, locking the screen, taking screenshots, and controlling the change of the display window. For example, shrinking the display window, jittering the display, and distorting the display.
[0076] In some embodiments, the system runtime library layer can provide support for the framework layer. When the framework layer is used, the operating system will run the instruction library included in the system runtime library layer, such as the C / C++ instruction library, to implement the functions to be achieved by the framework layer.
[0077] In some embodiments, the kernel layer is a functional layer between the hardware and software of the display device 200. The kernel layer can implement functions such as hardware abstraction, multitasking, and memory management. For example, as Figure 4 shown, hardware drivers can be configured in the kernel layer. The drivers included in the kernel layer can be at least one of the following drivers: audio driver, display driver, Bluetooth driver, camera driver, WIFI driver, USB driver, HDMI driver, sensor drivers (such as fingerprint sensors, temperature sensors, pressure sensors, etc.), and power drivers, etc.
[0078] It should be noted that the above examples are only simple divisions of the functions of the operating system, and do not limit the specific form of the operating system of the display device 200 in the embodiments of the present application. Depending on factors such as the functions of the display device and the type of the operating system, the number of levels and the specific types of levels included in the operating system may be in other forms.
[0079] In some embodiments, a display device is provided. The display device includes: a display configured to display a user interface, the user interface including at least one control; the user interface further has a cursor, and the position of the cursor on the user interface is determined by the position pointed to by the remote control in three-dimensional space.
[0080] Optionally, the user can start the display device by voice, remote control, or the switch of the television device. After the display device is started, the user interface corresponding to the home page is displayed through the display. The user can switch to other user interfaces by voice or remote control, such as: the user interface corresponding to the TV drama label, the user interface corresponding to the movie label, the user interface corresponding to a certain page provided by a certain application, etc. The embodiments of the present application do not limit this.
[0081] Optionally, among all the user interfaces displayed by the display, some user interfaces include controls, and some user interfaces may not include controls. The solution provided by the embodiments of the present application is directed to the user interfaces including controls. The number of controls on the user interfaces including controls may be only one or may be greater than one. The embodiments of the present application do not limit this.
[0082] Optionally, the remote control used in combination with the display device can be a remote control with a pointing function, hereinafter simply referred to as a pointing remote control. When the pointing function is turned on, the user interface displayed by the display further has a cursor, and the position of the cursor on the user interface is determined by the position pointed to by the pointing remote control in three-dimensional space. In the embodiments of the present application, the position pointed to by the pointing remote control in three-dimensional space is also referred to as the position data of the pointing remote control in three-dimensional space. The specific implementation process of determining the position of the cursor on the user interface based on the position data of the pointing remote control is described below.
[0083] The position data of the pointing remote control in three-dimensional space may include: position coordinates and pointing direction. Among them, the position coordinates are the physical position of the pointing remote control relative to the display device (for example, the horizontal distance and vertical height from the display device). The pointing direction is the pointing angle of the pointing remote control (for example, the horizontal angle and vertical angle relative to the display device). The pointing remote control is built-in with a gyroscope for detecting the rotation angle of the remote control and an accelerometer for detecting the moving acceleration of the remote control. Through these sensors, the pointing remote control can determine its own position data in three-dimensional space in real time.
[0084] In some embodiments, after obtaining its own position data in the three-dimensional space, the pointing remote control may send the position data to the display device. The display device may perform screen coordinate conversion based on the position data, so as to convert the position data of the pointing remote control in the three-dimensional space into the screen coordinate system, and obtain the screen coordinate. The screen coordinate may be used as the position of the cursor on the user interface, and the cursor may be drawn at this position, so as to display the cursor.
[0085] In some embodiments, the pointing remote control includes a coordinate conversion module. After obtaining its own position data in the three-dimensional space, the pointing remote control may input the position data into the coordinate conversion module. The coordinate conversion module may perform screen coordinate conversion based on the position data, so as to convert the position data into the screen coordinate system, obtain the screen coordinate, use the screen coordinate as the position of the cursor on the user interface, and send the position of the cursor on the user interface to the display device. After receiving the position of the cursor on the user interface, the display device draws the cursor at this position, so as to display the cursor. Exemplarily, the position of the cursor on the user interface is the coordinate (a, b), and the display device draws the cursor at the position with the coordinate (a, b) on the user interface, so as to display the cursor.
[0086] Exemplarily, refer to Figure 5 As shown, when the position data of the pointing remote control in the three-dimensional space is A, the position of the cursor on the user interface is the coordinate (a1, b1); when the position data of the pointing remote control in the three-dimensional space is B, the position of the cursor on the user interface is the coordinate (a2, b2). When the position data of the pointing remote control in the three-dimensional space is C, the screen coordinate calculated by the above method exceeds the screen range, and the display device no longer draws the cursor. Therefore, the cursor disappears.
[0087] Refer to Figure 6 As shown, the pointing remote control supports point pressing. When the cursor hovers over a certain control, the user can press the touch area (confirmation key) on the pointing remote control, and the display device executes the corresponding logic in response to this operation. Here, the control may be a card, a button, an input box, a radio button, a switch, a dialog box, a checkbox, a slider, a playback progress bar, a scroll bar, a drop-down menu, a label, a list, etc. The embodiments of the present application do not make any limitations thereto.
[0088] Refer to Figure 7As shown, the pointing remote control supports jump selection. When there are multiple options and corresponding selection boxes displayed in the user interface, if the user wants to select the first option and the third option, the user can first control the cursor to hover over the selection box corresponding to the first option and press the touch area on the pointing remote control. At this time, the first option is selected. Then, the user can control the cursor to hover over the selection box corresponding to the third option and press the touch area on the pointing remote control. At this time, the third option is selected, thus completing the jump selection.
[0089] See Figure 8 As shown, the pointing remote control supports drag-and-drop multiple selection. When there are multiple options and corresponding selection boxes displayed in the user interface, if the user wants to select all options, the user can control the cursor to hover over any position in the upper area of the first option, press the touch area on the pointing remote control and drag downward until the cursor moves to the lower area of the last option. At this time, all options are selected, thus completing the drag-and-drop multiple selection.
[0090] See Figure 9 As shown, the pointing remote control supports dragging. When a video is being played in the user interface and a playback progress bar is displayed, the user can control the cursor to hover over a certain position on the playback progress bar, and then press the touch area on the pointing remote control. The video played in the user interface will fast forward or rewind to the video frame corresponding to that position, thus completing the dragging of the playback progress. The playback progress bar in this example is just an example. Controls that support dragging also include sliders, scroll bars, labels, cards, lists, etc. The embodiments of the present application do not limit this.
[0091] See Figure 10 As shown, the pointing remote control supports swiping. When a cursor is displayed in the user interface, the user can swipe up, down, left, or right on the touch area of the pointing remote control, and the display device will execute the responses to these swipes.
[0092] See Figure 11 As shown, the pointing remote control supports continuous swiping. When a cursor is displayed in the user interface, the user can continuously swipe up, down, left, or right on the touch area of the pointing remote control. The display device will execute the responses to these continuous swipes and display a damping swipe effect in the user interface. Figure 11 Schematic diagram of continuous upward swiping.
[0093] See Figure 12As shown, the pointing remote control supports continuous reverse sliding. When there is a cursor displayed on the user interface, the user can first slide in one direction and then in the opposite direction on the touch area of the pointing remote control, and the display device will execute the response of continuous reverse sliding and display a damping sliding effect on the user interface. Figure 12 It is a schematic diagram of first sliding upward and then downward.
[0094] In some embodiments, the above display device further includes a processor, which is configured to: the control has a focus attribute; the focus attribute includes a focused attribute and an unfocused attribute.
[0095] Among them, as described above, the number of controls on the user interface containing controls may be one or greater than one. Among these controls, some controls have a focus attribute, and some controls do not have a focus attribute. It can be determined by the developer whether to set it according to the function of the control, or the developer defaults that all controls have a focus attribute. The solution provided in the embodiments of the present application is directed to the controls with a focus attribute.
[0096] Among them, for the control with a focus attribute, there are two possibilities for the focus attribute of the control, one is the focused attribute, and the other is the unfocused attribute. When the focus attribute of the control is the focused attribute, it can also be understood that the control has obtained the focus or is in the focus state; when the focus attribute of the control is the unfocused attribute, it can also be understood that the control has released the focus or is in the non-focus state.
[0097] Among them, for at least one control on the user interface, some controls have a hover attribute, and some controls do not have a hover attribute. It can also be determined by the developer whether to set it according to the function of the control, or the developer defaults that all controls have a hover attribute.
[0098] Among them, for the control with a hover attribute, there are two possibilities for the hover attribute of the control, one is the enter attribute, and the other is the leave attribute. When the cursor enters the control, the hover attribute is set to the enter attribute, and when the cursor exits the control, the hover attribute is set to the leave attribute.
[0099] In some embodiments, the update of the focus attribute is triggered by the user pressing a button on the remote control. For example, there are two controls, A and B, displayed on the user interface, with B to the right of A. The current focus is on A, that is, the focus attribute of A is the upper focus attribute, and the focus attribute of B is the out-of-focus attribute. When the user presses the right arrow key on the remote control, the focus will switch to B, that is, the focus attribute of A is the out-of-focus attribute, and the focus attribute of B is the upper focus attribute. As described above, the update of the hover attribute is triggered by the cursor position. The display style of the control is associated with both the focus attribute and the hover attribute. For example, for control A, when the cursor moves into control A, the hover attribute of control A becomes the in-move attribute, and the display style of control A will change to the display style corresponding to the in-move attribute. When the cursor moves out of control A, the hover attribute of control A becomes the out-move attribute, and the display style of control A will change to the display style corresponding to the out-move attribute. When the user makes control A gain focus by pressing a button on the remote control, the focus attribute of control A becomes the upper focus attribute, and the display style of control A will change to the display style corresponding to the upper focus attribute. When the user makes control A release the focus by pressing a button on the remote control, the focus attribute of control A becomes the out-of-focus attribute, and the display style of control A will change to the display style corresponding to the out-of-focus attribute. That is to say, the display style of control A is affected by the focus attribute and the hover attribute respectively. In this case, the variability of the display style results in a cluttered user interface and a poor user experience. In some solutions, the display style corresponding to the in-move attribute can be set to transparent, and the display style corresponding to the out-move attribute can also be set to transparent. Moreover, when the cursor moves into control A, not only the hover attribute of control A is set to the in-move attribute, but also the focus attribute of control A is set to the upper focus attribute. In this way, visually, when the cursor moves into control A, the display style of control A will change to the display style corresponding to the upper focus attribute, which is more in line with the user's habit of using the display device. Moreover, the user interface is more concise, which can improve the user's usage experience. However, this method has the following problems. Refer to Figure 13 As shown, when the cursor moves out of control A but has not moved into another control, since the focus has not yet been transferred, that is, the focus attribute of control A is still the upper focus attribute, the display style of control A is still the display style corresponding to the upper focus attribute, which does not match the user's expectation. The embodiment of the present application provides a solution to solve this problem, that is, the solution provided by the embodiment of the present application can achieve the following effect: when the cursor moves out of control A but has not moved into another control, although the focus attribute of control A is still the upper focus attribute, the display style of control A changes to the display style corresponding to the out-of-focus attribute. As Figure 14 shown, such a presentation is more in line with the user's expectation and can further improve the user's usage experience of the display device. The implementation process of the solution provided by the embodiment of the present application will be introduced in detail below.
[0100] In some embodiments, for a control with a focus attribute, the control is further provided with an attribute validity flag, and the display style of the control can be drawn based on a first preset value or a second preset value of the attribute validity flag. Among them, setting the attribute validity flag to the first preset value is used to indicate that the control draws the corresponding display style according to the current focus attribute; setting the attribute validity flag to the second preset value is used to indicate that the control draws the corresponding display style according to the out-of-focus attribute.
[0101] Optionally, the first preset value can be one or a combination of numbers, letters, characters, English words, etc. Similarly, the second preset value can also be one or a combination of numbers, letters, characters, English words, etc. Exemplarily, the first preset value can be false, and the second preset value can be true.
[0102] Optionally, the display styles mentioned in the embodiments of the present application may include the background color of the control, the font of the text in the control, the background image of the control, the size of the control, etc., and the embodiments of the present application do not limit this.
[0103] In some embodiments, the processor is configured to implement the following steps, see Figure 15 as shown:
[0104] Step 1501, when it is detected that the cursor moves into the control, set the focus attribute of the control to the on-focus attribute, and set the attribute validity flag to the first preset value; and draw the display style corresponding to the on-focus attribute on the control based on the first preset value.
[0105] Among them, for all controls displayed on the user interface, hover listening can be configured for all controls or some of them. When configuring hover listening, multiple listening events can be configured, such as enter event, move event, exit event, etc. In this way, for a control with hover listening configured, when the cursor moves into the control, the system will trigger the enter event for the control, that is, case MotionEvent.ACTION_HOVER_ENTER; when the cursor moves within the control, the system will trigger the move event for the control, that is, case MotionEvent.ACTION_HOVER_MOVE; when the cursor moves out of the control, the system will trigger the exit event for the control, that is, case MotionEvent.ACTION_OUTSIDE. The control can capture the above events through the OnHoverListener interface. When the enter event is captured, it can be determined that the cursor has moved into the control.
[0106] Among them, when it is detected that the cursor moves into the control, the focus attribute of the control is set to the upper focus attribute. In a specific implementation, when it is detected that the cursor moves into the control, the control can send a request for focus acquisition (request focus) to the system. The request for focus acquisition includes the control identifier of the control. After receiving the request for focus acquisition, the system parses the request for focus acquisition to obtain the control identifier, sets the focus attribute of the currently focused control to the out-of-focus attribute, and sets the focus attribute of the control corresponding to the control identifier to the upper focus attribute, thereby completing the switching of the focus.
[0107] Among them, when it is detected that the cursor moves into the control and the focus attribute of the control is set to the upper focus attribute, further set the attribute validity identifier of the control to a first preset value. The change of the attribute validity identifier of the control will trigger the control to redraw the display style on the control. In a specific implementation, the control judges the attribute validity identifier. When it is determined that the attribute validity identifier is the first preset value, obtain the current focus attribute of the control. Since the focus attribute of the control has been set to the upper focus attribute when it is detected that the cursor moves into the control, therefore, the current focus attribute of the control is the upper focus attribute. The control can search for the upper focus style data corresponding to the upper focus attribute, and based on the upper focus style data, draw the display style corresponding to the upper focus attribute on the control.
[0108] Step 1502, when it is detected that the cursor moves out of the control, keep the focus attribute of the control as the upper focus attribute, and set the attribute validity identifier of the control to a second preset value; and draw the display style corresponding to the out-of-focus attribute on the control based on the second preset value.
[0109] Among them, when the control captures the out event through the OnHoverListener interface, it can be determined that the cursor moves out of the control. At this time, keep the focus attribute of the control as the upper focus attribute, and set the attribute validity identifier of the control to a second preset value. As described above, the change of the attribute validity identifier of the control will trigger the control to redraw the display style on the control. In a specific implementation, the control judges the attribute validity identifier. When it is determined that the attribute validity identifier is the second preset value, directly search for the out-of-focus style data corresponding to the out-of-focus attribute, and based on the out-of-focus style data, draw the display style corresponding to the out-of-focus attribute on the control. In this way, when the cursor moves out of a certain control but has not moved into other controls, although the focus attribute of the control is still the upper focus attribute, the display style of the control becomes the display style corresponding to the out-of-focus attribute. Such a presentation is more in line with the user's expectations and improves the user experience of using the display device.
[0110] Exemplarily, refer to Figure 16As shown, in the upper focus style data corresponding to the upper focus attribute, the background color is red, and in the out-of-focus style data corresponding to the out-of-focus attribute, the background color is gray. Through the above method, it can be achieved that when the cursor moves into the control, the focus attribute of the control is the upper focus attribute and its background color is red; when the cursor moves out of the control but has not moved into other controls, the focus attribute of the control is still the upper focus attribute, but its background color changes to gray; when the cursor moves into other controls, the focus attribute of the control becomes the out-of-focus attribute and its background color is also gray.
[0111] In the above embodiment, the display device includes: a display configured to display a user interface, the user interface including at least one control; the user interface further has a cursor, and the position of the cursor on the user interface is determined by the position pointed to by the remote control in the three-dimensional space; a processor configured to: the control is provided with a focus attribute and an attribute validity flag; the focus attribute includes an upper focus attribute and an out-of-focus attribute; draw the display style of the control based on the first preset value or the second preset value of the attribute validity flag; wherein, setting the attribute validity flag to the first preset value is used to indicate that the control draws the corresponding display style according to the current focus attribute; setting the attribute validity flag to the second preset value is used to indicate that the control draws the corresponding display style according to the out-of-focus attribute; wherein, when it is detected that the cursor moves into the control, the focus attribute of the control is set to the upper focus attribute, and the attribute validity flag is set to the first preset value; and draw the display style corresponding to the upper focus attribute on the control based on the first preset value; when it is detected that the cursor moves out of the control, keep the focus attribute of the control as the upper focus attribute, set the attribute validity flag of the control to the second preset value; and draw the display style corresponding to the out-of-focus attribute on the control based on the second preset value. The above solution proposes the setting of the attribute validity flag. In the case where the user implements an interaction behavior, the display device can control the display style of the control by changing the value of the attribute validity flag, so that the presentation of the control display style is visually matched with the interaction behavior implemented by the user, improving the user experience of using the display device.
[0112] In some embodiments, when the processor executes to set the focus attribute of the control to the upper focus attribute and set the attribute validity flag to the first preset value; and draw the display style corresponding to the upper focus attribute on the control based on the first preset value, it is further configured to: determine whether the current focus attribute of the control is the upper focus attribute; if it is not the upper focus attribute, set the focus attribute of the control to the upper focus attribute, set the attribute validity flag to the first preset value; and draw the display style corresponding to the upper focus attribute on the control based on the first preset value; if it is the upper focus attribute, directly set the attribute validity flag to the first preset value; and draw the display style corresponding to the upper focus attribute on the control based on the first preset value.
[0113] Among them, as described above, when the cursor moves into a certain control, the display device will set the focus attribute of the control to the upper focus attribute. Subsequently, if the cursor moves out of the control but does not move into other controls and then moves into the control again, the focus attribute of the control is already the upper focus attribute and there is no need to set it to the upper focus attribute again. Considering this scenario, the embodiment of the present application proposes that when it is detected that the cursor moves into the control, first judge whether the current focus attribute of the control is the upper focus attribute. If it is already the upper focus attribute, do not perform the operation of setting the focus attribute to the upper focus attribute, and directly set the attribute validity flag to the first preset value; and draw the display style corresponding to the upper focus attribute on the control based on the first preset value; if it is not the upper focus attribute, set the focus attribute of the control to the upper focus attribute, set the attribute validity flag to the first preset value; and draw the display style corresponding to the upper focus attribute on the control based on the first preset value.
[0114] In the above embodiment, when it is detected that the cursor moves into the control, an action of judging the focus attribute of the control is added. When the focus attribute is not the upper focus attribute, the operation of setting the focus attribute to the upper focus attribute is performed, and when the focus attribute is the upper focus attribute, this operation is not performed again, which can avoid repeated setting of the focus attribute.
[0115] In some embodiments, the processor executes drawing the display style corresponding to the upper focus attribute on the control based on the first preset value, and is further configured to: call the style update method, and trigger the call of the attribute acquisition method by the style update method; judge the attribute validity flag of the control by the attribute acquisition method. When the attribute validity flag of the control is the first preset value, obtain the current focus attribute of the control. The current focus attribute is the upper focus attribute, find the upper focus style data corresponding to the upper focus attribute from the pre-stored layout file, and return the upper focus style data to the style update method; the style update method draws the display style corresponding to the upper focus attribute on the control based on the upper focus style data.
[0116] Among them, when it is detected that the cursor moves into the control, after setting the focus attribute of the control to the upper focus attribute, the attribute validity flag of the control is further set to the first preset value. The change of the attribute validity flag of the control will trigger the call of the style update method, and the style update method will further trigger the call of the attribute acquisition method. During the operation of the attribute acquisition method, it will search for the attribute validity flag of the control and judge the attribute validity flag. Since the attribute validity flag has been set to the first preset value, the judgment result here is the first preset value. When the attribute validity flag is the first preset value, the attribute acquisition method further queries the current focus attribute of the control. Since the focus attribute of the control has been set to the upper focus attribute, the current node attribute is the upper focus attribute. The attribute acquisition method further searches for the upper focus style data corresponding to the upper focus attribute from the pre-stored layout file, and returns the upper focus style data to the style update method. After receiving the upper focus style data, the style update method directly draws the display style corresponding to the upper focus attribute on the control based on the upper focus style data.
[0117] Optionally, the above-mentioned style update method can be the refreshDrawableState method, and the attribute acquisition method can be the onCreateDrawableState method.
[0118] Among them, the pre-stored layout file stores the upper focus style data corresponding to the upper focus attributes of all controls, as well as the out-of-focus style data corresponding to the out-of-focus attributes.
[0119] In the above embodiment, when it is detected that the cursor moves into the control, after setting the focus attribute of the control to the upper focus attribute, the attribute validity flag of the control is further set to the first preset value, and then by calling the style update method and the attribute acquisition method, the display style corresponding to the upper focus attribute is drawn on the control. This way of controlling the display style of the control through the attribute validity flag can achieve flexible control of the display style of the control.
[0120] In some embodiments, the processor executes to draw the display style corresponding to the out-of-focus attribute on the control based on the second preset value, and is further configured to: call the style update method, trigger the call of the attribute acquisition method by the style update method, judge the attribute validity flag of the control by the attribute acquisition method, and when the attribute validity flag of the control is the second preset value, search for the out-of-focus style data corresponding to the out-of-focus attribute from the pre-stored layout file, and return the out-of-focus style data to the style update method; the style update method draws the display style corresponding to the out-of-focus attribute on the control based on the out-of-focus style data.
[0121] Among them, when it is detected that the cursor moves out of the control, the focus attribute of the control is maintained as the previous focus attribute, and the attribute validity flag of the control is set to a second preset value. The change of the attribute validity flag of the control triggers the call of the style update method, and the style update method further triggers the call of the attribute acquisition method. During the operation of the attribute acquisition method, it will search for the attribute validity flag of the control and judge the attribute validity flag. Since the attribute validity flag has been set to the second preset value, the judgment result here is the second preset value. When the attribute validity flag is the second preset value, the attribute acquisition method directly searches for the out-of-focus style data corresponding to the out-of-focus attribute from the pre-stored layout file, and returns the out-of-focus style data to the style update method. After receiving the out-of-focus style data, the style update method directly draws the display style corresponding to the out-of-focus attribute on the control based on the out-of-focus style data.
[0122] Similarly, the above style update method can be the refreshDrawableState method, and the attribute acquisition method can be the onCreateDrawableState method.
[0123] In the above embodiment, when it is detected that the cursor moves out of the control, the focus attribute of the control is maintained as the previous focus attribute, and the attribute validity flag of the control is set to a second preset value. Then, by calling the style update method and the attribute acquisition method, the display style corresponding to the out-of-focus attribute is drawn on the control. This way of controlling the display style of the control through the attribute validity flag can achieve flexible control of the display style of the control, so as to achieve the following interface presentation effect: when the cursor moves out of a certain control but has not moved into other controls, although the focus attribute of the control is still the previous focus attribute, the display style of the control becomes the display style corresponding to the out-of-focus attribute. Such a presentation is more in line with the user's expectations and improves the user experience of using the display device.
[0124] In some embodiments, when a press event triggered by a touch screen is received, the focus attribute of the control is set to the out-of-focus attribute, and the attribute validity flag of the control is set to a first preset value; the style update method is called, and the style update method triggers the call of the attribute acquisition method. The attribute acquisition method judges the attribute validity flag of the control. When the attribute validity flag of the control is the first preset value, the current focus attribute of the control is obtained. The current focus attribute is the out-of-focus attribute. The out-of-focus style data corresponding to the out-of-focus attribute is searched from the pre-stored layout file, and the out-of-focus style data is returned to the style update method; the style update method draws the display style corresponding to the out-of-focus attribute on the control based on the out-of-focus style data.
[0125] Among them, when the display of the display device is configured with a touch screen, the user can perform a pressing operation on the control on the user interface, or when the cursor hovers over a certain control, the user can press the touch area on the pointing remote control. In both of these operations, the display device will generate a pressing event for the corresponding control.
[0126] Among them, after receiving the pressing event, determine the device source of the pressing event. When the device source of the pressing event is the touch screen, it is considered that a pressing event triggered by the touch screen is received. At this time, request the system to set the focus attribute of the control to the out-of-focus attribute, and set the attribute validity flag of the control to the first preset value. The change of this attribute validity flag will trigger the call of the style update method, and the style update method will further trigger the call of the attribute acquisition method. During the operation of the attribute acquisition method, it will search for the attribute validity flag of this control and judge this attribute validity flag. Since the attribute validity flag has been set to the first preset value, the judgment result here is the first preset value. When the attribute validity flag is the first preset value, the attribute acquisition method further queries the current focus attribute of this control. Since the focus attribute of this control has been set to the out-of-focus attribute, the current node attribute is the out-of-focus attribute. The attribute acquisition method further searches for the out-of-focus style data corresponding to the out-of-focus attribute from the pre-stored layout file, and returns the out-of-focus style data to the style update method. After receiving the out-of-focus style data, the style update method directly draws the display style corresponding to the out-of-focus attribute on this control based on this out-of-focus style data.
[0127] In the above embodiment, when receiving the pressing event of the control through the touch screen, set the focus attribute of the control to the out-of-focus attribute, and set the attribute validity flag of the control to the first preset value; then, by calling the style update method and the attribute acquisition method, draw the display style corresponding to the out-of-focus attribute on this control. This way of controlling the display style of the control through the attribute validity flag can achieve flexible control of the display style of the control.
[0128] In some embodiments, the processor is further configured to: when receiving the pressing event triggered by the pointing remote control, update the attribute validity flag of the control to the first preset value; call the style update method, and the style update method triggers the call of the attribute acquisition method; the attribute acquisition method judges the attribute validity flag of the control. When the attribute validity flag of the control is the first preset value, obtain the current focus attribute of the control, the current focus attribute is the in-focus attribute, search for the in-focus style data corresponding to the in-focus attribute from the pre-stored layout file, and return the in-focus style data to the style update method; the style update method draws the display style corresponding to the in-focus attribute on the control based on the in-focus style data.
[0129] Among them, after receiving a pressing event, the device source of the pressing event is judged. When the device source of the pressing event points to the remote control, it is considered that a pressing event triggered by pointing to the remote control is received. At this time, the attribute validity flag of the control is updated to the first preset value; the change of the attribute validity flag of the control will trigger the call of the style update method, and the style update method will further trigger the call of the attribute acquisition method. During the running of the attribute acquisition method, the attribute validity flag of the control will be searched and judged. Since the attribute validity flag has been set to the first preset value, the judgment result here is the first preset value. When the attribute validity flag is the first preset value, the attribute acquisition method further queries the current focus attribute of the control. Since the pressing event will occur only when the cursor first hovers over the control, and the focus attribute of the control will be set to the upper focus attribute after the cursor enters the control, the focus attribute of the control during the pressing event must be the upper focus attribute. Therefore, the current node attribute is the upper focus attribute. The attribute acquisition method further searches for the upper focus style data corresponding to the upper focus attribute from the pre-stored layout file, and returns the upper focus style data to the style update method. After receiving the upper focus style data, the style update method directly draws the display style corresponding to the upper focus attribute on the control based on the upper focus style data.
[0130] In the above embodiment, when receiving a pressing event triggered by pointing to the remote control, the attribute validity flag of the control is updated to the first preset value; then, by calling the style update method and the attribute acquisition method, the display style corresponding to the upper focus attribute is drawn on the control. This method of controlling the display style of the control through the attribute validity flag can achieve flexible control of the display style of the control.
[0131] In some embodiments, the processor is further configured to: receive an interaction behavior event triggered by pointing the remote controller, where the interaction behavior event is triggered after a press event; if the interaction behavior event occurs inside the control, update the attribute validity flag of the control to a first preset value; call a style update method, which triggers the call of an attribute acquisition method; the attribute acquisition method determines the attribute validity flag of the control, and when the attribute validity flag of the control is the first preset value, obtains the current focus attribute of the control, where the current focus attribute is the previous focus attribute, searches for the previous focus style data corresponding to the previous focus attribute from a pre-stored layout file, and returns the previous focus style data to the style update method; the style update method draws the display style corresponding to the previous focus attribute on the control based on the previous focus style data; if the interaction behavior event occurs outside the control, update the attribute validity flag of the control to a second preset value; call a style update method, which triggers the call of an attribute acquisition method, the attribute acquisition method determines the attribute validity flag of the control, and when the attribute validity flag of the control is the second preset value, searches for the out-of-focus style data corresponding to the out-of-focus attribute from a pre-stored layout file, and returns the out-of-focus style data to the style update method; the style update method draws the display style corresponding to the out-of-focus attribute on the control based on the out-of-focus style data.
[0132] Among them, after the user triggers a press event by pointing the remote controller, there may also be triggered a move event ACTION_MOVE, a lift event ACTION_UP, a cursor out event ACTION_OUTSIDE, an interruption event ACTION_CANCEL, etc. These events can all be used as the interaction behavior events mentioned above.
[0133] Among them, when the cursor hovers over a certain control, a press event is triggered when the user presses the touch area on the pointing remote controller. A move event ACTION_MOVE is triggered when the user moves the cursor on the user interface while pressing the touch area. A cursor out event ACTION_OUTSIDE is triggered when the user moves the cursor out of the control while pressing the touch area. A lift event ACTION_UP is triggered when the user releases the touch area. When the parent control where the control is located is a list, an interruption event ACTION_CANCEL is triggered when the user moves the cursor while pressing the touch area.
[0134] Among them, after receiving any of the above interaction behavior events, it is possible to determine whether the interaction behavior event occurs inside the control. If it occurs inside the control, update the attribute validity flag of the control to the first preset value; the change of the attribute validity flag of the control will trigger the call of the style update method, and the style update method will further trigger the call of the attribute acquisition method. During the operation of the attribute acquisition method, it will search for the attribute validity flag of the control and judge the attribute validity flag. Since the attribute validity flag has been set to the first preset value, the judgment result here is the first preset value. When the attribute validity flag is the first preset value, the attribute acquisition method further queries the current focus attribute of the control. Since the above interaction behavior event occurs inside the control, that is, the cursor is inside the control, and the focus attribute of the control will be set to the upper focus attribute after the cursor enters the control. Therefore, the focus attribute of the control when the interaction behavior event occurs must be the upper focus attribute. Therefore, the current node attribute is the upper focus attribute. The attribute acquisition method further searches for the upper focus style data corresponding to the upper focus attribute from the pre-stored layout file, and returns the upper focus style data to the style update method. After receiving the upper focus style data, the style update method directly draws the display style corresponding to the upper focus attribute on the control based on the upper focus style data.
[0135] Among them, after receiving any of the above interaction behavior events, it is possible to determine whether the interaction behavior event occurs inside the control. If it occurs outside the control, set the attribute validity flag of the control to the second preset value. The change of the attribute validity flag of the control will trigger the call of the style update method, and the style update method will further trigger the call of the attribute acquisition method. During the operation of the attribute acquisition method, it will search for the attribute validity flag of the control and judge the attribute validity flag. Since the attribute validity flag has been set to the second preset value, the judgment result here is the second preset value. When the attribute validity flag is the second preset value, the attribute acquisition method directly searches for the out-of-focus style data corresponding to the out-of-focus attribute from the pre-stored layout file, and returns the out-of-focus style data to the style update method. After receiving the out-of-focus style data, the style update method directly draws the display style corresponding to the out-of-focus attribute on the control based on the out-of-focus style data.
[0136] In the above embodiments, after receiving an interaction behavior event triggered by pointing at the remote control, if the interaction behavior event occurs inside the control, update the attribute validity flag of the control to a first preset value; then, by calling the style update method and the attribute acquisition method, draw the display style corresponding to the focused attribute on the control. If the interaction behavior event occurs outside the control, update the attribute validity flag of the control to a second preset value; then, by calling the style update method and the attribute acquisition method, draw the display style corresponding to the unfocused attribute on the control. This method of controlling the display style of the control through the attribute validity flag can achieve flexible control of the display style of the control.
[0137] In some embodiments, the processor is further configured to: after detecting that the focus attribute is updated, call back the focus state acquisition method to obtain the current focus attribute of the target control whose focus is updated; update the attribute validity flag of the target control to a first preset value; call the style update method, and the style update method triggers the call of the attribute acquisition method; the attribute acquisition method judges the attribute validity flag corresponding to the target control. When the attribute validity flag of the target control is the first preset value, obtain the current focus attribute of the target control, find the style data corresponding to the current focus attribute from the pre-stored layout file, and return the style data to the style update method; the style update method draws the corresponding display style on the control based on the style data.
[0138] Among them, when the system installed on the display device detects that the focus of the control on the user interface changes, that is, when it detects that the focus attribute is updated, it will call back the focus state acquisition method to obtain the current focus attribute of the target control whose focus is updated. Here, the focus state acquisition method can be, for example, the onFocusChange method.
[0139] Exemplarily, when the cursor moves from control A to inside control B, the focus attribute of control A will change from the focused attribute to the unfocused attribute, and the focus attribute of control B will change from the unfocused attribute to the focused attribute. After the system detects this change, it will call back the onFocusChange method once for control A. The onFocusChange method will obtain the current focus attribute (unfocused attribute) of control A and return it to the upper-layer application. It will also call back the onFocusChange method once for control B. The onFocusChange method will obtain the current focus attribute (focused attribute) of control B and return it to the upper-layer application.
[0140] For control A, the upper-layer application sets the property validity flag of control A to the first preset value. The change of the property validity flag of control A triggers the invocation of the style update method, and the style update method further triggers the invocation of the property acquisition method. During the operation of the property acquisition method, it will search for the property validity flag of control A and judge the property validity flag. Since the property validity flag has been set to the first preset value, the judgment result here is the first preset value. When the property validity flag is the first preset value, the property acquisition method further queries the current focus property of control A. Since the focus property of control A has been set to the out-of-focus property, the current node property is the out-of-focus property. The property acquisition method further searches for the out-of-focus style data corresponding to the out-of-focus property from the pre-stored layout file, and returns the out-of-focus style data to the style update method. After receiving the out-of-focus style data, the style update method directly draws the display style corresponding to the out-of-focus property on this control based on the out-of-focus style data.
[0141] For control B, the upper-layer application sets the property validity flag of control B to the first preset value. The change of the property validity flag of control B triggers the invocation of the style update method, and the style update method further triggers the invocation of the property acquisition method. During the operation of the property acquisition method, it will search for the property validity flag of control B and judge the property validity flag. Since the property validity flag has been set to the first preset value, the judgment result here is the first preset value. When the property validity flag is the first preset value, the property acquisition method further queries the current focus property of control B. Since the focus property of control B has been set to the in-focus property, the current node property is the in-focus property. The property acquisition method further searches for the in-focus style data corresponding to the in-focus property from the pre-stored layout file, and returns the in-focus style data to the style update method. After receiving the in-focus style data, the style update method directly draws the display style corresponding to the in-focus property on this control based on the in-focus style data.
[0142] In the above embodiments, when it is detected that the focus property is updated, the focus state acquisition method is called back to obtain the current focus property of the target control whose focus property has been updated; the property validity flag of the target control is updated to the first preset value; then, by calling the style update method and the property acquisition method, the display style corresponding to the current focus property is drawn on this control. This method of controlling the display style of the control through the property validity flag can achieve flexible control of the display style of the control.
[0143] In some embodiments, the control is a parent control, and the parent control includes at least one child control; the processor executes to draw the display style corresponding to the focused property on the control based on a first preset value, and is further configured to: draw the display style corresponding to the focused property on at least one child control based on the first preset value; the processor executes to draw the display style corresponding to the unfocused property on the control based on a second preset value, and is further configured to: draw the display style corresponding to the unfocused property on at least one child control based on the second preset value.
[0144] Among them, the control mentioned in the embodiments of the present application may be a parent control, and the parent control contains at least one child control. There are two display styles for the parent control, one is the display style corresponding to the focused property of the parent control, and the other is the display style corresponding to the unfocused property of the parent control. For each child control, there are also two display styles, one is the display style corresponding to the focused property of the parent control, and the other is the display style corresponding to the unfocused property of the parent control.
[0145] Among them, when the attribute validity flag of the control is the first preset value and the current focus attribute of the control is the focused property, draw the display style corresponding to the focused property of the control on the control, and draw the display style corresponding to the focused property of the control on the child controls inside the control.
[0146] Exemplarily, the parent control A contains child controls A1, A2, and A3 inside. For the parent control A, the display style corresponding to its focused property is style A1, and the display style corresponding to its unfocused property is style A2; for the child control A1, the display style corresponding to the focused property of the parent control is style A11, and the display style corresponding to the unfocused property of the parent control is style A12; for the child control A2, the display style corresponding to the focused property of the parent control is style A21, and the display style corresponding to the unfocused property of the parent control is style A22; for the child control A3, the display style corresponding to the focused property of the parent control is style A31, and the display style corresponding to the unfocused property of the parent control is style A32. When the attribute validity flag of the parent control A is set to the first preset value and the current focus attribute of the parent control A is the focused property, draw style A1 on the parent control A, draw style A11 on the child control A1, draw style A21 on the child control A2, and draw style A31 on the child control A3. When the attribute validity flag of the parent control A is set to the first preset value and the current focus attribute of the parent control A is the unfocused property, draw style A2 on the parent control A, draw style A12 on the child control A1, draw style A22 on the child control A2, and draw style A32 on the child control A3. When the attribute validity flag of the parent control A is set to the second preset value, draw style A2 on the parent control A, draw style A12 on the child control A1, draw style A22 on the child control A2, and draw style A32 on the child control A3.
[0147] In the above embodiments, when the control includes at least one sub-control, drawing is synchronously performed on the parent control and the sub-control, so that the overall presentation of the parent control and the sub-control has a focused or unfocused effect, which is closer to the expected effect of the user and further improves the user experience.
[0148] In some embodiments, a refreshed style sub-process is provided. This process includes: calling the refreshDrawableState method, the refreshDrawableState method triggers the call of the onCreateDrawableState method, the onCreateDrawableState method judges the validity flag of the control's attributes. When the attribute validity flag is true, the onCreateDrawableState method looks up the unfocused style data corresponding to the unfocused attribute from a pre-stored layout file, and returns the unfocused style data to the style update method. After receiving the unfocused style data, the style update method directly draws the display style corresponding to the unfocused attribute on the control based on this unfocused style data. When the attribute validity flag is false, the onCreateDrawableState method obtains the current focus attribute of the control, looks up the style data corresponding to the current focus attribute from a pre-stored layout file, and returns the style data to the style update method; the style update method draws the display style corresponding to the current focus attribute on the control based on the style data.
[0149] In some embodiments, a display style control method is provided. Refer to Figure 17As shown, the method includes: when it is detected that the cursor pointing to the remote control or the cursor of the mouse moves into the control, execute the HoverEnter sub - process. The HoverEnter sub - process includes: determining whether the focus attribute of the control is the top - focus attribute. If it is not the top - focus attribute, first request the system to set the focus attribute of the control to the top - focus attribute; if it is already the top - focus attribute, set the attribute validity flag to false and trigger the execution of the refresh style sub - process. Since the attribute validity flag has been set to false, the onCreateDrawableState method will obtain the current focus attribute of the control. Since the focus attribute of the control has been set to the top - focus attribute, the current node attribute is the top - focus attribute. The onCreateDrawableState method will look up the top - focus style data corresponding to the top - focus attribute from the pre - stored layout file and return it to the refreshDrawableState method. The refreshDrawableState method will draw the display style corresponding to the top - focus attribute on the control. When it is detected that the cursor pointing to the remote control or the cursor of the mouse moves out of the control, execute the HoverExit sub - process. The HoverExit sub - process includes: keeping the focus attribute of the control as the top - focus attribute, setting the attribute validity flag of the control to true, and triggering the execution of the refresh style sub - process. Since the attribute validity flag has been set to true, the onCreateDrawableState method will directly look up the out - of - focus style data corresponding to the out - of - focus attribute from the pre - stored layout file and return it to the refreshDrawableState method. The refreshDrawableState method will draw the display style corresponding to the out - of - focus attribute on the control. When a press event for a certain control is received, determine the device source of the press event. In the case where the device source of the press event is the touch screen, it is considered that a press event triggered by the touch screen is received. At this time, request the system to set the focus attribute of the control to the out - of - focus attribute, set the attribute validity flag of the control to false, and trigger the execution of the refresh style sub - process. Since the attribute validity flag has been set to false, the onCreateDrawableState method will obtain the current focus attribute of the control. Since the focus attribute of the control has been set to the out - of - focus attribute, the current node attribute is the out - of - focus attribute. The onCreateDrawableState method will look up the out - of - focus style data corresponding to the out - of - focus attribute from the pre - stored layout file and return it to the refreshDrawableState method. The refreshDrawableState method will draw the display style corresponding to the out - of - focus attribute on the control.When the device source of the press event is the pointing remote control, it is considered that a press event triggered by the pointing remote control is received, and the HoverPress sub-process is executed. The HoverEnter sub-process includes: setting the property validity flag of the control to false and triggering the execution of the refresh style sub-process. Since the property validity flag has been set to false, the onCreateDrawableState method will obtain the current focus property of the control. The current focus property is the upper focus property. The onCreateDrawableState method will look up the upper focus style data corresponding to the upper focus property from the pre-stored layout file and return it to the refreshDrawableState method. The refreshDrawableState method will draw the display style corresponding to the upper focus property on the control. When the lift event ACTION_UP is received after the press event, it can be determined whether the lift event ACTION_UP occurs inside the control. If it occurs inside the control, it can be directly ended, or the HoverEnter sub-process can be executed, so that the refreshDrawableState method will draw the display style corresponding to the upper focus property on the control; if it occurs outside the control, the HoverExit sub-process will be executed, so that the refreshDrawableState method will draw the display style corresponding to the out-of-focus property on the control. When the move event ACTION_MOVE is received after the press event, it can be determined whether the move event ACTION_MOVE occurs inside the control. If it occurs inside the control, it can be directly ended, or the HoverEnter sub-process can be executed; if it occurs outside the control, the HoverExit sub-process will be executed. When the cursor out event ACTION_OUTSIDE is received after the press event, the HoverEnter sub-process is directly executed. When the interruption event ACTION_CANCEL is received after the press event, it can be determined whether the interruption event ACTION_CANCEL occurs inside the control. If it occurs inside the control, it can be directly ended, or the HoverEnter sub-process can be executed; if it occurs outside the control, the HoverExit sub-process will be executed. When it is detected that the focus property is updated, the system will call the onFocusChange method to obtain the current focus property of the target control where the update occurs. At this time, the property validity flag of the control can be set to false and the execution of the refresh style sub-process can be triggered, so that the refreshDrawableState method will draw the display style corresponding to the current focus property on the control.
[0150] In some embodiments, a display style control method is provided. Refer to Figure 18, the method includes: S1. The pointing remote control sends data representing the cursor display position to the display device; S2. When the display device determines that the cursor moves into the control based on the received data, it sets the focus attribute of the control to the upper focus attribute, sets the attribute validity flag to the first preset value, and draws the display style corresponding to the upper focus attribute on the control based on the first preset value; S3. The remote control sends data representing the cursor display position to the display device; S4. When the display device determines that the cursor moves out of the control based on the received data, it keeps the focus attribute of the control as the upper focus attribute, sets the attribute validity flag of the control to the second preset value, and draws the display style corresponding to the out-of-focus attribute on the control based on the second preset value; S5. The pointing remote control triggers a pressing event; S6. The display device sets the attribute validity flag to the first preset value and draws the display style corresponding to the upper focus attribute on the control based on the first preset value; S7. The pointing remote control triggers an interaction behavior event (move event ACTION_MOVE, lift event ACTION_UP, cursor out event ACTION_OUTSIDE, interruption event ACTION_CANCEL, etc.); S8. If the interaction behavior event occurs inside the control, the display device sets the attribute validity flag of the control to the first preset value and draws the display style corresponding to the upper focus attribute on the control; if the interaction behavior event occurs outside the control, it sets the attribute validity flag of the control to the second preset value and draws the display style corresponding to the out-of-focus attribute on the control.
[0151] In some embodiments, a display style control method is provided, including: when it is detected that the cursor moves into the control, setting the focus attribute of the control to the upper focus attribute, setting the attribute validity flag of the control to the first preset value, and drawing the display style corresponding to the upper focus attribute on the control based on the first preset value; when it is detected that the cursor moves out of the control, keeping the focus attribute of the control as the upper focus attribute, setting the attribute validity flag of the control to the second preset value, and drawing the display style corresponding to the out-of-focus attribute on the control based on the second preset value. For the specific implementation process of this method, refer to the foregoing, and details are not described herein again.
[0152] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present application and are not intended to limit them; although the present application has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that they can still modify the technical solutions described in the foregoing embodiments, or perform equivalent replacements on some or all of the technical features; and these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of the present application.
[0153] For the sake of convenience in explanation, the above description has been made in connection with specific embodiments. However, the above exemplary discussion is not intended to be exhaustive or to limit the embodiments to the specific forms disclosed above. According to the above teachings, various modifications and variations can be obtained. The selection and description of the above embodiments are for the purpose of better explaining the principles and practical applications, so that those skilled in the art can better use the embodiments and various different variations of the embodiments suitable for specific use considerations.
Claims
1. A display device, characterized in that, Comprising: A display, configured to: display a user interface, the user interface including at least one control; the user interface further having a cursor, the position of the cursor on the user interface being determined by the position pointed to by a remote control in three-dimensional space; A processor, configured to: The control is provided with a focus attribute and an attribute validity flag; the focus attribute includes a focused attribute and an unfocused attribute; Draw the display style of the control based on a first preset value or a second preset value of the attribute validity flag; wherein, setting the attribute validity flag to the first preset value is used to indicate that the control draws the corresponding display style according to the current focus attribute; setting the attribute validity flag to the second preset value is used to indicate that the control draws the corresponding display style according to the unfocused attribute; Wherein, when it is detected that the cursor moves into the control, the focus attribute of the control is set to the focused attribute, and the attribute validity flag is set to the first preset value; and based on the first preset value, the display style corresponding to the focused attribute is drawn on the control; When it is detected that the cursor moves out of the control, the focus attribute of the control is maintained as the focused attribute, and the attribute validity flag of the control is set to the second preset value; and based on the second preset value, the display style corresponding to the unfocused attribute is drawn on the control.
2. The display device according to claim 1, wherein The processor executes setting the focus attribute of the control to the focused attribute, setting the attribute validity flag to the first preset value; and drawing the display style corresponding to the focused attribute on the control based on the first preset value, and is further configured to: Judge whether the current focus attribute of the control is the focused attribute; If it is not the focused attribute, set the focus attribute of the control to the focused attribute, and set the attribute validity flag to the first preset value; And draw the display style corresponding to the focused attribute on the control based on the first preset value; If it is the focused attribute, directly set the attribute validity flag to the first preset value; and draw the display style corresponding to the focused attribute on the control based on the first preset value.
3. The display device according to claim 1, characterized in that, The processor executes drawing the display style corresponding to the focused attribute on the control based on the first preset value, and is further configured to: Call a style update method, which triggers the call of an attribute acquisition method; the attribute acquisition method judges the attribute validity flag of the control, and when the attribute validity flag of the control is the first preset value, obtains the current focus attribute of the control, the current focus attribute being the focused attribute, searches for the focused style data corresponding to the focused attribute from a pre-stored layout file, and returns the focused style data to the style update method; The style update method draws the display style corresponding to the focused attribute on the control based on the focused style data.
4. The display device according to claim 1, wherein The processor executes drawing the display style corresponding to the unfocused attribute on the control based on the second preset value, and is further configured to: Invoke the style update method, which triggers the invocation of the property acquisition method. The property acquisition method determines the validity flag of the control's properties. When the validity flag of the control's properties is the second preset value, search for the out-of-focus style data corresponding to the out-of-focus property in the pre-stored layout file, and return the out-of-focus style data to the style update method. Based on the out-of-focus style data, the style update method draws the display style corresponding to the out-of-focus property on the control.
5. The display device according to claim 1, wherein The processor is further configured to: When receiving a press event triggered by the touch screen, set the focus property of the control to the out-of-focus property, and set the validity flag of the control's properties to the first preset value; Invoke the style update method, which triggers the invocation of the property acquisition method. The property acquisition method determines the validity flag of the control's properties. When the validity flag of the control's properties is the first preset value, obtain the current focus property of the control. The current focus property is the out-of-focus property. Search for the out-of-focus style data corresponding to the out-of-focus property in the pre-stored layout file, and return the out-of-focus style data to the style update method. Based on the out-of-focus style data, the style update method draws the display style corresponding to the out-of-focus property on the control.
6. The display device according to claim 1, wherein The processor is further configured to: When receiving a press event triggered by the remote control, set the validity flag of the control's properties to the first preset value; Invoke the style update method, which triggers the invocation of the property acquisition method. The property acquisition method determines the validity flag of the control's properties. When the validity flag of the control's properties is the first preset value, obtain the current focus property of the control. The current focus property is the in-focus property. Search for the in-focus style data corresponding to the in-focus property in the pre-stored layout file, and return the in-focus style data to the style update method; Based on the in-focus style data, the style update method draws the display style corresponding to the in-focus property on the control.
7. The display device according to claim 1, wherein The processor is further configured to: Receive an interaction behavior event triggered by the remote control. The interaction behavior event is triggered after the press event; If the interaction behavior event occurs inside the control, set the validity flag of the control's properties to the first preset value; Invoke the style update method, which triggers the invocation of the property acquisition method. The property acquisition method determines the validity flag of the control's properties. When the validity flag of the control's properties is the first preset value, obtain the current focus property of the control. The current focus property is the in-focus property. Search for the in-focus style data corresponding to the in-focus property in the pre-stored layout file, and return the in-focus style data to the style update method; Based on the in-focus style data, the style update method draws the display style corresponding to the in-focus property on the control; When the interactive behavior event occurs outside the control, set the property validity flag of the control to a second preset value; Invoke a style update method, which triggers the invocation of an attribute acquisition method. The attribute acquisition method determines the property validity flag of the control. When the property validity flag of the control is the second preset value, search for the out-of-focus style data corresponding to the out-of-focus attribute from a pre-stored layout file, and return the out-of-focus style data to the style update method; the style update method draws the display style corresponding to the out-of-focus attribute on the control based on the out-of-focus style data.
8. The display device according to claim 1, characterized in that, The processor is further configured to: When detecting an update of the focus attribute, call back a focus state acquisition method to obtain the current focus attribute of the target control whose focus attribute has been updated; set the property validity flag of the target control to a first preset value; Invoke a style update method, which triggers the invocation of an attribute acquisition method; the attribute acquisition method determines the property validity flag corresponding to the target control. When the property validity flag of the target control is the first preset value, obtain the current focus attribute of the target control, search for the style data corresponding to the current focus attribute from a pre-stored layout file, and return the style data to the style update method; the style update method draws the display style corresponding to the current focus attribute on the control based on the style data.
9. The display device according to claim 1, wherein The control is a parent control, and the parent control includes at least one child control; the processor executes drawing the display style corresponding to the in-focus attribute on the control based on the first preset value, and is further configured to: Based on the first preset value, draw the display style corresponding to the in-focus attribute on the parent control and the at least one child control; The processor executes drawing the display style corresponding to the out-of-focus attribute on the control based on the second preset value, and is further configured to: Based on the second preset value, draw the display style corresponding to the out-of-focus attribute on the parent control and the at least one child control.
10. A display style control method, characterized in that, Comprising: When detecting that the cursor moves into the control, set the focus attribute of the control to the in-focus attribute, and set the property validity flag of the control to the first preset value; And draw the display style corresponding to the in-focus attribute on the control based on the first preset value; When detecting that the cursor moves out of the control, keep the focus attribute of the control as the in-focus attribute, set the property validity flag of the control to the second preset value; and draw the display style corresponding to the out-of-focus attribute on the control based on the second preset value.