コード例 #1
0
  @Override
  protected void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.activity_main);

    GifMovieView gif1 = new GifMovieView(this);
    gif1.setMovieResource(R.drawable.gif_heart);
    setContentView(gif1);
  }
コード例 #2
0
 public void onGifClick(View v) {
   GifMovieView gif = (GifMovieView) v;
   gif.setPaused(!gif.isPaused());
 }