Specific embodiment
Currently in the application such as such as Alipay, QQ, wechat, application and development side, can be in order to promote the visual effect of user
User provides different background images to select for user, so that user selects corresponding background image to carry out decorative applications.
Existing is that the mode for selecting background image that user provides is: a selection background image can be generally provided for user
The setting page, and selected in the form of single choice for user, user needs to select corresponding background image in the setting page.And
Preview function can be also provided, user can be checked in advance by click preview button and be cut after selecting corresponding background image
The effect after background image is changed, if user is dissatisfied to effect achieved, then user is needed to go again in the setting page
Background image is selected, if user to good results achieved, then needs user to go to click confirming button, is clicked in user true
After determining button, the selected background image of user is just switched to by current background image, from the above, it is seen that for
It for family, selects the process CIMS of background image cumbersome, and the page is set and the staining effect page separately designs, user needs
The effect after switching background image can be just checked by preview function, user experience is poor.
For this purpose, user is by referring in view of the above-mentioned problems, this specification embodiment provides a kind of background image switching method
Determine the mode of region long-pressing, and the switching of background image can be completed after terminating long-pressing, in this way, for user and
Speech, simplifies the operating process of user, and user can promptly appreciate that staining effect at current display page interface, improve
User experience.
Specifically, the concrete scheme for the background image switching that this specification embodiment provides is as follows:
When monitoring that the operation triggering in region is specified in user's long-pressing, to be switched target background image is determined, according to setting
Fixed diffusion velocity controls the target background image with the diffusion velocity and spreads display in the display interface, when monitoring
When user stops the operation triggering in long-pressing specified region, judge whether current diffusion area meets preset requirement, if so, cutting
Shift to the target background image.
In order to make those skilled in the art more fully understand the technical solution in this specification embodiment, below in conjunction with this
Attached drawing in specification embodiment is described in detail the technical solution in this specification embodiment, it is clear that described
Embodiment is only a part of the embodiment of this specification, instead of all the embodiments.The embodiment of base in this manual,
Those of ordinary skill in the art's every other embodiment obtained, all should belong to the range of protection.
This specification embodiment, user can be completed by way of in specified region long-pressing, and after terminating long-pressing
The switching of background image, the technical solution that specific this specification embodiment provides are as follows:
As shown in Figure 1, the flow chart of the background image switching method provided for this specification embodiment, this method can wrap
Include following steps:
S101 determines to be switched target background image when monitoring that the operation triggering in region is specified in user's long-pressing;
For the application in terminal, in order to meet visual effect, user often selects the background image oneself liked
It is decorated, for this purpose, can be touched by way of the specified region in long-pressing terminal when user needs to switch background image
Background image switching is sent out, specifies region to can be the Home key in terminal here, as shown in Fig. 2, being also possible to terminal shows boundary
Any position on face.Here background image can be the background image of various colors, various patterns, it can be various colors,
The wallpaper of various patterns, various colors, background colour of various patterns etc..It is above-mentioned in addition to can be wherein for specifying region
Outside the position enumerated, the button of other positions in terminal can also be, this is no longer going to repeat them for this specification embodiment, specifically
It can be set according to the actual situation, this specification embodiment is not construed as limiting this.
When monitoring that the operation triggering in region is specified in user's long-pressing, to be switched target background image is determined, wherein to
The target background image of switching can be above-mentioned described any one, and determine the realization of to be switched target background image
There are many modes, determine the implementation of to be switched target background image can be it is following any one:
One of which determines being achieved in that for be switched target background image: determination does not make from background image set
Background image is to be switched target background image, includes two kinds of background images in the background image set.It is answered some
In, two kinds of background images can be generally provided and selected for user in the payment page especially for the application for payment, meaning
Taste current application provide background image set in include two kinds of background images, one of Background is being currently used
Picture determines that another not used background image is to be switched target background image.
As an example, such as Alipay, two kinds of background images is provided in the payment page and are selected for user, point
It is not black background image and blue background image, i.e., includes black and blue two kinds of Backgrounds in current background image set
Picture, the background image being being currently used are blue background image, then can determine that another not used background image is black
Background image determines that black background image is to be switched target background image.
Another kind determines being achieved in that for be switched target background image: sorting according to preset background image suitable
Sequence selects next background image from background image set, determines that next background image is that be switched target is carried on the back
Scape image.In some applications, numerous background themes can generally be provided to select for user, include a variety of backgrounds in background theme
Image, it is meant that include a variety of background images in the background image set that current application provides, and in advance to Background image set
These background images for including in conjunction are ranked up.When monitoring that the operation triggering in region is specified in user's long-pressing, according to preparatory
To the sequence that these background images for including in background image set are ranked up, these backgrounds for including from background image set
Next background image is selected in image, it is determined that next background image is to be switched target background image.
It as an example, include the background image of 7 kinds of colors, respectively red background figure in current background image set
Picture, orange background image, yellow background image, green background image, blue background image, indigo color background image, purple background
The background image of 7 kinds of colors such as image, is ranked up in advance for these background images, then after being ranked up, this 7 kinds of colors
The collating sequence of background image is as shown in figure 3, being being currently used is green background image, according to preset background image row
Sequence sequence can determine that next background image is blue background image from background image set, can determine blue background
Image is to be switched target background image.
In addition, another determine being achieved in that for be switched target background image: from the pre-set background of user
A background image is randomly choosed in image collection, determines that background image is to be switched target background image.Currently some
In, exploitation side can provide more background image for user and select for user, wherein it is full to can permit user's mark oneself
The background image of meaning, therefore user can mark from numerous background images that application and development side provides and oneself is satisfied with, by
The background image that user is marked forms a background image set.As an example, application and development side provides 100 kinds of back
Scape image, allow user's mark oneself be satisfied with background image, user is satisfied to wherein 5 kinds of background images, user to this 5
Kind background image is marked, then the pre-set background image set of a user can be made of this 5 kinds of background images, from
In the background image set, a background image is randomly choosed, determines that randomly selected background image is that be switched target is carried on the back
Scape image.
Before specifically randomly choosing background image in the pre-set background image set of user, determine currently
The background image used, from the pre-set background image set of user, random selection one and the back currently in use
The unduplicated background image of scape image, it is meant that the remaining background image for including from the pre-set background image set of user
One background image of middle random selection.As an example, user marks from numerous background images that application and development side provides
Wherein 5 kinds, this 5 kinds of background images are respectively red background image, orange background image, yellow background image, green background image
Picture, blue background image, form the pre-set background image set of a user by this 5 kinds of background images, pre- from user
Before randomly choosing a background image in the background image set being first arranged, determine that the background image being being currently used is red
Color background image, then from remaining 4 kinds of background image set randomly choose a background image, blue background image in this way,
To ensure that randomly selected background image is not repeated with the background image being being currently used.
S102 controls the target background image according to the diffusion velocity of setting with the diffusion velocity in display interface
Upper diffusion display;
After determining to be switched target background image, according to the diffusion velocity of setting, control target background image with
The diffusion velocity spreads display in terminal display interface, and the diffusion velocity set here can be at the uniform velocity.As an example,
The background image being being currently used is blue background image, and the to be switched target background image determined is black background figure
Picture then controls black background image at the uniform velocity diffusion display in terminal display interface, as shown in Figure 4.
In addition, the diffusion velocity of setting can also be adjusted according to user's long-pressing dynamics, i.e., according to user's long-pressing dynamics,
Determine the diffusion velocity of target background image, control target background image spreads aobvious in the display interface with the diffusion velocity
Show, it is meant that long-pressing dynamics of the user in specified region is bigger, then diffusion velocity is faster in the display interface, can be according to user
Long-pressing dynamics adjusts diffusion velocity.As an example, user's long-pressing dynamics can be divided into flicking, in by, again by three etc.
Grade, according to the current long-pressing dynamics of user, determines that the current long-pressing dynamics of user belongs to flicking, then controls target background image with flicking
Corresponding diffusion velocity spreads display in the display interface, and lower a moment user changes long-pressing dynamics, determines the current long-pressing power of user
Degree belongs to again by controlling target background image then to spread display in the display interface by corresponding diffusion velocity again, together with this
When user can be immediately seen in the display interface target background image diffusion display.
Wherein, it controls target background image and display is spread in the display interface with above-mentioned diffusion velocity, spread the reality of display
There are many kinds of existing modes, and two of them is illustrated in this specification embodiment, it is notable that this specification is implemented
Example is not to be defined to how spreading display.
The implementation of one of which diffusion display are as follows: to specify the position in region as initial position, expand to other positions
Dissipate display, as an example, terminal Home key as shown in Figure 4, using the position of terminal Home key as initial position, to end
The top position of display interface is held to spread display.It can certainly be using the position far from specified region as initial position, towards finger
Determine the direction diffusion display where region, as an example, terminal Home key as shown in Figure 4, with terminal display interface
Top position be initial position, towards where terminal Home key direction spread display.
The implementation of another diffusion are as follows: using the center of display interface as initial position, diffusion is aobvious around
Show, it is as an example, at the uniform velocity aobvious to the diffusion of the surrounding of display interface using the center of terminal display interface as initial position
Show.
S103 judges whether current diffusion area is full when monitoring that user stops the operation triggering in the specified region of long-pressing
The preset requirement of foot;
User can directly be seen that in the display interface target background image diffusion display, when monitor user stop long-pressing
When the operation triggering in specified region, target background image stops diffusion display in the display interface, judges that current diffusion area is
It is no to meet preset requirement, decide whether to switch to target background image with this.
Wherein judge whether current diffusion area meets preset requirement here, can be and whether judge current diffusion area
Meet preset threshold value, that is, judges whether current diffusion area is more than or equal to some preset value.
Certainly, judge whether current diffusion area meets preset requirement here, can also be and judge current diffusion area
Whether meet preset accounting in the accounting of display interface, that is, whether judges ratio of the current diffusion area shared by display interface
Accounting is preset more than or equal to some.As an example, display interface area can be calculated, in order to avoid user misoperation
And so on, preset area accounting is 50%, it is meant that current diffusion area is more than 50% in the accounting of display interface
If, then it may determine that and meet preset requirement, calculate the area currently spread, calculate current diffusion area in display interface institute
The ratio accounted for, ratio calculated are 60%, then can determine more than preset accounting, it can be determined that current diffusion area meets
Preset requirement.
S104, if so, switching to the target background image.
When monitoring that user stops the operation triggering in the specified region of long-pressing, it is default to judge whether current diffusion area meets
Requirement switch to target background image if meeting preset requirement, if being unsatisfactory for preset requirement, do not make to switch, protect
Stay the background image being being currently used.As an example, when the operation triggering for monitoring that region is specified in user's stopping long-pressing
When, calculating ratio of the current diffusion area shared by display interface is 70%, and preset accounting is 50%, current diffusion area
Meet preset requirement, black background image is switched to by the blue background image being being currently used.
By the description of the above-mentioned technical solution provided this specification embodiment, when monitoring user in specified region long-pressing
Operation triggering when, determine to be switched target background image, according to the diffusion velocity of setting, control the target background image
Display is spread in the display interface with the diffusion velocity, when monitoring that user stops the operation triggering in the specified region of long-pressing,
Judge whether current diffusion area meets preset requirement, if so, the target background image is switched to, for user
By way of long-pressing in the display interface, and the switching of background image can be completed after long-pressing terminates in speech.
Using the technical solution that this specification embodiment provides, the operating process of user is simplified, and user can be
Current display page interface promptly appreciates that staining effect, and the user experience is improved.
Corresponding to above method embodiment, this specification embodiment additionally provides a kind of background image switching device, referring to
Shown in Fig. 5, the apparatus may include: image determining module 510, control module 520, judgment module 530, image switching module
540。
Image determining module 510, for determining to be switched when monitoring that the operation triggering in region is specified in user's long-pressing
Target background image;
Control module 520 controls the target background image for the diffusion velocity according to setting with the diffusion velocity
Diffusion display in the display interface;
Judgment module 530, for judging current diffusion when monitoring that user stops the operation triggering in the specified region of long-pressing
Whether area meets preset requirement;
Image switching module 540, for if so, switching to the target background image.
According to a kind of specific embodiment that this specification provides, described image determining module 510 is used for:
Determine that not used background image is to be switched target background image, the Background from background image set
It includes two kinds of background images that image set, which closes,.
According to a kind of specific embodiment that this specification provides, described image determining module 510 is used for:
According to preset background image collating sequence, next background image is selected from background image set;
Determine that next background image is to be switched target background image.
According to a kind of specific embodiment that this specification provides, described image determining module 510, comprising: image selection
Submodule 511, image determine submodule 512;
Image selection submodule 511, for randomly choosing a background from the pre-set background image set of user
Image;
Image determines submodule 512, for determining that the background image is to be switched target background image.
According to a kind of specific embodiment that this specification provides, described image selection submodule 511 is specifically used for:
Determine the background image being being currently used;
From the pre-set background image set of user, random selection one and the background image currently in use are not
Duplicate background image.
According to a kind of specific embodiment that this specification provides, the control module 520 is specifically used for:
According to user's long-pressing dynamics, the diffusion velocity of the target background image is determined;
It controls the target background image and display is spread in the display interface with the diffusion velocity.
The function of modules and the realization process of effect are specifically detailed in the above method and correspond to step in above-mentioned apparatus
Realization process, details are not described herein.
By the description of the above-mentioned technical solution provided this specification embodiment, when monitoring user in specified region long-pressing
Operation triggering when, determine to be switched target background image, according to the diffusion velocity of setting, control the target background image
Display is spread in the display interface with the diffusion velocity, when monitoring that user stops the operation triggering in the specified region of long-pressing,
Judge whether current diffusion area meets preset requirement, if so, the target background image is switched to, for user
By way of long-pressing in the display interface, and the switching of background image can be completed after long-pressing terminates in speech.
Using the technical solution that this specification embodiment provides, the operating process of user is simplified, and user can be
Current display page interface promptly appreciates that staining effect, and the user experience is improved.
This specification embodiment also provides a kind of computer equipment, as shown in fig. 6, the equipment may include: processor
610, memory 620, input/output interface 630, communication interface 640 and bus 650.Wherein processor 610, memory 620,
Input/output interface 630 and communication interface 640 pass through the communication connection between the realization of bus 650 inside equipment.
Processor 610 can use general CPU (Central Processing Unit, central processing unit), micro process
Device, application specific integrated circuit (Application Specific Integrated Circuit, ASIC) or one or
The modes such as multiple integrated circuits are realized, for executing relative program, to realize technical solution provided by this specification embodiment.
Memory 620 can use ROM (Read Only Memory, read-only memory), RAM (Random Access
Memory, random access memory), static storage device, the forms such as dynamic memory realize.Memory 620 can store
Operating system and other applications are realizing technical solution provided by this specification embodiment by software or firmware
When, relevant program code is stored in memory 620, and execution is called by processor 610.
Input/output interface 630 is for connecting input/output module, to realize information input and output.Input and output/
Module can be used as component Configuration (not shown) in a device, can also be external in equipment to provide corresponding function.Wherein
Input equipment may include keyboard, mouse, touch screen, microphone, various kinds of sensors etc., output equipment may include display,
Loudspeaker, vibrator, indicator light etc..
Communication interface 640 is used for connection communication module (not shown), to realize the communication of this equipment and other equipment
Interaction.Wherein communication module can be realized by wired mode (such as USB, cable etc.) and be communicated, can also be wirelessly
(such as mobile network, WIFI, bluetooth etc.) realizes communication.
Bus 650 includes an access, in various components (such as the processor 610, memory 620, input/output of equipment
Interface 630 and communication interface 640) between transmit information.
It should be noted that although above equipment illustrates only processor 610, memory 620, input/output interface
630, communication interface 640 and bus 650, but in the specific implementation process, which can also include realizing to operate normally
Necessary other assemblies.In addition, it will be appreciated by those skilled in the art that, it can also be only comprising realizing in above equipment
Component necessary to this specification example scheme, without including all components shown in figure.
This specification embodiment also provides a kind of computer readable storage medium, is stored thereon with computer program, the journey
Background image switching method above-mentioned is realized when sequence is executed by processor.This method includes at least:
A kind of background image switching method, this method comprises:
When monitoring that the operation triggering in region is specified in user's long-pressing, to be switched target background image is determined;
According to the diffusion velocity of setting, controls the target background image and spread in the display interface with the diffusion velocity
Display;
When monitoring that user stops the operation triggering in the specified region of long-pressing, it is default to judge whether current diffusion area meets
Requirement;
If so, switching to the target background image.
Computer-readable medium includes permanent and non-permanent, removable and non-removable media can be by any method
Or technology come realize information store.Information can be computer readable instructions, data structure, the module of program or other data.
The example of the storage medium of computer includes, but are not limited to phase change memory (PRAM), static random access memory (SRAM), moves
State random access memory (DRAM), other kinds of random access memory (RAM), read-only memory (ROM), electric erasable
Programmable read only memory (EEPROM), flash memory or other memory techniques, read-only disc read only memory (CD-ROM) (CD-ROM),
Digital versatile disc (DVD) or other optical storage, magnetic cassettes, tape magnetic disk storage or other magnetic storage devices
Or any other non-transmission medium, can be used for storage can be accessed by a computing device information.As defined in this article, it calculates
Machine readable medium does not include temporary computer readable media (transitory media), such as the data-signal and carrier wave of modulation.
As seen through the above description of the embodiments, those skilled in the art can be understood that this specification
Embodiment can be realized by means of software and necessary general hardware platform.Based on this understanding, this specification is implemented
Substantially the part that contributes to existing technology can be embodied in the form of software products the technical solution of example in other words,
The computer software product can store in storage medium, such as ROM/RAM, magnetic disk, CD, including some instructions are to make
It is each to obtain computer equipment (can be personal computer, server or the network equipment etc.) execution this specification embodiment
Method described in certain parts of a embodiment or embodiment.
System, device, module or the unit that above-described embodiment illustrates can specifically realize by computer chip or entity,
Or it is realized by the product with certain function.A kind of typically to realize that equipment is computer, the concrete form of computer can
To be personal computer, laptop computer, cellular phone, camera phone, smart phone, personal digital assistant, media play
In device, navigation equipment, E-mail receiver/send equipment, game console, tablet computer, wearable device or these equipment
The combination of any several equipment.
All the embodiments in this specification are described in a progressive manner, same and similar portion between each embodiment
Dividing may refer to each other, and each embodiment focuses on the differences from other embodiments.Especially for device reality
For applying example, since it is substantially similar to the method embodiment, so describing fairly simple, related place is referring to embodiment of the method
Part explanation.The apparatus embodiments described above are merely exemplary, wherein described be used as separate part description
Module may or may not be physically separated, can be each module when implementing this specification example scheme
Function realize in the same or multiple software and or hardware.Can also select according to the actual needs part therein or
Person's whole module achieves the purpose of the solution of this embodiment.Those of ordinary skill in the art are not the case where making the creative labor
Under, it can it understands and implements.
The above is only the specific embodiment of this specification embodiment, it is noted that for the general of the art
For logical technical staff, under the premise of not departing from this specification embodiment principle, several improvements and modifications can also be made, this
A little improvements and modifications also should be regarded as the protection scope of this specification embodiment.