Specific embodiment
In order that those skilled in the art more fully understand the technical scheme in the application, below in conjunction with this
Accompanying drawing in application embodiment, is clearly and completely described to the technical scheme in the embodiment of the present application,
Obviously, described embodiment is only some embodiments of the present application, rather than whole embodiments.Base
Embodiment in the application, those of ordinary skill in the art are obtained under the premise of creative work is not paid
The every other embodiment for obtaining, should all belong to the scope of the application protection.
To solve the problems, such as that the numerical value in numerical value input frame in the prior art cannot quickly reach boundary value, propose
The numerical value input method of the application.
Fig. 1 is the flow chart of the numerical value input method of offer in the embodiment of the application one.In the present embodiment, institute
Numerical value input method is stated to comprise the following steps:
S100:The instruction that button is produced after being triggered in reception numerical value input frame.
Usually, on inputting interface (webpage or APP), to realize an input for numerical information, can
To set numerical value input frame on the inputting interface, user can be by clicking on button in the numerical value input frame
To control the increase and decrease of numerical value.The button includes that (such as button "+" controls numerical value for increasing the button for operating
Increase) or for the button (button "-" control numerical value is reduced) of reducing.In the numerical value input frame
Numerical value has a scope, such as -1024 to 1024, wherein -1024 and 1024 are the numerical value input frame
Boundary value.Wherein it is possible to be that above-mentioned numerical value input method, the end are realized on any form of terminal device
End equipment may, for example, be personal computer (PC), just as the executive agent of above-mentioned numerical value input method
Take formula computer, smart mobile phone, personal digital assistant (PDA), intelligent watch etc..Above-mentioned numerical value input
Button described in mode can be triggered by modes such as touch, mouse and keyboards.
S110:Judge whether the number of times of the instruction in the first preset duration reaches predetermined threshold value.
In actual scene, when user attempts to reach the boundary value of the numerical value input frame, often soon
Button in numerical value input frame described in the repeated trigger of speed, such as mouse quickly clicks button "+".
In the present embodiment, first preset duration and the predetermined threshold value can be the artificial warps for setting
Test value.
Assuming that the first preset duration is 1 second, predetermined threshold value is 3 times, if between 0 second to 1 second 1
When the number of times that the instruction produced after user's click button is received in second is 2 times, it can be deduced that first presets
The number of times of the instruction is not reaching to predetermined threshold value in duration.
If receiving the secondary of the instruction produced after user's click button in 1 second between 0 second to 1 second
When number is 3 times, it can be deduced that the number of times of the instruction reaches predetermined threshold value in the first preset duration.
S120:If the number of times of the instruction reaches predetermined threshold value in the first preset duration, the instruction is judged
Whether it is same instructions.
Because the button includes the button or the button for reducing for increasing operation, different button quilts
The instruction produced after triggering is different;And when user attempts to reach the boundary value of the numerical value input frame, it is past
Past is the same button of triggering.
As described in S110 steps 3 times instruction in, if 3 instructions respectively " increase ", " subtracting ",
" increasing ", so instruction is not same instructions, does not then meet user and attempts to reach numerical value input frame boundary value
Operation.If 3 instructions respectively " increase ", " increasing ", " increasing ", the instruction is same instructions,
Then meet user to attempt to reach the operation of numerical value input frame boundary value.
S130:If the instruction is same instructions, the numerical value in presently described numerical value input frame is changed into institute
State the corresponding boundary value of button.
The corresponding boundary value of the button includes:
The corresponding boundary value of button for increasing operation is maximum;
Or, the corresponding boundary value of button for reducing is minimum value.
Numerical value is changed into schematic diagram in being illustrated in figure 2 numerical value input frame, exists for increasing behaviour in numerical value input frame
The button "+" of work and the button "-" for reducing.Numerical value input frame Central Plains numerical value 10 is " 321 ",
When user clicked on button "+" 3 times in 1 second, by the numerical value " 321 " in presently described numerical value input frame
It is changed into the corresponding boundary value 30 of the button "+" for " 1024 ".
Or, there is the button "+" and the button "-" for reducing for increasing operation in numerical value input frame.
Numerical value input frame Central Plains numerical value 10 is " 321 ", when user clicked on button "-" 3 times in 1 second, general
Numerical value " 321 " in presently described numerical value input frame is changed into the corresponding boundary value 31 of the button "-"
“-1024”。
By the present embodiment, the instruction produced after being clicked by receiving button in numerical value input frame;Judge
In one preset duration the number of times of the same instructions whether reach predetermined threshold value or judge button click on when
Whether length reaches predetermined threshold value;If so, the numerical value in presently described numerical value input frame then is changed into the button
Corresponding boundary value.Can so realize that the numerical value in numerical value input frame is rapidly achieved boundary value
As shown in figure 3, can also have S121, S122 between step S110 and S120 in the present embodiment
Step, it is specific as follows:
S121:If the instruction is same instructions, pre-set button is shown.
The pre-set button can be shown in the region of button accessory in numerical value input frame, and the region can be with
For example above or below button.Be used for corresponding with the button can also be shown in the pre-set button
Point out the word of user, such as " maximum ", " minimum value " etc..
Numerical value is changed into schematic diagram in being illustrated in figure 4 numerical value input frame, exists for increasing behaviour in numerical value input frame
The button "+" of work and the button "-" for reducing.Numerical value input frame Central Plains numerical value 10 is " 321 ",
When user clicked on button "+" 3 times in 1 second, pre-set button 20 is shown, shown in the pre-set button
It is shown with word and " skips to maximum”.
Or, there is the button "+" and the button "-" for reducing for increasing operation in numerical value input frame.
Numerical value input frame Central Plains numerical value 10 is " 321 ", aobvious when user clicked on button "-" 3 times in 1 second
Show pre-set button 21, showing word in the pre-set button " skips to minimum value”.
S122:Judge whether the pre-set button is triggered;If so, then performing S130 steps.
Correspondingly, S130 steps described in the present embodiment, including:
If the pre-set button is triggered, the numerical value in presently described numerical value input frame is changed into the button
Corresponding boundary value.
As shown in figure 4, when pre-set button 20 is clicked on by user, S130 steps are performed, will current institute
State the numerical value " 321 " in numerical value input frame and be changed into the corresponding boundary value 30 of the button "+" for " 1024 ".
Or, when pre-set button 21 is clicked on by user, S130 steps are performed, will presently described numerical value
Numerical value " 321 " in input frame is changed into the corresponding boundary value 31 of the button "-" for " -1024 ".
In one embodiment of the application, the S122 steps can also include:
Judge whether the pre-set button is triggered in the second preset duration.
Correspondingly, S130 steps described in the present embodiment, including:
If the pre-set button is triggered, the numerical value in presently described numerical value input frame is changed into the button
Corresponding boundary value.
In the present embodiment, second preset duration can be the artificial empirical value for setting.In this way, the
In two preset durations (such as 0.5 second), if the pre-set button is not triggered, the numerical value input
Numerical value in frame is constant, and the pre-set button disappears automatically;If the pre-set button is triggered, S130 is performed
Step.
In actual applications, when same button is clicked on quick repetition, may be not intended to arrival border
Value.In this case, the present embodiment by increasing by one by after S120 steps, being used to point out
The pre-set button of user, just can be by presently described numerical value input frame only after user clicks on the pre-set button
Numerical value be changed into the corresponding boundary value of the button, improve the experience of user.
Fig. 5 is the flow chart of the numerical value input method of offer in the embodiment of the application one.In the present embodiment, institute
Numerical value input method is stated to comprise the following steps:
S200:The duration that button is persistently triggered in reception numerical value input frame.
When User reaches the boundary value of the numerical value input frame, may continue to trigger the numerical value defeated
Enter button in frame, be such as used to increase the button "+" of operation in numerical value input frame described in user's sustained hold, make
Button is persistently triggered in obtaining the numerical value input frame.
The button includes the button or the button for reducing for increasing operation;
S210:Judge whether the duration reaches preset duration.
The preset duration can be the artificial empirical value for setting.
S220:If the duration is more than preset duration, the numerical value in presently described numerical value input frame is changed into
The corresponding boundary value of the button.
The corresponding boundary value of the button includes:
The corresponding boundary value of button for increasing operation is maximum;
Or, the corresponding boundary value of button for reducing is minimum value.
Numerical value is changed into schematic diagram in being illustrated in figure 6 numerical value input frame, exists for increasing behaviour in numerical value input frame
The button "+" of work and the button "-" for reducing.Numerical value input frame Central Plains numerical value 10 is " 321 ",
When user persistently clicks on button "+" reaches preset duration (1 second), by presently described numerical value input frame
Numerical value " 321 " be changed into the corresponding boundary value 30 of the button "+" for " 1024 ".
Or, there is the button "+" and the button "-" for reducing for increasing operation in numerical value input frame.
Numerical value input frame Central Plains numerical value 10 is " 321 ", and preset duration is reached when user persistently clicks on button "-"
When (1 second), the numerical value " 321 " in presently described numerical value input frame is changed into the button "-" correspondence
Boundary value 31 be " -1024 ".
By the present embodiment, by receiving the duration that button in numerical value input frame is persistently clicked on;Judge described
Whether duration reaches preset duration;If so, then by the numerical value in presently described numerical value input frame be changed into it is described by
The corresponding boundary value of button.Can so realize that the numerical value in numerical value input frame is rapidly achieved boundary value.
As shown in fig. 7, can also have S211, S212 between step S210 and S220 in the present embodiment
Step, it is specific as follows:
S211:If whether the duration is more than preset duration, pre-set button is shown.
Numerical value is changed into schematic diagram in being illustrated in figure 8 numerical value input frame, exists for increasing behaviour in numerical value input frame
The button "+" of work and the button "-" for reducing.Numerical value input frame Central Plains numerical value 10 is " 321 ",
When user persistently clicks on button "+" reaches preset duration (1 second), pre-set button 20 is shown, pointed out
User " skips to maximum”.
Or, there is the button "+" and the button "-" for reducing for increasing operation in numerical value input frame.
Numerical value input frame Central Plains numerical value 10 is " 321 ", and preset duration is reached when user persistently clicks on button "-"
When (1 second), pre-set button 21 is shown, point out user " to skip to minimum value”.
S212:Judge whether the pre-set button is triggered;If so, then performing S130 steps.
Correspondingly, S220 steps described in the present embodiment, including:
If the pre-set button is triggered, the numerical value in presently described numerical value input frame is changed into the button
Corresponding boundary value.
As shown in figure 8, when pre-set button 20 is clicked on by user, S130 steps are performed, will current institute
State the numerical value " 321 " in numerical value input frame and be changed into the corresponding boundary value 30 of the button "+" for " 1024 ".
Or, when pre-set button 21 is clicked on by user, S130 steps are performed, will presently described numerical value
Numerical value " 321 " in input frame is changed into the corresponding boundary value 31 of the button "-" for " -1024 ".
In one embodiment of the application, the S212 steps can also include:
Judge whether the pre-set button is triggered in the second preset duration.
In the present embodiment, second preset duration can be the artificial empirical value for setting.In this way, the
In two preset durations (such as 0.5 second), if the pre-set button is not triggered, the numerical value input
Numerical value in frame is constant, and the pre-set button disappears automatically;If the pre-set button is triggered, S220 is performed
Step.
Correspondingly, S220 steps described in the present embodiment, including:
If the pre-set button is triggered in the second preset duration, by the number in presently described numerical value input frame
Value is changed into the corresponding boundary value of the button.
In actual applications, when same button is clicked on quick repetition, may be not intended to arrival border
Value.In this case, the present embodiment by increasing by one by after S210 steps, being used to point out
The pre-set button of user, just can be by presently described numerical value input frame only after user clicks on the pre-set button
Numerical value be changed into the corresponding boundary value of the button, improve the experience of user.
The embodiment of the present application is provided and also provides a kind of device, it is possible to achieve above-mentioned method and step, and the device
Can be realized by software, it is also possible to realized by way of hardware or software and hardware combining.It is implemented in software
As a example by, as the device on logical meaning, be by the CPU of server (Central Process Unit,
Central processing unit) corresponding computer program instructions are read run in internal memory what is formed.
Fig. 9 is the module diagram of the numerical value input unit of offer in the embodiment of the application one.In the present embodiment,
Described device includes:
First receiving unit 300, for receiving the instruction produced after button in numerical value input frame is triggered;
Whether the first judging unit 310, the number of times for the instruction in the first preset duration reaches default threshold
Value;
Second judging unit 320, the number of times for the instruction in the first preset duration reaches predetermined threshold value
When, judge whether the instruction is same instructions;
First processing units 330, for when the instruction is for same instructions, by the input of presently described numerical value
Numerical value in frame is changed into the corresponding boundary value of the button.
Preferably, after second judging unit, also include:
First display unit, for when the instruction is for same instructions, showing pre-set button;
3rd judging unit, for judging whether the pre-set button is triggered;
Correspondingly, the first processing units, are additionally operable to when the pre-set button is triggered, by current institute
State the numerical value in numerical value input frame and be changed into the corresponding boundary value of the button.
Preferably, the 3rd judging unit, is additionally operable to:
Judge whether the pre-set button is triggered in the second preset duration;
Correspondingly, the first processing units, are additionally operable to the pre-set button in the second preset duration and are touched
During hair, the numerical value in presently described numerical value input frame is changed into the corresponding boundary value of the button.
Preferably, the button includes the button for increasing or the button for subtracting;
Correspondingly, the corresponding boundary value of the button includes being used for the corresponding maximum of button of increasing or is used for
The corresponding minimum value of button for subtracting.
Figure 10 is the module diagram of the numerical value input unit of offer in the embodiment of the application one.The present embodiment
In, described device includes:
Second receiving unit 400, for receiving the duration that button in numerical value input frame is persistently clicked on;
4th judging unit 410, for judging the duration whether more than preset duration;
Second processing unit 420, it is for when the duration is more than preset duration, presently described numerical value is defeated
Enter the numerical value in frame and be changed into the corresponding boundary value of the button.
Preferably, after the 3rd judging unit, also include:
Second display unit, for when the duration is more than predetermined threshold value, showing pre-set button;
5th judging unit, for judging whether the pre-set button is triggered;
Correspondingly, the second processing unit, is additionally operable to when the pre-set button is triggered, by current institute
State the numerical value in numerical value input frame and be changed into the corresponding boundary value of the button.
Preferably, the 5th judging unit, is additionally operable to:
Judge whether the pre-set button is triggered in the second preset duration;
Correspondingly, the second processing unit, is additionally operable to the pre-set button in the second preset duration and is touched
During hair, the numerical value in presently described numerical value input frame is changed into the corresponding boundary value of the button.
Preferably, the button includes the button for increasing or the button for subtracting;
Correspondingly, the corresponding boundary value of the button includes being used for the corresponding maximum of button of increasing or is used for
The corresponding minimum value of button for subtracting.
In the nineties in 20th century, it is changing on hardware that can clearly be distinguished for the improvement of a technology
The improvement entered on (for example, the improvement to circuit structures such as diode, transistor, switches) or software is (right
In the improvement of method flow).However, with the development of technology, the improvement of current many method flows is
Through directly improving for hardware circuit can be considered as.Designer is nearly all by by improved method flow
It is programmed into hardware circuit to obtain corresponding hardware circuit.Therefore, it cannot be said that method flow
Improvement cannot be realized with hardware entities module.For example, PLD (Programmable
Logic Device, PLD) (for example field programmable gate array (Field Programmable Gate Array,
FPGA it is exactly)) such a integrated circuit, its logic function is determined by user to device programming.By setting
Meter personnel are voluntarily programmed a digital display circuit " integrated " on a piece of PLD, without asking chip system
Manufacturer is made to design and make special IC chip.And, nowadays, substitution manually makes integrated
Circuit chip, this programming also uses " logic compiler (logic compiler) " software instead to realize mostly,
Software compiler used is similar when it writes with program development, and the source code before compiling also is obtained
Write with specific programming language, this is referred to as hardware description language (Hardware Description
Language, HDL), and HDL is also not only a kind of, but have many kinds, such as ABEL (Advanced
Boolean Expression Language)、AHDL(Altera Hardware Description Language)、
Confluence、CUPL(Cornell University Programming Language)、HDCal、JHDL
(Java Hardware Description Language)、Lava、Lola、MyHDL、PALASM、RHDL
(Ruby Hardware Description Language) etc., that most commonly use at present is VHDL
(Very-High-Speed Integrated Circuit Hardware Description Language) with
Verilog.Those skilled in the art also will be apparent to the skilled artisan that and only need to method flow with above-mentioned several hardware descriptions
Language slightly programming in logic and is programmed into integrated circuit, it is possible to is readily available and is realized the logical method stream
The hardware circuit of journey.
Controller can be implemented in any suitable manner, for example, controller can take such as microprocessor
Or processor and storage can be by computer readable program code (such as softwares of (micro-) computing device
Or firmware) computer-readable medium, gate, switch, application specific integrated circuit (Application Specific
Integrated Circuit, ASIC), the form of programmable logic controller (PLC) and embedded microcontroller, controller
Example include but is not limited to following microcontroller:ARC 625D、Atmel AT91SAM、Microchip
PIC18F26K20 and Silicone Labs C8051F320, Memory Controller is also implemented as depositing
A part for the control logic of reservoir.It is also known in the art that except with pure computer-readable program
Code means are realized beyond controller, can cause to control by the way that method and step is carried out into programming in logic completely
Device is with the shape of gate, switch, application specific integrated circuit, programmable logic controller (PLC) and embedded microcontroller etc.
Formula realizes identical function.Therefore this controller is considered a kind of hardware component, and to bag in it
The structure that the device for realizing various functions for including can also be considered as in hardware component.Or even, can be with
To be used to realizing that the device of various functions is considered as not only being the software module of implementation method but also can be hardware
Structure in part.
System, device, module or unit that above-described embodiment is illustrated, specifically can be by computer chip or reality
Body is realized, or is realized by the product with certain function.
For convenience of description, it is divided into various units with function during description apparatus above to describe respectively.Certainly,
The function of each unit can be realized in same or multiple softwares and/or hardware when the application is implemented.
It should be understood by those skilled in the art that, embodiments of the invention can be provided as method, system or meter
Calculation machine program product.Therefore, the present invention can be using complete hardware embodiment, complete software embodiment or knot
Close the form of the embodiment in terms of software and hardware.And, the present invention can be used and wherein wrapped at one or more
Containing computer usable program code computer-usable storage medium (including but not limited to magnetic disk storage,
CD-ROM, optical memory etc.) on implement computer program product form.
The present invention is produced with reference to method according to embodiments of the present invention, equipment (system) and computer program
The flow chart and/or block diagram of product is described.It should be understood that can by computer program instructions realize flow chart and
/ or block diagram in each flow and/or the flow in square frame and flow chart and/or block diagram and/
Or the combination of square frame.These computer program instructions to all-purpose computer, special-purpose computer, insertion can be provided
The processor of formula processor or other programmable data processing devices is producing a machine so that by calculating
The instruction of the computing device of machine or other programmable data processing devices is produced for realizing in flow chart one
The device of the function of being specified in individual flow or multiple one square frame of flow and/or block diagram or multiple square frames.
These computer program instructions may be alternatively stored in can guide computer or the treatment of other programmable datas to set
In the standby computer-readable memory for working in a specific way so that storage is in the computer-readable memory
Instruction produce include the manufacture of command device, the command device realization in one flow of flow chart or multiple
The function of being specified in one square frame of flow and/or block diagram or multiple square frames.
These computer program instructions can be also loaded into computer or other programmable data processing devices, made
Obtain and series of operation steps is performed on computer or other programmable devices to produce computer implemented place
Reason, so as to the instruction performed on computer or other programmable devices is provided for realizing in flow chart one
The step of function of being specified in flow or multiple one square frame of flow and/or block diagram or multiple square frames.
In a typical configuration, computing device includes one or more processors (CPU), input/defeated
Outgoing interface, network interface and internal memory.
Internal memory potentially includes the volatile memory in computer-readable medium, random access memory
And/or the form, such as read-only storage (ROM) or flash memory (flash RAM) such as Nonvolatile memory (RAM).
Internal memory is the example of computer-readable medium.
Computer-readable medium includes that permanent and non-permanent, removable and non-removable media can be by appointing
What method or technique realizes information Store.Information can be computer-readable instruction, data structure, program
Module or other data.The example of the storage medium of computer includes, but are not limited to phase transition internal memory
(PRAM), static RAM (SRAM), dynamic random access memory (DRAM), its
The random access memory (RAM) of his type, read-only storage (ROM), electrically erasable are read-only
Memory (EEPROM), fast flash memory bank or other memory techniques, read-only optical disc read-only storage
(CD-ROM), digital versatile disc (DVD) or other optical storages, magnetic cassette tape, tape magnetic
Disk storage or other magnetic storage apparatus or any other non-transmission medium, can be used for storage can be calculated
The information that equipment is accessed.Defined according to herein, computer-readable medium does not include temporary computer-readable matchmaker
Body (transitory media), such as data-signal and carrier wave of modulation.
Also, it should be noted that term " including ", "comprising" or its any other variant be intended to non-row
His property is included, so that process, method, commodity or equipment including a series of key elements not only include
Those key elements, but also other key elements including being not expressly set out, or also include for this process,
Method, commodity or the intrinsic key element of equipment.In the absence of more restrictions, by sentence " including
One ... " key element that limits, it is not excluded that in the process including the key element, method, commodity or set
Also there is other identical element in standby.
It will be understood by those skilled in the art that embodiments herein can be provided as method, system or computer journey
Sequence product.Therefore, the application can using complete hardware embodiment, complete software embodiment or combine software and
The form of the embodiment of hardware aspect.And, the application can be used and wherein include calculating at one or more
Machine usable program code computer-usable storage medium (including but not limited to magnetic disk storage, CD-ROM,
Optical memory etc.) on implement computer program product form.
The application can be described in the general context of computer executable instructions, example
Such as program module.Usually, program module includes performing particular task or realizes particular abstract data type
Routine, program, object, component, data structure etc..This can also in a distributed computing environment be put into practice
Application, in these DCEs, by the remote processing devices connected by communication network come
Execution task.In a distributed computing environment, program module may be located at including local including storage device
In remote computer storage medium.
Each embodiment in this specification is described by the way of progressive, identical phase between each embodiment
As part mutually referring to, what each embodiment was stressed be it is different from other embodiment it
Place.For especially for system embodiment, because it is substantially similar to embodiment of the method, so description
Fairly simple, the relevent part can refer to the partial explaination of embodiments of method.
Embodiments herein is the foregoing is only, the application is not limited to.For this area skill
For art personnel, the application can have various modifications and variations.All institutes within spirit herein and principle
Any modification, equivalent substitution and improvements of work etc., within the scope of should be included in claims hereof.