<Button android:id="@+id/button_animate" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_alignParentBottom="true" android:layout_centerHorizontal="true" android:layout_marginBottom="140dp" android:text="Animate" /> <Button android:id="@+id/button_layout" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_alignParentBottom="true" android:layout_centerHorizontal="true" android:layout_marginBottom="75dp" android:text="Go to second layout" />
---------------------------------------
-----------------------------------------public void openActivity2(){ Intent intent = new Intent(this, Main2Activity.class); startActivity(intent); overridePendingTransition(R.anim.slide_in_right,R.anim.slide_out_left); /* TextView nom_pizza=findViewById(R.id.textView_nomPizza);
TextView nbPersonne=findViewById(R.id.textView_nombreDePersonne); TextView tempDecoock=findViewById(R.id.textView_tempDeCoock); TextView tempDeprepa=findViewById(R.id.textView_tempDePreparation); String nomPizza=nom_pizza.getText().toString(); intent.putExtra("NomPizza",nomPizza);*/ }