Dan Ardelean created CB-988: ------------------------------- Summary: AudioPlayer Bug when settings another media Key: CB-988 URL: https://issues.apache.org/jira/browse/CB-988 Project: Apache Cordova Issue Type: Bug Components: WP7 Affects Versions: 1.9.0 Environment: Emulator Reporter: Dan Ardelean Assignee: Jesse MacFadyen Fix For: 2.0.0
Inside the AudioPlayer.cs public void startPlaying(string filePath) before adding a MediaElement again to the LayoutRoot you should take the ole one out. Tried to reuse also but if it's the same audio file stream it will not work I have added for(int i=0;i<grid.Children.Count;i++) if ((grid.Children[i].GetType() == typeof(MediaElement)) && (((MediaElement)grid.Children[i]).Name.CompareTo("playerMediaElement") == 0)) { grid.Children.RemoveAt(i); i = grid.Children.Count; } After: Grid grid = page.FindName("LayoutRoot") as Grid; -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira