A kind of method and apparatus of display application program background image
Technical field
The present invention relates to field of computer technology, particularly to a kind of method of display application program background image and dress
Put.
Background technology
With the fast development of terminal technology, in terminal, the species of application program is more and more various, and function is also more and more richer
Rich.
In the application, respective background image can be all provided with different interfaces or window, background image is permissible
It is simple monochrome(As white, blue etc.)Still image or various more complicated image.
During realizing the present invention, inventor finds that above-mentioned technology at least has problems with:
The background image of application program is to be pre-set by developer or by user setup, after setting, in application journey
During the use of sequence, background image will not occurrence dynamics change, if necessary to change then need to re-start setting, this
The processing mode of display application program background image, can lead to the background image of application program more inflexible, show very flexible.
Content of the invention
In order to solve the problems, such as above-mentioned technology, embodiments provide a kind of side of display application program background image
Method and device, to improve the display flexibility of application program background image.Described technical scheme is as follows:
On the one hand, there is provided a kind of method of display application program background image, methods described includes:
Receive the background idsplay order of destination application, in described background idsplay order, carry geographic area mark;
According to the corresponding relation of the image prestoring and geographic area mark, determine in described background idsplay order and carry
Geographic area identify corresponding image be background image;
Described background image is shown in the background display position of described destination application.
On the other hand, there is provided a kind of device of display application program background image, described device includes:
Receiver module, for receiving the background idsplay order of destination application, carries in described background idsplay order
Geographic area identifies;
Determining module, for the corresponding relation according to the image prestoring and geographic area mark, determines described background
It is background image that the geographic area carrying in idsplay order identifies corresponding image;
Display module, the background for described background image is shown in described destination application shows position.
The beneficial effect that technical scheme provided in an embodiment of the present invention is brought is:
In the embodiment of the present invention, receive the background idsplay order carrying geographic area mark of destination application, root
According to the corresponding relation of the image prestoring and geographic area mark, determine the geographic area carrying in described background idsplay order
Identifying corresponding image is background image, and is shown, so, in the application, can be according to different geographic areas
Show different background images, such that it is able to improve the display flexibility of application program background image.
Brief description
For the technical scheme being illustrated more clearly that in the embodiment of the present invention, will make to required in embodiment description below
Accompanying drawing be briefly described it should be apparent that, drawings in the following description are only some embodiments of the present invention, for
For those of ordinary skill in the art, on the premise of not paying creative work, other can also be obtained according to these accompanying drawings
Accompanying drawing.
Fig. 1 is the method flow diagram of display application program background image provided in an embodiment of the present invention;
Fig. 2 is the apparatus structure schematic diagram of display application program background image provided in an embodiment of the present invention.
Specific embodiment
For making the object, technical solutions and advantages of the present invention clearer, below in conjunction with accompanying drawing to embodiment party of the present invention
Formula is described in further detail.
Embodiment one
Embodiments provide a kind of method of display application program background image, as shown in figure 1, the place of the method
Reason flow process can include the steps:
Step 101, receives the background idsplay order of destination application, carries geographic area mark in background idsplay order
Know.
Step 102, according to the corresponding relation of the image prestoring and geographic area mark, determines in background idsplay order
It is background image that the geographic area carrying identifies corresponding image.
Step 103, background image is shown in the background display position of destination application.
In the embodiment of the present invention, receive the background idsplay order carrying geographic area mark of destination application, root
According to the corresponding relation of the image prestoring and geographic area mark, determine the geographic area carrying in described background idsplay order
Identifying corresponding image is background image, and is shown, so, in the application, can be according to different geographic areas
Show different background images, such that it is able to improve the display flexibility of application program background image.
Embodiment two
Embodiments provide a kind of method of display application program background image, the executive agent of the method is permissible
Be preferably terminal, the such as mobile terminal such as mobile phone, panel computer, application program can be installed in the terminal, below in flow process
Any application in the application program that destination application is installed for terminal.
In the embodiment of the present invention, terminal can prestore image and the corresponding relation of geographic area mark.Wherein, geographical
Area identification can be the mark uniquely corresponding to a geographic area, and geographic area can be the region dividing by Administrative boundaries,
Such as geographic area mark can be urban sign, and geographic area can also be the region dividing by the feature such as natural or humane,
This mark can be artificially defined numbering etc..Identifying corresponding image with geographic area can be arbitrary image, Ke Yishi
Picture, animation, video etc. can reflect corresponding geographic area it is preferred that geographic area identifies corresponding image
The image of provincial characteristics, for example, tourist attraction in geographic area, famous building, representative plant, representative animal, peculiar
The image of custom etc..
The above-mentioned image prestoring and the corresponding relation of geographic area mark, can develop design in application program
When be configured and be stored in the installation kit of application program;Can also enter in server side after application program is installed and used
Row setting, is sent to terminal by server and is preserved;Can also be configured by user after application program is installed and used,
And it is saved in terminal.The embodiment of the present invention can be discussed in detail in terminal setting image and geographic area mark in the content below
Corresponding relation method.
Preferably, terminal, when the corresponding relation to image and geographic area mark stores, can store each figure
The image file of picture, and the corresponding relation of the filename using description file record image file and geographic area mark, will be each
Image file and the common packing of description file obtain background bag(As being packaged as the compressed file of predetermined format).Description file is permissible
It is XML(Extensible Markup Language, extensible markup language)The file of form.Description file can include as
Under content:
<Weatherscreen version="1"frameRate="60"screenWidth="720">
<Image w="#view_width"h="#view_height"srcExp="'weather_bg_'+#pid+'
.png'"/>
</Weatherscreen>
Wherein, srcExp corresponding be image file filename, #pid be geographic area mark(As urban sign),
During storage image file, the file name formats of image file can be:Weather_bg_ geographic area identifies .png, for example, north
The geographic area in capital is designated 10101010100, then the filename of corresponding image file can be weather_bg_
101010100.png.
It is state of weather application program for destination application(For showing the application program of state of weather)Situation,
Preferably, the image that terminal prestores and the corresponding relation of geographic area mark can be specially image, geographic area mark
With the corresponding relation of Weather information, each geographic area identifies and Weather information can correspond to an image, and Weather information is permissible
It is the information of mark state of weather, such as fine, cloudy, cloudy, mist etc..So, identical geographic area is identified, this geographic area
Weather conditions different when, different images can be corresponded to, the process of display background image can be described in detail below.
Below in conjunction with implementation process, the handling process shown in Fig. 1 is described in detail, content can be as follows.
Step 101, receives the background idsplay order of destination application, carries geographic area mark in background idsplay order
Know.
In force, the process of this step can be opened destination application in user or open destination application
Start behind certain interface to execute.
For example, user clicks on the shortcut of destination application, during starting destination application, can trigger
Generate the background image that background idsplay order is used for the interface of display target application program.When generating background idsplay order, permissible
Carry geographic area mark wherein.This geographic area mark can determine according to the current geographical location information of terminal, at end
End can prestore the corresponding relation of geographical location information and geographic area mark, the geographic region carrying in background idsplay order
Domain identifier can be determined according to the corresponding relation that the geographical location information that prestores is identified with geographic area with current
Geographical location information corresponding geographic area mark.Geographical location information can be coordinate information etc., by positioning can be
System obtains.Terminal then carries out follow-up handling process after being connected to background idsplay order.
Again for example, in state of weather application program, after user selects city switching, state of weather display circle can be carried out
The switching in face, at this moment can trigger the background image generating background idsplay order for switching state of weather display interface.Generate
During background idsplay order, the geographic area mark that user selects the city of switching can be carried wherein.
Step 102, according to the corresponding relation of the image prestoring and geographic area mark, determines in background idsplay order
It is background image that the geographic area carrying identifies corresponding image.
For the corresponding relation of the above-mentioned image prestoring and geographic area mark, can be stored in certain and pre-set
Storage location, in catalogue as default in certain.For example, operating system is had to the terminal of changeable framework functions, changeable frame
Frame can correspond to destination application and arrange a catalogue, can store each Background to destination application in this catalogue
The image file of picture and corresponding description file carry out pack the background bag obtaining, so, in execution step 102, Ke Yi
Pass through in this catalogue to describe the corresponding image file of ff.
In some cases, may not comprise all of in the corresponding relation of the image prestoring and geographic area mark
Geographic area identifies.It is preferred, therefore, that, the process of step 102 can be as follows:If the image prestoring and geographic area mark
Comprise to have powerful connections in the corresponding relation known the geographic area mark carrying in idsplay order, then according to the image prestoring and ground
The corresponding relation of reason area identification, determining that the geographic area carrying in background idsplay order identifies corresponding image is Background
Picture;If not comprising to carry in described background idsplay order in the corresponding relation of the image prestoring and geographic area mark
Geographic area mark is it is determined that the image of the destination application acquiescence prestoring is background image.The image of this acquiescence can
To be default arbitrary image in destination application, such as simply monochromatic still image etc..
For example, in execution step 102, in image file and the phase of each background image of above-mentioned storage destination application
In the catalogue of description file answered, when searching the geographic area corresponding image file of mark carrying in background idsplay order, such as
Fruit does not find this geographic area mark, then can obtain the image of acquiescence in the respective directories of destination application.
In the embodiment of the present invention, it is state of weather application program for above-mentioned destination application, and the figure prestoring
The corresponding relation of picture and geographic area mark is the corresponding relation of the image, geographic area mark and Weather information that prestore
Situation, the process of step 102 can be as follows:
First, obtain the geographic area carrying in background idsplay order and identify corresponding current Weather information.
This Weather information can obtain from server, and that is, terminal can send to server and carry geographic area mark
Weather information obtains request, then the current Weather information of the corresponding geographic area of the reception server feedback.
Then, the corresponding relation according to the image prestoring, geographic area mark and Weather information, determines that background shows
The geographic area mark carrying in instruction and the corresponding image of Weather information obtaining are background image.
Preferably, the image prestoring can reflect the feature of corresponding weather conditions, and for example, Weather information is
Snow, corresponding image can be snowy landscape image.For same geographic area, the figure storing under multiple weather conditions can be corresponded to
Picture.
Step 103, background image is shown in the background display position of destination application.
In force, the above-mentioned background image determined is shown in the orlop at interface by terminal.Upper in background image
Layer can show various windows, character, picture, icon etc..
When destination application is for state of weather application program, weather can be shown on the upper strata of background image
Image, the weather image of such as fine day adds floating clouds for the sun, and weather image can be static weather image, can also be that it is pneumatic
Draw etc..
In the embodiment of the present invention, can to the processing mode that prestored of corresponding relation of image and geographic area mark
There to be many kinds, shown below is two kinds of preferred processing modes:
Mode one
User writes description file according to predetermined form, chooses image file, and by image file according to predetermined name
Rule is named, and then image file and description file is packaged into background bag and is stored in default catalogue(As above-mentioned hundred
Become the catalogue that framework is arranged into destination application).The naming rule of the form of description file and image file may be referred to
The content in face.
Mode two
Receive image setting request, the setting request of this image carries the first geographic area mark and the first image;Pre-
In the corresponding relation of the image first storing and geographic area mark, add this first image right with what this first geographic area identified
Should be related to.
In force, the background setting page can be set in destination application, can set in the background setting page
It is equipped with geographic area selection window, user can select geographic area in geographic area selection window, the page is set in background
In can include image and add option, click on after image adds option can by local choose or the mode such as shoot select to wait to add
Plus image, be also provided with confirm add button, for trigger image setting request, generate image setting request when,
The geographic area mark of the geographic area that user is selected(I.e. above-mentioned first geographic area mark)With the figure to be added selecting
Picture(I.e. above-mentioned first image)It is carried in image setting request.
In addition, image setting request can also be generated and sent to terminal by server.
In the embodiment of the present invention, receive the background idsplay order carrying geographic area mark of destination application, root
According to the corresponding relation of the image prestoring and geographic area mark, determine the geographic area carrying in described background idsplay order
Identifying corresponding image is background image, and is shown, so, in the application, can be according to different geographic areas
Show different background images, such that it is able to improve the display flexibility of application program background image.
Embodiment three
Based on identical technology design, the embodiment of the present invention additionally provides a kind of dress of display application program background image
Put, as shown in Fig. 2 described device includes:
Receiver module 210, for receiving the background idsplay order of destination application, carries in described background idsplay order
Geographic area is had to identify;
Determining module 220, for the corresponding relation according to the image prestoring and geographic area mark, determines the described back of the body
It is background image that the geographic area carrying in scape idsplay order identifies corresponding image;
Display module 230, the background for described background image is shown in described destination application shows position.
Preferably, described geographic area is designated urban sign.
Preferably, the geographic area carrying in described background idsplay order is designated according to the geographical position letter prestoring
Geographic area corresponding with the current geographical location information mark that breath is determined with the corresponding relation of geographic area mark.
Preferably, described determining module 220, is used for:
Refer to if including described background in the corresponding relation of the described image prestoring and geographic area mark and showing
The geographic area mark carrying in order, then the corresponding relation according to the image prestoring and geographic area mark, determine described
It is background image that the geographic area carrying in background idsplay order identifies corresponding image;
Refer to if not comprising described background in the corresponding relation of the described image prestoring and geographic area mark and showing
The geographic area mark carrying in order is it is determined that the image of the described destination application acquiescence prestoring is background image.
Preferably, described destination application is state of weather application program;
The corresponding relation of the described image prestoring and geographic area mark is image, the geographic area mark prestoring
Know the corresponding relation with Weather information;
Described determining module 220, is used for:
Obtain the geographic area carrying in described background idsplay order and identify corresponding current Weather information;
According to the corresponding relation of the image prestoring, geographic area mark and Weather information, determine that described background shows
The geographic area mark carrying in instruction and the corresponding image of Weather information obtaining are background image.
Preferably, described determining module 220, is additionally operable to:
Receive image setting request, described image setting request carries the first geographic area mark and the first image;
In the corresponding relation of the described image prestoring and geographic area mark, add described first image and described
The corresponding relation of the first geographic area mark.
In the embodiment of the present invention, receive the background idsplay order carrying geographic area mark of destination application, root
According to the corresponding relation of the image prestoring and geographic area mark, determine the geographic area carrying in described background idsplay order
Identifying corresponding image is background image, and is shown, so, in the application, can be according to different geographic areas
Show different background images, such that it is able to improve the display flexibility of application program background image.
It should be noted that:The device of the display application program background image that above-described embodiment provides is in display application program
During background image, only it is illustrated with the division of above-mentioned each functional module, in practical application, can as desired will be upper
State function distribution to be completed by different functional modules, the internal structure of device will be divided into different functional modules, to complete
All or part of function described above.In addition, above-described embodiment provide the device of display application program background image and
The embodiment of the method for display application program background image belongs to same design, and it implements process and refers to embodiment of the method, this
In repeat no more.
The embodiments of the present invention are for illustration only, do not represent the quality of embodiment.
One of ordinary skill in the art will appreciate that all or part of step realizing above-described embodiment can pass through hardware
To complete it is also possible to the hardware being instructed correlation by program is completed, described program can be stored in a kind of computer-readable
In storage medium, storage medium mentioned above can be read-only storage, disk or CD etc..
The foregoing is only presently preferred embodiments of the present invention, not in order to limit the present invention, all spirit in the present invention and
Within principle, any modification, equivalent substitution and improvement made etc., should be included within the scope of the present invention.