chore: add more logs
This commit is contained in:
parent
4cd21b64cc
commit
e49aa1e9f4
|
@ -334,8 +334,6 @@ public class AlphaMovieView extends GLTextureView {
|
|||
AssetFileDescriptor afd = context.getResources().openRawResourceFd(resId);
|
||||
if (afd == null) return;
|
||||
|
||||
mediaPlayer.setDataSource(afd.getFileDescriptor(), afd.getStartOffset(), afd.getLength());
|
||||
|
||||
FileDescriptor fileDescriptor = afd.getFileDescriptor();
|
||||
long startOffset = afd.getStartOffset();
|
||||
long endOffset = afd.getLength();
|
||||
|
@ -347,7 +345,7 @@ public class AlphaMovieView extends GLTextureView {
|
|||
onDataSourceSet(retriever);
|
||||
|
||||
} catch (IOException e) {
|
||||
Log.e(TAG, e.getMessage(), e);
|
||||
Log.e(TAG + " setVideoFromResourceId", e.getMessage(), e);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -4,6 +4,7 @@ import static android.view.ViewGroup.LayoutParams.MATCH_PARENT;
|
|||
|
||||
import android.content.Context;
|
||||
import android.os.Bundle;
|
||||
import android.util.Log;
|
||||
import android.view.Gravity;
|
||||
import android.widget.LinearLayout;
|
||||
|
||||
|
@ -24,6 +25,7 @@ public class TransparentVideoViewManager extends SimpleViewManager<LinearLayout>
|
|||
private static List<LinearLayout> sInstances = new ArrayList<>();
|
||||
|
||||
public static final String REACT_CLASS = "TransparentVideoView";
|
||||
private static final String TAG = "TransparentVideoViewManager";
|
||||
|
||||
ReactApplicationContext reactContext;
|
||||
|
||||
|
@ -64,8 +66,11 @@ public class TransparentVideoViewManager extends SimpleViewManager<LinearLayout>
|
|||
String file = src.getString("uri");
|
||||
try {
|
||||
Integer rawResourceId = Utils.getRawResourceId(reactContext, file);
|
||||
Log.d(TAG + " setSrc", "ResourceID: " + rawResourceId);
|
||||
|
||||
alphaMovieView.setVideoFromResourceId(reactContext, rawResourceId);
|
||||
} catch (RuntimeException e) {
|
||||
Log.e(TAG + " setSrc", e.getMessage(), e);
|
||||
alphaMovieView.setVideoByUrl(file);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue