mirror of
https://github.com/status-im/instabug-reactnative.git
synced 2025-03-02 14:10:40 +00:00
commit
ba85a8bfde
@ -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.
|
||||
|
12
index.js
12
index.js
@ -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.
|
||||
|
@ -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": {
|
||||
|
Loading…
x
Reference in New Issue
Block a user