admin
2021-03-09 6aed6290ad05fe2aa125bb8e804e2e8c2f13a613
BuWanVideo/src/com/weikou/beibeivideo/ui/media/EpisodeFragment.java
@@ -110,6 +110,8 @@
    private int episodePage = 2;//当前页
    private String fromName = null;
    public static DisplayImageOptions option = new DisplayImageOptions.Builder()
            .showImageForEmptyUri(R.drawable.from_other)
            .showImageOnFail(R.drawable.from_other)
@@ -124,13 +126,14 @@
            .build();
    public static EpisodeFragment newInstance(VideoInfo videoInfo,
                                              int playingPosition, int start, int end) {
                                              int playingPosition, int start, int end,String from) {
        EpisodeFragment episodeFragment = new EpisodeFragment();
        Bundle args = new Bundle();
        args.putSerializable("video_info", videoInfo);
        args.putInt("playing_position", playingPosition);
        args.putInt("start", start);
        args.putInt("end", end);
        args.putString("from", from);
        episodeFragment.setArguments(args);
        return episodeFragment;
    }
@@ -230,6 +233,9 @@
        Bundle bundle = getArguments();
        mVideoInfo = (VideoInfo) bundle
                .getSerializable("video_info");
        fromName = bundle
                .getString("from", "");
        mPlayingPosition = bundle.getInt("playing_position");
        mStart = bundle.getInt("start");
        mEnd = bundle.getInt("end");
@@ -718,7 +724,7 @@
                        pd.show();
                        getVideoDetail(mVideoInfo.getId(), urlList
                                .get(position).getId(), mVideoInfo
                                .getThirdType(), true);
                                .getThirdType(), true,fromName);
                    }
                    selectedUrl = urlList.get(position);
                    if (selectedUrl == null || selectedUrl.getPicture() == null) {
@@ -791,13 +797,13 @@
    }
    private void getVideoDetail(String videoId, final String resourceId,
                                String videoThirdType, final boolean isSetup) {
                                String videoThirdType, final boolean isSetup, final String from) {
        SharedPreferences preferences = getContext().getSharedPreferences(
                "user", Context.MODE_PRIVATE);
        String uid = preferences.getString("uid", "");
        String loginid = preferences.getString("LoginUid", "");
        BeibeiVideoAPI.getVideoDetail(getContext(), uid, resourceId, videoId,null, loginid,
                videoThirdType, new BasicTextHttpResponseHandler() {
                videoThirdType, from, new BasicTextHttpResponseHandler() {
                    @Override
                    public void onStart() {