/** Unregisters file system listener and closes native voice notes recorder application. */
  protected void teardown() {
    // remove file system listener
    synchronized (UiApplication.getEventLock()) {
      UiApplication.getUiApplication().removeFileSystemJournalListener(listener);
    }

    // close the native voice notes recorder application
    AudioControl.closeAudioRecorder();
  }
  /** Registers file system listener and launches native voice notes recorder application. */
  protected void setup() {
    // register listener for files being written
    synchronized (UiApplication.getEventLock()) {
      UiApplication.getUiApplication().addFileSystemJournalListener(listener);
    }

    // launch the native voice notes recorder application
    AudioControl.launchAudioRecorder();
  }