Movatterモバイル変換


[0]ホーム

URL:


CN106412237A - Control method and device for suspension button of intelligent terminal - Google Patents

Control method and device for suspension button of intelligent terminal
Download PDF

Info

Publication number
CN106412237A
CN106412237ACN201610782296.6ACN201610782296ACN106412237ACN 106412237 ACN106412237 ACN 106412237ACN 201610782296 ACN201610782296 ACN 201610782296ACN 106412237 ACN106412237 ACN 106412237A
Authority
CN
China
Prior art keywords
full frame
frame state
suspension button
user
display window
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.)
Granted
Application number
CN201610782296.6A
Other languages
Chinese (zh)
Other versions
CN106412237B (en
Inventor
肖剑锋
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
World (beijing) Network Technology Co Ltd
Original Assignee
World (beijing) Network Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by World (beijing) Network Technology Co LtdfiledCriticalWorld (beijing) Network Technology Co Ltd
Priority to CN201610782296.6ApriorityCriticalpatent/CN106412237B/en
Publication of CN106412237ApublicationCriticalpatent/CN106412237A/en
Application grantedgrantedCritical
Publication of CN106412237BpublicationCriticalpatent/CN106412237B/en
Activelegal-statusCriticalCurrent
Anticipated expirationlegal-statusCritical

Links

Classifications

Landscapes

Abstract

The invention discloses a control method and device for a suspension button of an intelligent terminal. The method comprises the steps of: monitoring a height of a display window on an intelligent terminal display screen; after monitoring a variation of the height of the display window, judging whether switching between a full-screen state and a non full-screen state occurs to the display window; after judging that switching between the full-screen state and the non full-screen state occurs to the display window, judging whether the display window is switched into the full-screen state from the non full-screen state or the display window is switched into the non full-screen state from the full-screen state; after judging that the display window is switched into the full-screen state from the non full-screen state, controlling the suspension button on the intelligent terminal display screen to be hidden; and after judging that the display window is switched into the non full-screen state from the full-screen state, controlling the suspension button on the intelligent terminal display screen to be displayed. According to the method, after a case that the display window is switched into the full screen state from the non full-screen state is monitored, the suspension button can be intelligently controlled to be hidden, so that full-screen use experience of a user is effectively promoted.

Description

A kind of control method of suspension button of intelligent terminal and device
Technical field
The present invention relates to intelligent terminal's technical field, the control method particularly to a kind of suspension button of intelligent terminal andDevice.
Background technology
The popularization using with intelligent terminal, in order to operate facility, increasing user can select to use at oneselfThe application such as some EasyTouch or virtual key great master is installed on intelligent terminal's especially smart mobile phone, these apply energyEnough provide the user convenient, reliable operation in a large number by way of suspension button and suspended window, for example:Provide a user with quickContact person interface, user pass through one hand just can recall frequent contact information;Conventional application can also be provided a user withList, makes user can quickly jump to the application of needs;May also provide a lot of system setting functions, such as pocket lamp, bluetoothSwitch, wifi, mobile network, regulation volume and regulation screen intensity etc., so that user is keen to using empty very muchIntend button, correspondingly reduce the use to system button for the user, and then extend the service life of system button or even mobile phone.
In actual use, suspension button, while bringing advantage to the user, also brings certain puzzlement to user.For example, user is in full frame browsing pictures, or in full frame viewing video, or play under the full frame states such as game full frame,Suspension button can be shown on screen always, thus having influence on the full frame experience of user.In order to reduce to full frame use bodyThe impact tested, user drags to inconspicuous place often through by suspension button, or by the transparency to suspension buttonIt is configured so that it is shown etc. with translucent, but these operations are required for user and intervene manually, intelligent journeyDegree is relatively low, and because suspension button is still shown on screen, does not tackle the problem at its root, and user experience is notPreferable.
In order to lift intelligence degree, additionally provide a kind of suspension button control method of terminal screen in prior art,Including:Judge whether terminal screen is in interaction mode;If terminal screen is in interaction mode, suspension button is placed in screenWithin indication range;Beyond otherwise suspension button being placed in screen display scope;Or, judge whether terminal screen is in interactionState;If terminal screen is in interaction mode, generate suspension button on a terminal screen;Otherwise delete outstanding on terminal screenFloating button.
By analysis, above technical scheme pass through judge whether screen is in " interaction mode ", to control suspend byThe display location of button, generation or deletion, wherein " interaction mode " are construed as current screen and obtain focus, and user can enterRow operation, and intelligent terminal when being in full frame state it is also assumed that being in " interaction mode ", then now can be by the button that suspends" within being placed in screen display scope ", still cannot solve the problems, such as to affect user experience.Additionally, by judging that screen isNo be in " interaction mode " come to generate suspension button or delete suspension button, relatively costly, need window manager(Windows Manager) constantly addView and removeView, frequently application and free system resources, overhead increases,Easily increase the risk of program error.
It is under full frame state for intelligent terminal in prior art, suspension button affects the problem of user experience,Do not find effective solution.
Content of the invention
The present invention provides a kind of control method of suspension button and the device of intelligent terminal, is listening to display window by non-After full frame state is switched to full frame state, suspension button can be intelligently controlled to be hidden, thus effectively lifting user'sFull frame experience.
On the one hand, the present invention provides a kind of control method of the suspension button of intelligent terminal, including:
Monitor the height of the display window on intelligent terminal's display screen;
After the height listening to described display window changes, judge whether described display window occurs full frame stateSwitching and non-full frame state between;
After judging that described display window occurs the switching between full frame state and non-full frame state, judge described display windowMouth is to be switched to full frame state by non-full frame state, or is switched to non-full frame state by full frame state;
After judging that described display window is switched to full frame state by non-full frame state, control described intelligent terminal's display screenOn suspension button be hidden;After judging that described display window is switched to non-full frame state by full frame state, control describedSuspension button on intelligent terminal's display screen is shown.
Preferably, after judging that described display window is switched to full frame state by non-full frame state, methods described also includes:
Judge whether described display window is the switching by non-full frame state to full frame state first;
Judge described display window be first by non-full frame state to the switching of full frame state after, to user eject dialogueFrame, with the selection to option in described dialog box according to described user, it is determined whether to outstanding on described intelligent terminal's display screenFloating button is hidden;
Judge described display window be non-first by non-full frame state to the switching of full frame state after, according to last time occurNon- full frame state to full frame state switch when, user to eject dialog box in option selection record, it is determined whether to describedSuspension button on intelligent terminal's display screen is hidden, or again to user's pop-up dialogue box, so that described user is againSelected.
Preferably, described dialog box includes following multinomial content:Determine and hide suspension button prompts, hide suspension buttonChange position indicating, allow option, cancel option and no longer reminder option next time;
Described determine whether the suspension button on described intelligent terminal's display screen is hidden, including:
Judge whether described user hides priority level highest permission suspension button in intelligent terminal system settingOption is closed;Judge described user by described permission suspension button hide Options closing after, then no matter how user is to describedOption in dialog box is operated, and remains that described suspension button shows, not to outstanding on described intelligent terminal's display screenFloating button is hidden;
Judge described user by described permission suspension button do not hide Options closing after, then:
After receiving described user's selection cancellation option, continue to keep described suspension button to show, not to described intelligenceSuspension button on terminal display screen is hidden;After receiving described user's selection permission option, to described suspension buttonIt is hidden;
After receiving described user's selection cancellation option or allowing option, judge whether described user selects next time no longerReminder option;After judging that described user selects no longer reminder option next time, then the cancellation option that execution is selected with described userOr allow the corresponding display of option or hide operation continuous and effective, and display window is occurred to be arrived entirely by non-full frame state follow-upDuring the switching of screen state, no longer reselect to user's pop-up dialogue box for user;Judging described user non-selected next time notAgain after reminder option, then execution display corresponding with the cancellation option that described user selects or permission option or hiding operation are rightThis operation is effective, and when follow-up generation display window is by the switching of non-full frame state to full frame state, again to user's bulletGo out dialog box to reselect for user.
Preferably, before the height of the display window on monitoring intelligent terminal's display screen, methods described also includes:
Start service processes, the control that described service processes embed creates suspension button;
Create display window audiomonitor, and the height of described display window audiomonitor is equal to described intelligent terminalThe height of display screen, width be set to 0, the form of described display window audiomonitor is set to transparent, by window managementDescribed window audiomonitor is added in the display window of described intelligent terminal's display screen the view functions that add of device.
Preferably, methods described also includes:After described suspension button is hidden, creates in information informing and carryDescribed suspension button of waking up is hidden and is clicked on the prompting message recovering, so that described user is after clicking on described prompting message,The display of described suspension button is recovered on the display screen of described intelligent terminal.
On the other hand, the present invention provides a kind of control device of the suspension button of intelligent terminal, including:
Monitor module, for monitoring the height of the display window on intelligent terminal's display screen;
First judge module, for, after the height that described monitoring module listens to described display window changes, sentencingWhether the described display window that breaks there is the switching between full frame state and non-full frame state;
In described first judge module, second judge module, for judging that described display window occurs full frame state complete with non-After switching between screen state, judge that described display window is to be switched to full frame state by non-full frame state, or by full frame shapeState is switched to non-full frame state;
Control module, full frame for judging that described display window is switched to by non-full frame state in described second judge moduleAfter state, control the suspension button on described intelligent terminal's display screen to be hidden, be additionally operable to sentence in described second judge moduleThe described display window that breaks is switched to after non-full frame state by full frame state, controls the suspension button on described intelligent terminal's display screenShown.
Preferably, described device also includes:
In described second judge module, 3rd judge module, for judging that described display window is switched to by non-full frame stateAfter full frame state, judge whether described display window is the switching by non-full frame state to full frame state first;
Play frame module, for the 3rd judge module judge described display window for first by non-full frame state to full frame shapeDuring the switching of state, to user's pop-up dialogue box;
First determining module, for the selection to option in described dialog box according to described user, it is determined whether to describedSuspension button on intelligent terminal's display screen is hidden;
Second determining module, for when described 3rd judge module judge described display window for non-first by non-full frame shapeState to full frame state switching when, according to last time occur non-full frame state arrive full frame state switch when, user to ejection dialogueThe selection record of option in frame, it is determined whether the suspension button on described intelligent terminal's display screen is hidden, or againTo user's pop-up dialogue box, so that described user re-starts selection.
Preferably, described dialog box includes following multinomial content:Determine and hide suspension button prompts, hide suspension buttonChange position indicating, allow option, cancel option and no longer reminder option next time;
Described first determining module, including:
First judging unit, for judge described user whether in intelligent terminal system setting by priority level highestSuspension button is allowed to hide Options closing;
In described judging unit, first display and hidden unit, for judging that described user will be hidden for described permission suspension buttonAfter hiding option closing, no matter how user operates to the option in described dialog box, remains that described suspension button showsShow, the suspension button on described intelligent terminal's display screen is not hidden;
Second display and hidden unit, for judging that described user do not allow suspension button to hide Options closing by describedAfterwards, and after receiving described user's selection cancellation option, continue to keep described suspension button to show, not to described intelligent terminalSuspension button on display screen is hidden;It is additionally operable to judging that described permission suspension button do not hide Options pass by described userAfter closing, and after receiving described user's selection permission option, described suspension button is hidden;
Second judging unit, for, after receiving described user's selection cancellation option or allowing option, judging described useWhether family selects no longer reminder option next time;
Performance element, for, after described second judging unit judges that described user selects no longer reminder option next time, holdingRow display corresponding with the cancellation option that described user selects or permission option or hiding operation continuous and effective, and in rear superventionRaw display window by non-full frame state to full frame state switching when, no longer reselect to user's pop-up dialogue box for user;It is additionally operable to after described second judging unit judges no longer reminder option described user non-selected next time, execution and described user's choosingThe cancellation option selected or allow the corresponding display of option or hide operation to this operation effectively, and there is display window follow-upMouthful by non-full frame state to full frame state switching when, again reselect to user's pop-up dialogue box for user.
Preferably, described device also includes:
First creation module, for, before the height of the display window monitored on intelligent terminal's display screen, starting serviceProcess, and create suspension button in the control that described service processes embed;
Second creation module, for creating display window audiomonitor, and the height setting by described display window audiomonitorIt is that the height of display screen equal to described intelligent terminal, width are set to 0, the form of described display window audiomonitor is set toTransparent, by the view functions that add of window manager, described window audiomonitor is added to the aobvious of described intelligent terminal's display screenShow in window.
Preferably, described device also includes:
3rd creation module, for, after being hidden described suspension button, creating and reminding institute in information informingState suspension button to hide and click on the prompting message recovering, so that described user is after clicking on described prompting message, describedThe display of described suspension button is recovered on the display screen of intelligent terminal.
Other features and advantages of the present invention will illustrate in the following description, and, partly become from descriptionObtain it is clear that or being understood by implementing the present invention.The purpose of the present invention and other advantages can be by the explanations writeIn book, claims and accompanying drawing, specifically noted structure is realizing and to obtain.
Below by drawings and Examples, technical scheme is described in further detail.
Brief description
Accompanying drawing is used for providing a further understanding of the present invention, and constitutes a part for description, the reality with the present inventionApply example and be used for explaining the present invention together, be not construed as limiting the invention.In the accompanying drawings:
Fig. 1 is a kind of flow chart of the control method of suspension button of intelligent terminal provided in an embodiment of the present invention;
Fig. 2 is a kind of block diagram of the control device of suspension button of intelligent terminal provided in an embodiment of the present invention;
Fig. 3 is a kind of schematic diagram of suspension button provided in an embodiment of the present invention;
Fig. 4 is a kind of schematic diagram of dialog box provided in an embodiment of the present invention;
Fig. 5 is a kind of schematic diagram clicking on recovery prompting message provided in an embodiment of the present invention.
Specific embodiment
Below in conjunction with accompanying drawing, the preferred embodiments of the present invention are illustrated it will be appreciated that preferred reality described hereinApply example to be merely to illustrate and explain the present invention, be not intended to limit the present invention.
Hereinafter noun used in present patent application or term are explained as follows:
Suspension button:After switching, a circle or the void of other graphic form in mobile device in the middle of screenIntend button, it can arbitrarily drag to the optional position on screen, and can be suspended on most application interface.
Android:Chinese is ARIXTRA, is a kind of freedom based on Linux and the operating system of open source code, mainMobile device to be used for, such as smart mobile phone and panel computer, by Google company and open mobile phone alliance leader and exploitation.
A kind of control method of the suspension button of intelligent terminal provided in an embodiment of the present invention, comprises the following steps S101-S104:
Step S101:Monitor the height of the display window on intelligent terminal's display screen;
Step S102:After the height listening to described display window changes, judge whether display window occurs entirelySwitching between screen state and non-full frame state;
Step S103:After judging that display window occurs the switching between full frame state and non-full frame state, judge displayWindow is to be switched to full frame state by non-full frame state, or is switched to non-full frame state by full frame state;
Step S104:After judging that display window is switched to full frame state by non-full frame state, intelligent terminal is controlled to showSuspension button on screen is hidden;After judging that display window is switched to non-full frame state by full frame state, control intelligence eventuallySuspension button on the display screen of end is shown.
In another embodiment, as shown in figure 4, judging that display window is switched to full frame state by non-full frame stateAfterwards, the control method of the suspension button of above-mentioned intelligent terminal, also includes:
Step S1:Judge whether display window is the switching by non-full frame state to full frame state first;
Step S2:Judge display window be first by non-full frame state to the switching of full frame state after, to user ejectDialog box, with the selection to option in dialog box according to user, it is determined whether the suspension button on intelligent terminal's display screen is enteredRow is hidden;
Step S3:Judge display window be non-first by non-full frame state to the switching of full frame state after, according to last timeOccur non-full frame state to full frame state switch when, user to eject dialog box in option selection record, it is determined whether rightSuspension button on intelligent terminal's display screen is hidden, or again to user's pop-up dialogue box, so that user re-startsSelect.
In one embodiment, following multinomial content can be included in above-mentioned dialog box:The hiding suspension button prompts of determination,The change position indicating of hiding suspension button, permission option, cancellation option and no longer reminder option next time;Wherein, above-mentioned trueDetermine whether the suspension button on described intelligent terminal's display screen to be hidden, including:
Step S11:Judge whether user allows suspension button by priority level highest in intelligent terminal system settingHide Options closing;Judge user by allow suspension button hide Options closing after, then no matter how user is to described dialogueOption in frame is operated, and remains that suspension button shows, the suspension button on intelligent terminal's display screen is not carried out hiddenHide;
Step S12:Judge user by allow suspension button do not hide Options closing after, then:
Step S13:After receiving user's selection cancellation option, continue to keep suspension button to show, not to intelligent terminalSuspension button on display screen is hidden;After receiving user's selection permission option, suspension button is hidden;
Step S14:After receiving user's selection cancellation option or allowing option, judge whether user selects next time no longerReminder option;After judging that user selects no longer reminder option next time, then execution is selected with user cancellation option or permission choosingCorresponding display or hide operation continuous and effective, and occur display window by non-full frame state to full frame state follow-upDuring switching, no longer reselect to user's pop-up dialogue box for user;After judging no longer reminder option user non-selected next time,Then execution display corresponding with the cancellation option that user selects or permission option or hiding operation are effective to this operation, andFollow-up occur display window by non-full frame state to full frame state switching when, again to user's pop-up dialogue box for user againSelect.
In another embodiment, before the height of the display window on monitoring intelligent terminal's display screen, above-mentioned intelligenceThe control method of the suspension button of energy terminal also includes:
Step S22:Start service processes, the control that service processes embed creates suspension button;
Step S23:Create display window audiomonitor, and the height of display window audiomonitor is equal to intelligent terminalThe height of display screen, width be set to 0, the form of display window audiomonitor is set to transparent, by window managerAdd view functions window audiomonitor is added in the display window of intelligent terminal's display screen.
In one embodiment, as shown in figure 5, the control method of the suspension button of above-mentioned intelligent terminal, can also include:After suspension button is hidden, creates in information informing and remind suspension button to hide and click on the prompting letter recoveringBreath, so that user is after clicking on described prompting message, recovers the display of suspension button on the display screen of intelligent terminal.
Hereinafter the process of realizing of the control method of the suspension button to intelligent terminal provided in an embodiment of the present invention is carried outDescribe in detail as follows:
The service processes (Service process) being located by suspension button create a window audiomonitor, can be to windowHeight monitored, once change to respond.The parent of this audiomonitor is a View in fact, is created at itAfter building, can be added in window manager, make this View height be equal to screen height, width is equal to 0, and so it is notCan be seen by user, but it can listen to the change of window height.
When this audiomonitor receives window change, its onSizeChanged method can be triggered, inside its method, sentenceWhether the height of current view of breaking is equal to screen height screenHeight, if equal, illustrate by non-full frame state change toFull frame state;If triggering onSizeChanged method when, present level is simultaneously not equal to screen height, then judge whenWhen whether carried out horizontal/vertical screen switching, that is, onConfigurationChanged method is either with or without triggering, if it did not, and protectingThe old view height deposited is equal to screen height, and explanation is to be switched to normal condition by full frame state, i.e. non-full frame state;
If it is determined that full frame and non-full frame state there occurs switching in the audiomonitor of view, will be given by HandlerService process sends message, carries out Message Processing by Service process.
Here several situations will be divided to be processed:
1 if first time operation program, it will create a dialog box first and user interacts, and whether promptingSuspension button being hidden, if not choosing " next time does not reresent ", have selected " cancellation ", suspension button will continue display,Will not hide;If selected for " permission ", this is by hiding suspension button.If having chosen " next time does not reresent ", at this moment selectSelect " cancellation ", forever no longer will hide suspension button later, and also no longer reminded user;As have selected " permission ", afterWhen every time full frame situation occurring, all will hide suspension button immediately, and also no longer remind user.
2nd, if not first time operation program, ejected the such prompting frame of Fig. 4 before, and do not chose " underSecondary do not reresent ", specifically continue to eject this prompting frame.
If 3 operations before have been chosen " next time does not reresent ", and click " permission ", will directly hide suspension and pressButton;
If 4 operations before have been chosen " next time does not reresent ", and click " cancellation ", press continuing display suspensionButton, full frame switching does not affect on button;
If " full frame automatic hidden " is switched closing by 5, in client process, no matter how screen switches, orHow to operate, all will continue display suspension button.
In the present embodiment, if suspension button is hidden, one can be sent and notify informing, in informingThere is such a notice, as shown in figure 5, " xxx here, click on and return screen ", if now clicking on this notice, can be bySuspension button shows.
If current suspension button has been hidden, and it is switched to non-full frame by full frame, now suspension button will be by notifyingAutomatically it is shown on screen in hurdle, and the notice creating before can be canceled.By above-mentioned steps, it is achieved that in screenWhen switching is full frame and non-full frame, the hiding and display function of suspension button.
For achieving the above object, the invention provides the full frame and non-full frame change of detailed utilization screen, control and suspendButton automatic hidden and the method for display, implementation step is as follows:
Program starts:The application that suspension button is located needs to start and could run after mounting.
Start a Service process:We using an Android Service, suspension button is managed andLogic control, and put it in a single process, this is because Service can remain operation on backstage, toolHave the advantages that to be not easy to be killed it is not necessary to visualization interface is supported, and after cell phone system is restarted, can also be by localThe system broadcast message of registration, for example, the broadcast of handset starting, the broadcast of network state change, bluetooth state changes, WiFi shapeState change etc., the broadcast of general system class can be started up, and vitality is very strong, so selectingService is as the carrier realizing suspension button.
Create suspension button, button enters holding state, monitor click event:Suspension button is deposited with oneWithin RelativeLayout control, its own is to be realized by an ImageView control, using systemThe addView method of WindowManager (window manager) is added in manager.By arranging its LayoutParams'sThe attribute of type is WindowManager.LayoutParams.TYPE_SYSTEM_ALERT, to realize being suspended in most of answeringOn window.Because TYPE_SYSTEM_ALERT represents a very high priority, this value is set so that it may so thatThe priority of suspension button is more than other most of windows, in display, naturally would be on other windows.Give outstanding simultaneouslyFloating button setting is clicked, and grows and presses, double-clicks, the monitoring event of movement etc., and suspension button, after receiving different events, can be carried out notSame process.As clicked suspension button, suspended window can be opened, carry out the use of virtual key function, hide suspension button simultaneously.
Create a screen audiomonitor FloatMonitor:A screen audiomonitor is created in Service processThe parent of FloatMonitor, FloatMonitor is a View, and its height height is set to by we when it createsThe height of screen, width width is set to 0, and format is set to PixelFormat.TRANSPARENT simultaneously, that is, transparent,So it is sightless for a user, but it but can monitor the change of height, then passes through WindowManagerAddView function be added in current active window region.
FloatMonitor enters holding state, monitors screen change:Creating screen window audiomonitorAfter FloatMonitor, need to rewrite its onSizeChanged method, when window height changes, the method can be adjusted backIn, so in its onSizeChanged method just can according to before preserve window value and present window height value makeCompare, to judge how window is changed.For the switching of distinguishing terminal transverse screen and portrait layout, simultaneously need to rewriteeing itOnConfigurationChanged method, this method can be adjusted back in the method when screen carries out horizontal/vertical screen switching.?In the method it can be determined that and record be currently that portrait layout is changed into by transverse screen, or portrait layout changes into transverse screen, so for judging screenAssosting effect is played in full frame and non-full frame conversion.
Screen state changes, and judges whether screen is switched to full frame state by non-full frame state:Screen state occursChange, can adjust back in onSizeChanged method, by the h value in the method parameter and screen height screenHeightMake comparisons, if equal, illustrate currently to have changed to full frame state;If this two values unequal then it is assumed that being from full frame shapeState has been withdrawn into non-full frame state.
State does not change, and continues standby monitoring;In the event of the change of other situations, then carry out other functions logicProcess:Here in two kinds of situation, one kind is that screen state does not change, and will continue to keep the monitoring shape of FloatMonitorState;In the event of change, but be not from non-full frame enter into full frame, e.g., the change of two kinds of non-full frame states.Exemplary is such asOpen during input method and when closing input method, both states also can cause the execution of callback method onSizeChanged.NowWe can carry out the logical process of other side, is then re-introduced into screen listening state.
FloatMonitor sends messages to Service process by Handler:When receiving window change, do not existProcess message in FloatMonitor, but put it in UI main thread and processed, we can pass throughHandler in FloatMonitor sends self-defined message MSG_FULL_SCREEN_CHANGE to Service process.Because being related to UI operation, it is put into the safety execution that can guarantee that flow process in main thread.And if UI operation is put into fortune in sub-line journeyIt is about to lead to program crashing.
Service receives message, is processed in UI main thread:Service is receiving MSG_FULL_SCREEN_After CHANGE message, distinct program branch can be selected to be executed according to the parameter of message band.
Judge whether full frame hiding switch is open mode:Before perform function, first byIsFullScreenHideEnable method judges whether full frame hiding switch opens because this function by one switch intoRow controls, and user can be configured in the application, if switch cuts out illustrates that this application is inoperative, now can be rightHide and not respond;If switching as opening, downward configuration processor can be continued.
Full frame hidden function is closed, and proceeds to monitor:Full frame hidden function switch is if turned off illustrating that user is not intended toHide suspension button when full frame, therefore now will be returned directly to FloatMonitor and continue to monitor screen state, because afterThis switch may be reopened by continuous user.Suspension button keeps dispaly state.
Judge whether " next time does not reresent " value of statistical indicant is true:Full frame hidden function switchs as opening, then need to judgeWhether " next time does not reresent " value of statistical indicant no_hint_forever is true, starts for the first time in program, and default conditions areFalse's, that is, when ejecting prompting frame, acquiescence is not choose " next time does not reresent ", needs user oneself to enter as neededRow selects.
Illustrate it is not to operate first, select to hide suspension button:" next time does not reresent " value of statistical indicant no_hint_foreverFor true, after ejecting prompting frame before explanation, user has chosen " next time does not reresent " check box, it will directly hides suspension and pressesButton.
Create and eject selection prompting frame:" next time does not reresent " value of statistical indicant no_hint_forever is false, explanationLast time does not choose " next time does not reresent " check box, or operation program first, at this moment needs to create and eject prompting frame.
Prompting frame content includes a check box " next time does not reresent ", two buttons, " cancellation " and " permission ":Prompting moneyIt is a common Android prompting frame, as shown in figure 3, there being title, description, and the check box of " next time does not reresent ",And two buttons, " cancellation " and " permission ".
If selecting check box " next time does not reresent ", its mark is set to true, otherwise for false:Select check box,Mark no_hint_forever can be set to true by program, represent and subsequently must not eject this frame again;Remove selection or do not selectSelect check box, then mark no_hint_forever can be set to false, represent and subsequently go back after the message receiving full frame changeTo eject this frame again.
Judge prompting frame click is " cancellation ", or " permission ":User needs to click on and cancels, or allows to closeThis prompting frame, selects " cancellation " to represent not and hides suspension button;Select " permission " to represent and hide suspension button.
Suspension button is not hidden, and FloatMonitor proceeds to monitor:Click on after cancelling, suspension button will not be hidden,Program enters and continues listening state, and suspension button continues display, waits the process of key-press event.
Click on and allow, select to hide suspension button:Click on and allow, illustrate that user wishes to hide suspension button, will go intoHiding flow process.
Create and send notice Notification, hide suspension button immediately:In hiding suspension button flow process, firstA notification message Notification can be created, and send it to informing.After notifying establishment to finish, then useSuspension button is hidden by setVisibility (View.GONE) method;
Suspension button is hidden, and provides, in informing, the information clicking on reduction simultaneously:Now suspension button enters and hidesState, launches informing and can be appreciated that a notice, display suspension button has been hidden, and clicking on this notice can be reduced.But Service process is not turned off, may proceed to be run, while listening for the audiomonitor FloatMonitor of screen changeMay proceed to work, such as monitor screen whether from full frame and changed to non-full frame etc..
Be more than by non-full frame state change to full frame state when, the hiding handling process of suspension button, say belowBy full frame state change to non-full frame state, the display processing flow process of suspension button, detailed step is as follows:
Suspension button is hidden:Suspension button is in hidden state.
FloatMonitor is in holding state, monitors screen change:Monitor screen change:In its readjustmentThe message of screen change is processed in onSizeChanged method.Once there being screen to change, readjustment is arrivedIn onSizeChanged method.
Screen state changes, and judges whether screen is switched to non-full frame state by full frame state:Screen state occursChange, can adjust back in onSizeChanged method, by the h value in the method parameter and screen height screenHeightMake comparisons, if this two values unequal then it is assumed that being to be withdrawn into non-full frame state from full frame state.Need in the processThe situation that horizontal/vertical screen is switched excludes, it is possible to use whether onConfigurationChanged method is called back to carry out areaPoint.
State does not change, and continues standby monitoring;In the event of the change of other situations, then carry out other side's aspectFunction logic is processed:Here in two kinds of situation, one kind is that screen state does not change, and will continue to keep FloatMonitor'sListening state;In the event of change, but be not from full frame enter into non-full frame, e.g., the change of two kinds of non-full frame states.Allusion quotationType example is such as opened during input method and when closing input method, and both states also can cause callback method onSizeChangedExecution.Now we can carry out the process of other logics, is then re-introduced into screen listening state.
FloatMonitor sends messages to Service process by Handler:When receiving window change, do not existProcess message in FloatMonitor, but put it in UI main thread and processed, we can pass throughHandler in FloatMonitor sends message MSG_FULL_SCREEN_CHANGE to Service process.Because relating toAnd arrive operation UI, it is put into the correct execution that can guarantee that flow process in main thread.
Service receives message, is processed in UI main thread:Service is receiving MSG_FULL_SCREEN_After CHANGE message, distinct program branch can be selected to be executed according to the parameter of message band.
Judge whether suspension button is to be hidden by window change:Judge current suspension button hide reason be whether byWindow change causes, because it not is a kind of only this mode that suspension button is hidden, can also manually grow and presses by suspensionButton or alternate manner are realizing hiding.
The suspension button that possibly other reasonses cause is hidden, and now needs to go successively to listening state, processes other windowsMouth change logic:If the suspension button that other reasonses lead to is hidden, now it will not be processed, will not be shownOut.Continue into standby listening state.
Display suspension button, cancels the notice in informing simultaneously:If it is determined that being by hanging that window change is hiddenFloating button, now will call setVisibility (View.VISIBLE) method to show suspension button, will lead to simultaneouslyKnow that the notice in hurdle is canceled.
Suspension button shows:Suspension button enters dispaly state, begins listening for key-press event, the input of response user.
After suspension button is hidden into informing, in addition to it being shown again by window change, can also pass throughManual mode, displays it, and implements step as follows:
Suspension button is in hidden state, and Service process continues running background (that is, program still lives), simplySuspension button is hidden temporarily, can be shown suspension button by clicking on this notice.Whether judge userClick this notice manually, if not clicking on notice, suspension button will be always maintained at hiding, and enter into Service holding state;If user clicks on notified, we do not judge to be because which kind of reason is hidden before, click on and notify, it will triggering is outstandingFloating button is shown, concurrently disinfects this notice in informing, and suspension button enters dispaly state, begins listening for button thingPart, the input of response user.
The control method of the suspension button of intelligent terminal provided in an embodiment of the present invention, by monitoring intelligent terminal's display screenOn display window height;After the height listening to display window changes, judge whether display window occurs full frameSwitching between state and non-full frame state;Judging the switching between the display window full frame state of generation and non-full frame stateAfterwards, judge that display window is to be switched to full frame state by non-full frame state, or non-full frame state is switched to by full frame state;?Judge that display window is switched to after full frame state by non-full frame state, control the suspension button on intelligent terminal's display screen to carry out hiddenHide;After judging that display window is switched to non-full frame state by full frame state, control the suspension button on intelligent terminal's display screenShown.The method is listening to after display window is switched to full frame state by non-full frame state, can intelligently controlSuspension button is hidden, thus effectively lifting the full frame experience of user, intelligence degree is high, and does not consume internal memory and electricityAmount resource.
In addition the embodiment of the present invention provides a kind of control device of the suspension button of intelligent terminal, as shown in Fig. 2 including:
Monitor module 201, for monitoring the height of the display window on intelligent terminal's display screen;
First judge module 202, after the height for listening to display window in monitoring module 201 changes, judgesWhether display window there is the switching between full frame state and non-full frame state;
In the first judge module 202, second judge module 203, for judging that display window occurs full frame state full frame with non-After switching between state, judge that display window is to be switched to full frame state by non-full frame state, or switched by full frame stateTo non-full frame state;
In the second judge module 203, control module 204, for judging that display window is switched to full frame shape by non-full frame stateAfter state, control the suspension button on intelligent terminal's display screen to be hidden, be additionally operable to judge display window in the second judge module 203Mouth is switched to after non-full frame state by full frame state, controls the suspension button on intelligent terminal's display screen to be shown.
In another embodiment, the control device of the suspension button of above-mentioned intelligent terminal, also includes:
3rd judge module, full frame for judging that display window is switched to by non-full frame state in the second judge module 203After state, judge whether display window is the switching by non-full frame state to full frame state first;
Play frame module, for judging that display window is first to full frame state by non-full frame state in the 3rd judge moduleDuring switching, to user's pop-up dialogue box;
First determining module, for the selection to option in dialog box according to user, it is determined whether intelligent terminal is shownSuspension button on screen is hidden;
Second determining module, for when the 3rd judge module judge display window for non-first by non-full frame state to full frameDuring the switching of state, when being switched according to the non-full frame state of last time generation to full frame state, user is to option in the dialog box ejectingSelection record, it is determined whether the suspension button on intelligent terminal's display screen is hidden, or again to user eject rightWords frame, so that user re-starts selection.
In the another embodiment that the present invention provides, can include following multinomial interior in frame if ejecting to userHold:Determine change position indicating, permission option, cancellation option and the next time hidden suspension button prompts, hide suspension buttonNo longer reminder option;Wherein, above-mentioned first determining module, including:
First judging unit, for judging whether user allows priority level highest in intelligent terminal system settingSuspension button hides Options cut out;
In judging unit, first display and hidden unit, for judging that permission suspension button hides Options cut out by userAfterwards, no matter how user operates to the option in dialog box, remains that suspension button shows, intelligent terminal is not shownSuspension button on screen is hidden;
Second display and hidden unit, for judge user by allow suspension button do not hide Options close after, andAfter receiving user's selection cancellation option, continue to keep suspension button to show, not to the suspension button on intelligent terminal's display screenIt is hidden;Be additionally operable to judge user by allow suspension button do not hide Options closing after, and receive user select permitAfter being permitted option, suspension button is hidden;
Second judging unit, for, after receiving user's selection cancellation option or allowing option, judging whether user selectsSelect no longer reminder option next time;
Performance element, for, after the second judging unit judges that user selects no longer reminder option next time, executing and userThe cancellation option that selects or allow the corresponding display of option or hide operation continuous and effective, and follow-up occur display window byNon- full frame state to full frame state switching when, no longer reselect to user's pop-up dialogue box for user;It is additionally operable to secondAfter judging unit judges no longer reminder option user non-selected next time, cancellation option that execution is selected with user or allow option pairThe display answered or hide operation to this operation effectively, and occur display window by non-full frame state to full frame state follow-upSwitching when, again reselect to user's pop-up dialogue box for user.
The control device of the suspension button of above-mentioned intelligent terminal, also includes:
First creation module, for, before the height of the display window monitored on intelligent terminal's display screen, starting serviceProcess, and create suspension button in the control that service processes embed;
Second creation module, for creating display window audiomonitor, and the height of display window audiomonitor is set toIt is set to 0 in the height of the display screen of intelligent terminal, width, the form of display window audiomonitor is set to transparent, by windowWindow audiomonitor is added in the display window of intelligent terminal's display screen the view functions that add of mouth manager.
In another embodiment, the control device of the suspension button of above-mentioned intelligent terminal, also includes:
3rd creation module, for, after being hidden suspension button, creating and reminding suspension to press in information informingButton is hidden and is clicked on the prompting message recovering, so that user is after clicking on described prompting message, in the display screen of intelligent terminalThe upper display recovering described suspension button.
Those skilled in the art are it should be appreciated that embodiments of the invention can be provided as method, system or computer programProduct.Therefore, the present invention can be using complete hardware embodiment, complete software embodiment or the reality combining software and hardware aspectApply the form of example.And, the present invention can be using in one or more computers wherein including computer usable program codeThe shape of the upper computer program implemented of usable storage medium (including but not limited to disk memory and optical memory etc.)Formula.
The present invention is the flow process with reference to method according to embodiments of the present invention, equipment (system) and computer programFigure and/or block diagram are describing.It should be understood that can be by each stream in computer program instructions flowchart and/or block diagramFlow process in journey and/or square frame and flow chart and/or block diagram and/or the combination of square frame.These computer programs can be providedThe processor instructing general purpose computer, special-purpose computer, Embedded Processor or other programmable data processing device is to produceA raw machine is so that produced for reality by the instruction of computer or the computing device of other programmable data processing deviceThe device of the function of specifying in present one flow process of flow chart or multiple flow process and/or one square frame of block diagram or multiple square frame.
These computer program instructions may be alternatively stored in and can guide computer or other programmable data processing device with spyDetermine in the computer-readable memory that mode works so that the instruction generation inclusion being stored in this computer-readable memory refers toMake the manufacture of device, this command device realize in one flow process of flow chart or multiple flow process and/or one square frame of block diagram orThe function of specifying in multiple square frames.
These computer program instructions also can be loaded in computer or other programmable data processing device so that countingOn calculation machine or other programmable devices, execution series of operation steps to be to produce computer implemented process, thus in computer orOn other programmable devices, the instruction of execution is provided for realizing in one flow process of flow chart or multiple flow process and/or block diagram oneThe step of the function of specifying in individual square frame or multiple square frame.
Obviously, those skilled in the art can carry out the various changes and modification essence without deviating from the present invention to the present inventionGod and scope.So, if these modifications of the present invention and modification belong to the scope of the claims in the present invention and its equivalent technologiesWithin, then the present invention is also intended to comprise these changes and modification.

Claims (10)

After receiving described user's selection cancellation option or allowing option, judge whether described user selects no longer remind next timeOption;After judging that described user selects no longer reminder option next time, then the cancellation option or fair that execution is selected with described userPermitted the corresponding display of option or hidden operation continuous and effective, and occur display window by non-full frame state to full frame shape follow-upDuring the switching of state, no longer reselect to user's pop-up dialogue box for user;Judging that described user no longer carries non-selected next timeAfter awake option, then execution display corresponding with the cancellation option that described user selects or permission option or hiding operation are to thisOperation is effective, and when follow-up generation display window is by the switching of non-full frame state to full frame state, it is right again to eject to userWords frame reselects for user.
Performance element, for after described second judging unit judges that described user selects no longer reminder option next time, execution withCancellation option or the corresponding display of permission option or hiding operation continuous and effective that described user selects, and aobvious in follow-up generationShow window by non-full frame state to full frame state switching when, no longer reselect to user's pop-up dialogue box for user;Also useAfter judging no longer reminder option described user non-selected next time in described second judging unit, execution is selected with described userCancel option or allow the corresponding display of option or hide operation to this operation effectively, and follow-up occur display window byNon- full frame state to full frame state switching when, again reselect to user's pop-up dialogue box for user.
CN201610782296.6A2016-08-302016-08-30A kind of control method and device of the suspension button of intelligent terminalActiveCN106412237B (en)

Priority Applications (1)

Application NumberPriority DateFiling DateTitle
CN201610782296.6ACN106412237B (en)2016-08-302016-08-30A kind of control method and device of the suspension button of intelligent terminal

Applications Claiming Priority (1)

Application NumberPriority DateFiling DateTitle
CN201610782296.6ACN106412237B (en)2016-08-302016-08-30A kind of control method and device of the suspension button of intelligent terminal

Publications (2)

Publication NumberPublication Date
CN106412237Atrue CN106412237A (en)2017-02-15
CN106412237B CN106412237B (en)2019-06-11

Family

ID=58001509

Family Applications (1)

Application NumberTitlePriority DateFiling Date
CN201610782296.6AActiveCN106412237B (en)2016-08-302016-08-30A kind of control method and device of the suspension button of intelligent terminal

Country Status (1)

CountryLink
CN (1)CN106412237B (en)

Cited By (13)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN107037949A (en)*2017-03-292017-08-11北京小米移动软件有限公司A kind of multi-screen display method and device
CN107124508A (en)*2017-04-182017-09-01北京小米移动软件有限公司Location regulation method, device and the terminal of suspension control, readable storage medium storing program for executing
CN108170346A (en)*2017-12-252018-06-15广东欧珀移动通信有限公司 Electronic device, method for displaying game interface, and related products
CN108182101A (en)*2017-12-262018-06-19深圳豪客互联网有限公司A kind of dialog box pop-up control method and system
CN108334354A (en)*2017-09-012018-07-27武汉斗鱼网络科技有限公司The view design method and device of match pattern
CN108460031A (en)*2017-02-172018-08-28北京嘀嘀无限科技发展有限公司The methods of exhibiting and device of data information
CN109032700A (en)*2018-07-242018-12-18北京酷我科技有限公司A kind of button interaction method based on state control
CN109254719A (en)*2018-08-242019-01-22维沃移动通信有限公司A kind of processing method and mobile terminal of display interface
CN109284041A (en)*2018-09-182019-01-29维沃移动通信有限公司 Application interface switching method and mobile terminal
CN109753331A (en)*2018-12-262019-05-14维沃移动通信有限公司 A kind of information preview method and mobile terminal
CN110489043A (en)*2019-07-312019-11-22华为技术有限公司A kind of management method and relevant apparatus of suspension windows
CN111596985A (en)*2020-04-242020-08-28腾讯科技(深圳)有限公司Interface display method, device, terminal and medium in multimedia conference scene
CN114090098A (en)*2020-07-162022-02-25阿里巴巴集团控股有限公司Application program starting method and device

Citations (3)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
US20030202101A1 (en)*2002-04-292003-10-30Monroe David A.Method for accessing and controlling a remote camera in a networked system with multiple user support capability and integration to other sensor systems
CN105786379A (en)*2016-02-192016-07-20广东欧珀移动通信有限公司Virtual key processing method and device
CN105867797A (en)*2015-12-042016-08-17乐视移动智能信息技术(北京)有限公司Control method and device of virtual keys on touch screen, and mobile terminal

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
US20030202101A1 (en)*2002-04-292003-10-30Monroe David A.Method for accessing and controlling a remote camera in a networked system with multiple user support capability and integration to other sensor systems
CN105867797A (en)*2015-12-042016-08-17乐视移动智能信息技术(北京)有限公司Control method and device of virtual keys on touch screen, and mobile terminal
CN105786379A (en)*2016-02-192016-07-20广东欧珀移动通信有限公司Virtual key processing method and device

Cited By (18)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN108460031A (en)*2017-02-172018-08-28北京嘀嘀无限科技发展有限公司The methods of exhibiting and device of data information
CN107037949A (en)*2017-03-292017-08-11北京小米移动软件有限公司A kind of multi-screen display method and device
US10976887B2 (en)2017-03-292021-04-13Beijing Xiaomi Mobile Software Co., Ltd.Method and apparatus for split-window display
CN107037949B (en)*2017-03-292020-11-27北京小米移动软件有限公司 A split-screen display method and device
CN107124508B (en)*2017-04-182020-02-07北京小米移动软件有限公司Position adjusting method and device of suspension control, terminal and readable storage medium
CN107124508A (en)*2017-04-182017-09-01北京小米移动软件有限公司Location regulation method, device and the terminal of suspension control, readable storage medium storing program for executing
CN108334354A (en)*2017-09-012018-07-27武汉斗鱼网络科技有限公司The view design method and device of match pattern
CN108170346A (en)*2017-12-252018-06-15广东欧珀移动通信有限公司 Electronic device, method for displaying game interface, and related products
CN108182101A (en)*2017-12-262018-06-19深圳豪客互联网有限公司A kind of dialog box pop-up control method and system
CN109032700A (en)*2018-07-242018-12-18北京酷我科技有限公司A kind of button interaction method based on state control
CN109254719A (en)*2018-08-242019-01-22维沃移动通信有限公司A kind of processing method and mobile terminal of display interface
CN109284041A (en)*2018-09-182019-01-29维沃移动通信有限公司 Application interface switching method and mobile terminal
CN109753331A (en)*2018-12-262019-05-14维沃移动通信有限公司 A kind of information preview method and mobile terminal
CN110489043A (en)*2019-07-312019-11-22华为技术有限公司A kind of management method and relevant apparatus of suspension windows
CN110489043B (en)*2019-07-312023-03-24华为技术有限公司Management method and related device for floating window
CN111596985A (en)*2020-04-242020-08-28腾讯科技(深圳)有限公司Interface display method, device, terminal and medium in multimedia conference scene
CN111596985B (en)*2020-04-242023-03-14腾讯科技(深圳)有限公司Interface display method, device, terminal and medium in multimedia conference scene
CN114090098A (en)*2020-07-162022-02-25阿里巴巴集团控股有限公司Application program starting method and device

Also Published As

Publication numberPublication date
CN106412237B (en)2019-06-11

Similar Documents

PublicationPublication DateTitle
CN106412237A (en)Control method and device for suspension button of intelligent terminal
US12056341B2 (en)Method, apparatus, and terminal for processing notification information
EP4145260A1 (en)Information sending method and apparatus, and electronic device
CN102841732B (en)The method and device of task management in a kind of terminal
KR101891259B1 (en)Intelligent Output supporting Method for Event Information And Electro Device supporting the same
EP3037913A1 (en)Method for performing power-saving mode in electronic device and electronic device therefor
EP4206913A1 (en)Function execution method and apparatus
EP2557760A1 (en)Communication system, communication apparatus, communication control method and communication program
KR20140137509A (en)Operating Method of Notification Screen And Electronic Device supporting the same
CN105335224A (en)Application switching method and apparatus
CN102902478A (en)Method, device and equipment for preventing false triggering
CN106775195A (en)A kind of control method and device of suspension button
KR20200102491A (en) User interface display method, apparatus and device
CN106375601A (en)Reminding processing method and mobile terminal
CN110399576B (en)Page switching method and device, readable medium and electronic equipment
CN104571926A (en)Touch method and touch device
EP3242207A1 (en)Method, device and terminal for switching operating system
CN103701996A (en)Quick opening and closing method for application program notification of mobile terminal
CN105634909A (en)Message-displaying method and device
CN104679497A (en)Mobile terminal control method, device and mobile terminal
US20170003875A1 (en)Display Processing Method for Transient Interface, and Terminal
CN104506732B (en)System switching method and device based on contact person
CN112685122B (en)Information processing method, electronic equipment and computer readable storage medium
CN112269502A (en)Object display method and device
CN100466827C (en)New message of short message presenting method

Legal Events

DateCodeTitleDescription
C06Publication
PB01Publication
C10Entry into substantive examination
SE01Entry into force of request for substantive examination
GR01Patent grant
GR01Patent grant

[8]ページ先頭

©2009-2025 Movatter.jp