小编ave*_*sha的帖子

NineOldAndroids, not clickable view after rotation or move

I use NineOldAndroids 2.4.0 to animate objects mainly for the movement and transformation of control. On Android 4.0 and above all works fine,but on previous versions (2.1, 2.3) after the animation elements do not receive focus and do not clickable. Sample code:

View v = findViewById(R.id.button1);
v.setOnClickListener(new OnClickListener() {

     @Override
     public void onClick(View v) {
        Toast.makeText(MainActivity.this, "Click!", Toast.LENGTH_SHORT).show();
     }
});
ObjectAnimator moveDown = ObjectAnimator.ofFloat(v, "translationY", 100f);
moveDown.setDuration(5000);
moveDown.start();
Run Code Online (Sandbox Code Playgroud)

This is a bug in the library or something I'm doing wrong? …

animation android

8
推荐指数
1
解决办法
4239
查看次数

标签 统计

android ×1

animation ×1