public void onResume() {
   if (onStop_state) {
     // start voice actions
     DataModel.getInstance().setVoiceActionsEnabled(true);
     WordActivatorAPI.getInstance().start();
   }
 }
 public void onStop() {
   onStop_state = DataModel.getInstance().isVoiceActionsEnabled();
   if (onStop_state) {
     DataModel.getInstance().setVoiceActionsEnabled(false);
     WordActivatorAPI.getInstance().stopListening();
   }
 }