Skip to content

Commit

Permalink
fix: remove interaction handle (Animated takes care of it)
Browse files Browse the repository at this point in the history
  • Loading branch information
DanielMSchmidt committed Mar 16, 2017
1 parent e2edcee commit 1b11382
Showing 1 changed file with 0 additions and 12 deletions.
12 changes: 0 additions & 12 deletions src/DrawerLayout.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ import dismissKeyboard from 'react-native-dismiss-keyboard';
import {
Animated,
Dimensions,
InteractionManager,
PanResponder,
StyleSheet,
TouchableWithoutFeedback,
Expand Down Expand Up @@ -53,8 +52,6 @@ export default class DrawerLayout extends Component {
constructor(props, context) {
super(props, context);

this.interactionHandle = null;

this.state = {
openValue: new Animated.Value(0),
drawerShown: false,
Expand All @@ -74,15 +71,6 @@ export default class DrawerLayout extends Component {
dismissKeyboard();
}

if (value === 0 || value === 1) {
if (this.interactionHandle) {
InteractionManager.clearInteractionHandle(this.interactionHandle);
this.interactionHandle = undefined;
}
} else if (!this.interactionHandle) {
this.interactionHandle = InteractionManager.createInteractionHandle();
}

this._lastOpenValue = value;
if (this.props.onDrawerSlide) {
this.props.onDrawerSlide({ nativeEvent: { offset: value } });
Expand Down

0 comments on commit 1b11382

Please sign in to comment.