2024-01-17 07:55:44 +00:00
|
|
|
package com.example.childguard;
|
|
|
|
|
|
|
|
import android.os.Bundle;
|
|
|
|
|
|
|
|
import androidx.fragment.app.Fragment;
|
|
|
|
|
|
|
|
import android.view.LayoutInflater;
|
|
|
|
import android.view.View;
|
|
|
|
import android.view.ViewGroup;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* A simple {@link Fragment} subclass.
|
|
|
|
* Use the {@link SettingFragment#newInstance} factory method to
|
|
|
|
* create an instance of this fragment.
|
|
|
|
*/
|
|
|
|
public class SettingFragment extends Fragment {
|
|
|
|
public SettingFragment() {
|
|
|
|
// Required empty public constructor
|
|
|
|
}
|
|
|
|
|
2024-01-17 07:56:14 +00:00
|
|
|
public static SettingFragment newInstance() {
|
2024-01-17 07:55:44 +00:00
|
|
|
SettingFragment fragment = new SettingFragment();
|
|
|
|
Bundle args = new Bundle();
|
|
|
|
fragment.setArguments(args);
|
|
|
|
return fragment;
|
|
|
|
}
|
|
|
|
|
|
|
|
@Override
|
|
|
|
public void onCreate(Bundle savedInstanceState) {
|
|
|
|
super.onCreate(savedInstanceState);
|
|
|
|
}
|
|
|
|
|
|
|
|
@Override
|
|
|
|
public View onCreateView(LayoutInflater inflater, ViewGroup container,
|
|
|
|
Bundle savedInstanceState) {
|
|
|
|
// Inflate the layout for this fragment
|
|
|
|
return inflater.inflate(R.layout.fragment_setting, container, false);
|
|
|
|
}
|
2024-01-17 08:23:07 +00:00
|
|
|
|
|
|
|
@Override
|
|
|
|
public void onViewCreated(View view, Bundle savedInstanceState) {
|
|
|
|
super.onViewCreated(view, savedInstanceState);
|
|
|
|
|
|
|
|
view.findViewById(R.id.button_bluetooth_setting).setOnClickListener( v -> {
|
|
|
|
getParentFragmentManager().beginTransaction().replace(R.id.fragmentContainerView, bluetooth_setupFragment.newInstance("test", "test")).commit();
|
|
|
|
});
|
|
|
|
|
|
|
|
}
|
2024-01-17 07:55:44 +00:00
|
|
|
}
|