WindowActivity.java 文件源码

java
阅读 36 收藏 0 点赞 0 评论 0

项目:GSYVideoPlayer 作者:
@OnClick({R.id.start_window, R.id.jump_other})
public void onViewClicked(View view) {
    switch (view.getId()) {
        case R.id.start_window:
            if (FloatWindow.get() != null) {
                return;
            }
            FloatPlayerView floatPlayerView = new FloatPlayerView(getApplicationContext());
            FloatWindow
                    .with(getApplicationContext())
                    .setView(floatPlayerView)
                    .setWidth(Screen.width, 0.4f)
                    .setHeight(Screen.width, 0.4f)
                    .setX(Screen.width, 0.8f)
                    .setY(Screen.height, 0.3f)
                    .setMoveType(MoveType.slide)
                    .setFilter(false)
                    .setMoveStyle(500, new BounceInterpolator())
                    .build();
            FloatWindow.get().show();
            break;
        case R.id.jump_other:
            startActivity(new Intent(this, EmptyActivity.class));
            break;
    }
}
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号