@@ -59,19 +59,19 @@ var DateTimePickerTime = onClickOutside( createClass({
59
59
}
60
60
}
61
61
return React . createElement ( 'div' , { key : type , className : 'rdtCounter' } , [
62
- React . createElement ( 'span' , { key : 'up' , className : 'rdtBtn' , onMouseDown : this . onStartClicking ( 'increase' , type ) , onContextMenu : this . disableContextMenu } , '▲' ) ,
62
+ React . createElement ( 'span' , { key : 'up' , className : 'rdtBtn' , onTouchStart : this . onStartClicking ( 'increase' , type ) , onMouseDown : this . onStartClicking ( 'increase' , type ) , onContextMenu : this . disableContextMenu } , '▲' ) ,
63
63
React . createElement ( 'div' , { key : 'c' , className : 'rdtCount' } , value ) ,
64
- React . createElement ( 'span' , { key : 'do' , className : 'rdtBtn' , onMouseDown : this . onStartClicking ( 'decrease' , type ) , onContextMenu : this . disableContextMenu } , '▼' )
64
+ React . createElement ( 'span' , { key : 'do' , className : 'rdtBtn' , onTouchStart : this . onStartClicking ( 'decrease' , type ) , onMouseDown : this . onStartClicking ( 'decrease' , type ) , onContextMenu : this . disableContextMenu } , '▼' )
65
65
] ) ;
66
66
}
67
67
return '' ;
68
68
} ,
69
69
70
70
renderDayPart : function ( ) {
71
71
return React . createElement ( 'div' , { key : 'dayPart' , className : 'rdtCounter' } , [
72
- React . createElement ( 'span' , { key : 'up' , className : 'rdtBtn' , onMouseDown : this . onStartClicking ( 'toggleDayPart' , 'hours' ) , onContextMenu : this . disableContextMenu } , '▲' ) ,
72
+ React . createElement ( 'span' , { key : 'up' , className : 'rdtBtn' , onTouchStart : this . onStartClicking ( 'toggleDayPart' , 'hours' ) , onMouseDown : this . onStartClicking ( 'toggleDayPart' , 'hours' ) , onContextMenu : this . disableContextMenu } , '▲' ) ,
73
73
React . createElement ( 'div' , { key : this . state . daypart , className : 'rdtCount' } , this . state . daypart ) ,
74
- React . createElement ( 'span' , { key : 'do' , className : 'rdtBtn' , onMouseDown : this . onStartClicking ( 'toggleDayPart' , 'hours' ) , onContextMenu : this . disableContextMenu } , '▼' )
74
+ React . createElement ( 'span' , { key : 'do' , className : 'rdtBtn' , onTouchStart : this . onStartClicking ( 'toggleDayPart' , 'hours' ) , onMouseDown : this . onStartClicking ( 'toggleDayPart' , 'hours' ) , onContextMenu : this . disableContextMenu } , '▼' )
75
75
] ) ;
76
76
} ,
77
77
@@ -181,9 +181,11 @@ var DateTimePickerTime = onClickOutside( createClass({
181
181
clearInterval ( me . increaseTimer ) ;
182
182
me . props . setTime ( type , me . state [ type ] ) ;
183
183
document . body . removeEventListener ( 'mouseup' , me . mouseUpListener ) ;
184
+ document . body . removeEventListener ( 'touchend' , me . mouseUpListener ) ;
184
185
} ;
185
186
186
187
document . body . addEventListener ( 'mouseup' , me . mouseUpListener ) ;
188
+ document . body . addEventListener ( 'touchend' , me . mouseUpListener ) ;
187
189
} ;
188
190
} ,
189
191
0 commit comments