app/src/main/java/com/voices/ui/activity/HomeActivity.java
/**
     * Handle Activity result from Speech Activity
     *
     * @param requestCode
     * @param resultCode
     * @param data
     */
Handle Activity result from Speech Activity
@param requestCode
@param resultCode
@param data
Handle Activity result from Speech Activity @param requestCode @param resultCode @param data
@Override
    protected void onActivityResult(int requestCode, int resultCode, final Intent data) {
        super.onActivityResult(requestCode, resultCode, data);
        if (resultCode == RESULT_OK) {
            switch (requestCode) {
                case REQ_SPEECH_INPUT_RESULT:
                    showProgress();
                    new Handler().postDelayed(new Runnable() { 
                        @Override
                        public void run() {
                            if (data != null)
                                checkWordInDictionary(data.getStringExtra(INTENT_KEY_SPEECH_INPUT_RESULT));
                        }
                    }, 1000);
                    break;
            }
        }
    }
@ Override protected void onActivityResult ( int requestCode , int resultCode , final Intent data ) { super . onActivityResult ( requestCode , resultCode , data ) ; if ( resultCode == RESULT_OK ) { switch ( requestCode ) { case REQ_SPEECH_INPUT_RESULT : showProgress ( ) ; new Handler ( ) . postDelayed ( new Runnable ( ) { @ Override public void run ( ) { if ( data != null ) checkWordInDictionary ( data . getStringExtra ( INTENT_KEY_SPEECH_INPUT_RESULT ) ) ; } } , 1000 ) ; break ; } } }
Handle Activity result from Speech Activity
 @param requestCode
 @param resultCode
 @param data
Handle Activity result from Speech Activity @param requestCode @param resultCode @param data
//Used just for showing a UI Progress dialog, in order to better user experience