projects
/
pub
/
Android
/
ownCloud.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge remote-tracking branch 'remotes/upstream/streaming' into beta
[pub/Android/ownCloud.git]
/
src
/
com
/
owncloud
/
android
/
media
/
MediaService.java
diff --git
a/src/com/owncloud/android/media/MediaService.java
b/src/com/owncloud/android/media/MediaService.java
index
15fad66
..
7bd9c0c
100644
(file)
--- a/
src/com/owncloud/android/media/MediaService.java
+++ b/
src/com/owncloud/android/media/MediaService.java
@@
-454,11
+454,6
@@
public class MediaService extends Service implements OnCompletionListener, OnPre
releaseResources(false); // release everything except MediaPlayer
try {
releaseResources(false); // release everything except MediaPlayer
try {
-// if (mFile == null) {
-// Toast.makeText(this, R.string.media_err_nothing_to_play, Toast.LENGTH_LONG).show();
-// processStopRequest(true);
-// return;
-
if (mAccount == null) {
Toast.makeText(this, R.string.media_err_not_in_owncloud, Toast.LENGTH_LONG).show();
processStopRequest(true);
if (mAccount == null) {
Toast.makeText(this, R.string.media_err_not_in_owncloud, Toast.LENGTH_LONG).show();
processStopRequest(true);
@@
-468,7
+463,7
@@
public class MediaService extends Service implements OnCompletionListener, OnPre
createMediaPlayerIfNeeded();
mPlayer.setAudioStreamType(AudioManager.STREAM_MUSIC);
String url = mFile.getStoragePath();
createMediaPlayerIfNeeded();
mPlayer.setAudioStreamType(AudioManager.STREAM_MUSIC);
String url = mFile.getStoragePath();
- // Streaming is not possible right now
+
if (url == null || url.length() <= 0) {
url = AccountUtils.constructFullURLForAccount(this, mAccount) + mFile.getRemotePath();
}
if (url == null || url.length() <= 0) {
url = AccountUtils.constructFullURLForAccount(this, mAccount) + mFile.getRemotePath();
}