Skip to content

Commit cf66fd4

Browse files
committed
Add mouse hover events to TouchableWithoutFeedback
1 parent cc3eec3 commit cf66fd4

File tree

4 files changed

+9
-6
lines changed

4 files changed

+9
-6
lines changed

Examples/UIExplorer/TouchableExample.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -131,8 +131,8 @@ var TextOnPressBox = React.createClass({
131131
var Hoverable = React.createClass({
132132
render: function() {
133133
return (
134-
<View onMouseEnter={() => console.log('asdf')} style={{backgroundColor: 'black'}}>
135-
<Text>Hover this</Text>
134+
<View style={{backgroundColor: 'black'}}>
135+
<Text>TODO: Hover this</Text>
136136
</View>
137137
);
138138
}

Examples/UIExplorer/UIExplorerApp.osx.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,10 @@ class UIExplorerApp extends React.Component {
3434

3535
constructor() {
3636
super();
37+
var UIExplorerListBase = require('./UIExplorerListBase');
38+
var BorderExample = require('./BorderExample');
3739
this.state = {
38-
component: Welcome,
40+
component: UIExplorerListBase.makeRenderable(BorderExample),
3941
layout: defaultLayout
4042
};
4143
}

Libraries/Components/Touchable/TouchableWithoutFeedback.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,9 @@ var TouchableWithoutFeedback = React.createClass({
135135
onResponderGrant: this.touchableHandleResponderGrant,
136136
onResponderMove: this.touchableHandleResponderMove,
137137
onResponderRelease: this.touchableHandleResponderRelease,
138-
onResponderTerminate: this.touchableHandleResponderTerminate
138+
onResponderTerminate: this.touchableHandleResponderTerminate,
139+
onMouseEnter: this.props.onMouseEnter,
140+
onMouseLeave: this.props.onMouseLeave,
139141
});
140142
}
141143
});

Libraries/react-native/react-native.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,9 +33,8 @@ var ReactNative = Object.assign(Object.create(require('React')), {
3333
Text: require('Text'),
3434
TextInput: require('TextInput'),
3535
TouchableHighlight: require('TouchableHighlight'),
36-
// TouchableNativeFeedback: require('TouchableNativeFeedback'),
3736
TouchableOpacity: require('TouchableOpacity'),
38-
// TouchableWithoutFeedback: require('TouchableWithoutFeedback'),
37+
TouchableWithoutFeedback: require('TouchableWithoutFeedback'),
3938
View: require('View'),
4039
WebView: require('WebView'),
4140

0 commit comments

Comments
 (0)