The generation method and device of the main interface configuration information of desktop starterTechnical field
The invention belongs to intelligent television technical field, particularly relate to a kind of main interface configuration information of desktop starterGeneration method and device.
Background technology
Intelligent television is the new product formed based on the impact of the Internet tide, its objective is to bring user more convenientExperience, have become as the trend trend of TV at present.
Along with " Intelligent hardware interconnection networking ", the operation of intelligent television the Internet has become as a kind of trend.Launcher is Android system desktop starter.Generally, Launcher main interface operation personnel will be according to marketVideo resource inside change and the user preferences main interface of layout Launcher at any time.
But, the arranging system great majority at the main interface of Launcher based on WEB that currently there are are alsoIt it is operation personnel's craft mark up of video resource.Operation personnel will be according to country variant code, different licence plate business, noWith the video resource inside the main interfaces of condition layout Launcher such as visual classification.With upper type, transported every dayThe workload at the main interface of battalion personnel layout Launcher is the biggest.
Summary of the invention
Embodiments provide the generation method and device of the main interface configuration information of a kind of desktop starter, purportIn the generation method solving the main interface configuration information of desktop starter that prior art provides so that every day runs peopleThe biggest problem of workload at the member main interface of layout Launcher.
On the one hand, it is provided that the generation method of the main interface configuration information of a kind of Launcher, described method includes:
Step A, the layout at the main interface of layout Launcher, add Tab page on the main interface of described Launcher,And in each Tab page, add the Block block of corresponding size;
Step B, editor's national code, the layout for the programmed main interface of described Launcher adds national code;
The other weight of each video class under step C, the weight that each licence plate business is set and each licence plate business;
On step D, the calculating main interface of Launcher, video resource is the block number of empty Block block;
Step E, according to the other power of each video class under described piece of number, the weight of each licence plate business and each licence plate businessRe-computation each video classification needs the video resource number filled;
Step F, the video resource number corresponding video resource of acquisition filled according to described each video classification needs,And poster to the video resource filling the video resource got is in empty Block block, generate the main boundary of LauncherFace configuration information.
Further, described D includes:
In the traversal main interface of Launcher each Tab page;
The block number that video resource in each Tab page is empty Block block is added up, obtains LauncherOn main interface, video resource is the total block data of empty Block block.
Further, described step F includes:
The video resource number filled is needed to obtain the video money under respective country code according to described each video classificationSource;
It is in empty Block block filling after the poster cutting of described video resource to video resource, generatesThe main interface configuration information of Launcher.
Further, the poster of described video resource is rectangle, and described Block block is square, described instituteFill after stating the poster cutting of video resource to the Block block that video resource is sky, including:
Take the limit that the poster of described video resource is the shortest, clipping rectangle is become square;
If the poster length of side after cutting is more than the length of side of filling block, then the poster after cutting is compressed operation;
If the poster length of side after cutting is less than the length of side of filling block, then the poster after cutting is carried out stretched operation.
Further, before described step A, also include:
Configuring timing tasks, arranges and triggers the moment automatically generating the main interface configuration information of Launcher;
After described step C, also include:
Start timer and carry out timing;
When timing time arrives the moment that the triggering arranged automatically generates the main interface configuration information of Launcher,Perform step D successively to step F.
On the other hand, it is provided that the generating means of the main interface configuration information of a kind of Launcher, described device includes:
Layout orchestration module, for the layout at the main interface of layout Launcher, on the main interface of described LauncherAdd Tab page, and in each Tab page, add the Block block of corresponding size;
National code editor module, is used for editing national code, for the layout at the programmed main interface of described LauncherAdd national code;
Weight setting module, the other power of each video class under the weight that each licence plate business is set and each licence plate businessWeight;
Filler computing module, for calculating the block that video resource on the main interface of Launcher is empty Block blockNumber;
Number of resources computing module, for according under described piece of number, the weight of each licence plate business and each licence plate business eachThe other weight calculation of video class each video classification needs the video resource number filled;
Resource packing module, corresponding for needing the video resource number filled to obtain according to described each video classificationVideo resource under national code, and the Block that poster to the video resource filling the video resource got is skyIn block, generate the main interface configuration information of Launcher.
Further, described filler computing module includes:
Traversal Unit, for traveling through each Tab page in the main interface of Launcher;
Summing elements, for being added up by the Block block that video resource in each Tab page is empty, obtainsOn the main interface of Launcher, video resource is the total block data of empty Block block.
Further, described resource packing module includes:
Resource acquisition unit, corresponding for needing the video resource number filled to obtain according to described each video classificationVideo resource under national code;
Resource fills unit, and it is empty for being used for filling after the poster cutting of described video resource to video resourceIn Block block, generate the main interface configuration information of Launcher.
Further, the poster of described video resource is rectangle, and described Block block is square, described resourceFilling unit includes:
Cutting subelement, for taking the limit that the poster of described video resource is the shortest, becomes square by clipping rectangle;
Compression unit, if the poster length of side after cutting is more than the length of side of filling block, then to the poster after cuttingIt is compressed operation;
Draw unit, if the poster length of side after cutting is less than the length of side of filling block, then to the poster after cuttingCarry out stretched operation.
Further, described device also includes:
Timed task configuration module, for configuring timing tasks, arranges triggering and automatically generates the main interface of LauncherThe moment of configuration information;
Timing module, is used for starting timer and carries out timing;
Trigger module, for automatically generating the main interface configurations of Launcher when timing time arrives the triggering arrangedDuring moment of information, call successively filler computing module, number of resources computing module and resource packing module fromThe dynamic generation main interface configuration information of Launcher.
In the embodiment of the present invention, the layout at the main interface of the good Launcher of operation personnel's layout, edit national code,Setting under the weight of each licence plate business and each licence plate business after the other weight of each video class, system can the most first be countedCalculating video resource on the main interface of Launcher is the block number of empty Block block, further according to described piece of number, each licence plate businessWeight and each licence plate business under the other weight calculation of each video class each video classification need fill videoNumber of resources, then needs the video resource number filled to obtain under respective country code according to described each video classificationIn video resource, and the Block block that poster to the video resource filling the video resource got is sky, generateThe main interface configuration information of Launcher.The method of the main interface configuration information of this generation Launcher substantially reduces fortuneThe workload of battalion personnel, improves operation personnel and issues the efficiency at the main interface of Launcher.
Accompanying drawing explanation
Fig. 1 is the realization of the generation method of the main interface configuration information of desktop starter that the embodiment of the present invention one providesFlow chart;
Fig. 2 is in the generation method of the main interface configuration information of desktop starter that the embodiment of the present invention one provides, and compilesThe schematic diagram of the layout at the row main interface of Launcher;
Fig. 3 is in the generation method of the main interface configuration information of desktop starter that the embodiment of the present invention one provides, and compilesThe schematic diagram of the layout at the row main interface of Launcher;
Fig. 4 is in the generation method of the main interface configuration information of desktop starter that the embodiment of the present invention one provides, ifPut the weight schematic diagram of each licence plate business;
Fig. 5 is in the generation method of the main interface configuration information of desktop starter that the embodiment of the present invention one provides, ifPut each video class other weight schematic diagram under each licence plate business;
Fig. 6 is the structure of the generating means of the main interface configuration information of desktop starter that the embodiment of the present invention two providesBlock diagram.
Detailed description of the invention
In order to make the purpose of the present invention, technical scheme and advantage clearer, below in conjunction with accompanying drawing and realityExecute example, the present invention is further elaborated.Only should be appreciated that specific embodiment described hereinOnly in order to explain the present invention, it is not intended to limit the present invention.
In embodiments of the present invention, the main interface of the good Launcher of operation personnel's layout layout, edit countryUnder code, the weight setting each licence plate business and each licence plate business after the other weight of each video class, system can be certainlyIt is dynamic that first to calculate video resource on the main interface of Launcher be the block number of empty Block block, further according to described piece of number,Under the weight of each licence plate business and each licence plate business, the other weight calculation of each video class each video classification needs to fill outThe video resource number filled, the video resource number then should filled according to described each video classification obtains correspondingVideo resource, and to fill poster to the video resource of video resource got be in empty Block block, rawBecome the main interface configuration information of Launcher.
Below in conjunction with specific embodiment, the realization of the present invention is described in detail:
Embodiment one
Fig. 1 shows the generation method of the main interface configuration information of desktop starter that the embodiment of the present invention one providesRealizing flow process, details are as follows:
In step S101, the layout at the main interface of layout Launcher, the main interface of described Launcher addsAdd Tab page, and in each Tab page, add the Block block of corresponding size.
In embodiments of the present invention, operation personnel adds tab page by browser at the main interface of Launcher, andIn each tab page, add the Block block of corresponding size, Fig. 2 is shown that the main interface information of LauncherTab page of list, enter into editor's Tab page after clicking on [add Tab] button, as Fig. 3 has fourButton, can add in Tab page by the Block block of correspondingly-sized after clicking on corresponding button automatically, eachBlock block can fill the poster of corresponding video resource, and intelligent television receives user's aforesaid operations and stores operation knotReally.
In step s 102, editing national code, the layout for the programmed main interface of described Launcher is addedNational code.
In embodiments of the present invention, operation personnel passes through browser at the programmed main interface of described LauncherLayout add, revise, delete national code, intelligent television receives user's aforesaid operations and also stores national code.
In step s 103, the other weight of each video class under the weight of each licence plate business and each licence plate business is set.
In embodiments of the present invention, operation personnel arranges the weight of each licence plate business and each licence plate by browserThe other weight of each video class under business.First the weight of each licence plate business, as shown in Figure 4, weight sum are setIt is 100;Then the other weight of each video class under each licence plate business is set, as it is shown in figure 5, weight sum is100, intelligent television receives user's aforesaid operations and stores each weight number.
In step S104, calculating video resource on the main interface of Launcher is the block number of empty Block block.
In embodiments of the present invention, each Tab page during first intelligent television travels through the main interface of Launcher;SoAfter the block number that video resource in each Tab page is empty Block block is added up, obtain the main interface of LauncherUpper video resource is the total block data of empty Block block, can be designated as FillNum.
In step S105, according to each video class under described piece of number, the weight of each licence plate business and each licence plate businessOther weight calculation each video classification needs the video resource number filled.
In embodiments of the present invention, intelligent television is arranged according to calculated piece of number of step S104, step S103The weight of each licence plate business and each licence plate business under the other weight calculation of each video class each video classification needThe video resource number filled.
Such as: the weight of licence plate business A is 80;
The weight of video classification aa of licence plate business A is 40;The weight of video classification ab is 60;
The weight of licence plate business B is 20;
The weight of video classification ba of licence plate business B is 30;The weight of video classification bb is 70;
The number of resources that video classification aa should be filled is 80*40*FillNum/10000;
The number of resources that video classification class ab should be filled is 80*60*FillNum/10000;
The number of resources that video classification ba should be filled is 20*30*FillNum/10000;
The number of resources that visual classification bb should fill is 20*70*FillNum/10000.
In step s 106, the video resource number filled is needed to obtain respective country according to described each video classificationIn video resource under Ma, and the Block block that poster to the video resource filling the video resource got is sky,Generate the main interface configuration information of Launcher.
In embodiments of the present invention, intelligent television first needs the video resource filled according to described each video classificationNumber obtains the video resource under respective country code from server, then fills out after the poster cutting of described video resourceBeing charged to video resource is in empty Block block, generates the main interface configuration information of Launcher.
Concrete, video prefecture server provides two interfaces.Wherein, interface A is for according to licence plate business idObtain video categorical data;Interface B is for obtaining video resource data according to licence plate business id and video classification.
After calling interface A obtains the video categorical data of licence plate business, recall interface B and obtain video resource numberAccording to.
Wherein, the poster of the video resource got is rectangle, and in the main interface of Launcher Block block beSquare, therefore, after getting video resource data, can first take the limit that the poster of video resource is the shortest, willClipping rectangle becomes square;If the poster length of side after cutting is more than the length of side of filling block, the most again to the sea after cuttingReport is compressed operation;If the poster length of side after cutting is less than the length of side of filling block, the most again to the poster after cuttingCarry out stretched operation.
The poster of the video resource after cutting is compressed or after stretched operation, the poster that can will processFilling to video resource is in empty Block block, generates the main interface configuration information of Launcher.
Preferably, before step S101, it is also possible to including:
Step 1, configuring timing tasks, arrange and trigger the moment automatically generating the main interface configuration information of Launcher.
In embodiments of the present invention, operation personnel passes through browser configuring timing tasks, arranges triggering the most rawBecome the moment of the main interface configuration information of Launcher.Intelligent television provides and selects in date Hour Minute Second week etc..Operation personnel can control startup time and the startup of timed task by arranging the information such as date Hour Minute SecondFrequency, intelligent television arranges this timed task according to the configuration of operation personnel and stores configuration information.
Concrete, configuring timing tasks can be carried out by writing configuration file, compiling form is as shown in table 1, usesDate Hour Minute Second totally 6 groups of numerals represent, often group numeral space separates, and gives every set of number in table 1Detailed description.
Such as, the timed task of configuration is to perform 8: 45 every morning to be then 0008 45 0.
Table 1
After step s 103, also include:
Step 2, startup timer carry out timing;
Step 3, when timing time arrive arrange triggering automatically generate the main interface configuration information of Launcher timeDuring quarter, perform step S104 successively to step S106.
The present embodiment, receives the input operation layout with the main interface of the good Launcher of layout of operation personnel, editorUnder good national code, the weight setting each licence plate business and each licence plate business after the other weight of each video class, intelligenceTelevision system can the most first calculate the block number that video resource on the main interface of Launcher is empty Block block, further according toEach video class each video class of other weight calculation under described piece of number, the weight of each licence plate business and each licence plate businessDo not need the video resource number filled, then need the video resource number filled to obtain according to described each video classificationTake the video resource under respective country code, and poster to the video resource filling the video resource got is emptyIn Block block, generate the main interface configuration information of Launcher.The side of the main interface configuration information of this generation LauncherMethod substantially reduces the workload of operation personnel, improves operation personnel and issues the efficiency at the main interface of Launcher.
One of ordinary skill in the art will appreciate that all or part of step realizing in the various embodiments described above methodThe program that can be by completes to instruct relevant hardware, and corresponding program can be stored in a computer-readableTaking in storage medium, described storage medium, such as ROM/RAM, disk or CD etc..
Embodiment two
Fig. 6 shows the generating means of the main interface configuration information of desktop starter that the embodiment of the present invention two providesConcrete structure block diagram, for convenience of description, illustrate only the part relevant to the embodiment of the present invention.This desktopThe generating means 6 of the main interface configuration information of trigger includes: layout orchestration module 61, national code editor module62, weight setting module 63, filler computing module 64, number of resources computing module 65 and resource packing module66。
Wherein, layout orchestration module 61, for the layout at the main interface of layout Launcher, at described LauncherAdd Tab page on main interface, and in each Tab page, add the Block block of corresponding size;
National code editor module 62, is used for editing national code, for the cloth at the programmed main interface of described LauncherOffice adds national code;
Weight setting module 63, under the weight arranging each licence plate business and each licence plate business, each video class is otherWeight;
Filler computing module 64, for calculating the block that video resource on the main interface of Launcher is empty Block blockNumber;
Number of resources computing module 65, for according to each under described piece of number, the weight of each licence plate business and each licence plate businessThe other weight calculation of individual video class each video classification needs the video resource number filled;
Resource packing module 66, for needing the video resource number filled to obtain phase according to described each video classificationAnswer the video resource under national code, and poster to the video resource filling the video resource got is emptyIn Block block, generate the main interface configuration information of Launcher.
Further, described filler computing module 65 includes:
Traversal Unit, for traveling through each Tab page in the main interface of Launcher;
Summing elements, for being added up by the Block block that video resource in each Tab page is empty, obtainsOn the main interface of Launcher, video resource is the total block data of empty Block block.
Further, described resource packing module 66 includes:
Resource acquisition unit, corresponding for needing the video resource number filled to obtain according to described each video classificationVideo resource under national code;
Resource fills unit, and it is empty for being used for filling after the poster cutting of described video resource to video resourceIn Block block, generate the main interface configuration information of Launcher.
Further, the poster of described video resource is rectangle, and described Block block is square, described resourceFilling unit includes:
Cutting subelement, for taking the limit that the poster of described video resource is the shortest, becomes square by clipping rectangle;
Compression unit, if the poster length of side after cutting is more than the length of side of filling block, then to the poster after cuttingIt is compressed operation;
Draw unit, if the poster length of side after cutting is less than the length of side of filling block, then to the poster after cuttingCarry out stretched operation.
Preferably, the generating means 6 of the main interface configuration information of described desktop starter also includes:
Timed task configuration module, for configuring timing tasks, arranges triggering and automatically generates the main interface of LauncherThe moment of configuration information;
Timing module, is used for starting timer and carries out timing;
Trigger module, for automatically generating Launcher main interface configurations letter when timing time arrives the triggering arrangedDuring the moment ceased, call filler computing module 64, number of resources computing module 65 and resource packing module 66 successivelyAutomatically generate the main interface configuration information of Launcher.
The generating means of the main interface configuration information of desktop starter that the embodiment of the present invention provides can be applied frontStating in the embodiment of the method one of correspondence, details see the description of above-described embodiment one, do not repeat them here.
It should be noted that in said apparatus embodiment, included unit is according to function logicCarry out dividing, but be not limited to above-mentioned division, as long as being capable of corresponding function;SeparatelyOutward, the specific name of each functional unit also only to facilitate mutually distinguish, is not limited to the present invention'sProtection domain.
The foregoing is only presently preferred embodiments of the present invention, not in order to limit the present invention, all at thisAny amendment, equivalent and the improvement etc. made within bright spirit and principle, should be included in the present inventionProtection domain within.