728x90

    ImageSwitcher imageSwitcher = (ImageSwitcher)findViewById(R.id.view);
    
            imageSwitcher.setFactory(new ViewSwitcher.ViewFactory() {
    
                @Override
    
                public View makeView() {
    
                    ImageView imageView = new ImageView(getApplicationContext());
    
                    return imageView;
    
                }
    
            });
    
     
    
      //기본애니메이션 in, out 가져오기
    
            Animation in = AnimationUtils.loadAnimation(this, android.R.anim.slide_in_left);
    
            Animation out = AnimationUtils.loadAnimation(this, android.R.anim.slide_out_right);
    
           
    
    
    
           //애니메이션 설정
    
            imageSwitcher.setInAnimation(in);
    
            imageSwitcher.setOutAnimation(out);
    

    Posted by 천상나타