This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
For MAC: | |
cd $ANDROID_HOME; | |
cd tools; | |
emulator @Nexus_5X_API_23; // Emulator name |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export default class Api { | |
static headers() { | |
return { | |
Accept: "application/json", | |
"Content-Type": "multipart/form-data" | |
}; | |
} | |
static get(route, token) { | |
return this.request(route, token, null, "GET"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React, { Component } from "react"; | |
import { View, Text, PanResponder } from "react-native"; | |
let initialState = { grant: false, move: false }; | |
class Test extends Component { | |
state = initialState; | |
constructor() { | |
super(); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cd $ANDROID_HOME; | |
cd tools; | |
emulator @Nexus_5X_API_23;// emulator @<YOUR_EMULATOR_NAME> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export default class Api { | |
static headers() { | |
return { | |
Accept: "application/json", | |
"Content-Type": "application/json" | |
}; | |
} | |
static get(route) { | |
return this.request(route, null, "GET"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React, { Component } from 'react'; | |
import { | |
AppRegistry, | |
StyleSheet, | |
Text, | |
View, | |
Picker, | |
Item, | |
Button, | |
AsyncStorage, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
MediaRecorder recorder = new MediaRecorder(); | |
recorder.setAudioSource(MediaRecorder.AudioSource.MIC); | |
recorder.setOutputFormat(MediaRecorder.OutputFormat.AMR_NB); | |
recorder.setOutputFile(audioPath); | |
recorder.setAudioEncoder(MediaRecorder.AudioEncoder.AMR_NB); | |
try { | |
recorder.prepare(); | |
recorder.start();l̥ | |
} catch (Exception exception) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
04-26 12:26:14.025 1307-1706/? W/APM_AudioPolicyManager: getInputForAttr() failed opening input: samplingRate 8000, format 1, channelMask 10 | |
04-26 12:26:14.025 1315-1315/? E/AudioRecord: Could not get audio input for session 1401, record source 1, sample rate 8000, format 0x1, channel mask 0x10, flags 0 | |
04-26 12:26:14.025 1315-1315/? E/StagefrightRecorder: audio source is not initialized | |
04-26 12:26:14.025 682-682/com.wowconnect E/MediaRecorder: start failed: -2147483648 | |
04-26 12:26:14.026 682-682/com.wowconnect E/RecordAudioActivity: onStart: | |
java.lang.RuntimeException: start failed. | |
at android.media.MediaRecorder.start(Native Method) | |
at com.example.ajit.RecordAudioActivity$3.onClick(RecordAudioActivity.java:164) | |
at android.view.View.perfor |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class MyViewPager extends ViewPager { | |
public MyViewPager(Context context) { | |
this(context, null); | |
} | |
public MyViewPager(Context context, AttributeSet attrs) { | |
super(context, attrs); | |
setPageTransformer(false, new DefaultTransformer()); | |
} |
NewerOlder