package com.wd.workoffice.ui.activity.mes;

import com.bumptech.glide.Glide;
import com.wd.workoffice.R;
import com.wd.workoffice.app.WorkBaseActivity;
import com.wd.workoffice.app.WorkToolBarActivity;

import butterknife.BindView;
import butterknife.ButterKnife;
import cn.jzvd.Jzvd;
import cn.jzvd.JzvdStd;


/**
 * 视频展示
 * author : flexible
 * email : lgd19940421@163.com
 * github: https://github.com/FlexibleXd
 **/
public class VideoActivity extends WorkToolBarActivity {


    @BindView(R.id.jz_video)
    JzvdStd jzVideo;

    @Override
    protected void initView() {
        ButterKnife.bind(this);
    }


    @Override
    protected void initData() {
        jzVideo.setUp(getIntent().getStringExtra("url")
                , "", JzvdStd.SCREEN_NORMAL);
        jzVideo.startVideo();
    }


    @Override
    protected void initEvent() {
    }


    @Override
    protected int layoutId() {
        return R.layout.activity_video;
    }
    @Override
    public void onBackPressed() {
        if (Jzvd.backPress()) {
            return;
        }
        super.onBackPressed();
    }

    @Override
    protected void onPause() {
        super.onPause();
        Jzvd.releaseAllVideos();
    }

}
