CN106445533A - Toast display method and device and electronic equipment - Google Patents
Toast display method and device and electronic equipment Download PDFInfo
- Publication number
- CN106445533A CN106445533A CN201610861379.4A CN201610861379A CN106445533A CN 106445533 A CN106445533 A CN 106445533A CN 201610861379 A CN201610861379 A CN 201610861379A CN 106445533 A CN106445533 A CN 106445533A
- Authority
- CN
- China
- Prior art keywords
- toast
- queue
- display
- function
- explicit function
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements 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/44—Arrangements for executing specific programs
- G06F9/451—Execution arrangements for user interfaces
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements 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/46—Multiprogramming arrangements
- G06F9/54—Interprogram communication
- G06F9/546—Message passing systems or structures, e.g. queues
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F2209/00—Indexing scheme relating to G06F9/00
- G06F2209/54—Indexing scheme relating to G06F9/54
- G06F2209/548—Queue
Landscapes
- Engineering & Computer Science (AREA)
- Software Systems (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Human Computer Interaction (AREA)
- User Interface Of Digital Computer (AREA)
Abstract
The embodiment of the invention discloses a Toast display method, a Toast display device and electronic equipment, and relates to the technical field of computers. The method comprises the following steps: calling a text creating function, and creating a Toast object according to the text creating function; creating a Toast queue; calling a display function, and adding the created Toast object into the created Toast queue according to the display function; calling a creating display function, and pre-displaying the Toast objects in the Toast queue according to the creating display function; and calling an increase display function, and displaying the Toast object according to the increase display function. The method and the device realize that the self-contained service queue of the android system is not used any more, and the display and the hiding of the Toast are maintained through the self-built Toast queue, so that a user can acquire the application program information running in the background in time.
Description
Technical field
The present invention relates to field of computer technology, more particularly, to a kind of Toast display packing, device and electronic equipment.
Background technology
Toast (Toast) is one of ARIXTRA (Android) system common message notification mechanism, applies to each in a large number
In class application program (Application).As shown in figure 1, its displaying principle is as follows:
Terminal passes through Toast class, calls text creation function (make Text ()) to create Toast object, and instantiation one
Individual TN class object.This TN class is used for the communication between subsequently each process.Terminal calls service to join the team function by Toast class
(service.enqueue Toast ()), the Toast object of establishment is added in service queue go etc. to be shown.This service
Queue carries queue for Android system bottom.
Terminal obtains the mark (Identification) creating Toast object process, according to identifier lookup Toast object
Whether in service queue.If it is present lookup result is returned to upper strata caller by terminal, and update this Toast object
The display time.Terminal calls holding process lock by notifying management service (Notification Manager Service) class
Fixed (keep Process Alive Locked (calling Pid)) function setup process corresponding with Toast object is foreground
Process is not so that this process is destroyed.Keep Process Alive Locked (calling Pid) function, by adjustable pipe
Reason service class (Activity Manager Service) class calls setting foreground process (set Process Foreground
()) this process is set to foreground process by function.
Terminal calls the next Toast of display to lock (Show by Notification Manager Service class
Next Toast Locked ()) function scheduling Toast object.If the queue index value of this Toast object is 0, terminal
Determine that this Toast object is located at the head of queue.Terminal calls display by Notification Manager Service class
(show ()) function pair Toast object carries out pre-display.
If the underlying programs in system have been provided with the display execution time of Toast object, terminal is passed through
Notification Manager Service class allocating time arrangement locks (schedule Time out Locked ()) letter
Number.It is controlled according to the display time of schedule Time out Locked () function pair Toast object.
Terminal calls process display (handle Show ()) function, handle Show () function pair Toast by TN class
The contents such as the position of object, alignment thereof are configured.Terminal calls increase by window management (Window Manager) class
View (add View ()) function pair Toast object is shown.
By said process, the Toast object of establishment can be shown to terminal interface.But, existing Toast shows
Process there is also following defect:In running background, some manufacturer terminals pass through modification to application program residing for when Toast object
The underlying programs of Android system, the Toast object in running background are set to forbid pop-up display state so that certain model
Terminal Toast object cannot be shown, and then lead to user obtain running background application messages exist delayed.
Content of the invention
In view of this, the embodiment of the present invention provides a kind of Toast display packing, device and electronic equipment, solves existing
During Toast shows, the Toast object of running background cannot pop-up display, and then lead to that user obtains running background should
With the delayed problem of program message.
In a first aspect, the embodiment of the present invention provides a kind of Toast to show, methods described includes:
Call text creation function, according to described text creation function, create Toast object;
Create Toast queue;
Call explicit function, according to described explicit function, the described Toast object creating is added described in creating
In Toast queue;
Call establishment explicit function, according to described establishment explicit function, to described Toast pair in described Toast queue
As carrying out pre-display;
Call increase explicit function, according to described increase explicit function, described Toast object is shown.
In conjunction with a first aspect, in the first embodiment of first aspect, described according to explicit function, the institute that will create
State Toast object to add in the described Toast queue creating, specifically include:
Call the subfunction of joining the team in explicit function;
According to described subfunction of joining the team, the described Toast object creating is added in the described Toast queue creating.
In conjunction with a first aspect, in the second embodiment of first aspect, described according to explicit function, the institute that will create
After stating in the described Toast queue that the addition of Toast object creates, methods described also includes:
Judge whether the described Toast object in described Toast queue can carry out team's process;
If the described Toast object in described Toast queue can carry out team processing it is determined that described Toast team
Described Toast object in row, according to the order of joining the team of described Toast object, obtains described Toast pair from described Toast queue
As.
In conjunction with the second embodiment of first aspect, in the third embodiment of first aspect, described determination institute
State the order of joining the team according to described Toast object for the described Toast object in Toast queue, obtain institute from described Toast queue
State Toast object to specifically include:
By processing routine, call establishment mission function;
By creating mission function, determine order of joining the team in described Toast queue for the described Toast object;
According to described order of joining the team, obtain described Toast object from described Toast queue successively.
In conjunction with a first aspect, in the 4th kind of embodiment of first aspect, described according to described establishment explicit function, right
Described Toast object in described Toast queue carries out pre-display, specifically includes:
According to described establishment explicit function, the display properties of each described Toast object is set;
According to described display properties, each described Toast object of pre-display.
In conjunction with the 4th kind of embodiment of first aspect, in the 5th kind of possible implementation of first aspect, described
According to described increase explicit function, described Toast object is carried out display and specifically includes:
In increasing explicit function, call described display properties, described Toast object is shown.
The 4th kind in conjunction with first aspect or the 5th kind of embodiment, in the 6th kind of possible implementation of first aspect
In, described display properties includes the display location of described Toast, display size, display time.
Second aspect, the embodiment of the present invention provides a kind of Toast display device, and described device includes:
First call unit, is used for calling text creation function, according to described text creation function, creates Toast object;
Creating unit, for creating Toast queue;
Second call unit, is used for calling explicit function, according to described explicit function, the described Toast object that will create
Add in the described Toast queue creating;
3rd call unit, is used for calling establishment explicit function, according to described establishment explicit function, to described Toast team
Described Toast object in row carries out pre-display;
4th call unit, is used for calling increase explicit function, according to described increase explicit function, by described Toast pair
As being shown.
In conjunction with second aspect, in the first embodiment of second aspect, described second call unit is specifically for adjusting
With the subfunction of joining the team in explicit function;
According to described subfunction of joining the team, the described Toast object creating is added in the described Toast queue creating.
In conjunction with second aspect, in the second embodiment of second aspect, described device also includes:
Judging unit, for judging whether the described Toast object in described Toast queue can carry out team's process;
Acquiring unit, if can carry out team's process for the described Toast object in described Toast queue, really
Order of joining the team in described Toast queue for the fixed described Toast object, and obtain described Toast pair from described Toast queue
As.
In conjunction with the second embodiment of second aspect, in the third embodiment of second aspect, described acquisition is single
Unit is specifically for calling establishment mission function;
By creating mission function, determine order of joining the team in described Toast queue for the described Toast object;
According to described order of joining the team, obtain described Toast object from described Toast queue successively.
In conjunction with second aspect, in the 4th kind of embodiment of second aspect, described 3rd call unit is specifically for root
According to described establishment explicit function, the display properties of each described Toast object is set;
According to described display properties, each described Toast object of pre-display.
In conjunction with the 4th kind of embodiment of second aspect, in the 5th kind of embodiment of second aspect, described 4th tune
With unit specifically for, in increasing explicit function, calling described display properties, described Toast object being shown.
The 4th kind in conjunction with second aspect or the 5th kind of embodiment, in the 6th kind of embodiment of second aspect, institute
The described display properties stating the 3rd call unit setting includes the display location of described Toast, display size, display time.
The third aspect, the embodiment of the present invention provides a kind of electronic equipment, and described electronic equipment includes:Housing, processor, deposit
Reservoir, circuit board and power circuit, wherein, circuit board is placed in the interior volume that housing surrounds, processor and memorizer setting
On circuit boards;Power circuit, for being each circuit of above-mentioned electronic equipment or device is powered;Memorizer is used for storing can be held
Line program code;Processor is run and executable program code pair by reading the executable program code of storage in memorizer
The program answered, for executing aforementioned arbitrary described method.
Fourth aspect, the embodiment of the present invention additionally provides a kind of storage medium, for storing application program, described application journey
Sequence is used for executing a kind of Toast display packing that the embodiment of the present invention is provided.
5th aspect, the embodiment of the present invention additionally provides a kind of application program, is provided for executing the embodiment of the present invention
A kind of Toast display packing.
A kind of Toast display packing provided in an embodiment of the present invention, device and electronic equipment, terminal will be to be shown
Toast object adds in the Toast queue creating, and calls establishment explicit function, the Toast object in Toast queue is carried out
Pre-display, calls increase explicit function, and Toast object is shown.Because, in the embodiment of the present invention, terminal practicality is voluntarily created
Toast object to be shown is placed in the Toast queue built, and then solves during solution existing Toast show, backstage fortune
The Toast object of row cannot pop-up display, and then lead to user can not obtain asking of the application messages of running background in time
Topic.Achieve and do not use the service queue that Android system carries, by the display of self-built Toast queue maintenance Toast and
Hide, allow user obtain the application messages of running background in time, also improve Consumer's Experience.
Brief description
In order to be illustrated more clearly that the embodiment of the present invention or technical scheme of the prior art, below will be to embodiment or existing
Have technology description in required use accompanying drawing be briefly described it should be apparent that, drawings in the following description be only this
Some embodiments of invention, for those of ordinary skill in the art, on the premise of not paying creative work, acceptable
Other accompanying drawings are obtained according to these accompanying drawings.
Fig. 1 is the sequential chart that in prior art, Toast object is shown;
Fig. 2 is a kind of flow chart of Toast display packing provided in an embodiment of the present invention;
Fig. 3 shows the sequential chart of process for the Toast that embodiments of the invention provide;
Fig. 4 is a kind of embodiments of the invention Toast display device structure schematic diagram;
Fig. 5 is a kind of Toast display device hardware architecture diagram provided in an embodiment of the present invention.
Specific embodiment
Below in conjunction with the accompanying drawings the embodiment of the present invention is described in detail.It will be appreciated that described embodiment is only
The a part of embodiment of the present invention, rather than whole embodiments.Based on the embodiment in the present invention, those of ordinary skill in the art
The all other embodiment being obtained under the premise of not making creative work, broadly falls into the scope of protection of the invention.
Below in conjunction with the accompanying drawings 2, describe scheme provided in an embodiment of the present invention in detail and illustrate, Fig. 2 is present invention enforcement
A kind of flow chart of Toast display packing that example provides, subject of implementation is terminal in embodiments of the present invention, and described terminal can be
There is the electronic equipments such as PC, the desktop computer of processing function.As shown in Fig. 2 the method for the present embodiment specifically include with
Lower step:
Step 210, call text creation function, according to described text creation function, create Toast object.
In the present embodiment, Toast is the simple message notifying frame of one of Android system, applies to types of applications journey in a large number
In sequence (App).Prompting frame is used for displaying to the user that information.When prompting frame is shown to user, it shows in the application
It is shown as quick condition.
Terminal is specially make Text in Android system Calling text creation function, described text creation function
() function.By at least one Toast object of make Text () function creation.
It is understood that terminal can be that application program creates one or more Toast according to specific application program
Object.
Step 220, establishment Toast queue.
In the present embodiment, terminal creates Toast queue, and this Toast queue is used for placing passes through make in step 210
The Toast object of Text () function creation.
Step 230, call explicit function, according to described explicit function, the described Toast object creating is added and creates
In described Toast queue.
In the present embodiment, after terminal creates Toast queue, call explicit function, described explicit function is specially show ().
By show () function, terminal adds the Toast object that step 210 creates in the Toast queue that step 220 creates.
Further, in the present embodiment, show () function includes multiple subfunctions.Terminal is called in show () function
Subfunction of joining the team, described join the team subfunction be specially enqueue Toast ().According to enqueue Toast () subfunction,
Terminal adds the Toast object that step 210 creates in the Toast queue that step 220 creates.
It is understood that the Toast queue creating in this step 220 is fifo queue.In the embodiment of the present invention,
Terminal voluntarily creates Toast queue, and the Toast object of establishment is placed in Toast queue, and does not use Android system certainly
The Toast object creating is placed in the service queue of band.
Step 240, call establishment explicit function, according to described establishment explicit function, described in described Toast queue
Toast object carries out pre-display.
In the present embodiment, after the Toast object of establishment is placed in Toast queue terminal, terminal calls establishment display
Function, described calling creates explicit function specially post (show).According to post (show) function, the queue of terminal-pair Toast
In Toast object carry out pre-display process.
Further, in the present embodiment, when Toast object is shown, terminal is it needs to be determined that Toast object is in terminal
The contents such as position during display, size, time.Therefore, according to post (show) function, each Toast object of terminal-pair aobvious
Show that attribute is configured, described display properties includes the display location of Toast, display size, display time, wherein, during display
Between generally 2s or 3.5s.According to the display properties after setting, each Toast object of terminal pre-display.
Further, terminal can carry out pre-display by the Toast object in ordered pair Toast queue.For example, terminal can root
Queue index according to Toast queue carries out pre-display to Toast object successively.
It is understood that in this step, terminal is after carrying out pre-display to Toast object, if Toast object is pre-
Display result does not meet expected display effect, and terminal also can be by being once again set up to the display properties of Toast object, directly
To meeting expected display effect.
Step 250, call increase explicit function, according to described increase explicit function, described Toast object is shown
Show.
In the present embodiment, after carrying out pre-display to Toast object, terminal calls increase explicit function, described increasing to terminal
Plus explicit function is specially add View ().According to add View () function, Toast object is shown by terminal.
Further, terminal, in increasing explicit function, calls the display of the Toast object arranging in step 240 to belong to
Property, so that Toast object is shown.
It is understood that in the present embodiment, add View () function is in Window Manager apoplexy due to endogenous wind.Described
Window Manager class is the class in Android system.Terminal is entered to add View () function by Window Manager class
Row calls.
The present embodiment, terminal adds Toast object to be shown in the Toast queue creating, and calls establishment display letter
Number, carries out pre-display to the Toast object in Toast queue, calls increase explicit function, Toast object is shown.By
In the embodiment of the present invention, Toast object to be shown is placed in the Toast queue that terminal practicality voluntarily creates, and then solves
Solve during existing Toast shows, the Toast object of running background cannot pop-up display, and then lead to user can not and
When obtain running background application messages problem.Achieve and do not use the service queue that Android system carries, pass through
The self-built display of Toast queue maintenance Toast and hide, allow user obtain the application messages of running background in time,
Improve Consumer's Experience.
Below in conjunction with the accompanying drawings 3, describe scheme provided in an embodiment of the present invention in detail and illustrate, Fig. 3 is present invention enforcement
The Toast that example provides shows the sequential chart of process, and subject of implementation is terminal in embodiments of the present invention, and described terminal can be for having
The electronic equipments such as the PC of processing function, desktop computer.As shown in figure 3, the method for the present embodiment specifically includes following step
Suddenly:
Step 310, call text creation function, according to described text creation function, create Toast object.
In the present embodiment, terminal calls text creation function, according to text creation function, creates the process of Toast object
Similar with the step 210 of said method embodiment, here is omitted.
Step 320, establishment Toast queue.
In the present embodiment, in the present embodiment, terminal creates the process of Toast object and the step of said method embodiment
220 are similar to, and here is omitted.
Step 330, call explicit function, according to described explicit function, the described Toast object creating is added and creates
In described Toast queue.
In the present embodiment, terminal calls explicit function, according to explicit function, the Toast object creating is added establishment
Process in Toast queue is similar with the step 230 of said method embodiment, and here is omitted.
Whether step 340, the described Toast object judging in described Toast queue can carry out team's process.
In the present embodiment, terminal can judge Toast pair by queuing time in Toast queue for the terminal Toast object
As if no can carry out team and process.
For example, if queuing time in Toast queue for the Toast object exceedes default time threshold, terminal is true
Determine Toast object can carry out team's process;Otherwise, Toast object cannot carry out team's process.
If the described Toast object in step 350 described Toast queue can carry out team processing it is determined that described
Order of joining the team in described Toast queue for the Toast object, and obtain described Toast object from described Toast queue.
In the present embodiment, if the terminal determine that the Toast object in Toast queue can carry out team's process, then terminal
Determine order of joining the team in Toast queue for the Toast object, terminal obtains Toast object from Toast queue.
Further, terminal calls establishment mission function, and described establishment mission function is specially post (runnable).Logical
Cross post (runnable) function, terminal determines order of joining the team in Toast queue for the Toast object;According to order of joining the team, whole
End obtains Toast object from Toast queue successively.
Terminal also can determine Toast object in Toast by obtaining index of joining the team in Toast queue for the Toast object
Order of joining the team in queue.
It is understood that in the present embodiment, post (runnable) function is in Handler apoplexy due to endogenous wind.Described
Handler class is the class in Android system.Terminal is called to post (runnable) function by Handler class.
Step 360, call establishment explicit function, according to described establishment explicit function, described in described Toast queue
Toast object carries out pre-display.
In the present embodiment, terminal calls establishment explicit function, according to creating explicit function, to the Toast in Toast queue
The process that object carries out pre-display is similar with the step 240 of said method embodiment, and here is omitted.
Step 370, call increase explicit function, according to described increase explicit function, described Toast object is shown
Show.
In the present embodiment, terminal calls increase explicit function, according to increasing explicit function, Toast object is shown
Process similar with the step 250 of said method embodiment, here is omitted.
By step 350 and step 360, terminal only can carry out pre-display process to the Toast object determining team, enter
And Toast object is shown;And other Toast objects in Toast queue are not processed, improve the process of terminal
Efficiency, also saves the process time of terminal.
In the present embodiment, terminal adds Toast object to be shown in the Toast queue creating, and calls establishment display
Function, carries out pre-display to the Toast object in Toast queue, calls increase explicit function, Toast object is shown.
Because, in the embodiment of the present invention, Toast object to be shown is placed in the Toast queue that terminal practicality voluntarily creates, and then solves
During solution existing Toast shows, the Toast object of running background cannot pop-up display, and then lead to the user can not
Obtain the problem of the application messages of running background in time.Achieve and do not use the service queue that Android system carries, lead to
Cross the self-built display of Toast queue maintenance Toast and hide, allow user obtain the application messages of running background in time,
Also improve Consumer's Experience.
Fig. 4 is a kind of Toast display device structure schematic diagram provided in an embodiment of the present invention, as shown in figure 4, the present embodiment
Toast display device can include:First call unit 410, creating unit 420, the second call unit the 430, the 3rd call
Unit 440 and the 4th call unit 450.
Wherein, the first call unit 410, is used for calling text creation function, according to described text creation function, creates
Toast object;
Creating unit 420, for creating Toast queue;
Second call unit 430, is used for calling explicit function, according to described explicit function, described Toast pair creating
As adding in the described Toast queue creating;
3rd call unit 440, is used for calling establishment explicit function, according to described establishment explicit function, to described Toast
Described Toast object in queue carries out pre-display;
4th call unit 450, is used for calling increase explicit function, according to described increase explicit function, by described Toast
Object is shown.
Further, described second call unit 430 is specifically for calling the subfunction of joining the team in explicit function;
According to described subfunction of joining the team, the described Toast object creating is added in the described Toast queue creating.
Further, described device also includes:Judging unit 460, described in judging in described Toast queue
Whether Toast object can carry out team's process;
Acquiring unit 470, if can carry out team's process for the described Toast object in described Toast queue,
Determine order of joining the team in described Toast queue for the described Toast object, and obtain described Toast pair from described Toast queue
As.
Further, described acquiring unit 470 is specifically for calling establishment mission function;
By creating mission function, determine order of joining the team in described Toast queue for the described Toast object;
According to described order of joining the team, obtain described Toast object from described Toast queue successively.
Further, described 3rd call unit 440 is specifically for according to described establishment explicit function, arranging each institute
State the display properties of Toast object;
According to described display properties, each described Toast object of pre-display.
Further, described 4th call unit 450 is specifically for, in increasing explicit function, calling described display to belong to
Property, described Toast object is shown.
Further, the described display properties of described 3rd call unit 440 setting includes the display position of described Toast
Put, display size, the display time.
The device of the present embodiment, can be used for executing the technical scheme of embodiment of the method shown in Fig. 2, Fig. 3, it realizes principle
Similar with technique effect, here is omitted.
Correspondingly, a kind of Toast display device provided in an embodiment of the present invention also can use another kind of structure to realize.Fig. 5 is
A kind of Toast display device hardware architecture diagram provided in an embodiment of the present invention, it is possible to achieve implement shown in Fig. 2-3 of the present invention
The flow process of example, as shown in figure 5, above-mentioned Toast display device can include:Housing 51, processor 52, memorizer 53, circuit board
54 and power circuit 55, wherein, circuit board 54 is placed in the interior volume that housing 51 surrounds, and processor 52 and memorizer 53 are arranged
On circuit board 54;Power circuit 55, for being each circuit of above-mentioned server or device is powered;Memorizer 53 is used for storing
Executable program code;Processor 52 is run and executable journey by reading the executable program code of storage in memorizer 53
The corresponding program of sequence code, for executing the method described in previous embodiment.
Processor 52 to the concrete implementation procedure of above-mentioned steps and processor 52 by run executable program code
The step executing further, may refer to the description of Fig. 2-3 illustrated embodiment of the present invention, will not be described here.
This terminal exists in a variety of forms, including but not limited to:
(1) super mobile personal computer equipment:This kind equipment belongs to the category of personal computer, has calculating and processes work(
Can, typically also possess mobile Internet access characteristic.This Terminal Type includes:PC, desktop computer, PDA, MID and UMPC equipment etc.,
Such as iPad.
(2) portable entertainment device:This kind equipment can show and play content of multimedia.This kind equipment includes:Audio frequency,
Video player (such as iPod), handheld device, e-book, and intelligent toy and portable car-mounted navigator.
(3) other have the electronic equipment of data interaction function.
The embodiment of the present invention additionally provides a kind of storage medium, and for storing application program, described application program is used for holding
A kind of Toast display packing that the row embodiment of the present invention is provided.
The embodiment of the present invention additionally provides a kind of application program, for executing one kind that the embodiment of the present invention is provided
Toast display packing.
It should be noted that herein, such as term " inclusion ", "comprising" or its any other variant are intended to
Comprising of nonexcludability, wants so that including a series of process of key elements, method, article or equipment and not only including those
Element, but also include other key elements being not expressly set out, or also include for this process, method, article or equipment
Intrinsic key element.In the absence of more restrictions, the key element that limited by sentence " include ... " it is not excluded that
Also there is other identical element in process, method, article or the equipment including described key element.
Each embodiment in this specification is all described by the way of related, identical similar portion between each embodiment
Divide mutually referring to what each embodiment stressed is the difference with other embodiment.
For device embodiment, because it is substantially similar to embodiment of the method, so the comparison of description is simple
Single, in place of correlation, the part referring to embodiment of the method illustrates.
Represent in flow charts or here logic described otherwise above and/or step, for example, it is possible to be considered as to use
In the order list of the executable instruction realizing logic function, may be embodied in any computer-readable medium, for
Instruction execution system, device or equipment (system as computer based system, including processor or other can hold from instruction
Row system, device or equipment instruction fetch the system of execute instruction) use, or with reference to these instruction execution systems, device or set
Standby and use.For the purpose of this specification, " computer-readable medium " can any can be comprised, store, communicate, propagate or pass
Defeated program is for instruction execution system, device or equipment or the dress using with reference to these instruction execution systems, device or equipment
Put.
The more specifically example (non-exhaustive list) of computer-readable medium includes following:There are one or more wirings
Electrical connection section (electronic installation), portable computer diskette box (magnetic device), random access memory (RAM), read only memory
(ROM), erasable edit read-only storage (EPROM or flash memory), fiber device, and portable optic disk is read-only deposits
Reservoir (CDROM).In addition, computer-readable medium can even is that the paper that can print described program thereon or other are suitable
Medium, because edlin, interpretation or if necessary with it can then be entered for example by carrying out optical scanning to paper or other media
His suitable method is processed to electronically obtain described program, is then stored in computer storage.
It should be appreciated that each several part of the present invention can be realized with hardware, software, firmware or combinations thereof.
In the above-described embodiment, multiple steps or method can be with storage in memory and by suitable instruction execution
The software of system execution or firmware are realizing.For example, if realized with hardware, and the same in another embodiment, can use
Any one of following technology well known in the art or their combination are realizing:Have for data signal is realized with logic work(
The discrete logic of the logic gates of energy, has the special IC of suitable combinational logic gate circuit, programmable gate
Array (PGA), field programmable gate array (FPGA) etc..
Those skilled in the art are appreciated that to realize all or part step that above-described embodiment method carries
Suddenly the program that can be by completes come the hardware to instruct correlation, and described program can be stored in a kind of computer-readable storage medium
In matter, this program upon execution, including one or a combination set of the step of embodiment of the method.
For convenience of description, description apparatus above is to be divided into various units/modules to be respectively described with function.Certainly, exist
Implement the function of each unit/module can be realized in same or multiple softwares and/or hardware during the present invention.
As seen through the above description of the embodiments, those skilled in the art can be understood that the present invention can
Mode by software plus necessary general hardware platform to be realized.Based on such understanding, technical scheme essence
On in other words prior art is contributed partly can be embodied in the form of software product, this computer software product
Can be stored in storage medium, such as ROM/RAM, magnetic disc, CD etc., include some instructions use so that a computer equipment
(can be personal computer, server, or network equipment etc.) executes some of each embodiment of the present invention or embodiment
Partly described method.
Claims (10)
1. a kind of Toast display packing is it is characterised in that methods described includes:
Call text creation function, according to described text creation function, create Toast object;
Create Toast queue;
Call explicit function, according to described explicit function, the described Toast object creating is added the described Toast team creating
In row;
Call establishment explicit function, according to described establishment explicit function, the described Toast object in described Toast queue is entered
Row pre-display;
Call increase explicit function, according to described increase explicit function, described Toast object is shown.
2. Toast display packing according to claim 1 is it is characterised in that the described institute that according to explicit function, will create
State Toast object to add in the described Toast queue creating, specifically include:
Call the subfunction of joining the team in explicit function;
According to described subfunction of joining the team, the described Toast object creating is added in the described Toast queue creating.
3. Toast display packing according to claim 1 is it is characterised in that the described institute that according to explicit function, will create
After stating in the described Toast queue that the addition of Toast object creates, methods described also includes:
Judge whether the described Toast object in described Toast queue can carry out team's process;
If the described Toast object in described Toast queue can carry out team's process it is determined that described Toast object exists
Order of joining the team in described Toast queue, and obtain described Toast object from described Toast queue.
4. Toast display packing according to claim 3 is it is characterised in that described determination described Toast object is described
Order of joining the team in Toast queue, and specifically include from the described Toast queue described Toast object of acquisition:
Call establishment mission function;
By creating mission function, determine order of joining the team in described Toast queue for the described Toast object;
According to described order of joining the team, obtain described Toast object from described Toast queue successively.
5. Toast display packing according to claim 1 it is characterised in that described according to described establishment explicit function, right
Described Toast object in described Toast queue carries out pre-display, specifically includes:
According to described establishment explicit function, the display properties of each described Toast object is set;
According to described display properties, each described Toast object of pre-display.
6. Toast display packing according to claim 5 it is characterised in that described according to described increase explicit function, will
Described Toast object carries out display and specifically includes:
In increasing explicit function, call described display properties, described Toast object is shown.
7. the Toast display packing according to claim 5 or 6 it is characterised in that described display properties include described
The display location of Toast, display size, display time.
8. a kind of Toast display device is it is characterised in that described device includes:
First call unit, is used for calling text creation function, according to described text creation function, creates Toast object;
Creating unit, for creating Toast queue;
Second call unit, is used for calling explicit function, according to described explicit function, the described Toast object creating is added
In the described Toast queue creating;
3rd call unit, is used for calling establishment explicit function, according to described establishment explicit function, in described Toast queue
Described Toast object carry out pre-display;
4th call unit, is used for calling increase explicit function, according to described increase explicit function, described Toast object is entered
Row display.
9. Toast display device according to claim 8 is it is characterised in that described second call unit is specifically for adjusting
With the subfunction of joining the team in explicit function;
According to described subfunction of joining the team, the described Toast object creating is added in the described Toast queue creating.
10. a kind of electronic equipment is it is characterised in that described electronic equipment includes:Housing, processor, memorizer, circuit board and electricity
Source circuit, wherein, circuit board is placed in the interior volume that housing surrounds, and processor and memorizer are arranged on circuit boards;Power supply
Circuit, for being each circuit of above-mentioned electronic equipment or device is powered;Memorizer is used for storing executable program code;Process
Device runs program corresponding with executable program code by reading the executable program code of storage in memorizer, is used for holding
Row following steps:
Call text creation function, according to described text creation function, create Toast object;
Create Toast queue;
Call explicit function, according to described explicit function, the described Toast object creating is added the described Toast team creating
In row;
Call establishment explicit function, according to described establishment explicit function, the described Toast object in described Toast queue is entered
Row pre-display;
Call increase explicit function, according to described increase explicit function, described Toast object is shown.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610861379.4A CN106445533A (en) | 2016-09-28 | 2016-09-28 | Toast display method and device and electronic equipment |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610861379.4A CN106445533A (en) | 2016-09-28 | 2016-09-28 | Toast display method and device and electronic equipment |
Publications (1)
Publication Number | Publication Date |
---|---|
CN106445533A true CN106445533A (en) | 2017-02-22 |
Family
ID=58171190
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201610861379.4A Pending CN106445533A (en) | 2016-09-28 | 2016-09-28 | Toast display method and device and electronic equipment |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN106445533A (en) |
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106941568A (en) * | 2017-03-30 | 2017-07-11 | 努比亚技术有限公司 | A kind of Toast pop-ups optimization display methods, device and Toast pop-ups dispatching method and device |
WO2020064000A1 (en) * | 2018-09-30 | 2020-04-02 | 中兴通讯股份有限公司 | Method and apparatus for displaying message box, terminal and storage medium |
CN112527443A (en) * | 2020-12-28 | 2021-03-19 | 平安普惠企业管理有限公司 | Prompt box display method and device, electronic equipment and computer readable storage medium |
CN116088714A (en) * | 2022-05-26 | 2023-05-09 | 荣耀终端有限公司 | Message prompt box processing method and related device |
Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104572110A (en) * | 2015-01-19 | 2015-04-29 | 山东大学 | Optimizing method of Toast activeX in android system |
CN105743774A (en) * | 2016-01-28 | 2016-07-06 | 广州市动景计算机科技有限公司 | Pushed information monitoring device, pushed information monitoring method and client side |
-
2016
- 2016-09-28 CN CN201610861379.4A patent/CN106445533A/en active Pending
Patent Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104572110A (en) * | 2015-01-19 | 2015-04-29 | 山东大学 | Optimizing method of Toast activeX in android system |
CN105743774A (en) * | 2016-01-28 | 2016-07-06 | 广州市动景计算机科技有限公司 | Pushed information monitoring device, pushed information monitoring method and client side |
Non-Patent Citations (2)
Title |
---|
ZHITAOCAI: "【Deprecated】兼容小米MIUI系统上,后台应用没法弹出Toast的问题", 《HTTPS://GITHUB.COM/ZHITAOCAI/TOASTCOMPAT_DEPRECATED/TREE/MASTER/TOASTCOMPAT/SRC/MAIN/JAVA/IO/GITHUB/ZHITAOCAI》 * |
张老虎: "Toast显示超详细过程", 《HTTP://WWW.JIANSHU.COM/P/8E08DB11F1C5》 * |
Cited By (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106941568A (en) * | 2017-03-30 | 2017-07-11 | 努比亚技术有限公司 | A kind of Toast pop-ups optimization display methods, device and Toast pop-ups dispatching method and device |
WO2020064000A1 (en) * | 2018-09-30 | 2020-04-02 | 中兴通讯股份有限公司 | Method and apparatus for displaying message box, terminal and storage medium |
CN112527443A (en) * | 2020-12-28 | 2021-03-19 | 平安普惠企业管理有限公司 | Prompt box display method and device, electronic equipment and computer readable storage medium |
CN116088714A (en) * | 2022-05-26 | 2023-05-09 | 荣耀终端有限公司 | Message prompt box processing method and related device |
CN116088714B (en) * | 2022-05-26 | 2024-05-28 | 荣耀终端有限公司 | Message prompt box processing method and related device |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN102404127B (en) | Method and device both for reminding of new message | |
CN104106054B (en) | Energy-saving application notifies system | |
CN106445533A (en) | Toast display method and device and electronic equipment | |
CN104317649B (en) | Processing method and device of terminal application program APP and terminal | |
CN106777184A (en) | A kind of page loading method, device and electronic equipment | |
CN109117260A (en) | A kind of method for scheduling task, device, equipment and medium | |
CN107908680A (en) | Management method, electronic device and the computer-readable recording medium of wechat public platform | |
US20120166534A1 (en) | System and method for grouping conference participants | |
CN107004182A (en) | The souvenir taken action from Real-Time Sharing | |
CN104050353A (en) | Effectuating Modifications Within An Instance Of Virtual Space Responsive To Detection Of A Token | |
CN106301885A (en) | The method and system of uniform traffic management | |
CN106411920A (en) | Data sharing method and device | |
CN109891828A (en) | Context painting canvas for collaboration workspace environment | |
CN107258071A (en) | The method and system and recording medium of the abundant menu of official's account are provided in instant Communications service | |
CN107729216A (en) | Application program management-control method, device, storage medium and electronic equipment | |
CN106599680A (en) | Application program permission setting method and apparatus, and electronic equipment | |
CN106096034A (en) | application log management method and device | |
CN109324847A (en) | Interface switching method and device | |
US20120166235A1 (en) | System and method for programmatically benchmarking performance of contact centers on social networks | |
CN103893970A (en) | Managing objectives associated with a virtual space based on characters made accessible responsive to corresponding tokens being detected | |
CN111464352A (en) | Call link data processing method and device | |
CN106156295A (en) | Notification bar display method and device and electronic equipment | |
CN108595481A (en) | A kind of notification message display methods and terminal device | |
CN107169134A (en) | Promotion information display method and device and electronic equipment | |
CN110262832A (en) | Application program permission judgment method and device and electronic equipment |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
RJ01 | Rejection of invention patent application after publication | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20170222 |