X-Git-Url: http://git.linex4red.de/pub/Android/ownCloud.git/blobdiff_plain/3d3046dc264792475c72987afc25beae23da4dc6..2477d496e3cdfe4eb7735a8e8c4e095bc201be61:/src/com/owncloud/android/ui/preview/PreviewVideoActivity.java diff --git a/src/com/owncloud/android/ui/preview/PreviewVideoActivity.java b/src/com/owncloud/android/ui/preview/PreviewVideoActivity.java index ada25802..23188b5e 100644 --- a/src/com/owncloud/android/ui/preview/PreviewVideoActivity.java +++ b/src/com/owncloud/android/ui/preview/PreviewVideoActivity.java @@ -1,7 +1,8 @@ -/* ownCloud Android client application +/** + * ownCloud Android client application * * @author David A. Velasco - * Copyright (C) 2012-2013 ownCloud Inc. + * Copyright (C) 2015 ownCloud Inc. * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2, @@ -25,7 +26,7 @@ import com.owncloud.android.media.MediaService; import com.owncloud.android.ui.activity.FileActivity; import android.accounts.Account; -import android.app.AlertDialog; +import android.support.v7.app.AlertDialog; import android.content.DialogInterface; import android.content.Intent; import android.media.MediaPlayer; @@ -203,8 +204,8 @@ public class PreviewVideoActivity extends FileActivity implements OnCompletionLi file = getStorageManager().getFileById(file.getFileId()); if (file != null) { if (file.isDown()) { - mVideoPlayer.setVideoPath(file.getStoragePath()); - + mVideoPlayer.setVideoURI(file.getStorageUri()); + } else { // not working yet String url; @@ -215,13 +216,13 @@ public class PreviewVideoActivity extends FileActivity implements OnCompletionLi onError(null, MediaService.OC_MEDIA_ERROR, R.string.media_err_no_account); } } - + // create and prepare control panel for the user mMediaController = new MediaController(this); mMediaController.setMediaPlayer(mVideoPlayer); mMediaController.setAnchorView(mVideoPlayer); mVideoPlayer.setMediaController(mMediaController); - + } else { finish(); }