package me.brysonsteck.wiimmfiwatcher; import android.content.ClipData; import android.os.Bundle; import android.view.View; import androidx.appcompat.app.AppCompatActivity; import androidx.databinding.ObservableArrayList; import me.brysonsteck.wiimmfiwatcher.database.AppDatabase; import me.brysonsteck.wiimmfiwatcher.model.FriendCode; public class MainActivity extends AppCompatActivity { ObservableArrayList recentFCList = new ObservableArrayList<>(); AppDatabase database; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); if (savedInstanceState == null) { getSupportFragmentManager().beginTransaction() .replace(R.id.friend_code_input_fragment, new WatchCodeFragment(), null) .setReorderingAllowed(true) .commit(); } setContentView(R.layout.activity_main); View aboutButton = findViewById(R.id.about_button); aboutButton.setOnClickListener((about) -> { getSupportFragmentManager().beginTransaction() .replace(R.id.friend_code_input_fragment, new AboutFragment(), null) .setReorderingAllowed(true) .addToBackStack(null) .commit(); }); } }