Code example for ViewSwitcher

Methods: getDisplayedChild, showNext, showPrevious

0
                		    Bitmap ThumbImage = BitmapFactory.decodeFile(separated[count_img_play],bfo); 
 
                		    Drawable drawableImage = new BitmapDrawable(getResources(),ThumbImage); 
                		    Log.i("drawableImage", separated[count_img_play]);
                		    //image_nxt.setImageDrawable(drawableImage); 
                		    Log.i("position", switcher.getDisplayedChild()+"");
                		    //ImageViewAnimatedChange(context,image,drawableImage); 
                		    //switcher.showNext(); 
                		     
                		    if (switcher.getDisplayedChild() == 0) {
                		    	image_nxt.setImageDrawable(drawableImage);
                                switcher.showNext();
                            } else { 
                            	image.setImageDrawable(drawableImage);
                                switcher.showPrevious();
                            } 
                		     
                		     
                		    Log.i("position11", switcher.getDisplayedChild()+"");
                		     
                		     
                         } 
                         count_img_play++; //count_img_play = ++count_img_play % separated.length;
                        }