• R/O
  • HTTP
  • SSH
  • HTTPS

Commit

Tags
No Tags

Frequently used words (click to add to your profile)

javac++androidlinuxc#objective-cqtwindows誰得cocoapythonphprubygameguibathyscaphec翻訳omegat計画中(planning stage)frameworktwittertestdomvb.netdirectxbtronarduinopreviewerゲームエンジン

Navigation voice changer app for Android


Commit MetaInfo

Revision89728df4579c20b7d20a97d292bfbc03d5b666fe (tree)
Time2013-07-30 17:59:22
AuthorHMML <hmml3939@gmai...>
CommiterHMML

Log Message

Fix media player error when file is missing.

Change Summary

Incremental Difference

--- a/src/jp/nekoteki/android/navivoicechanger/VoiceData.java
+++ b/src/jp/nekoteki/android/navivoicechanger/VoiceData.java
@@ -445,7 +445,9 @@ public class VoiceData {
445445 }
446446
447447 public void playPreview() {
448- MediaPlayer.create(this.getContext(), Uri.parse("file://"+this.getPath()+"/"+PREVIEW_FILESNAME)).start();
448+ MediaPlayer player = MediaPlayer.create(this.getContext(), Uri.parse("file://"+this.getPath()+"/"+PREVIEW_FILESNAME));
449+ if (player != null)
450+ player.start();
449451 }
450452
451453 }
\ No newline at end of file