Skip to content

Instantly share code, notes, and snippets.

@codingwithsara
Created July 18, 2019 02:16
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save codingwithsara/87f4302f51c780951d71e4f2664e5ef0 to your computer and use it in GitHub Desktop.
Save codingwithsara/87f4302f51c780951d71e4f2664e5ef0 to your computer and use it in GitHub Desktop.
Activity Animation
package jp.codeforfun.activityanimation;
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import android.view.View;
public class MainActivity extends AppCompatActivity implements View.OnClickListener {
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
// クリックリスナーをセット
findViewById(R.id.normalBtn).setOnClickListener(this);
findViewById(R.id.fadeBtn).setOnClickListener(this);
findViewById(R.id.slideBtn).setOnClickListener(this);
}
@Override
public void onClick(View v) {
// ボタンが押された時の処理を書きます
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment