CN110618852A - View processing method, view processing device and terminal equipment - Google Patents

View processing method, view processing device and terminal equipment Download PDF

Info

Publication number
CN110618852A
CN110618852A CN201910905299.8A CN201910905299A CN110618852A CN 110618852 A CN110618852 A CN 110618852A CN 201910905299 A CN201910905299 A CN 201910905299A CN 110618852 A CN110618852 A CN 110618852A
Authority
CN
China
Prior art keywords
view
type
dialog
processing method
views
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN201910905299.8A
Other languages
Chinese (zh)
Other versions
CN110618852B (en
Inventor
刘开辉
范锦浩
陈志业
吴颖仪
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Guangdong Oppo Mobile Telecommunications Corp Ltd
Original Assignee
Guangdong Oppo Mobile Telecommunications Corp Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Guangdong Oppo Mobile Telecommunications Corp Ltd filed Critical Guangdong Oppo Mobile Telecommunications Corp Ltd
Priority to CN201910905299.8A priority Critical patent/CN110618852B/en
Publication of CN110618852A publication Critical patent/CN110618852A/en
Application granted granted Critical
Publication of CN110618852B publication Critical patent/CN110618852B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/451Execution arrangements for user interfaces

Abstract

The application is applicable to the technical field of terminals, and provides a view processing method, a view processing device and terminal equipment, which comprise the following steps: when the dark mode is detected to be started, acquiring all views on the current interface; acquiring the type of each view in all the views; and adjusting the background color of each view according to the type of each view. The method and the device can solve the problem that the contrast of the interface of the terminal equipment is not obvious in a dark mode in the prior art.

Description

View processing method, view processing device and terminal equipment
Technical Field
The present application belongs to the technical field of terminals, and in particular, to a view processing method, a view processing apparatus, and a terminal device.
Background
The dark mode is a design of forming an interface by using a large area of dark color in the UI interface, and the dark mode can reduce the brightness of a screen and save the power of the terminal device while maintaining the color contrast. However, when the existing terminal device is turned on in the dark mode, the contrast is limited by google, and the interface contrast in the dark mode is not obvious.
Disclosure of Invention
The application provides a view processing method, a view processing device and a terminal device, which are used for solving the problem that in the prior art, the contrast of an interface of the terminal device is not obvious in a dark mode.
A first aspect of the present application provides a view processing method, including:
when the dark mode is detected to be started, acquiring all views on the current interface;
acquiring the type of each view in all the views;
and adjusting the background color of each view according to the type of each view.
A second aspect of the present application provides a view processing apparatus including:
the view acquisition module is used for acquiring all views on the current interface when the dark color mode is detected to be started;
the type acquisition module is used for acquiring the type of each view in all the views;
and the color adjusting module is used for adjusting the background color of each view according to the type of each view.
A third aspect of the present application provides a terminal device comprising a memory, a processor and a computer program stored in the memory and executable on the processor, the processor implementing the steps of the view processing method according to the first aspect when executing the computer program.
A fourth aspect of the present application provides a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, performs the steps of the view processing method according to the first aspect as described above.
A fifth aspect of the present application provides a computer program product, which, when run on a terminal device, causes the terminal device to perform the steps of the view processing method of the first aspect.
Therefore, when the dark mode is detected to be started, all views on the current interface are obtained, the type of each view in all the views is obtained, and the background color of each view is adjusted according to the type of each view, so that when the terminal equipment starts the dark mode, the background color of the views is adjusted according to the type of the views, the background color level of the views on the interface is increased, and the contrast of the interface in the dark mode is enhanced.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings needed to be used in the embodiments or the prior art descriptions will be briefly described below, and it is obvious that the drawings in the following description are only some embodiments of the present application, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without inventive exercise.
Fig. 1 is a schematic flow chart of an implementation of a view processing method according to an embodiment of the present application;
FIG. 2 is an exemplary diagram of adjusting a background color of a view according to a type of the view;
fig. 3 is a schematic flow chart of an implementation of a view processing method provided in the second embodiment of the present application;
FIG. 4 is a schematic view of a view processing apparatus provided in the third embodiment of the present application;
fig. 5 is a schematic diagram of a terminal device provided in the fourth embodiment of the present application;
fig. 6 is a schematic diagram of a terminal device provided in the fifth embodiment of the present application.
Detailed Description
In the following description, for purposes of explanation and not limitation, specific details are set forth, such as particular system structures, techniques, etc. in order to provide a thorough understanding of the embodiments of the present application. It will be apparent, however, to one skilled in the art that the present application may be practiced in other embodiments that depart from these specific details. In other instances, detailed descriptions of well-known systems, devices, circuits, and methods are omitted so as not to obscure the description of the present application with unnecessary detail.
It will be understood that the terms "comprises" and/or "comprising," when used in this specification and the appended claims, specify the presence of stated features, integers, steps, operations, elements, and/or components, but do not preclude the presence or addition of one or more other features, integers, steps, operations, elements, components, and/or groups thereof.
It is also to be understood that the terminology used in the description of the present application herein is for the purpose of describing particular embodiments only and is not intended to be limiting of the application. As used in the specification of the present application and the appended claims, the singular forms "a," "an," and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise.
It should be further understood that the term "and/or" as used in this specification and the appended claims refers to and includes any and all possible combinations of one or more of the associated listed items.
As used in this specification and the appended claims, the term "if" may be interpreted contextually as "when", "upon" or "in response to a determination" or "in response to a detection". Similarly, the phrase "if it is determined" or "if a [ described condition or event ] is detected" may be interpreted contextually to mean "upon determining" or "in response to determining" or "upon detecting [ described condition or event ]" or "in response to detecting [ described condition or event ]".
In particular implementations, the terminal devices described in embodiments of the present application include, but are not limited to, other portable devices such as mobile phones, laptop computers, or tablet computers having touch sensitive surfaces (e.g., touch screen displays and/or touch pads). It should also be understood that in some embodiments, the device is not a portable communication device, but is a desktop computer having a touch-sensitive surface (e.g., a touch screen display and/or touchpad).
In the discussion that follows, a terminal device that includes a display and a touch-sensitive surface is described. However, it should be understood that the terminal device may include one or more other physical user interface devices such as a physical keyboard, mouse, and/or joystick.
The terminal device supports various applications, such as one or more of the following: a drawing application, a presentation application, a word processing application, a website creation application, a disc burning application, a spreadsheet application, a gaming application, a telephone application, a video conferencing application, an email application, an instant messaging application, an exercise support application, a photo management application, a digital camera application, a web browsing application, a digital music player application, and/or a digital video player application.
Various applications that may be executed on the terminal device may use at least one common physical user interface device, such as a touch-sensitive surface. One or more functions of the touch-sensitive surface and corresponding information displayed on the terminal can be adjusted and/or changed between applications and/or within respective applications. In this way, a common physical architecture (e.g., touch-sensitive surface) of the terminal can support various applications with user interfaces that are intuitive and transparent to the user.
It should be understood that, the sequence numbers of the steps in this embodiment do not mean the execution sequence, and the execution sequence of each process should be determined by the function and the inherent logic of the process, and should not constitute any limitation to the implementation process of the embodiment of the present application.
In order to explain the technical solution described in the present application, the following description will be given by way of specific examples.
Referring to fig. 1, it is a schematic view of an implementation flow of a view processing method provided in an embodiment of the present application, where the view processing method is applied to a terminal device, and as shown in the figure, the view processing method may include the following steps:
and step S101, when the dark color mode is detected to be started, acquiring all views on the current interface.
In this embodiment, the dark mode may refer to a mode in which the background brightness of all views on the interface is less than a preset brightness, that is, a mode in which the color of the interface is dark. Where, luminance refers to the L component in the lab (lab color space) color space, ranging from 0 to 100, representing from pure black to pure white. The LAB color space also includes an a component representing a range from magenta to green and a B component representing a range from yellow to blue. The current interface may refer to an interface currently displayed on a screen of the terminal device. The interface is usually composed of a plurality of views which are regularly combined, for example, a text box, a picture, a dialog box and other views are added on one interface view (i.e. a base view of the whole interface, and other views can be added on the interface view). A View (i.e., View) may also be referred to as a control.
Step S102, acquiring the type of each view in all the views.
Step S103, adjusting the background color of each view according to the type of each view.
In the embodiment of the application, after all the views on the current interface are acquired, as the terminal device starts a dark mode, the colors of all the views on the current interface need to be redrawn, when the color of each view in all the views on the current interface is redrawn, the type of each view can be acquired through the class called by each view during drawing, the target color of the background of each view is acquired according to the type of each view, and the background color of each view is modified from the current color to the target color, so that the adjustment of the background color of each view is realized. For example, adding a text box, a dialog box, etc. to one interface view, when adjusting the background color of all the views on the interface, the background color of the interface view and the text box may be adjusted to pure black, and the background color of the dialog box may be adjusted to gray, as shown in fig. 2.
The adjusting the background color of each view according to the type of each view comprises:
acquiring a dimming algorithm corresponding to the type of each view;
and adjusting the background color of each view according to the dimming algorithm corresponding to the type of each view.
Wherein the dimming algorithm may refer to an algorithm that reduces or decreases the L component of the background color of the view, such that the background color of the view is dimmed. When the terminal equipment does not start the dark color mode, the L component of the background color of the view is larger, the L component of the background color of the view is reduced through a dimming algorithm, and the background color of the view can be dimmed, so that the whole interface is darker, and the requirement of a user on the dark color mode is met. Different types of views may enhance the contrast of the interface using different dimming algorithms.
It should be noted that, when adjusting the background color of each view, the background color of each view may be first converted from an RGB color space (i.e., an RGB color mode) to an LAB color space, and the adjustment of the background color of each view is realized by adjusting an L component in the LAB color space, so that when the terminal device starts the dark color mode, the background colors of all the views on the interface are darkened, and after adjusting the L component of the background color of each view, the background color of each view is then converted from the LAB color space to the RGB color space according to the adjusted L component, so as to display the color of each view on the interface. The implementation methods for converting the RGB color space into the LAB color space and converting the LAB color space into the RGB color space can be referred to in the prior art, and are not described herein again.
The embodiment of the application can be applied to system layer application and third party application, the split feeling of the system layer application and the third party application in use experience is reduced, when the dark mode of the terminal equipment is started, the background color of the view is adjusted according to the type of the view, the background color level of the view on the interface can be increased, the dark color contrast is effectively improved, and the contrast of the interface in the dark mode is enhanced.
Referring to fig. 3, it is a schematic flow chart of an implementation of a view processing method provided in the second embodiment of the present application, where the view processing method is applied to a terminal device, and as shown in the figure, the view processing method may include the following steps:
in step S301, when an instruction to turn on the dark color mode is received, the dark color mode is turned on.
In the embodiment of the application, a dark mode option can be added in the system setting of the terminal equipment, a user can determine whether to start the dark mode according to actual requirements, and the dark mode is started when an instruction for starting the dark mode triggered by the user is detected; or when detecting that the terminal device is in a preset use scene and/or the light intensity of the environment where the terminal device is located is lower than the preset intensity, automatically triggering to generate an instruction for starting the dark color mode to use, and starting the dark color mode when the terminal device receives the instruction for starting the dark color mode. The preset use scene and the preset intensity may be preset by a user (for example, a plurality of use scenes and/or a plurality of light intensities are set in the terminal device, the user may select at least one of the plurality of use scenes as the preset use scene, and select at least one of the plurality of light intensities as the preset intensity), or machine learning may be added in the terminal device, according to a behavior track of the user adjusting the screen brightness, the light intensity of the use scene of the terminal device or an environment where the terminal device is located when the user adjusts the screen brightness to be lower than the preset brightness is recorded, the use scene is used as the preset use scene, and the light intensity is used as the preset light intensity. Optionally, the user may set the preset brightness according to actual needs, which is not limited herein. The preset usage scenario may be a scenario in which a terminal device performs a preset operation, such as a photographing scenario and a payment scenario.
Step S302, all views on the current interface are obtained.
The step is partially the same as step S101, and reference may be made to the related description of step S101, which is not repeated herein.
Step S303, detecting whether each view in all the views is a dialog view.
In the embodiment of the application, the types of the views can be divided into an dialog box type and a non-dialog box type, and the classification of all the views on the current interface is realized by detecting whether each view in all the views on the current interface is a dialog box view. Wherein each view refers to any one of all views.
Optionally, the detecting whether each view is a dialog view includes:
detecting whether each view calls a Dialog class;
if the fact that the Dialog class is called by each view is detected, determining each view as a Dialog box view;
and if detecting that the Dialog class is not called by each view, determining that each view is not a Dialog view.
In the embodiment of the present application, when a Dialog view is drawn, a Dialog class needs to be called, and then it may be determined whether the Dialog view is a Dialog view by detecting whether each view in all views on a current interface calls the Dialog class, for example, when the color of two views (respectively, a text box view and a Dialog view) on the current interface is redrawn, it is detected that the Dialog class is not called when the color of one view is redrawn, it is determined that the view is not a Dialog view; and detecting that the Dialog class is called when the color of the other view is redrawn, determining the view as the Dialog box view. Wherein the Dialog class is a base class of the Dialog box.
Step S304, if each view is a dialog box view, determining that the type of each view is a dialog box type, and the dimming algorithm corresponding to the type of each view is L2=min{La-L1,100}。
In the embodiment of the application, when a dialog box view exists in all views of a current interface, in order to enhance the contrast between the dialog box and the whole interface and make the hierarchy of the dialog box and the whole interface obvious, when the background color of all views on the interface is adjusted, the background color of the dialog box view and the background color of other views on the interface can be adjusted to be different through different dimming algorithms, so that the backgrounds of the dialog box and the whole interface are darkened from white to different colors, the display effect is differentiated, and the contrast is obvious.
Wherein L is2Adjusted brightness, L, for the background color of each view1The brightness before the background color of each view is adjusted (i.e. the current brightness of the background color of the view), LaIs a number greater than 100, LaIs a preset constant greater than 100, e.g., 120, 30, etc., setting LaIn order to distinguish between non-dialog type views when displayed in color. Alternatively to this, the first and second parts may,the embodiment of the application further comprises:
displaying a plurality of different La
Obtaining user-selected LaAnd the L selected by the user is selectedaApplied to the dimming algorithm L2=min{La-L1100 }.
In the embodiment of the present application, a plurality of different ls may be preset in the terminal deviceaTo provide a plurality of different contrast modes (using different L in the dimming algorithm)aDifferent contrast ratios when displayed on the interface) for the user to select, increasing the selectivity of the contrast ratio mode. For example, the current brightness L of the background color of the dialog view1Is 100 at LaWhen the brightness is 120, the brightness of the dialog box view after background color adjustment is 20; at LaAt 130, the brightness of the dialog box view after background color adjustment is 30; when the background color of the dialog box view is converted into RGB according to the adjusted brightness for color display, the display effect with the brightness of 20 is darker than the display effect with the brightness of 30.
Step S305, if each view is not a dialog box view, determining that the type of each view is a non-dialog box type, and the dimming algorithm corresponding to the type of each view is L2=100-L1
In this embodiment of the application, since the brightness of the background color of all the views on the interface is usually 100 (i.e., pure white) when the dark mode is not turned on by the terminal device, when a view other than the view of the dialog box exists on the interface, the brightness of the background color of the view other than the view of the dialog box may be changed to 0 by the above-mentioned dimming algorithm, that is, the background color of the view other than the view of the dialog box is changed from white to pure appropriate, so that the screen of the terminal device is further saved in power, and the cruising ability of the terminal device is extended.
Step S306, adjusting the background color of each view according to the dimming algorithm corresponding to the type of each view.
In this embodiment of the present application, different types of views on the current interface may adjust the brightness of the background color of the view according to a corresponding dimming algorithm, and convert the background color of the view from the LAB color space to the RGB color space according to the adjusted brightness (i.e., the L component) and the a component and the B component before adjustment, thereby implementing adjustment of the background color of the view.
It should be noted that when the view calls the corresponding dimming algorithm, the dimming algorithm may be transmitted to the node corresponding to the view for storage, after the view is drawn, the node transmits the dimming algorithm to the canvas before drawing, performs corresponding dimming algorithm processing on the background color of the view before subsequently executing all draw OP commands, and finally draws again to obtain the final color display effect.
According to the method and the device, the dialog box view and the non-dialog box view on the current interface are subjected to different dimming algorithms, so that the interface contrast can be effectively enhanced, and the display effect of the dialog box and the background of the whole interface after dimming is differentiated.
Referring to fig. 4, a schematic view of a view processing apparatus provided in the third embodiment of the present application is shown, and for convenience of description, only the portions related to the third embodiment of the present application are shown.
The view processing apparatus includes:
a view obtaining module 41, configured to obtain all views on the current interface when the dark color mode is detected to be turned on;
a type obtaining module 42, configured to obtain a type of each view in all views;
a color adjusting module 43, configured to adjust a background color of each view according to the type of each view.
Optionally, the type obtaining module 42 includes:
the view detection unit is used for detecting whether each view is a dialog box view;
a first determining unit, configured to determine that the type of each view is an dialog box type if each view is a dialog box view;
a second determining unit, configured to determine that the type of each view is a non-dialog type if the each view is not a dialog view.
Optionally, the view detecting unit is configured to:
detecting whether each view calls a Dialog class;
if the fact that the Dialog class is called by each view is detected, determining each view as a Dialog box view;
and if detecting that the Dialog class is not called by each view, determining that each view is not a Dialog view.
Optionally, the color adjusting module 43 includes:
the algorithm acquisition unit is used for acquiring a dimming algorithm corresponding to each view type;
and the adjusting unit is used for adjusting the background color of each view according to the dimming algorithm corresponding to the type of each view.
Optionally, the algorithm obtaining unit is configured to:
if the type of each view is the dialog box type, determining that a dimming algorithm corresponding to the type of each view is L2=min{La-L1,100};
If the type of each view is a non-dialog box type, determining that a dimming algorithm corresponding to the type of each view is L2=100-L1
Wherein L is2Adjusted brightness, L, for the background color of each view1Adjusting the brightness, L, of the background color of each viewaA number greater than 100.
Optionally, the algorithm obtaining unit is further configured to:
displaying a plurality of different La
Obtaining user-selected LaAnd the L selected by the user is selectedaApplied to the dimming algorithm L2=min{La-L1100 }.
Optionally, the view processing apparatus further includes:
and a mode opening module 44, configured to open the dark color mode when receiving an instruction to open the dark color mode.
The view processing apparatus provided in the embodiment of the present application can be applied to the first method embodiment and the second method embodiment, and for details, reference is made to the description of the first method embodiment and the second method embodiment, and details are not repeated here.
Fig. 5 is a schematic diagram of a terminal device according to a fourth embodiment of the present application. The terminal device as shown in the figure may include: one or more processors 501 (only one shown); one or more input devices 502 (only one shown), one or more output devices 503 (only one shown), and a memory 504. The processor 501, the input device 502, the output device 503, and the memory 504 are connected by a bus 505. The memory 504 is used for storing instructions and the processor 501 is used for executing the instructions stored by the memory 504. Wherein:
the processor 501 is configured to, when it is detected that the dark mode is turned on, obtain all views on the current interface;
acquiring the type of each view in all the views;
and adjusting the background color of each view according to the type of each view.
Optionally, the processor 501 is specifically configured to:
detecting whether each view is a dialog view;
if each view is a dialog box view, determining the type of each view as an dialog box type;
and if the view is not a dialog box view, determining that the type of the view is a non-dialog box type.
Optionally, the processor 501 is specifically configured to:
detecting whether each view calls a Dialog class;
if the fact that the Dialog class is called by each view is detected, determining each view as a Dialog box view;
and if detecting that the Dialog class is not called by each view, determining that each view is not a Dialog view.
Optionally, the processor 501 is specifically configured to:
acquiring a dimming algorithm corresponding to the type of each view;
and adjusting the background color of each view according to the dimming algorithm corresponding to the type of each view.
Optionally, the processor 501 is specifically configured to:
if the type of each view is the dialog box type, determining that a dimming algorithm corresponding to the type of each view is L2=min{La-L1,100};
If the type of each view is a non-dialog box type, determining that a dimming algorithm corresponding to the type of each view is L2=100-L1
Wherein L is2Adjusted brightness, L, for the background color of each view1Adjusting the brightness, L, of the background color of each viewaA number greater than 100.
Optionally, the processor 501 is further configured to:
displaying a plurality of different La
Obtaining user-selected LaAnd the L selected by the user is selectedaApplied to the dimming algorithm L2=min{La-L1100 }.
Optionally, the processor 501 is further configured to:
when an instruction to turn on a dark mode is received, the dark mode is turned on.
It should be understood that, in the embodiment of the present Application, the Processor 501 may be a Central Processing Unit (CPU), and the Processor may also be other general purpose processors, Digital Signal Processors (DSPs), Application Specific Integrated Circuits (ASICs), Field Programmable Gate Arrays (FPGAs) or other Programmable logic devices, discrete Gate or transistor logic devices, discrete hardware components, and the like. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
The input device 502 may include a touch pad, a fingerprint sensor (for collecting fingerprint information of a user and direction information of the fingerprint), a microphone, a data receiving interface, and the like. The output device 503 may include a display (LCD, etc.), a speaker, a data transmission interface, and the like.
The memory 504 may include a read-only memory and a random access memory, and provides instructions and data to the processor 501. A portion of the memory 504 may also include non-volatile random access memory. For example, the memory 504 may also store device type information.
In a specific implementation, the processor 501, the input device 502, the output device 503, and the memory 504 described in this embodiment of the present application may execute the implementation described in the embodiment of the view processing method provided in this embodiment of the present application, or may execute the implementation described in the view processing apparatus described in the third embodiment of the present application, which is not described herein again.
Fig. 6 is a schematic diagram of a terminal device provided in the fifth embodiment of the present application. As shown in fig. 6, the terminal device 6 of this embodiment includes: a processor 60, a memory 61 and a computer program 62 stored in said memory 61 and executable on said processor 60. The processor 60 implements the steps in the various view processing method embodiments described above when executing the computer program 62. Alternatively, the processor 60 implements the functions of the modules/units in the above-described view processing apparatus embodiment when executing the computer program 62.
Illustratively, the computer program 62 may be partitioned into one or more modules/units that are stored in the memory 61 and executed by the processor 60 to accomplish the present application. The one or more modules/units may be a series of computer program instruction segments capable of performing specific functions, which are used to describe the execution of the computer program 62 in the terminal device 6. For example, the computer program 62 may be divided into an event acquisition module, a display module, an update module, and an information transmission module, and each module has the following specific functions:
the terminal device 6 may be a desktop computer, a notebook, a palm computer, a cloud server, or other computing devices. The terminal device may include, but is not limited to, a processor 60, a memory 61. Those skilled in the art will appreciate that fig. 6 is merely an example of a terminal device 6 and does not constitute a limitation of terminal device 6 and may include more or less components than those shown, or some components in combination, or different components, for example, the terminal device may also include input output devices, network access devices, buses, etc.
The processor 60 may be a central processing unit CPU, but may also be other general purpose processors, digital signal processors DSP, application specific integrated circuits ASIC, off-the-shelf programmable gate arrays FPGA or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
The memory 61 may be an internal storage unit of the terminal device 6, such as a hard disk or a memory of the terminal device 6. The memory 61 may also be an external storage device of the terminal device 6, such as a plug-in hard disk, a Smart Media Card (SMC), a Secure Digital (SD) Card, a Flash memory Card (Flash Card), and the like, which are provided on the terminal device 6. Further, the memory 61 may also include both an internal storage unit and an external storage device of the terminal device 6. The memory 61 is used for storing the computer program and other programs and data required by the terminal device. The memory 61 may also be used to temporarily store data that has been output or is to be output.
It will be apparent to those skilled in the art that, for convenience and brevity of description, only the above-mentioned division of the functional units and modules is illustrated, and in practical applications, the above-mentioned function distribution may be performed by different functional units and modules according to needs, that is, the internal structure of the apparatus is divided into different functional units or modules to perform all or part of the above-mentioned functions. Each functional unit and module in the embodiments may be integrated in one processing unit, or each unit may exist alone physically, or two or more units are integrated in one unit, and the integrated unit may be implemented in a form of hardware, or in a form of software functional unit. In addition, specific names of the functional units and modules are only for convenience of distinguishing from each other, and are not used for limiting the protection scope of the present application. The specific working processes of the units and modules in the system may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
In the above embodiments, the descriptions of the respective embodiments have respective emphasis, and reference may be made to the related descriptions of other embodiments for parts that are not described or illustrated in a certain embodiment.
Those of ordinary skill in the art will appreciate that the various illustrative elements and algorithm steps described in connection with the embodiments disclosed herein may be implemented as electronic hardware or combinations of computer software and electronic hardware. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the implementation. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present application.
In the embodiments provided in the present application, it should be understood that the disclosed apparatus/terminal device and method may be implemented in other ways. For example, the above-described embodiments of the apparatus/terminal device are merely illustrative, and for example, the division of the modules or units is only one logical division, and there may be other divisions when actually implemented, for example, a plurality of units or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or units, and may be in an electrical, mechanical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present application may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit can be realized in a form of hardware, and can also be realized in a form of a software functional unit.
The embodiments of the present application further provide a computer-readable storage medium, where a computer program is stored, and when the computer program is executed by a processor, the computer program implements the steps in the above-mentioned method embodiments.
The embodiments of the present application provide a computer program product, which when running on a terminal device, enables the terminal device to implement the steps in the above method embodiments when executed.
The integrated modules/units, if implemented in the form of software functional units and sold or used as separate products, may be stored in a computer readable storage medium. Based on such understanding, all or part of the flow in the method of the embodiments described above can be realized by a computer program, which can be stored in a computer-readable storage medium and can realize the steps of the embodiments of the methods described above when the computer program is executed by a processor. Wherein the computer program comprises computer program code, which may be in the form of source code, object code, an executable file or some intermediate form, etc. The computer-readable medium may include: any entity or device capable of carrying the computer program code, recording medium, usb disk, removable hard disk, magnetic disk, optical disk, computer Memory, Read-Only Memory (ROM), Random Access Memory (RAM), electrical carrier wave signals, telecommunications signals, software distribution medium, and the like. It should be noted that the computer readable medium may contain content that is subject to appropriate increase or decrease as required by legislation and patent practice in jurisdictions, for example, in some jurisdictions, computer readable media does not include electrical carrier signals and telecommunications signals as is required by legislation and patent practice.
The above-mentioned embodiments are only used for illustrating the technical solutions of the present application, and not for limiting the same; although the present application has been described in detail with reference to the foregoing embodiments, it should be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; such modifications and substitutions do not substantially depart from the spirit and scope of the embodiments of the present application and are intended to be included within the scope of the present application.

Claims (10)

1. A view processing method, characterized in that the view processing method comprises:
when the dark mode is detected to be started, acquiring all views on the current interface;
acquiring the type of each view in all the views;
and adjusting the background color of each view according to the type of each view.
2. The view processing method according to claim 1, wherein said acquiring a type of each of all views comprises:
detecting whether each view is a dialog view;
if each view is a dialog box view, determining the type of each view as an dialog box type;
and if the view is not a dialog box view, determining that the type of the view is a non-dialog box type.
3. The view processing method of claim 2, wherein said detecting whether each of said views is a dialog view comprises:
detecting whether each view calls a Dialog class;
if the fact that the Dialog class is called by each view is detected, determining each view as a Dialog box view;
and if detecting that the Dialog class is not called by each view, determining that each view is not a Dialog view.
4. The view processing method according to claim 2, wherein said adjusting the background color of said each view according to the type of said each view comprises:
acquiring a dimming algorithm corresponding to the type of each view;
and adjusting the background color of each view according to the dimming algorithm corresponding to the type of each view.
5. The view processing method according to claim 4, wherein said obtaining the dimming algorithm corresponding to the type of each view comprises:
if the type of each view is the dialog box type, determining that a dimming algorithm corresponding to the type of each view is L2=min{La-L1,100};
If the type of each view is a non-dialog box type, determining that a dimming algorithm corresponding to the type of each view is L2=100-L1
Wherein L is2Adjusted brightness, L, for the background color of each view1Adjusting the brightness, L, of the background color of each viewaA number greater than 100.
6. The view processing method of claim 5, wherein the dimming algorithm corresponding to the type of each view is determined to be L2=min{La-L1100, further comprising:
displaying a plurality of different La
Obtaining user-selected LaAnd the L selected by the user is selectedaApplied to the dimming algorithm L2=min{La-L1100 }.
7. The view processing method according to any one of claims 1 to 6, further comprising:
when an instruction to turn on a dark mode is received, the dark mode is turned on.
8. A view processing apparatus characterized by comprising:
the view acquisition module is used for acquiring all views on the current interface when the dark color mode is detected to be started;
the type acquisition module is used for acquiring the type of each view in all the views;
and the color adjusting module is used for adjusting the background color of each view according to the type of each view.
9. A terminal device comprising a memory, a processor and a computer program stored in the memory and executable on the processor, characterized in that the processor implements the steps of the view processing method according to any of claims 1 to 7 when executing the computer program.
10. A computer-readable storage medium, in which a computer program is stored which, when being executed by a processor, carries out the steps of the view processing method according to any one of claims 1 to 7.
CN201910905299.8A 2019-09-24 2019-09-24 View processing method, view processing device and terminal equipment Active CN110618852B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910905299.8A CN110618852B (en) 2019-09-24 2019-09-24 View processing method, view processing device and terminal equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910905299.8A CN110618852B (en) 2019-09-24 2019-09-24 View processing method, view processing device and terminal equipment

Publications (2)

Publication Number Publication Date
CN110618852A true CN110618852A (en) 2019-12-27
CN110618852B CN110618852B (en) 2023-12-29

Family

ID=68924263

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910905299.8A Active CN110618852B (en) 2019-09-24 2019-09-24 View processing method, view processing device and terminal equipment

Country Status (1)

Country Link
CN (1) CN110618852B (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111223432A (en) * 2020-01-10 2020-06-02 北京小米移动软件有限公司 Method and device for controlling screen display
CN112331158A (en) * 2020-11-18 2021-02-05 北京小米移动软件有限公司 Terminal display adjusting method, device, equipment and storage medium
CN113781959A (en) * 2021-09-23 2021-12-10 Oppo广东移动通信有限公司 Interface processing method and device

Citations (18)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20060010374A1 (en) * 2004-07-09 2006-01-12 Microsoft Corporation Defining the visual appearance of user-interface controls
CN101877745A (en) * 2010-06-30 2010-11-03 中兴通讯股份有限公司 Power saving system and method for mobile terminal
US20120200587A1 (en) * 2011-02-09 2012-08-09 Qualcomm Innovation Center, Inc. Method and Apparatus For Content-Based Reduction of Display Power
US20120306906A1 (en) * 2011-06-03 2012-12-06 Apple Inc. Color-Space Selective Darkness and Lightness Adjustment
US8675019B1 (en) * 2009-12-03 2014-03-18 Innoventions, Inc. View navigation guidance system for hand held devices with display
US20150205505A1 (en) * 2014-01-17 2015-07-23 Jeremy B. Conn Dynamic adjustment of a user interface
CN105511717A (en) * 2015-11-30 2016-04-20 北京京东尚科信息技术有限公司 Page display method and page display device
US20160246475A1 (en) * 2015-02-22 2016-08-25 Microsoft Technology Licensing, Llc Dynamic icon recoloring to improve contrast
CN106033334A (en) * 2015-03-11 2016-10-19 腾讯科技(深圳)有限公司 An interface element drawing method and device
CN106484396A (en) * 2016-09-18 2017-03-08 北京京东尚科信息技术有限公司 Night changing method, device and terminal unit
CN107038037A (en) * 2017-05-22 2017-08-11 北京小米移动软件有限公司 Display mode switching method and device
US20180101506A1 (en) * 2016-10-06 2018-04-12 Microsoft Technology Licensing, Llc User Interface
CN108874134A (en) * 2018-06-12 2018-11-23 Oppo(重庆)智能科技有限公司 Eyeshield mode treatment method, mobile terminal and computer readable storage medium
CN109413264A (en) * 2018-09-26 2019-03-01 维沃移动通信有限公司 A kind of background picture method of adjustment and terminal device
WO2019095392A1 (en) * 2017-11-20 2019-05-23 华为技术有限公司 Method and device for dynamically displaying icon according to background image
CN109917901A (en) * 2019-02-25 2019-06-21 努比亚技术有限公司 The color adjustment method and wearable device of picture are applied in wearable device
CN110069312A (en) * 2019-04-26 2019-07-30 北京三快在线科技有限公司 A kind of method and device of UI component Configuration and generation UI Component Gallery
CN110113534A (en) * 2019-05-13 2019-08-09 Oppo广东移动通信有限公司 A kind of image processing method, image processing apparatus and mobile terminal

Patent Citations (18)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20060010374A1 (en) * 2004-07-09 2006-01-12 Microsoft Corporation Defining the visual appearance of user-interface controls
US8675019B1 (en) * 2009-12-03 2014-03-18 Innoventions, Inc. View navigation guidance system for hand held devices with display
CN101877745A (en) * 2010-06-30 2010-11-03 中兴通讯股份有限公司 Power saving system and method for mobile terminal
US20120200587A1 (en) * 2011-02-09 2012-08-09 Qualcomm Innovation Center, Inc. Method and Apparatus For Content-Based Reduction of Display Power
US20120306906A1 (en) * 2011-06-03 2012-12-06 Apple Inc. Color-Space Selective Darkness and Lightness Adjustment
US20150205505A1 (en) * 2014-01-17 2015-07-23 Jeremy B. Conn Dynamic adjustment of a user interface
US20160246475A1 (en) * 2015-02-22 2016-08-25 Microsoft Technology Licensing, Llc Dynamic icon recoloring to improve contrast
CN106033334A (en) * 2015-03-11 2016-10-19 腾讯科技(深圳)有限公司 An interface element drawing method and device
CN105511717A (en) * 2015-11-30 2016-04-20 北京京东尚科信息技术有限公司 Page display method and page display device
CN106484396A (en) * 2016-09-18 2017-03-08 北京京东尚科信息技术有限公司 Night changing method, device and terminal unit
US20180101506A1 (en) * 2016-10-06 2018-04-12 Microsoft Technology Licensing, Llc User Interface
CN107038037A (en) * 2017-05-22 2017-08-11 北京小米移动软件有限公司 Display mode switching method and device
WO2019095392A1 (en) * 2017-11-20 2019-05-23 华为技术有限公司 Method and device for dynamically displaying icon according to background image
CN108874134A (en) * 2018-06-12 2018-11-23 Oppo(重庆)智能科技有限公司 Eyeshield mode treatment method, mobile terminal and computer readable storage medium
CN109413264A (en) * 2018-09-26 2019-03-01 维沃移动通信有限公司 A kind of background picture method of adjustment and terminal device
CN109917901A (en) * 2019-02-25 2019-06-21 努比亚技术有限公司 The color adjustment method and wearable device of picture are applied in wearable device
CN110069312A (en) * 2019-04-26 2019-07-30 北京三快在线科技有限公司 A kind of method and device of UI component Configuration and generation UI Component Gallery
CN110113534A (en) * 2019-05-13 2019-08-09 Oppo广东移动通信有限公司 A kind of image processing method, image processing apparatus and mobile terminal

Non-Patent Citations (4)

* Cited by examiner, † Cited by third party
Title
汪小威: "基于Retinex亮度校正与感知对比度的图像增强算法", 《电子测量与仪器学报》 *
汪小威: "基于Retinex亮度校正与感知对比度的图像增强算法", 《电子测量与仪器学报》, no. 06, 30 June 2018 (2018-06-30) *
董菁等: "选择调整的亮度增强算法", 《液晶与显示》 *
董菁等: "选择调整的亮度增强算法", 《液晶与显示》, no. 04, 31 August 2008 (2008-08-31) *

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111223432A (en) * 2020-01-10 2020-06-02 北京小米移动软件有限公司 Method and device for controlling screen display
CN111223432B (en) * 2020-01-10 2024-02-13 北京小米移动软件有限公司 Method and device for controlling screen display
CN112331158A (en) * 2020-11-18 2021-02-05 北京小米移动软件有限公司 Terminal display adjusting method, device, equipment and storage medium
CN113781959A (en) * 2021-09-23 2021-12-10 Oppo广东移动通信有限公司 Interface processing method and device

Also Published As

Publication number Publication date
CN110618852B (en) 2023-12-29

Similar Documents

Publication Publication Date Title
US10958850B2 (en) Electronic device and method for capturing image by using display
CN111654594B (en) Image capturing method, image capturing apparatus, mobile terminal, and storage medium
US9607421B2 (en) Displaying particle effect on screen of electronic device
CN108900770B (en) Method and device for controlling rotation of camera, smart watch and mobile terminal
US11158057B2 (en) Device, method, and graphical user interface for processing document
CN110618852B (en) View processing method, view processing device and terminal equipment
CN110457963B (en) Display control method, display control device, mobile terminal and computer-readable storage medium
CN109298912B (en) Theme color adjusting method and device, storage medium and electronic equipment
CN111767554B (en) Screen sharing method and device, storage medium and electronic equipment
WO2018174581A1 (en) Method and device for controlling white balance function of electronic device
US20230345113A1 (en) Display control method and apparatus, electronic device, and medium
WO2021098609A1 (en) Method and device for image detection, and electronic device
CN109358927B (en) Application program display method and device and terminal equipment
US10438377B2 (en) Method and device for processing a page
WO2019184017A1 (en) Control display method and electronic device
WO2021068766A1 (en) Image display method, image display apparatus, and mobile terminal
CN112817555A (en) Volume control method and volume control device
CN112055156A (en) Preview image updating method and device, mobile terminal and storage medium
CN110705653A (en) Image classification method, image classification device and terminal equipment
CN111861965A (en) Image backlight detection method, image backlight detection device and terminal equipment
KR102643243B1 (en) Electronic device to support improved visibility for user interface
CN114038370A (en) Display parameter adjusting method and device, storage medium and display equipment
CN110688035B (en) Photo album processing method, photo album processing device and mobile terminal
CN107835553B (en) Method for controlling flashlight, mobile terminal and computer readable storage medium
CN110875875B (en) Electronic red packet message detection method and device and terminal equipment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant