Merge pull request #43 from Instabug/dev

Dev
This commit is contained in:
Hossam Hassan 2017-06-26 23:38:48 +02:00 committed by GitHub
commit ba85a8bfde
3 changed files with 29 additions and 1 deletions

View File

@ -1058,6 +1058,22 @@ public class RNInstabugReactnativeModule extends ReactContextBaseJavaModule {
}
}
/**
* Sets the threshold value of the shake gesture for android devices.
* Default for android is an integer value equals 350.
* you could increase the shaking difficulty level by
* increasing the `350` value and vice versa.
*
* @param {number} androidThreshold Threshold for android devices.
*/
@ReactMethod
public void setShakingThresholdForAndroid(androidThreshold) {
try {
mInstabug.setShakingThreshold(androidThreshold);
} catch (Exception e) {
e.printStackTrace();
}
}
/**
* Sets a block of code that gets executed when a new message is received.

View File

@ -246,6 +246,18 @@ module.exports = {
Instabug.setShakingThresholdForIPhone(iPhoneShakingThreshold, iPadShakingThreshold);
},
/**
* Sets the threshold value of the shake gesture for android devices.
* Default for android is an integer value equals 350.
* you could increase the shaking difficulty level by
* increasing the `350` value and vice versa
* @param {number} androidThreshold Threshold for android devices.
*/
setShakingThresholdForAndroid: function (androidThreshold) {
if (Platform.OS === 'android')
Instabug.setShakingThresholdForAndroid(androidThreshold);
},
/**
* Sets the default edge and offset from the top at which the floating button
* will be shown. Different orientations are already handled.

View File

@ -1,6 +1,6 @@
{
"name": "instabug-reactnative",
"version": "1.1.1",
"version": "1.1.2",
"description": "React Native plugin for integrating the Instabug SDK",
"main": "index.js",
"repository": {