[go: up one dir, main page]

CN110035181B - A kind of quick application card theme setting method and terminal - Google Patents

A kind of quick application card theme setting method and terminal Download PDF

Info

Publication number
CN110035181B
CN110035181B CN201910294525.3A CN201910294525A CN110035181B CN 110035181 B CN110035181 B CN 110035181B CN 201910294525 A CN201910294525 A CN 201910294525A CN 110035181 B CN110035181 B CN 110035181B
Authority
CN
China
Prior art keywords
card
theme
information
quick application
quick
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.)
Active
Application number
CN201910294525.3A
Other languages
Chinese (zh)
Other versions
CN110035181A (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.)
Vivo Mobile Communication Co Ltd
Original Assignee
Vivo Mobile Communication 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 Vivo Mobile Communication Co Ltd filed Critical Vivo Mobile Communication Co Ltd
Priority to CN201910294525.3A priority Critical patent/CN110035181B/en
Publication of CN110035181A publication Critical patent/CN110035181A/en
Application granted granted Critical
Publication of CN110035181B publication Critical patent/CN110035181B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING OR CALCULATING; 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
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/06Protocols specially adapted for file transfer, e.g. file transfer protocol [FTP]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/72Mobile telephones; Cordless telephones, i.e. devices for establishing wireless links to base stations without route selection
    • H04M1/724User interfaces specially adapted for cordless or mobile telephones
    • H04M1/72403User interfaces specially adapted for cordless or mobile telephones with means for local support of applications that increase the functionality
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/72Mobile telephones; Cordless telephones, i.e. devices for establishing wireless links to base stations without route selection
    • H04M1/724User interfaces specially adapted for cordless or mobile telephones
    • H04M1/72403User interfaces specially adapted for cordless or mobile telephones with means for local support of applications that increase the functionality
    • H04M1/72406User interfaces specially adapted for cordless or mobile telephones with means for local support of applications that increase the functionality by software upgrading or downloading
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/72Mobile telephones; Cordless telephones, i.e. devices for establishing wireless links to base stations without route selection
    • H04M1/724User interfaces specially adapted for cordless or mobile telephones
    • H04M1/72448User interfaces specially adapted for cordless or mobile telephones with means for adapting the functionality of the device according to specific conditions
    • H04M1/72454User interfaces specially adapted for cordless or mobile telephones with means for adapting the functionality of the device according to specific conditions according to context-related or environment-related conditions
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M2250/00Details of telephonic subscriber devices
    • H04M2250/12Details of telephonic subscriber devices including a sensor for measuring a physical value, e.g. temperature or motion

Landscapes

  • Engineering & Computer Science (AREA)
  • Human Computer Interaction (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Environmental & Geological Engineering (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

本发明提供一种快应用卡片主题设置方法及终端,涉及通信技术领域。该快应用卡片主题设置方法包括:获取待加载的快应用卡片的属性信息;根据所述属性信息下载所述待加载的快应用卡片的卡片包体;解析所述卡片包体,并获得解析结果,所述解析结果包括卡片页面元素信息;根据所述解析结果以及目标主题信息设置所述待加载的快应用卡片主题的属性值。本发明的实施例,通过卡片包体的解析结果判断卡片组件是否使用主题,并在确定组件使用主题后,利用目标主题信息设置卡片主题,能够实现卡片在不同应用场景中以统一样式的主题显示,也可以实现卡片在不同应用场景的界面内以不同主题来显示,卡片主题的设置具有更高的灵活性。

Figure 201910294525

The invention provides a method and a terminal for setting the theme of a quick application card, and relates to the technical field of communication. The quick application card theme setting method includes: acquiring attribute information of a quick application card to be loaded; downloading a card package body of the quick application card to be loaded according to the attribute information; parsing the card package body, and obtaining a parsing result , the parsing result includes card page element information; the attribute value of the to-be-loaded quick application card theme is set according to the parsing result and target theme information. In the embodiment of the present invention, whether the card component uses the theme is judged by the analysis result of the card package body, and after the component use theme is determined, the target theme information is used to set the card theme, so that the card can be displayed in a unified style in different application scenarios. , the card can also be displayed with different themes in the interface of different application scenarios, and the setting of the card theme has higher flexibility.

Figure 201910294525

Description

一种快应用卡片主题设置方法及终端A kind of quick application card theme setting method and terminal

技术领域technical field

本发明涉及通信技术领域,尤其涉及一种快应用卡片主题设置方法及终端。The present invention relates to the technical field of communications, and in particular, to a method and a terminal for setting the theme of a quick application card.

背景技术Background technique

快应用是十大手机厂商共同推出的新型的手机应用形态,快应用无需下载安装,能够即点即用,卡片是属于快应用中的定义的一个页面,是以嵌入其他应用进行展示为表现方式的一种信息载体。一个快应用可以对应多张卡片,每张卡片只能对应一个页面。卡片可以在各类使用场景的原生应用中嵌入展示,比如:负一屏、全局搜索、智慧场景等。Quick app is a new type of mobile phone application form jointly launched by the top ten mobile phone manufacturers. Quick app does not need to be downloaded and installed, and can be clicked and used immediately. Card is a page defined in quick app, and it is displayed by embedding in other apps. an information carrier. A quick app can correspond to multiple cards, and each card can only correspond to one page. Cards can be embedded and displayed in native applications of various usage scenarios, such as: negative one screen, global search, smart scenarios, etc.

现有技术中,快应用卡片不支持开发者设置主题,每个开发者开发的卡片的风格都不尽相同,所以在终端系统中要显示多个开发者的卡片时,卡片在原生应用中展示时不能以统一的风格进行展示。如负一屏、全局搜索、智慧识图等,因为这些使用场景的应用会在同一终端屏幕中展示不同开发者的卡片,会造成卡片的风格不统一,用户界面(UserInterface,UI)显示不协调,给用户带来较差的视觉体验。In the prior art, the quick application card does not support the developer to set the theme, and the styles of the cards developed by each developer are different. Therefore, when the cards of multiple developers are to be displayed in the terminal system, the cards are displayed in the native application. cannot be displayed in a uniform style. Such as negative one screen, global search, smart map recognition, etc., because the applications of these usage scenarios will display the cards of different developers on the same terminal screen, which will cause the styles of the cards to be inconsistent and the user interface (UI) display to be inconsistent. , which brings a poor visual experience to the user.

发明内容SUMMARY OF THE INVENTION

本发明实施例提供一种快应用卡片主题设置方法及终端,以解决现有的快应用卡片主题不统一的问题。Embodiments of the present invention provide a method and a terminal for setting the theme of a quick application card, so as to solve the problem of inconsistent themes of existing quick application cards.

为了解决上述技术问题,本发明是这样实现的:In order to solve the above-mentioned technical problems, the present invention is achieved in this way:

第一方面,本发明的实施例提供了一种快应用卡片主题设置方法,包括:In a first aspect, an embodiment of the present invention provides a method for setting the theme of a quick application card, including:

获取待加载的快应用卡片的属性信息;Get the attribute information of the quick app card to be loaded;

根据所述属性信息下载所述待加载的快应用卡片的卡片包体;Download the card package of the quick application card to be loaded according to the attribute information;

解析所述卡片包体,并获得解析结果,所述解析结果包括卡片页面元素信息;Parsing the card body, and obtaining an parsing result, where the parsing result includes card page element information;

根据所述解析结果以及目标主题信息,设置所述待加载的快应用卡片主题的属性值。According to the parsing result and target theme information, the attribute value of the to-be-loaded quick application card theme is set.

第二方面,本发明的实施例还提供了一种终端,包括:In a second aspect, an embodiment of the present invention further provides a terminal, including:

获取模块,用于获取待加载的快应用卡片的属性信息;The acquisition module is used to acquire the attribute information of the quick application card to be loaded;

下载模块,用于根据所述属性信息下载所述待加载的快应用卡片的卡片包体;a download module, configured to download the card package of the to-be-loaded quick application card according to the attribute information;

解析模块,用于解析所述卡片包体,并获得解析结果,所述解析结果包括卡片页面元素信息;a parsing module, used for parsing the card package body, and obtaining parsing results, where the parsing results include card page element information;

设置模块,用于根据所述解析结果以及目标主题信息,设置所述待加载的快应用卡片主题的属性值。A setting module is configured to set the attribute value of the theme of the quick application card to be loaded according to the analysis result and target theme information.

第三方面,本发明实施例还提供了一种终端,包括处理器、存储器及存储在所述存储器上并可在所述处理器上运行的计算机程序,所述计算机程序被所述处理器执行时实现如上所述的快应用卡片主题设置方法的步骤。In a third aspect, an embodiment of the present invention further provides a terminal, including a processor, a memory, and a computer program stored on the memory and executable on the processor, where the computer program is executed by the processor When implementing the steps of the above-mentioned quick application card theme setting method.

这样,本发明实施例中,通过卡片包体的解析结果判断卡片组件是否使用主题,并在确定组件使用主题后,利用目标主题信息设置卡片主题,能够实现卡片在不同应用场景中以统一样式的主题显示,也可以实现卡片在不同应用场景的界面内以不同主题来显示,卡片主题的设置具有更高的灵活性。In this way, in the embodiment of the present invention, whether the card component uses the theme is judged through the analysis result of the card package body, and after the component use theme is determined, the target theme information is used to set the card theme, which can realize the uniform style of the card in different application scenarios. Theme display, it is also possible to display cards with different themes in the interface of different application scenarios, and the setting of the card theme has higher flexibility.

附图说明Description of drawings

为了更清楚地说明本发明实施例的技术方案,下面将对本发明实施例描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本发明的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动性的前提下,还可以根据这些附图获得其他的附图。In order to illustrate the technical solutions of the embodiments of the present invention more clearly, the following briefly introduces the accompanying drawings that need to be used in the description of the embodiments of the present invention. Obviously, the drawings in the following description are only some embodiments of the present invention. For those of ordinary skill in the art, other drawings can also be obtained from these drawings without creative labor.

图1为本发明实施例的快应用卡片主题设置方法的流程示意图之一;1 is one of the schematic flowcharts of a method for setting a theme of a quick application card according to an embodiment of the present invention;

图2为本发明实施例的快应用卡片主题设置方法的流程示意图之二;FIG. 2 is a second schematic flowchart of a method for setting a theme for a quick application card according to an embodiment of the present invention;

图3为本发明实施例的终端的结构框图;3 is a structural block diagram of a terminal according to an embodiment of the present invention;

图4为本发明实施例的终端的硬件结构示意图。FIG. 4 is a schematic diagram of a hardware structure of a terminal according to an embodiment of the present invention.

具体实施方式Detailed ways

下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例是本发明一部分实施例,而不是全部的实施例。基于本发明中的实施例,本领域普通技术人员在没有作出创造性劳动前提下所获得的所有其他实施例,都属于本发明保护的范围。The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, but not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative efforts shall fall within the protection scope of the present invention.

如图1所示,本发明实施例的快应用卡片主题设置方法,包括:As shown in FIG. 1 , the method for setting the theme of a quick application card according to an embodiment of the present invention includes:

步骤101、获取待加载的快应用卡片的属性信息;Step 101: Obtain attribute information of the quick application card to be loaded;

该实施例的快应用卡片主题设置方法,应用于终端的快应用引擎,所述快应用引擎获取待加载的快应用卡片的属性信息。待加载的快应用卡片的属性信息包括:所述待加载的快应用卡片的统一资源定位符(Uniform Resource Location,URL)信息。The method for setting the theme of a quick application card in this embodiment is applied to a quick application engine of a terminal, where the quick application engine acquires attribute information of a quick application card to be loaded. The attribute information of the quick application card to be loaded includes: uniform resource locator (Uniform Resource Location, URL) information of the quick application card to be loaded.

步骤102、根据所述属性信息下载所述待加载的快应用卡片的卡片包体;Step 102: Download the card package of the quick application card to be loaded according to the attribute information;

快应用引擎根据所述属性信息由服务器下载待加载的快应用卡片的卡片包体,所述卡片包体为开发者设计的卡片布局文件的压缩包体。开发者在设计卡片布局文件时,对卡片布局文件中的组件进行添加主题属性参数,即主题使用标记,用于标识组件是否使用主题;然后使用快应用的打包工具把开发者编写的卡片布局文件打包成快应用包体,并上传到服务器。The quick application engine downloads the card package body of the quick application card to be loaded from the server according to the attribute information, and the card package body is the compressed package body of the card layout file designed by the developer. When designing the card layout file, developers add theme attribute parameters to the components in the card layout file, that is, the theme use mark, which is used to identify whether the component uses the theme; Package it into a quick application package and upload it to the server.

步骤103、解析所述卡片包体,并获得解析结果,所述解析结果包括卡片页面元素信息;Step 103, parse the card package body, and obtain a parsing result, where the parsing result includes card page element information;

所述卡片包体为卡片布局文件的压缩包体,解析所述卡片包体,能够获得开发者编写的卡片布局文件,所述卡片布局文件中包含卡片页面元素信息,所述卡片页面元素信息指示组件是否使用主题。The card package body is a compressed package body of a card layout file. By parsing the card package body, a card layout file written by the developer can be obtained. The card layout file contains card page element information, and the card page element information indicates Whether the component uses themes.

步骤104、根据所述解析结果以及目标主题信息,设置所述待加载的卡片主题的属性值。Step 104: Set the attribute value of the to-be-loaded card theme according to the parsing result and target theme information.

根据所述卡片页面元素信息能够确定卡片组件是否使用主题,如果确定组件使用主题,则将预先确定的目标主题信息赋值给组件。其中,所述目标主题信息可以包括卡片页面的轮廓大小和形状、背景颜色、点击动效、字体大小和类型以及颜色等,根据所述目标主题信息,将所述快应用卡片的主题统一设置为所述目标主题信息规定的样式。Whether the card component uses the theme can be determined according to the card page element information, and if it is determined that the component uses the theme, the predetermined target theme information is assigned to the component. The target theme information may include the outline size and shape of the card page, background color, click animation, font size and type, and color, etc. According to the target theme information, the theme of the quick application card is uniformly set as The style specified by the target theme information.

本发明的实施例,通过卡片包体的解析结果判断卡片组件是否使用主题,并在确定组件使用主题后,利用目标主题信息设置卡片主题,能够实现卡片在不同应用场景中以统一样式的主题显示,也可以实现卡片在不同应用场景的界面内以不同主题来显示。通过设置卡片的主题,终端在加载不同开发者开发的卡片时,卡片的标题文字、内容区文字、按钮的文字、背景颜色、和卡片的四角弧度等UI组件能够以统一主题风格进行显示,可以提高卡片主题设置的灵活性,提升卡片美观度,提升用户体验。In the embodiment of the present invention, whether the card component uses the theme is judged by the analysis result of the card package body, and after the component use theme is determined, the target theme information is used to set the card theme, which can realize the theme display of the card in a unified style in different application scenarios , it is also possible to display cards with different themes in the interface of different application scenarios. By setting the theme of the card, when the terminal loads cards developed by different developers, UI components such as the title text, content area text, button text, background color, and four-corner arc of the card can be displayed in a unified theme style. Improve the flexibility of card theme settings, improve card aesthetics, and improve user experience.

具体地,所述目标主题信息包括以下中的一项:终端上传的快应用卡片的主题信息;快应用引擎内置的快应用卡片的主题信息;预先设定的快应用卡片的主题信息。Specifically, the target subject information includes one of the following: subject information of the quick application card uploaded by the terminal; subject information of the quick application card built in the quick application engine; and preset subject information of the quick application card.

具体地,所述终端上传的快应用卡片的主题信息是指:终端内用于显示所述快应用卡片的应用上传的主题信息,如终端的负一屏、或者终端的全局搜索、或者终端的智慧识图等,向快应用引擎上传的其自身自定义的卡片主题信息。用于显示所述快应用卡片的应用,在加载卡片前向所述快应用引擎传入一组主题为JS对象简谱(JavaScript ObjectNotation,JSON)格式的主题信息,以便所述快应用引擎使用此主题生成对应的组件,JSON格式的主题信息可以包括卡片页面的轮廓大小和形状、背景颜色、点击动效、字体大小和类型以及颜色等。Specifically, the topic information of the quick application card uploaded by the terminal refers to: the topic information uploaded by the application used to display the quick application card in the terminal, such as the negative screen of the terminal, or the global search of the terminal, or the Smart image recognition, etc., and its own custom card theme information uploaded to the quick application engine. An application for displaying the quick application card, before loading the card, a set of subject information in the format of JS Object Notation (JavaScript ObjectNotation, JSON) is passed to the quick application engine, so that the quick application engine can use this theme To generate corresponding components, the theme information in JSON format can include the outline size and shape of the card page, background color, click animation, font size and type, and color, etc.

所述目标主题信息也可以为所述快应用引擎内置的默认的快应用卡片的主题信息或者预先设定的快应用卡片的主题信息。其中,如果所述快应用引擎接收到了终端上传的所述快应用卡片的主题信息,则利用该主题信息作为目标主题信息为组件赋值;如果所述快应用引擎未接收到终端上传的所述快应用卡片的主题信息,则利用自身内置的默认的快应用卡片主题信息作为所述目标主题信息为组件赋值;如果所述快应用引擎自身没有内置主题信息,则还可以利用预先设定的快应用卡片的主题信息作为所述目标主题信息为组件赋值。The target subject information may also be the subject information of the default quick application card built in the quick application engine or the subject information of the preset quick application card. Wherein, if the quick application engine has received the subject information of the quick application card uploaded by the terminal, the subject information is used as the target subject information to assign value to the component; if the quick application engine has not received the quick application card uploaded by the terminal The theme information of the application card, then use its own built-in default quick application card theme information as the target theme information to assign value to the component; if the quick application engine itself does not have built-in theme information, you can also use the preset quick application. The subject information of the card is used as the target subject information to assign a value to the component.

具体地,步骤102,包括:Specifically, step 102 includes:

根据所述待加载的快应用卡片的所述URL信息,向服务器发送所述待加载的快应用卡片的卡片包体下载请求;下载所述待加载的快应用卡片的卡片包体。According to the URL information of the quick application card to be loaded, a request for downloading the card package of the quick application card to be loaded is sent to the server; the card package of the quick application card to be loaded is downloaded.

其中,URL信息是带有需要加载哪张卡片的信息,例如:URL的一般格式为:hap://card/com.application.ctrip-card/Card,这样的URL信息就代表需要加载快应用“com.application.ctrip-card”中的卡片页面Card,这种URL信息类似浏览器打开一个具体网站的某个页面。Among them, the URL information is the information about which card needs to be loaded. For example, the general format of the URL is: hap://card/com.application.ctrip-card/Card, such URL information means that the quick application needs to be loaded" com.application.ctrip-card" in the card page Card, this URL information is similar to the browser opening a certain page of a specific website.

需要说明的是,终端内用于显示所述快应用卡片的应用还需要向所述快应用引擎上传所述待加载的快应用卡片的卡片包体的下载地址,所述快应用引擎解析所述URL信息后,确定待加载的快应用卡片,并根据卡片包体的下载地址,向服务器发送待加载的快应用卡片的卡片包体下载请求,并根据服务器指示下载所述待加载卡片的卡片包体。It should be noted that the application for displaying the quick application card in the terminal also needs to upload the download address of the card package body of the quick application card to be loaded to the quick application engine, and the quick application engine parses the After the URL information is obtained, the quick application card to be loaded is determined, and according to the download address of the card package body, a card package download request of the quick application card to be loaded is sent to the server, and the card package of the to-be-loaded card is downloaded according to the instruction of the server. body.

具体地,解析所述卡片包体并获得解析结果的步骤包括:Specifically, the steps of parsing the card package body and obtaining the parsing result include:

对所述卡片包体进行解压,获得卡片布局文件;Decompress the card package to obtain a card layout file;

所述卡片包体为开发者设计的卡片布局文件的压缩包体,下载所述卡片包体到本地后,所述快应用引擎解压所述卡片包体,得到开发者编写的卡片布局文件。The card package is a compressed package of the card layout file designed by the developer. After downloading the card package to the local, the quick application engine decompresses the card package to obtain the card layout file written by the developer.

根据所述卡片布局文件,获取所述卡片页面元素信息。解析所述卡片布局文件,根据解析到的卡片布局文件中开发者编写的代码,能够获取到卡片页面元素信息,所述卡片页面元素信息指示组件是否使用主题。Obtain the card page element information according to the card layout file. The card layout file is parsed, and according to the code written by the developer in the parsed card layout file, card page element information can be obtained, and the card page element information indicates whether the component uses a theme.

具体地,所述步骤104,包括:Specifically, the step 104 includes:

根据所述解析结果判断卡片页面组件是否使用主题;According to the analysis result, determine whether the card page component uses the theme;

其中,根据所述解析结果判断卡片页面组件是否使用主题的步骤,包括:Wherein, the step of judging whether the card page component uses the theme according to the analysis result includes:

判断所述卡片页面元素信息是否包括主题使用标记;若包括所述主题使用标记,则确定卡片页面组件使用主题,否则,确定卡片页面组件不使用主题。It is judged whether the card page element information includes the theme usage mark; if the theme usage mark is included, it is determined that the card page component uses the theme, otherwise, it is determined that the card page component does not use the theme.

所述主题使用标记为开发者在编写卡片布局文件时加入的用于指示组件是否使用主题的参数,例如,如果卡片的背景、卡片左下角圆角以及卡片右下角圆角均使用主题,则在编写的卡片布局文件的代码中加入背景使用主题的标记、卡片左下角圆角使用主题的标记以及卡片右下角圆角使用主题的标记。The theme usage is marked as a parameter added by the developer when writing the card layout file to indicate whether the component uses the theme. In the code of the written card layout file, add the mark of using the theme in the background, the mark of using the theme in the rounded corner of the lower left corner of the card, and the mark of using the theme in the rounded corner of the lower right corner of the card.

若使用主题,则根据所述待加载卡片的属性信息给所述卡片页面组件的主题属性赋值。If a theme is used, assign a value to the theme attribute of the card page component according to the attribute information of the card to be loaded.

如果所述快应用引擎根据所述解析结果判断到卡片的组件使用主题,则利用确定的目标主题信息为确定需要使用主题的组件赋值。If the quick application engine determines that the component of the card uses the theme according to the analysis result, it uses the determined target theme information to assign a value to the component that needs to use the theme.

其中,所述卡片主题的设置动作的触发点是应用,例如,终端的负一屏可以触发快应用卡片主题的设置动作,让快应用卡片以负一屏的统一样式显示。全局搜索应用也可以触发快应用卡片主题的设置动作,让快应用卡片以全局搜索中规定主题来显示,并且这两者的主题模式可以在同一终端的同一时间设置,让快应用卡片在不同应用的界面内以不同的主题来显示,灵活性较高。The trigger point of the setting action of the card theme is the application. For example, the negative screen of the terminal can trigger the setting action of the quick application card theme, so that the quick application card is displayed in a uniform style of the negative one screen. The global search application can also trigger the setting action of the quick application card theme, so that the quick application card is displayed with the theme specified in the global search, and the theme modes of the two can be set at the same time on the same terminal, so that the quick application card can be displayed in different applications. The interface is displayed with different themes, with high flexibility.

具体地,根据所述解析结果以及目标主题信息,设置所述待加载的快应用卡片主题的属性值的步骤之后,还包括:对所述待加载的快应用卡片加载渲染,生成包含新主题的卡片界面。Specifically, after the step of setting the attribute value of the theme of the quick application card to be loaded according to the analysis result and the target theme information, the step further includes: loading and rendering the quick application card to be loaded, and generating a new theme Card interface.

该实施例中,所述快应用引擎为需要使用主题的组件赋值后,对卡片进行加载渲染,生成带有新主题的卡片界面,并通过终端的场景应用将包含新主题的卡片界面展示给用户。In this embodiment, the quick application engine loads and renders the card after assigning a value to the component that needs to use the theme, generates a card interface with a new theme, and displays the card interface including the new theme to the user through the terminal scene application .

以上介绍了应用于快应用引擎的快应用卡片主题设置方法,下面结合附图对其在快应用引擎、终端的场景应用、开发者以及服务器之间的实现过程做进一步说明:The above has introduced the method for setting the theme of the quick app card applied to the quick app engine. The following is a further description of the implementation process between the quick app engine, the terminal scenario application, the developer and the server with reference to the accompanying drawings:

如图2所示,开发者设计卡片,在设计卡片布局文件时,在原有的内容下增加了卡片内容,即对卡片布局文件中的组件进行添加主题使用标记,标识组件是否使用主题;使用快应用的打包工具把开发者编写的卡片布局文件打包成快应用包体,并上传到服务器,厂家审核通过并上架成功;终端内用于显示快应用卡片的应用(如负一屏、全局搜索、智慧识图等),在加载卡片前向快应用引擎传入待加载的快应用卡片的属性信息,以便快应用引擎使用此属性信息生成对应的组件;快应用引擎根据所述待加载的快应用卡片的属性信息由服务器下载待加载的快应用卡片的卡片包体,并解析所述卡片包体,根据解析结果以及目标主题信息设置快应用卡片主题的属性值;所述快应用引擎渲染生成包含新主题的快应用卡片界面,由终端的应用(如负一屏、全局搜索、智慧识图等)显示所述快应用卡片界面,并展现给用户。其中,所述目标主题信息可以为终端上传的快应用卡片的主题信息;也可以为快应用引擎内置的快应用卡片的主题信息;还可以为预先设定的快应用卡片的主题信息。As shown in Figure 2, when the developer designs the card, when designing the card layout file, the card content is added under the original content, that is, the theme use mark is added to the components in the card layout file to identify whether the component uses the theme; The application packaging tool packages the card layout file written by the developer into a quick application package body, and uploads it to the server, which is approved by the manufacturer and successfully put on the shelves; the application used to display the quick application card in the terminal (such as negative one screen, global search, Smart image recognition, etc.), before loading the card, pass the attribute information of the quick application card to be loaded to the quick application engine, so that the quick application engine can use this attribute information to generate corresponding components; The attribute information of the card is downloaded by the server to the card package of the quick application card to be loaded, and the card package is parsed, and the attribute value of the quick application card theme is set according to the analysis result and the target theme information; the quick application engine rendering and generating includes For the quick application card interface of the new theme, the application of the terminal (such as negative one screen, global search, smart map recognition, etc.) displays the quick application card interface and presents it to the user. Wherein, the target subject information may be the subject information of the quick application card uploaded by the terminal; may also be the subject information of the quick application card built in the quick application engine; or may be the subject information of the pre-set quick application card.

本发明的实施例,以快应用引擎、终端内显示快应用卡片的应用和开发者三者相互配合,使用约定的规范,达到设置卡片主题的目的,快应用引擎集成了解析主题和渲染组件的能力,终端内显示快应用卡片的应用可以自定义主题样式,开发者在编写卡片页面布局文件时对组件设置主题使用标记。通过设置卡片的主题,终端加载不同开发者开发的快应用卡片时,卡片的标题文字、内容区文字、按钮的文字、背景颜色、和卡片的四角弧度等UI组件能够以统一主题风格进行显示,可以提高快应用卡片主题设置的灵活性,提升快应用卡片美观度,提升用户体验。In the embodiment of the present invention, the quick application engine, the application displaying the quick application card in the terminal, and the developer cooperate with each other, and use the agreed specification to achieve the purpose of setting the card theme. The quick application engine integrates the parsing theme and the rendering component. The application that displays the quick application card in the terminal can customize the theme style, and the developer sets the theme use mark on the component when writing the card page layout file. By setting the theme of the card, when the terminal loads the quick application cards developed by different developers, the UI components such as the title text of the card, the text of the content area, the text of the button, the background color, and the arc of the four corners of the card can be displayed in a unified theme style. It can improve the flexibility of quick application card theme settings, improve the aesthetics of quick application cards, and improve user experience.

图3是本发明一个实施例的终端的框图。图3所示的终端300包括获取模块301、下载模块302、解析模块303以及设置模块304。FIG. 3 is a block diagram of a terminal according to an embodiment of the present invention. The terminal 300 shown in FIG. 3 includes an acquisition module 301 , a download module 302 , a parsing module 303 and a setting module 304 .

获取模块301,用于获取待加载的快应用卡片的属性信息;An obtaining module 301, configured to obtain attribute information of the quick application card to be loaded;

下载模块302,用于根据所述属性信息下载所述待加载的快应用卡片的卡片包体;a downloading module 302, configured to download the card package of the quick application card to be loaded according to the attribute information;

解析模块303,用于解析所述卡片包体,并获得解析结果,所述解析结果包括卡片页面元素信息;A parsing module 303, configured to parse the card package body, and obtain a parsing result, where the parsing result includes card page element information;

设置模块304,用于根据所述解析结果以及目标主题信息,设置所述待加载的快应用卡片主题的属性值。The setting module 304 is configured to set the attribute value of the topic of the quick application card to be loaded according to the parsing result and target topic information.

在图3的基础上,可选地,待加载的快应用卡片的属性信息包括:所述待加载的快应用卡片的统一资源定位符URL信息。On the basis of FIG. 3 , optionally, the attribute information of the quick application card to be loaded includes: Uniform Resource Locator URL information of the quick application card to be loaded.

可选地,所述下载模块包括:Optionally, the download module includes:

请求单元,用于根据所述待加载的快应用卡片的所述URL信息,向服务器发送所述待加载的快应用卡片的卡片包体下载请求;a requesting unit, configured to send a card package download request of the to-be-loaded quick-application card to the server according to the URL information of the to-be-loaded quick-application card;

下载单元,用于下载所述待加载的快应用卡片的卡片包体。The downloading unit is used for downloading the card package body of the quick application card to be loaded.

可选地,所述目标主题信息包括以下中的一项:Optionally, the target subject information includes one of the following:

终端上传的快应用卡片的主题信息;The subject information of the quick application card uploaded by the terminal;

快应用引擎内置的快应用卡片的主题信息;The topic information of the quick app card built in the quick app engine;

预先设定的快应用卡片的主题信息。The subject information of the pre-set quick application card.

可选地,所述设置模块包括:Optionally, the setting module includes:

判断单元,用于根据所述解析结果判断卡片页面组件是否使用主题;a judging unit for judging whether the card page component uses a theme according to the analysis result;

属性赋值单元,用于若使用主题,则根据所述目标主题信息给所述卡片页面组件的主题属性赋值。The attribute assignment unit is configured to assign value to the theme attribute of the card page component according to the target theme information if the theme is used.

可选地,所述判断单元包括:Optionally, the judging unit includes:

判断子单元,用于判断所述卡片页面元素信息是否包括主题使用标记;a judging subunit for judging whether the element information of the card page includes a theme usage mark;

确定单元,同于若包括所述主题使用标记,则确定卡片页面组件使用主题,否则,确定卡片页面组件不使用主题。The determining unit is the same as determining that the card page component uses the theme if the theme usage flag is included; otherwise, determining that the card page component does not use the theme.

终端300能够实现图1至图2的方法实施例中终端实现的各个过程,为避免重复,这里不再赘述。本发明的实施例,通过卡片包体的解析结果判断卡片组件是否使用主题,并在确定组件使用主题后,利用目标主题信息设置卡片主题,能够实现卡片在不同应用场景中以统一样式的主题显示,也可以实现卡片在不同应用场景的界面内以不同主题来显示,卡片主题的设置具有更高的灵活性。The terminal 300 can implement each process implemented by the terminal in the method embodiments of FIG. 1 to FIG. 2 , and to avoid repetition, details are not repeated here. In the embodiment of the present invention, whether the card component uses the theme is judged by the analysis result of the card package body, and after the component use theme is determined, the target theme information is used to set the card theme, which can realize the theme display of the card in a unified style in different application scenarios , the card can also be displayed with different themes in the interface of different application scenarios, and the setting of the card theme has higher flexibility.

图4为实现本发明各个实施例的一种终端的硬件结构示意图,该终端400包括但不限于:射频单元401、网络模块402、音频输出单元403、输入单元404、传感器405、显示单元406、用户输入单元407、接口单元408、存储器409、处理器410、以及电源411等部件。本领域技术人员可以理解,图4中示出的终端结构并不构成对终端的限定,终端可以包括比图示更多或更少的部件,或者组合某些部件,或者不同的部件布置。在本发明实施例中,终端包括但不限于手机、平板电脑、笔记本电脑、掌上电脑、车载终端、可穿戴设备、以及计步器等。4 is a schematic diagram of the hardware structure of a terminal implementing various embodiments of the present invention. The terminal 400 includes but is not limited to: a radio frequency unit 401, a network module 402, an audio output unit 403, an input unit 404, a sensor 405, a display unit 406, User input unit 407 , interface unit 408 , memory 409 , processor 410 , and power supply 411 and other components. Those skilled in the art can understand that the terminal structure shown in FIG. 4 does not constitute a limitation on the terminal, and the terminal may include more or less components than the one shown, or combine some components, or arrange different components. In the embodiment of the present invention, the terminal includes but is not limited to a mobile phone, a tablet computer, a notebook computer, a palmtop computer, a vehicle-mounted terminal, a wearable device, a pedometer, and the like.

其中,处理器410,用于获取待加载卡片的属性信息;根据所述属性信息下载所述待加载卡片的卡片包体;The processor 410 is configured to acquire attribute information of the card to be loaded; download the card package of the card to be loaded according to the attribute information;

处理器410,用于解析所述卡片包体,并获得解析结果,所述解析结果包括卡片页面元素信息;根据所述解析结果设置卡片主题的属性值。The processor 410 is configured to parse the card package body, and obtain a parsing result, where the parsing result includes card page element information; and set the attribute value of the card subject according to the parsing result.

可见,该终端通过卡片包体的解析结果判断卡片组件是否使用主题,并在确定组件使用主题后,利用待加载卡片的属性信息设置卡片主题,能够实现卡片在不同场景应用中以统一样式的主题显示,也可以实现卡片在不同场景应用的界面内以不同主题来显示,卡片主题的设置具有更高的灵活性。It can be seen that the terminal judges whether the card component uses the theme through the analysis result of the card package body, and after determining the component uses the theme, uses the attribute information of the card to be loaded to set the card theme, which can realize the theme of the card in a unified style in different scene applications It is also possible to display cards with different themes in the interface of different scene applications, and the setting of the card theme has higher flexibility.

应理解的是,本发明实施例中,射频单元401可用于收发信息或通话过程中,信号的接收和发送,具体的,将来自基站的下行数据接收后,给处理器410处理;另外,将上行的数据发送给基站。通常,射频单元401包括但不限于天线、至少一个放大器、收发信机、耦合器、低噪声放大器、双工器等。此外,射频单元401还可以通过无线通信系统与网络和其他设备通信。It should be understood that, in this embodiment of the present invention, the radio frequency unit 401 can be used for receiving and sending signals during sending and receiving information or during a call. Specifically, after receiving the downlink data from the base station, it is processed by the processor 410; The uplink data is sent to the base station. Generally, the radio frequency unit 401 includes, but is not limited to, an antenna, at least one amplifier, a transceiver, a coupler, a low noise amplifier, a duplexer, and the like. In addition, the radio frequency unit 401 can also communicate with the network and other devices through a wireless communication system.

终端通过网络模块402为用户提供了无线的宽带互联网访问,如帮助用户收发电子邮件、浏览网页和访问流式媒体等。The terminal provides the user with wireless broadband Internet access through the network module 402, such as helping the user to send and receive emails, browse web pages, and access streaming media.

音频输出单元403可以将射频单元401或网络模块402接收的或者在存储器409中存储的音频数据转换成音频信号并且输出为声音。而且,音频输出单元403还可以提供与终端400执行的特定功能相关的音频输出(例如,呼叫信号接收声音、消息接收声音等等)。音频输出单元403包括扬声器、蜂鸣器以及受话器等。The audio output unit 403 may convert audio data received by the radio frequency unit 401 or the network module 402 or stored in the memory 409 into audio signals and output as sound. Also, the audio output unit 403 may also provide audio output related to a specific function performed by the terminal 400 (eg, call signal reception sound, message reception sound, etc.). The audio output unit 403 includes a speaker, a buzzer, a receiver, and the like.

输入单元404用于接收音频或视频信号。输入单元404可以包括图形处理器(Graphics Processing Unit,GPU)4041和麦克风4042,图形处理器4041对在视频捕获模式或图像捕获模式中由图像捕获装置(如摄像头)获得的静态图片或视频的图像数据进行处理。处理后的图像帧可以显示在显示单元406上。经图形处理器4041处理后的图像帧可以存储在存储器409(或其它存储介质)中或者经由射频单元401或网络模块402进行发送。麦克风4042可以接收声音,并且能够将这样的声音处理为音频数据。处理后的音频数据可以在电话通话模式的情况下转换为可经由射频单元401发送到移动通信基站的格式输出。The input unit 404 is used to receive audio or video signals. The input unit 404 may include a graphics processor (Graphics Processing Unit, GPU) 4041 and a microphone 4042. The graphics processor 4041 captures images of still pictures or videos obtained by an image capture device (such as a camera) in a video capture mode or an image capture mode data is processed. The processed image frames may be displayed on the display unit 406 . The image frames processed by the graphics processor 4041 may be stored in the memory 409 (or other storage medium) or transmitted via the radio frequency unit 401 or the network module 402 . The microphone 4042 can receive sound and can process such sound into audio data. The processed audio data can be converted into a format that can be transmitted to a mobile communication base station via the radio frequency unit 401 for output in the case of a telephone call mode.

终端400还包括至少一种传感器405,比如光传感器、运动传感器以及其他传感器。具体地,光传感器包括环境光传感器及接近传感器,其中,环境光传感器可根据环境光线的明暗来调节显示面板4061的亮度,接近传感器可在终端400移动到耳边时,关闭显示面板4061和/或背光。作为运动传感器的一种,加速计传感器可检测各个方向上(一般为三轴)加速度的大小,静止时可检测出重力的大小及方向,可用于识别终端姿态(比如横竖屏切换、相关游戏、磁力计姿态校准)、振动识别相关功能(比如计步器、敲击)等;传感器405还可以包括指纹传感器、压力传感器、虹膜传感器、分子传感器、陀螺仪、气压计、湿度计、温度计、红外线传感器等,在此不再赘述。The terminal 400 also includes at least one sensor 405, such as a light sensor, a motion sensor, and other sensors. Specifically, the light sensor includes an ambient light sensor and a proximity sensor, wherein the ambient light sensor can adjust the brightness of the display panel 4061 according to the brightness of the ambient light, and the proximity sensor can turn off the display panel 4061 and/or when the terminal 400 is moved to the ear. or backlight. As a type of motion sensor, the accelerometer sensor can detect the magnitude of acceleration in all directions (generally three axes), and can detect the magnitude and direction of gravity when stationary, and can be used to identify the terminal posture (such as horizontal and vertical screen switching, related games, The sensor 405 may also include a fingerprint sensor, a pressure sensor, an iris sensor, a molecular sensor, a gyroscope, a barometer, a hygrometer, a thermometer, an infrared Sensors, etc., will not be repeated here.

显示单元406用于显示由用户输入的信息或提供给用户的信息。显示单元406可包括显示面板4061,可以采用液晶显示器(Liquid Crystal Display,LCD)、有机发光二极管(Organic Light-Emitting Diode,OLED)等形式来配置显示面板4061。The display unit 406 is used to display information input by the user or information provided to the user. The display unit 406 may include a display panel 4061, and the display panel 4061 may be configured in the form of a Liquid Crystal Display (LCD), an Organic Light-Emitting Diode (OLED), or the like.

用户输入单元407可用于接收输入的数字或字符信息,以及产生与终端的用户设置以及功能控制有关的键信号输入。具体地,用户输入单元407包括触控面板4071以及其他输入设备4072。触控面板4071,也称为触摸屏,可收集用户在其上或附近的触摸操作(比如用户使用手指、触笔等任何适合的物体或附件在触控面板4071上或在触控面板4071附近的操作)。触控面板4071可包括触摸检测装置和触摸控制器两个部分。其中,触摸检测装置检测用户的触摸方位,并检测触摸操作带来的信号,将信号传送给触摸控制器;触摸控制器从触摸检测装置上接收触摸信息,并将它转换成触点坐标,再送给处理器410,接收处理器410发来的命令并加以执行。此外,可以采用电阻式、电容式、红外线以及表面声波等多种类型实现触控面板4071。除了触控面板4071,用户输入单元407还可以包括其他输入设备4072。具体地,其他输入设备4072可以包括但不限于物理键盘、功能键(比如音量控制按键、开关按键等)、轨迹球、鼠标、操作杆,在此不再赘述。The user input unit 407 may be used to receive input numerical or character information, and generate key signal input related to user settings and function control of the terminal. Specifically, the user input unit 407 includes a touch panel 4071 and other input devices 4072 . The touch panel 4071, also referred to as a touch screen, can collect the user's touch operations on or near it (such as the user's finger, stylus, etc., any suitable object or accessory on or near the touch panel 4071). operate). The touch panel 4071 may include two parts, a touch detection device and a touch controller. Among them, the touch detection device detects the user's touch orientation, detects the signal brought by the touch operation, and transmits the signal to the touch controller; the touch controller receives the touch information from the touch detection device, converts it into contact coordinates, and then sends it to the touch controller. To the processor 410, the command sent by the processor 410 is received and executed. In addition, the touch panel 4071 can be implemented in various types such as resistive, capacitive, infrared, and surface acoustic waves. In addition to the touch panel 4071 , the user input unit 407 may also include other input devices 4072 . Specifically, other input devices 4072 may include, but are not limited to, physical keyboards, function keys (such as volume control keys, switch keys, etc.), trackballs, mice, and joysticks, which will not be repeated here.

进一步的,触控面板4071可覆盖在显示面板4061上,当触控面板4071检测到在其上或附近的触摸操作后,传送给处理器410以确定触摸事件的类型,随后处理器410根据触摸事件的类型在显示面板4061上提供相应的视觉输出。虽然在图4中,触控面板4071与显示面板4061是作为两个独立的部件来实现终端的输入和输出功能,但是在某些实施例中,可以将触控面板4071与显示面板4061集成而实现终端的输入和输出功能,具体此处不做限定。Further, the touch panel 4071 can be covered on the display panel 4061. When the touch panel 4071 detects a touch operation on or near it, it transmits it to the processor 410 to determine the type of the touch event, and then the processor 410 determines the type of the touch event according to the touch The type of event provides corresponding visual output on display panel 4061. Although in FIG. 4, the touch panel 4071 and the display panel 4061 are used as two independent components to realize the input and output functions of the terminal, in some embodiments, the touch panel 4071 and the display panel 4061 can be integrated to form a Realize the input and output functions of the terminal, which is not limited here.

接口单元408为外部装置与终端400连接的接口。例如,外部装置可以包括有线或无线头戴式耳机端口、外部电源(或电池充电器)端口、有线或无线数据端口、存储卡端口、用于连接具有识别模块的装置的端口、音频输入/输出(I/O)端口、视频I/O端口、耳机端口等等。接口单元408可以用于接收来自外部装置的输入(例如,数据信息、电力等等)并且将接收到的输入传输到终端400内的一个或多个元件或者可以用于在终端400和外部装置之间传输数据。The interface unit 408 is an interface for connecting an external device to the terminal 400 . For example, external devices may include wired or wireless headset ports, external power (or battery charger) ports, wired or wireless data ports, memory card ports, ports for connecting devices with identification modules, audio input/output (I/O) ports, video I/O ports, headphone ports, and more. The interface unit 408 may be used to receive input (eg, data information, power, etc.) from an external device and transmit the received input to one or more elements within the terminal 400 or may be used between the terminal 400 and the external device. transfer data between.

存储器409可用于存储软件程序以及各种数据。存储器409可主要包括存储程序区和存储数据区,其中,存储程序区可存储操作系统、至少一个功能所需的应用程序(比如声音播放功能、图像播放功能等)等;存储数据区可存储根据手机的使用所创建的数据(比如音频数据、电话本等)等。此外,存储器409可以包括高速随机存取存储器,还可以包括非易失性存储器,例如至少一个磁盘存储器件、闪存器件、或其他易失性固态存储器件。The memory 409 may be used to store software programs as well as various data. The memory 409 may mainly include a stored program area and a stored data area, wherein the stored program area may store an operating system, an application program (such as a sound playback function, an image playback function, etc.) required for at least one function, and the like; Data created by the use of the mobile phone (such as audio data, phone book, etc.), etc. Additionally, memory 409 may include high-speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other volatile solid state storage device.

处理器410是终端的控制中心,利用各种接口和线路连接整个终端的各个部分,通过运行或执行存储在存储器409内的软件程序和/或模块,以及调用存储在存储器409内的数据,执行终端的各种功能和处理数据,从而对终端进行整体监控。处理器410可包括一个或多个处理单元;优选的,处理器410可集成应用处理器和调制解调处理器,其中,应用处理器主要处理操作系统、用户界面和应用程序等,调制解调处理器主要处理无线通信。可以理解的是,上述调制解调处理器也可以不集成到处理器410中。The processor 410 is the control center of the terminal, uses various interfaces and lines to connect various parts of the entire terminal, and executes by running or executing the software programs and/or modules stored in the memory 409, and calling the data stored in the memory 409. Various functions of the terminal and processing data, so as to monitor the terminal as a whole. The processor 410 may include one or more processing units; preferably, the processor 410 may integrate an application processor and a modem processor, wherein the application processor mainly processes the operating system, user interface, and application programs, etc., and the modem The processor mainly handles wireless communication. It can be understood that, the above-mentioned modulation and demodulation processor may not be integrated into the processor 410.

终端400还可以包括给各个部件供电的电源411(比如电池),优选的,电源411可以通过电源管理系统与处理器410逻辑相连,从而通过电源管理系统实现管理充电、放电、以及功耗管理等功能。The terminal 400 may also include a power supply 411 (such as a battery) for supplying power to various components. Preferably, the power supply 411 may be logically connected to the processor 410 through a power management system, so as to manage charging, discharging, and power consumption management through the power management system. Function.

另外,终端400包括一些未示出的功能模块,在此不再赘述。In addition, the terminal 400 includes some unshown functional modules, which are not repeated here.

优选的,本发明实施例还提供一种终端,包括处理器、存储器及存储在存储器上并可在所述处理器上运行的计算机程序,该计算机程序被处理器执行时实现上述的快应用卡片主题设置方法的实施例的各个过程,且能达到相同的技术效果,为避免重复,这里不再赘述。Preferably, an embodiment of the present invention further provides a terminal, including a processor, a memory, and a computer program stored in the memory and running on the processor, the computer program implementing the above-mentioned quick application card when executed by the processor The various processes of the embodiments of the theme setting method can achieve the same technical effect, and are not repeated here in order to avoid repetition.

本发明实施例还提供一种计算机可读存储介质,计算机可读存储介质上存储有计算机程序,该计算机程序被处理器执行时实现上述的快应用卡片主题设置方法实施例的各个过程,且能达到相同的技术效果,为避免重复,这里不再赘述。其中,所述的计算机可读存储介质,如只读存储器(Read-Only Memory,简称ROM)、随机存取存储器(Random AccessMemory,简称RAM)、磁碟或者光盘等。Embodiments of the present invention also provide a computer-readable storage medium, where a computer program is stored on the computer-readable storage medium, and when the computer program is executed by a processor, each process of the above-mentioned embodiment of the method for setting a theme of a quick application card is implemented, and can To achieve the same technical effect, in order to avoid repetition, details are not repeated here. The computer-readable storage medium is, for example, a read-only memory (Read-Only Memory, ROM for short), a random access memory (Random Access Memory, RAM for short), a magnetic disk or an optical disk, and the like.

需要说明的是,在本文中,术语“包括”、“包含”或者其任何其他变体意在涵盖非排他性的包含,从而使得包括一系列要素的过程、方法、物品或者装置不仅包括那些要素,而且还包括没有明确列出的其他要素,或者是还包括为这种过程、方法、物品或者装置所固有的要素。在没有更多限制的情况下,由语句“包括一个……”限定的要素,并不排除在包括该要素的过程、方法、物品或者装置中还存在另外的相同要素。It should be noted that, herein, the terms "comprising", "comprising" or any other variation thereof are intended to encompass non-exclusive inclusion, such that a process, method, article or device comprising a series of elements includes not only those elements, It also includes other elements not expressly listed or inherent to such a process, method, article or apparatus. Without further limitation, an element qualified by the phrase "comprising a..." does not preclude the presence of additional identical elements in a process, method, article or apparatus that includes the element.

通过以上的实施方式的描述,本领域的技术人员可以清楚地了解到上述实施例方法可借助软件加必需的通用硬件平台的方式来实现,当然也可以通过硬件,但很多情况下前者是更佳的实施方式。基于这样的理解,本发明的技术方案本质上或者说对现有技术做出贡献的部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质(如ROM/RAM、磁碟、光盘)中,包括若干指令用以使得一台终端(可以是手机,计算机,服务器,空调器,或者网络设备等)执行本发明各个实施例所述的方法。From the description of the above embodiments, those skilled in the art can clearly understand that the method of the above embodiment can be implemented by means of software plus a necessary general hardware platform, and of course can also be implemented by hardware, but in many cases the former is better implementation. Based on this understanding, the technical solutions of the present invention can be embodied in the form of software products in essence or the parts that make contributions to the prior art, and the computer software products are stored in a storage medium (such as ROM/RAM, magnetic disk, CD), including several instructions to make a terminal (which may be a mobile phone, a computer, a server, an air conditioner, or a network device, etc.) execute the methods described in the various embodiments of the present invention.

上面结合附图对本发明的实施例进行了描述,但是本发明并不局限于上述的具体实施方式,上述的具体实施方式仅仅是示意性的,而不是限制性的,本领域的普通技术人员在本发明的启示下,在不脱离本发明宗旨和权利要求所保护的范围情况下,还可做出很多形式,均属于本发明的保护之内。The embodiments of the present invention have been described above in conjunction with the accompanying drawings, but the present invention is not limited to the above-mentioned specific embodiments, which are merely illustrative rather than restrictive. Under the inspiration of the present invention, without departing from the spirit of the present invention and the scope protected by the claims, many forms can be made, which all belong to the protection of the present invention.

Claims (13)

1.一种快应用卡片主题设置方法,其特征在于,包括:1. a quick application card theme setting method, is characterized in that, comprises: 获取待加载的快应用卡片的属性信息;Get the attribute information of the quick app card to be loaded; 根据所述属性信息下载所述待加载的快应用卡片的卡片包体;Download the card package of the quick application card to be loaded according to the attribute information; 解析所述卡片包体,并获得解析结果,所述解析结果包括卡片页面元素信息;Parsing the card body, and obtaining an parsing result, where the parsing result includes card page element information; 根据所述解析结果以及目标主题信息,设置所述待加载的快应用卡片主题的属性值。According to the parsing result and target theme information, the attribute value of the to-be-loaded quick application card theme is set. 2.根据权利要求1所述的快应用卡片主题设置方法,其特征在于,待加载的快应用卡片的属性信息包括:所述待加载的快应用卡片的统一资源定位符URL信息。2 . The method for setting a theme of a quick application card according to claim 1 , wherein the attribute information of the quick application card to be loaded comprises: Uniform Resource Locator URL information of the quick application card to be loaded. 3 . 3.根据权利要求2所述的快应用卡片主题设置方法,其特征在于,根据所述属性信息下载所述待加载的快应用卡片的卡片包体的步骤,包括:3. The method for setting the theme of a quick application card according to claim 2, wherein the step of downloading the card package of the quick application card to be loaded according to the attribute information comprises: 根据所述待加载的快应用卡片的所述URL信息,向服务器发送所述待加载的快应用卡片的卡片包体下载请求;According to the URL information of the to-be-loaded quick-application card, sending a card package download request of the to-be-loaded quick application card to the server; 下载所述待加载的快应用卡片的卡片包体。Download the card package of the quick application card to be loaded. 4.根据权利要求1所述的快应用卡片主题设置方法,其特征在于,所述目标主题信息包括以下中的一项:4. The method for setting the theme of a quick application card according to claim 1, wherein the target theme information comprises one of the following: 终端上传的快应用卡片的主题信息;The subject information of the quick application card uploaded by the terminal; 快应用引擎内置的快应用卡片的主题信息;The topic information of the quick app card built in the quick app engine; 预先设定的快应用卡片的主题信息。The subject information of the pre-set quick application card. 5.根据权利要求1所述的快应用卡片主题设置方法,其特征在于,根据所述解析结果以及目标主题信息,设置所述待加载的快应用卡片主题的属性值的步骤,包括:5. The method for setting a quick application card theme according to claim 1, wherein, according to the analysis result and target theme information, the step of setting the attribute value of the to-be-loaded quick application card theme comprises: 根据所述解析结果判断卡片页面组件是否使用主题;According to the analysis result, determine whether the card page component uses the theme; 若使用主题,则根据所述目标主题信息给所述卡片页面组件的主题属性赋值。If a theme is used, assign a value to the theme attribute of the card page component according to the target theme information. 6.根据权利要求5所述的快应用卡片主题设置方法,其特征在于,根据所述解析结果判断卡片页面组件是否使用主题的步骤,包括:6. The method for setting the theme of a quick application card according to claim 5, wherein the step of judging whether the card page component uses the theme according to the analysis result comprises: 判断所述卡片页面元素信息是否包括主题使用标记;judging whether the element information of the card page includes a theme usage mark; 若包括所述主题使用标记,则确定卡片页面组件使用主题,否则,确定卡片页面组件不使用主题。If the theme usage flag is included, it is determined that the card page component uses the theme, otherwise, it is determined that the card page component does not use the theme. 7.一种终端,其特征在于,包括:7. A terminal, characterized in that, comprising: 获取模块,用于获取待加载的快应用卡片的属性信息;The acquisition module is used to acquire the attribute information of the quick application card to be loaded; 下载模块,用于根据所述属性信息下载所述待加载的快应用卡片的卡片包体;a download module, configured to download the card package of the to-be-loaded quick application card according to the attribute information; 解析模块,用于解析所述卡片包体,并获得解析结果,所述解析结果包括卡片页面元素信息;a parsing module, used for parsing the card package body, and obtaining parsing results, where the parsing results include card page element information; 设置模块,用于根据所述解析结果以及目标主题信息,设置所述待加载的快应用卡片主题的属性值。A setting module is configured to set the attribute value of the theme of the quick application card to be loaded according to the analysis result and target theme information. 8.根据权利要求7所述的终端,其特征在于,待加载的快应用卡片的属性信息包括:所述待加载的快应用卡片的统一资源定位符URL信息。8 . The terminal according to claim 7 , wherein the attribute information of the quick application card to be loaded comprises: Uniform Resource Locator URL information of the quick application card to be loaded. 9 . 9.根据权利要求8所述的终端,其特征在于,所述下载模块包括:9. The terminal according to claim 8, wherein the downloading module comprises: 请求单元,用于根据所述待加载的快应用卡片的所述URL信息,向服务器发送所述待加载的快应用卡片的卡片包体下载请求;a requesting unit, configured to send a card package download request of the to-be-loaded quick-application card to the server according to the URL information of the to-be-loaded quick-application card; 下载单元,用于下载所述待加载的快应用卡片的卡片包体。The downloading unit is used for downloading the card package body of the quick application card to be loaded. 10.根据权利要求7所述的终端,其特征在于,所述目标主题信息包括以下中的一项:10. The terminal according to claim 7, wherein the target subject information comprises one of the following: 终端上传的快应用卡片的主题信息;The subject information of the quick application card uploaded by the terminal; 快应用引擎内置的快应用卡片的主题信息;The topic information of the quick app card built in the quick app engine; 预先设定的快应用卡片的主题信息。The subject information of the pre-set quick application card. 11.根据权利要求7所述的终端,其特征在于,所述设置模块包括:11. The terminal according to claim 7, wherein the setting module comprises: 判断单元,用于根据所述解析结果判断卡片页面组件是否使用主题;a judging unit for judging whether the card page component uses a theme according to the analysis result; 属性赋值单元,用于若使用主题,则根据所述目标主题信息给所述卡片页面组件的主题属性赋值。The attribute assignment unit is configured to assign value to the theme attribute of the card page component according to the target theme information if the theme is used. 12.根据权利要求11所述的终端,其特征在于,所述判断单元包括:12. The terminal according to claim 11, wherein the judging unit comprises: 判断子单元,用于判断所述卡片页面元素信息是否包括主题使用标记;a judging subunit for judging whether the element information of the card page includes a theme usage mark; 确定单元,同于若包括所述主题使用标记,则确定卡片页面组件使用主题,否则,确定卡片页面组件不使用主题。The determining unit is the same as determining that the card page component uses the theme if the theme usage flag is included; otherwise, determining that the card page component does not use the theme. 13.一种终端,其特征在于,包括处理器、存储器及存储在所述存储器上并可在所述处理器上运行的计算机程序,所述计算机程序被所述处理器执行时实现如权利要求1至6中任一项所述的快应用卡片主题设置方法的步骤。13. A terminal, characterized in that it comprises a processor, a memory, and a computer program stored on the memory and running on the processor, the computer program being executed by the processor to achieve as claimed in the claims The steps of any one of 1 to 6 in the method for setting the theme of a quick application card.
CN201910294525.3A 2019-04-12 2019-04-12 A kind of quick application card theme setting method and terminal Active CN110035181B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910294525.3A CN110035181B (en) 2019-04-12 2019-04-12 A kind of quick application card theme setting method and terminal

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910294525.3A CN110035181B (en) 2019-04-12 2019-04-12 A kind of quick application card theme setting method and terminal

Publications (2)

Publication Number Publication Date
CN110035181A CN110035181A (en) 2019-07-19
CN110035181B true CN110035181B (en) 2020-08-04

Family

ID=67238359

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910294525.3A Active CN110035181B (en) 2019-04-12 2019-04-12 A kind of quick application card theme setting method and terminal

Country Status (1)

Country Link
CN (1) CN110035181B (en)

Families Citing this family (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110572431A (en) * 2019-07-31 2019-12-13 华为技术有限公司 A card sharing method, device and system
CN110865864B (en) * 2019-11-18 2023-07-25 北京小米移动软件有限公司 Quick application interface display method, device, equipment and storage medium
CN110874217B (en) * 2019-11-18 2023-08-15 北京小米移动软件有限公司 Interface display method and device for quick application and storage medium
CN113138827B (en) * 2021-04-29 2024-05-31 北京百度网讯科技有限公司 Method, device, electronic device and medium for displaying data
CN114546375A (en) * 2021-12-23 2022-05-27 厦门科灿信息技术有限公司 Page configuration method, page configuration device and electronic equipment
CN115033331B (en) * 2022-06-28 2024-11-19 Oppo广东移动通信有限公司 Card display method and related products
CN116737405B (en) * 2022-10-24 2024-03-05 荣耀终端有限公司 A data communication method and related equipment for quick application cards

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107911469A (en) * 2017-11-29 2018-04-13 广东欧珀移动通信有限公司 Card configuration method, device and server
WO2018109589A1 (en) * 2016-12-15 2018-06-21 Walkme Ltd. Updating data records by adding editing functions to non-editable display elements
CN108509526A (en) * 2018-03-13 2018-09-07 百度在线网络技术(北京)有限公司 The method and apparatus of interface element for Dynamic Distribution's mobile application
CN108733448A (en) * 2018-05-28 2018-11-02 北京小米移动软件有限公司 Theme processing method, device, equipment, system and storage medium
CN109388453A (en) * 2018-09-07 2019-02-26 Oppo广东移动通信有限公司 Application page display method and device, storage medium and electronic equipment

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2018109589A1 (en) * 2016-12-15 2018-06-21 Walkme Ltd. Updating data records by adding editing functions to non-editable display elements
CN107911469A (en) * 2017-11-29 2018-04-13 广东欧珀移动通信有限公司 Card configuration method, device and server
CN108509526A (en) * 2018-03-13 2018-09-07 百度在线网络技术(北京)有限公司 The method and apparatus of interface element for Dynamic Distribution's mobile application
CN108733448A (en) * 2018-05-28 2018-11-02 北京小米移动软件有限公司 Theme processing method, device, equipment, system and storage medium
CN109388453A (en) * 2018-09-07 2019-02-26 Oppo广东移动通信有限公司 Application page display method and device, storage medium and electronic equipment

Also Published As

Publication number Publication date
CN110035181A (en) 2019-07-19

Similar Documents

Publication Publication Date Title
CN110035181B (en) A kind of quick application card theme setting method and terminal
CN108415652B (en) A text processing method and mobile terminal
CN108958074B (en) A kind of smart machine control method and mobile terminal
CN111142930B (en) Installation package file packaging method and device, terminal device and storage medium
CN109284144B (en) Fast application processing method and mobile terminal
CN107682359B (en) Application registration method and mobile terminal
WO2018107941A1 (en) Multi-screen linking method and system utilized in ar scenario
CN108170723B (en) Webpage resource acquisition method, terminal equipment, server and system
CN110046015A (en) Using sharing method and terminal
CN107808107B (en) Application message display method and mobile terminal
CN111061404A (en) Control method and first electronic device
CN108469968A (en) A kind of applied program processing method and mobile terminal
CN110096203B (en) A screenshot method and mobile terminal
CN108898040A (en) A kind of recognition methods and mobile terminal
CN108391253B (en) Application recommendation method and mobile terminal
CN108009031B (en) Application program control method and mobile terminal
CN110796438B (en) Message sending method and mobile terminal
CN109491670A (en) A kind of page display method and terminal device
CN108121546A (en) A kind of information processing method and mobile terminal
CN107861786A (en) The reminding method and mobile terminal of a kind of notice
CN105094872B (en) A kind of method and apparatus showing web application
WO2017005080A1 (en) Webpage display method, terminal device and storage medium
CN110471895B (en) Sharing method and terminal device
CN105320532B (en) Method, device and terminal for displaying interactive interface
CN108710789B (en) Unlocking method 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