CN111638927A - Skin switching method and device - Google Patents

Skin switching method and device Download PDF

Info

Publication number
CN111638927A
CN111638927A CN202010375901.4A CN202010375901A CN111638927A CN 111638927 A CN111638927 A CN 111638927A CN 202010375901 A CN202010375901 A CN 202010375901A CN 111638927 A CN111638927 A CN 111638927A
Authority
CN
China
Prior art keywords
skin
view
target
attribute information
switching
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202010375901.4A
Other languages
Chinese (zh)
Inventor
谢威威
张瑞峰
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Dajia Internet Information Technology Co Ltd
Original Assignee
Beijing Dajia Internet Information Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Dajia Internet Information Technology Co Ltd filed Critical Beijing Dajia Internet Information Technology Co Ltd
Priority to CN202010375901.4A priority Critical patent/CN111638927A/en
Publication of CN111638927A publication Critical patent/CN111638927A/en
Pending legal-status Critical Current

Links

Images

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 disclosure relates to a skin switching method and device, relates to the field of user pages, and can improve the efficiency of switching the user pages and skin, so that the user experience is improved. The specific scheme comprises the following steps: the skin switching device responds to the skin switching instruction and determines a target view of the skin to be switched in the page; determining a target skin to be switched according to the view of the target view, the skin mapping information and the current skin; the view and skin mapping information comprises mapping relations between corresponding views and supported skin resources; and switching the current skin of the target view into the target skin and then displaying.

Description

Skin switching method and device
Technical Field
The present disclosure relates to the field of user pages, and in particular, to a method and an apparatus for skin switching.
Background
At present, Applications (APP) on a terminal have a skin switching function in addition to satisfying specific functional requirements. Therefore, the problems of preference and aesthetic fatigue of the user can be solved, and different skin effects can be achieved for different scenes.
In the related art, a night mode (night mode) provided by a native system (e.g., android system) of a terminal allows creation of a resource directory suffixed with night, such as dry-night and values-night, for storing resource files in the night mode. In this way, when the user switches the current skin of the user page of an application to the skin of the night mode, the terminal may obtain the resource files of the night mode from the resource directory in which the night is suffix, and recreate the user page according to the resource files.
The related art has at least the following technical problems: since each user page includes a plurality of views (views), the user page is recreated, that is, each view supporting the night mode skin is recreated. This can make skin switching time consuming and inefficient, resulting in a poor user experience.
Disclosure of Invention
The present disclosure provides a skin switching method and device, which can improve the efficiency of switching the skin of a user page, thereby improving the user experience. The technical scheme of the disclosure is as follows:
according to a first aspect of the present disclosure, there is provided a skin switching method, the method comprising:
responding to a skin switching instruction, and determining a target view of a skin to be switched in a page;
determining a target skin to be switched according to the view of the target view, the skin mapping information and the current skin; the view and skin mapping information comprises mapping relations between corresponding views and supported skin resources;
and switching the current skin of the target view into the target skin and then displaying.
Optionally, the view and skin mapping information includes: mapping relation between the view and the attribute information of the current skin and mapping relation between the view and the attribute information of the skin supporting switching;
determining a target skin to be switched according to the view of the target view, the skin mapping information and the current skin, comprising:
and determining the target skin from the skin supporting switching according to the mapping relation between the view and the attribute information of the skin supporting switching and the current skin.
Optionally, the method further includes:
acquiring a pre-stored skin mapping file, and acquiring the view and skin mapping information from the skin mapping file;
alternatively, the first and second electrodes may be,
and acquiring a skin mapping file from a corresponding server, and acquiring the view and skin mapping information from the skin mapping file.
Optionally, the method further includes:
when the page is created, analyzing a view included in the page to obtain attribute information of the current skin of the view and attribute information of a skin which supports switching of the view;
and saving the mapping relation between the view and the attribute information of the current skin and the mapping relation between the view and the attribute information of the skin supporting switching.
Optionally, the method further includes:
and acquiring the attribute information of the target skin from the attribute information of the current skin according to a preset naming rule.
Optionally, the method further includes:
acquiring prestored skin resources corresponding to the attribute information of the target skin according to the attribute information of the target skin;
alternatively, the first and second electrodes may be,
and acquiring a skin resource corresponding to the attribute information of the target skin from a server according to the attribute information of the target skin.
Optionally, the switching the current skin of the target view to the target skin for displaying includes:
and after the skin resource corresponding to the attribute information of the target skin is acquired, switching the attribute information of the current skin of the target view into the attribute information of the target skin.
According to a second aspect of the present disclosure, there is provided a skin switching device comprising:
the determining module is configured to execute the step of determining a target view of the skin to be switched in the page in response to the skin switching instruction; determining a target skin to be switched according to the view of the target view, the skin mapping information and the current skin; the view and skin mapping information comprises mapping relations between corresponding views and supported skin resources;
and the display module is configured to perform displaying after the current skin of the target view is switched to the target skin.
Optionally, the view and skin mapping information includes: mapping relation between the view and the attribute information of the current skin and mapping relation between the view and the attribute information of the skin supporting switching;
the determining module is specifically configured to determine the target skin from the skin supporting the handover according to the mapping relationship between the view and the attribute information of the skin supporting the handover and the current skin.
Optionally, the skin switching device further comprises: an acquisition module;
the acquisition module is configured to execute acquisition of a pre-stored skin mapping file, and acquire the view and skin mapping information from the skin mapping file; or, acquiring a skin mapping file from a corresponding server, and acquiring the view and skin mapping information from the skin mapping file.
Optionally, the skin switching device further comprises: the device comprises an analysis module and a storage module;
the analysis module is configured to analyze a view included in the page when the page is created, so as to obtain attribute information of the current skin of the view and attribute information of a skin which the view supports switching;
the storage module is configured to perform saving of a mapping relationship between the view and the attribute information of the current skin and a mapping relationship between the view and the attribute information of the skin supporting switching.
Optionally, the obtaining module is further configured to perform obtaining, according to a preset naming rule, attribute information of the target skin from the attribute information of the current skin.
Optionally, the obtaining module is further configured to perform:
acquiring prestored skin resources corresponding to the attribute information of the target skin according to the attribute information of the target skin;
alternatively, the first and second electrodes may be,
and acquiring a skin resource corresponding to the attribute information of the target skin from a server according to the attribute information of the target skin.
Optionally, the display module is specifically configured to perform:
and after the skin resource corresponding to the attribute information of the target skin is acquired, switching the attribute information of the current skin of the target view into the attribute information of the target skin.
According to a third aspect of the present disclosure, there is provided a terminal comprising:
a processor;
a memory for storing the processor-executable instructions;
wherein the processor is configured to execute the instructions to implement any of the above-described optional skin-switch methods of the first aspect.
According to a fourth aspect of the present disclosure, there is provided a computer readable storage medium having instructions stored thereon, which when executed by a processor of a terminal, enable the terminal to perform any of the above-mentioned first aspect, optionally a skin switching method.
According to a fifth aspect of the present disclosure, there is provided a computer program product containing instructions which, when run on a computer, cause the computer to perform the method of optionally skin-switching as in any one of the first aspects.
The technical scheme provided by the disclosure at least brings the following beneficial effects: the skin switching device responds to the skin switching instruction, determines a target view of the skin to be switched in the page, determines the target skin to be switched according to the view, the skin mapping information and the current skin of the target view, wherein the view and the skin mapping information comprise a mapping relation between the corresponding view and the skin resources supported by the view and the skin mapping information, and finally switches the current skin of the target view into the target skin for displaying. Therefore, when the skin of the page is switched, the target skin to be switched can be determined directly according to the mapping relation between the view and the supported skin resources and the current skin, the current skin of the target view is switched to the target skin and then displayed, the skin can be switched directly and dynamically without rebuilding the page, the development amount is reduced, the time consumed by skin switching is reduced, and the skin switching efficiency is improved.
It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the disclosure.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present disclosure and, together with the description, serve to explain the principles of the disclosure and are not to be construed as limiting the disclosure.
Fig. 1 is a flow chart illustrating a skin switching method according to an exemplary embodiment.
Fig. 2 is a flow chart illustrating another skin switching method according to an example embodiment.
Fig. 3 is a flow chart illustrating another skin switching method according to an example embodiment.
FIG. 4 is a schematic diagram illustrating a page in accordance with an exemplary embodiment.
Fig. 5 is a block diagram illustrating a logical structure of a skin switching device according to an exemplary embodiment.
Fig. 6 is a block diagram illustrating a logical structure of another skin-switching device according to an exemplary embodiment.
Fig. 7 is a block diagram illustrating a structure of a terminal according to an exemplary embodiment.
Detailed Description
In order to make the technical solutions of the present disclosure better understood by those of ordinary skill in the art, the technical solutions in the embodiments of the present disclosure will be clearly and completely described below with reference to the accompanying drawings.
It should be noted that the terms "first," "second," and the like in the description and claims of the present disclosure and in the above-described drawings are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used is interchangeable under appropriate circumstances such that the embodiments of the disclosure described herein are capable of operation in sequences other than those illustrated or otherwise described herein. The implementations described in the exemplary embodiments below are not intended to represent all implementations consistent with the present disclosure. Rather, they are merely examples of apparatus and methods consistent with certain aspects of the present disclosure, as detailed in the appended claims.
The following description is provided for terms/nouns involved in embodiments of the present disclosure.
Page: the method refers to the overall design of human-computer interaction, operation logic and attractive interface of software.
View: refers to the individual components that make up a user's page, each view having a variety of attributes. An attribute name may be declared for each attribute of the view to distinguish between different attributes of the view. And each attribute can be assigned with a corresponding attribute value, the attribute value can be the resource name of a certain skin, and the corresponding resource of the skin can be obtained according to the resource name.
For example, the view of the page may be a text view, a picture view, and the like. Wherein, the attribute of the text view may include: character size, character color, character position, etc.
In practical applications, an application may include multiple pages, and a page may include multiple views, each view having multiple attributes, each attribute specifying an attribute value. That is, under one type of skin, each view corresponds to multiple attribute values. Switching the skin, i.e. switching the attribute values of each view. And, the views included in the page before and after switching the skin are the same, and only the attribute information of the views is changed. Such as background color, text color, variations in text font, etc.
The skin switching method provided by the embodiment of the disclosure is applied to a scene that a page is switched from a current skin to a new skin. In the first scheme of the related art, in a case where a page is switched from a normal skin to a skin in a night mode, the terminal may acquire a resource file in the night mode and create a view of the skin supporting the night mode according to the resource file. In a second scheme of the related art, an attribute value of each view under different skins can be preset, and when a page needs to be switched from a current skin to a target skin, a terminal can acquire the attribute value of each view of the page under the target skin and acquire a corresponding resource file according to the attribute value, so as to recreate a view supporting the target skin, thereby changing a visual effect of the page. However, in both schemes of the related art, views need to be created again when skin is switched, which results in long time consumption for skin switching and poor user experience.
In order to solve the above problem, embodiments of the present disclosure provide a method and an apparatus for skin switching, where a target skin is determined directly according to a mapping relationship between a view and a supported skin resource, so as to switch a skin of the view without reconstructing a page, so that skin switching is more convenient and faster, and user experience is improved.
Fig. 1 is a flowchart illustrating a skin handover method according to an exemplary embodiment, and when the method is applied to a terminal, as shown in fig. 1, the method may include steps 101 to 103.
101. And responding to the skin switching instruction, and determining a target view of the skin to be switched in the page.
Optionally, in an embodiment of the present disclosure, in a scenario, in response to the skin switching instruction, a process of determining a target view of a skin to be switched in a page is as follows: the skin changing control can be displayed on the page, and the terminal can determine all views of the skin to be changed in the page in response to the triggering operation of the skin changing control by the user to obtain the target view.
102. And determining the target skin to be switched according to the view and skin mapping information of the target view and the current skin.
The view and skin mapping information includes mapping relationships between corresponding views and supported skin resources.
After determining the target view of the skin to be switched in the page, the terminal can determine the target skin to be switched according to the view of the target view, the skin mapping information, namely the mapping relation between the view and the supported skin resources, and the current skin. The target skin is the skin other than the current skin among the view-supported skins.
103. And switching the current skin of the target view into the target skin and then displaying.
The technical scheme provided by the embodiment at least has the following beneficial effects: the skin switching device responds to the skin switching instruction, determines a target view of the skin to be switched in the page, determines the target skin to be switched according to the view, the skin mapping information and the current skin of the target view, wherein the view and the skin mapping information comprise a mapping relation between the corresponding view and the skin resources supported by the view and the skin mapping information, and finally switches the current skin of the target view into the target skin for displaying. Therefore, when the skin of the page is switched, the target skin to be switched can be determined directly according to the mapping relation between the view and the supported skin resources and the current skin, the current skin of the target view is switched to the target skin and then displayed, the skin can be switched directly and dynamically without rebuilding the page, the development amount is reduced, the time consumed by skin switching is reduced, and the skin switching efficiency is improved.
Optionally, in this embodiment of the present disclosure, after the step 101 is executed and before the step 102 is executed, the terminal may obtain the view and the skin mapping information of the target view. Specifically, with reference to fig. 1, as shown in fig. 2, the skin switching method provided by the embodiment of the present disclosure may further include steps 104a and 104 b. Step 104a and step 104b are two implementations of acquiring view and skin mapping information for the terminal.
104a, acquiring a pre-stored skin mapping file, and acquiring a view of a target view and skin mapping information from the skin mapping file.
In this implementation, the view and skin mapping information is obtained from the server in advance and stored locally, and a skin mapping file, such as a mapping file, may be predefined in the terminal for storing the view and skin mapping information. Therefore, after the terminal determines the target view of the skin to be switched in the page, the terminal can acquire the locally pre-stored skin mapping file and acquire the view of the target view and the skin mapping information from the skin mapping file.
104b, acquiring the skin mapping file from the corresponding server, and acquiring the view of the target view and the skin mapping information from the skin mapping file.
In this implementation, the view and skin mapping information is obtained in real-time from an external configuration. After determining the target view of the skin to be switched in the page, the terminal can obtain the skin mapping file from the corresponding server by sending a request, and obtain the view of the target view and the skin mapping information from the skin mapping file.
The technical scheme provided by the embodiment at least has the following beneficial effects: compared with the mode in the step 104b, in the step 104a, the view and skin mapping information is pre-stored locally, so that the terminal can directly obtain the information from the local, and the speed is higher. In step 104b, the view and skin mapping information is obtained from the external configuration in real time, and since interaction with the server is required, the information is obtained at a slower rate than from local. But the externally configured skin resources are updated in real time, so that more skin choices can be provided, and the complex requirements of the user on the skin changing function can be further met.
Optionally, in this embodiment of the present disclosure, the mapping information of the view and the skin in step 102 may specifically include a mapping relationship between the view and the attribute information of the current skin, and a mapping relationship between the view and the attribute information of the skin supporting switching. In this case, the determining, by the terminal in step 102, the target skin according to the view and skin mapping information of the target view and the current skin may specifically include: and the terminal determines a target skin from the skins supporting the switching according to the mapping relation between the view and the attribute information of the skins supporting the switching and the current skin.
Optionally, in this embodiment of the present disclosure, the attribute information of the supported skin corresponding to the view may include an attribute value, and the attribute value may be a resource name of the view under the supported skin.
The technical scheme provided by the embodiment at least has the following beneficial effects: because the mapping relation between the view and the attribute information of the supported skin is included in the view and skin mapping information, and the supported skin comprises the current skin and the skin supporting switching, the terminal can quickly determine the target skin from the skin supporting switching and display the page of the target skin. The development speed is high, almost zero delay is realized, smooth transition is realized, the current user operation is not interrupted, the user data is not lost, and only the visual impression of the page is changed.
Optionally, in this embodiment of the present disclosure, before the terminal performs step 101, it needs to generate view and skin mapping information. Specifically, when creating a page, the terminal may parse the view included in the page, so as to obtain attribute information of a current skin of the view and attribute information of a skin that the view supports switching, and store a mapping relationship between the view and the attribute information of the current skin and a mapping relationship between the view and the attribute information of the skin that supports switching.
In a specific implementation, a class layout may be defined first, and a subclass of the class layout may be defined as skinnlautinfluxerfactory. Then, an instance of the SkinLayoutInflauterFactory is set in the LayoutInflactor of each page, the terminal can acquire all views of the page created by the Factory by rewriting an onCreateView method of the SkinLayoutInflauterFactory, and the attribute information of the current skin of the view and the attribute information of the skin of which the view supports switching can be acquired by analyzing all attributes of each view.
The technical scheme provided by the embodiment at least has the following beneficial effects: by rewriting the onCreateView method in the example SkinLayoutInflatFactory, the terminal can obtain the attribute information of the skin supported by the view in the page, so as to obtain the view and skin mapping information, and the view and skin mapping information is the basis for realizing the rapid skin switching of the terminal.
Optionally, in this embodiment of the present disclosure, in the case that the mapping information between the view and the skin includes a mapping relationship between the view and the attribute information of the current skin and a mapping relationship between the view and the attribute information of the skin supporting switching, after the terminal executes the step 102 and before the step 103, the terminal may obtain the corresponding skin resource according to the attribute information of the target skin. Specifically, with reference to fig. 2, as shown in fig. 3, the skin switching method provided by the embodiment of the present disclosure may further include steps 105a and 105 b. Step 105a and step 105b are two implementations of the terminal acquiring the skin resource of the target skin.
And 105a, acquiring the prestored skin resources corresponding to the attribute information of the target skin according to the attribute information of the target skin.
In this implementation, the skin resources of the target skin are obtained from the server in advance and stored locally. Therefore, after the terminal determines the target skin, the terminal can acquire the skin resource corresponding to the attribute information of the target skin according to the attribute information of the target skin.
And 105b, acquiring the skin resource corresponding to the attribute information of the target skin from the server according to the attribute information of the target skin.
In this implementation, the skin resources of the target skin are obtained in real-time from the external configuration. After the terminal determines the target skin, the terminal can acquire the skin resource corresponding to the attribute information of the target skin from the corresponding server by sending a request.
The technical scheme provided by the embodiment at least has the following beneficial effects: compared with the mode in the step 105b, in the step 105a, the skin resource of the target skin is pre-stored locally, so that the terminal can directly obtain the skin resource of the target skin from the local, and the speed is high. In step 105b, the skin resources of the target skin are acquired from the external configuration in real time, and the skin resources of the target skin are acquired slower than those acquired from the local because of the interaction with the server. But the externally configured skin resource is updated in real time, so that richer resources can be provided, and the complex requirements of the user on the skin changing function can be met.
Optionally, in this embodiment of the present disclosure, after the terminal acquires the skin resource corresponding to the attribute information of the target skin, step 103 may specifically include: and the terminal switches the attribute information of the current skin of the target view into the attribute information of the target skin. That is, the resource name of the current skin of the target view is switched to the resource name of the target skin.
After switching the attribute information of the target skin, the mapping relationship between the target view and the attribute information of the current skin is changed, and the current skin at this time is the target skin.
For example, assuming that the page of the current skin is as shown in a in fig. 4, after the attribute information of the current skin of the target view is switched to the attribute information of the target skin, the page of the target skin displayed may be as shown in B in fig. 4.
The technical scheme provided by the embodiment at least has the following beneficial effects: the next switching of the page is facilitated by switching the attribute information of the skin, namely changing the mapping relation between the target view and the attribute information of the current skin.
Optionally, in this embodiment of the present disclosure, the terminal may obtain the attribute information of the target skin from the attribute information of the current skin according to a preset naming rule. Therefore, the attribute information of the target skin is obtained based on the attribute information of the current skin, so that the corresponding skin resource can be accurately and quickly found according to the attribute information of the target skin, and the method is simple and easy to implement.
In a specific implementation manner, the preset naming rule may be: the attribute information of the target skin is the identification of the target skin + the attribute information of the current skin.
For example, assume that the target view is a text view (text view), and two attributes of the text view are a background color and a text color, and the attribute names of the two attributes are: background and textcolor. The attribute information of the current skin of the background color is title _ background, and the attribute information of the current skin of the text color is title _ color. And assuming that the target skin is a dark skin, the dark skin is identified as dark skin. Then, the terminal may obtain attribute information of the target skin of the background color in the text view as: and the dark _ skin _ title _ background, and the attribute information of the target skin of the text color can be obtained as follows: dark _ skin _ title _ color.
Fig. 5 is a block diagram illustrating a logical structure of a skin switching device according to an exemplary embodiment. As shown in fig. 5, the skin switching apparatus is applied to a terminal, the skin switching apparatus comprising: a determination module 21 and a display module 22;
a determining module 21 configured to execute determining a target view of a skin to be switched in a page in response to a skin switching instruction; determining a target skin to be switched according to the view of the target view, the skin mapping information and the current skin; the view and skin mapping information comprises mapping relations between corresponding views and supported skin resources;
a display module 22 configured to perform displaying after switching the current skin of the target view to the target skin.
Optionally, the view and skin mapping information includes: mapping relation between the view and the attribute information of the current skin and mapping relation between the view and the attribute information of the skin supporting switching;
the determining module 21 is specifically configured to determine the target skin from the skin supporting the handover according to the mapping relationship between the view and the attribute information of the skin supporting the handover and the current skin.
Optionally, as shown in fig. 6, the skin-switching device further includes: an acquisition module 23;
the obtaining module 23 is configured to execute obtaining a pre-stored skin mapping file, and obtain the view and skin mapping information from the skin mapping file; or, acquiring a skin mapping file from a corresponding server, and acquiring the view and skin mapping information from the skin mapping file.
Optionally, as shown in fig. 6, the skin-switching device further includes: a parsing module 24 and a storage module 25;
the parsing module 24 is configured to, when the page is created, parse a view included in the page to obtain attribute information of the current skin of the view and attribute information of a skin for which the view supports switching;
the storage module 25 is configured to perform saving of the mapping relationship between the view and the attribute information of the current skin and the mapping relationship between the view and the attribute information of the skin supporting switching.
Optionally, the obtaining module 23 is further configured to perform obtaining the attribute information of the target skin from the attribute information of the current skin according to a preset naming rule.
Optionally, the obtaining module 23 is further configured to perform:
acquiring prestored skin resources corresponding to the attribute information of the target skin according to the attribute information of the target skin;
alternatively, the first and second electrodes may be,
and acquiring a skin resource corresponding to the attribute information of the target skin from a server according to the attribute information of the target skin.
Optionally, the display module 22 is specifically configured to perform:
and after the skin resource corresponding to the attribute information of the target skin is acquired, switching the attribute information of the current skin of the target view into the attribute information of the target skin.
Fig. 7 is a block diagram illustrating a structure of a terminal according to an exemplary embodiment, where the terminal may be a skin switching device, and the skin switching device may be: a smartphone, a tablet, a laptop, or a desktop computer.
The skin-switching device may comprise at least one processor 31, a communication bus 32, a memory 33 and at least one communication interface 34.
The processor 31 may be a CPU, micro-processing unit, ASIC, or one or more integrated circuits for controlling the execution of the programs of the disclosed aspects.
The communication bus 32 may include a path to transfer information between the aforementioned components.
The communication interface 34, which may be any transceiver or other communication network, is used for communicating with other devices or communication networks, such as a server, an ethernet, a Radio Access Network (RAN), a Wireless Local Area Network (WLAN), and so on.
The memory 33 may be a read-only memory (ROM) or other type of static storage device that can store static information and instructions, a Random Access Memory (RAM) or other type of dynamic storage device that can store information and instructions, an electrically erasable programmable read-only memory (EEPROM), a compact disc read-only memory (CD-ROM) or other optical disk storage, optical disk storage (including compact disc, laser disc, optical disc, digital versatile disc, blu-ray disc, etc.), magnetic disk storage media or other magnetic storage devices, or any other medium that can be used to carry or store desired program code in the form of instructions or data structures and that can be accessed by a computer, but is not limited to these. The memory may be self-contained and connected to the processing unit by a bus. The memory may also be integrated with the processing unit.
The memory 33 is used for storing application program codes for executing the disclosed scheme, and the processor 31 is used for controlling the execution. The processor 31 is configured to execute application program code stored in the memory 33 to implement the functions of the disclosed method.
In particular implementations, processor 31 may include one or more CPUs such as CPU0 and CPU1 of fig. 7, for example, as one embodiment.
In a specific implementation, the skin-switching device may include multiple processors, such as processor 31 and processor 35 in fig. 7, as one embodiment. Each of these processors may be a single-core (single-CPU) processor or a multi-core (multi-CPU) processor. A processor herein may refer to one or more devices, circuits, and/or processing cores for processing data (e.g., computer program instructions).
In a specific implementation, the skin-switching apparatus may further include an input device 36 and an output device 37, as an embodiment. The input device 36 is in communication with the processor 31 and may accept user input in a variety of ways. For example, the input device 36 may be a mouse, a keyboard, a touch screen device or a sensing device, and the like. An output device 37 is in communication with the processor 31 and may display information in a variety of ways. For example, the output device 37 may be a Liquid Crystal Display (LCD), a Light Emitting Diode (LED) display device, or the like.
Those skilled in the art will appreciate that the configuration shown in fig. 7 is not intended to be limiting and may include more or fewer components than those shown, or some components may be combined, or a different arrangement of components may be used.
The present disclosure also provides a computer-readable storage medium comprising instructions stored thereon, which when executed by a processor of a computer device, enable a computer to perform the skin-switching method provided by the illustrated embodiments described above. For example, the computer readable storage medium may be a memory 33 comprising instructions executable by a processor 31 of the terminal to perform the above-described method. Alternatively, the computer readable storage medium may be a non-transitory computer readable storage medium, for example, which may be a ROM, a RAM, a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, and the like.
The present disclosure also provides a computer program product containing instructions which, when run on a computer, cause the computer device to perform the skin switching method provided by the above-described illustrative embodiments.
Other embodiments of the disclosure will be apparent to those skilled in the art from consideration of the specification and practice of the disclosure disclosed herein. This application is intended to cover any variations, uses, or adaptations of the disclosure following, in general, the principles of the disclosure and including such departures from the present disclosure as come within known or customary practice within the art to which the disclosure pertains. It is intended that the specification and examples be considered as exemplary only, with a true scope and spirit of the disclosure being indicated by the following claims.
It will be understood that the present disclosure is not limited to the precise arrangements described above and shown in the drawings and that various modifications and changes may be made without departing from the scope thereof. The scope of the present disclosure is limited only by the appended claims.

Claims (10)

1. A skin switching method, characterized in that the method comprises:
responding to a skin switching instruction, and determining a target view of a skin to be switched in a page;
determining a target skin to be switched according to the view of the target view, the skin mapping information and the current skin; the view and skin mapping information comprises mapping relations between corresponding views and supported skin resources;
and switching the current skin of the target view into the target skin and then displaying.
2. The skin-switching method of claim 1, wherein the view-to-skin mapping information comprises: mapping relation between the view and the attribute information of the current skin and mapping relation between the view and the attribute information of the skin supporting switching;
determining a target skin to be switched according to the view of the target view, the skin mapping information and the current skin, comprising:
and determining the target skin from the skin supporting switching according to the mapping relation between the view and the attribute information of the skin supporting switching and the current skin.
3. The skin switching method of claim 2, further comprising:
acquiring a pre-stored skin mapping file, and acquiring the view and skin mapping information from the skin mapping file;
alternatively, the first and second electrodes may be,
and acquiring a skin mapping file from a corresponding server, and acquiring the view and skin mapping information from the skin mapping file.
4. The skin switching method of claim 1, further comprising:
when the page is created, analyzing a view included in the page to obtain attribute information of the current skin of the view and attribute information of a skin which supports switching of the view;
and saving the mapping relation between the view and the attribute information of the current skin and the mapping relation between the view and the attribute information of the skin supporting switching.
5. The skin switching method according to any one of claims 2-4, further comprising:
and acquiring the attribute information of the target skin from the attribute information of the current skin according to a preset naming rule.
6. The skin switching method according to any one of claims 2-4, further comprising:
acquiring prestored skin resources corresponding to the attribute information of the target skin according to the attribute information of the target skin;
alternatively, the first and second electrodes may be,
and acquiring a skin resource corresponding to the attribute information of the target skin from a server according to the attribute information of the target skin.
7. The skin switching method according to claim 6, wherein the switching the current skin of the target view to the target skin for showing comprises:
and after the skin resource corresponding to the attribute information of the target skin is acquired, switching the attribute information of the current skin of the target view into the attribute information of the target skin.
8. A skin switching device, comprising:
the determining module is configured to execute the step of determining a target view of the skin to be switched in the page in response to the skin switching instruction; determining a target skin to be switched according to the view of the target view, the skin mapping information and the current skin; the view and skin mapping information comprises mapping relations between corresponding views and supported skin resources;
and the display module is configured to perform displaying after the current skin of the target view is switched to the target skin.
9. A terminal, comprising:
a processor;
a memory for storing the processor-executable instructions;
wherein the processor is configured to execute the instructions to implement the skin-switching method of any one of claims 1-7.
10. A computer-readable storage medium having instructions stored thereon, wherein the instructions in the computer-readable storage medium, when executed by a processor of a terminal, enable the terminal to perform the skin-switch method of any one of claims 1-7.
CN202010375901.4A 2020-05-06 2020-05-06 Skin switching method and device Pending CN111638927A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010375901.4A CN111638927A (en) 2020-05-06 2020-05-06 Skin switching method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010375901.4A CN111638927A (en) 2020-05-06 2020-05-06 Skin switching method and device

Publications (1)

Publication Number Publication Date
CN111638927A true CN111638927A (en) 2020-09-08

Family

ID=72328270

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010375901.4A Pending CN111638927A (en) 2020-05-06 2020-05-06 Skin switching method and device

Country Status (1)

Country Link
CN (1) CN111638927A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112394932A (en) * 2020-11-19 2021-02-23 建信金融科技有限责任公司 Automatic browser webpage skin changing method and device

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20020101444A1 (en) * 2001-01-31 2002-08-01 Novak Michael J. Methods and systems for creating skins
US20140095977A1 (en) * 2012-04-05 2014-04-03 Guangzhou Ucweb Computer Technology Co., Ltd Webpage skin replacement method, apparatus, and mobile terminal
CN108008997A (en) * 2017-12-22 2018-05-08 北京酷我科技有限公司 A kind of unified method replaced of APP skins
CN109426541A (en) * 2017-08-31 2019-03-05 阿里巴巴集团控股有限公司 A kind of method and apparatus that the page changes skin

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20020101444A1 (en) * 2001-01-31 2002-08-01 Novak Michael J. Methods and systems for creating skins
US20140095977A1 (en) * 2012-04-05 2014-04-03 Guangzhou Ucweb Computer Technology Co., Ltd Webpage skin replacement method, apparatus, and mobile terminal
CN109426541A (en) * 2017-08-31 2019-03-05 阿里巴巴集团控股有限公司 A kind of method and apparatus that the page changes skin
CN108008997A (en) * 2017-12-22 2018-05-08 北京酷我科技有限公司 A kind of unified method replaced of APP skins

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112394932A (en) * 2020-11-19 2021-02-23 建信金融科技有限责任公司 Automatic browser webpage skin changing method and device

Similar Documents

Publication Publication Date Title
CN110096277B (en) Dynamic page display method and device, electronic equipment and storage medium
WO2018133663A1 (en) Page generation method, terminal, and data storage medium
CN111639289A (en) Webpage loading method and device
JP2022525831A (en) Page pre-rendering methods, devices, electronic devices, computer programs and storage media
TW201911020A (en) Page update method and device
CN112416461B (en) Video resource processing method, device, electronic equipment and computer readable medium
US10768947B2 (en) Method for interface refresh synchronization,terminal device, and non-transitory computer-readable storage medium
CN113095995A (en) Webpage watermark adding method and device, electronic equipment and storage medium
US11930096B2 (en) Systems and methods for rendering interactive web pages
CN111667199A (en) Workflow construction method and device, computer equipment and storage medium
CN110262749B (en) Webpage operation method, device, container, equipment and medium
CN115309470A (en) Method, device and equipment for loading widgets and storage medium
CN111625312A (en) APP skin changing method and device, electronic equipment and storage medium
CN112306594A (en) Rendering method and device based on mobile terminal and storage medium
US11151314B2 (en) Extensible grid layout
CN111638927A (en) Skin switching method and device
CN112783494A (en) Automatic skeleton screen generation method and device and application page updating method and device
CN112559109A (en) Method, system, device and medium for generating display interface based on component library
CN112287256A (en) Page display method, terminal device, cloud server, system and storage medium
CN112905931B (en) Page information display method and device, electronic equipment and storage medium
US11836212B2 (en) Systems and methods for rendering interactive web pages
CN112395535A (en) Image lazy loading method and device, medium and electronic equipment
CN115543534A (en) Training task management method and device, electronic equipment and storage medium
CN113849164A (en) Data processing method and device, electronic equipment and memory
CN110187881B (en) Special-shaped window creation method, system, device and computer storage medium

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