Renamed class and function
This commit is contained in:
@@ -272,7 +272,7 @@ public class MainActivity extends AppCompatActivity
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onFragmentInteraction(Uri uri) {
|
||||
public void onScheduleFragmentInteraction(Uri uri) {
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -16,12 +16,12 @@ import de.sebse.fuplanner.tools.ui.ItemViewHolder;
|
||||
* specified {@link OnModulesFragmentInteractionListener}.
|
||||
* TODO: Replace the implementation with code for your data type.
|
||||
*/
|
||||
public class ModulesRecyclerViewAdapter extends RecyclerView.Adapter<ItemViewHolder> {
|
||||
public class ModulesAdapter extends RecyclerView.Adapter<ItemViewHolder> {
|
||||
|
||||
private Modules mValues;
|
||||
private final OnModulesFragmentInteractionListener mListener;
|
||||
|
||||
public ModulesRecyclerViewAdapter(OnModulesFragmentInteractionListener listener) {
|
||||
public ModulesAdapter(OnModulesFragmentInteractionListener listener) {
|
||||
mValues = null;
|
||||
mListener = listener;
|
||||
}
|
||||
@@ -30,7 +30,7 @@ public class ModulesFragment extends Fragment {
|
||||
// TODO: Customize parameters
|
||||
private OnModulesFragmentInteractionListener mListener;
|
||||
private Logger log = new Logger(this);
|
||||
private ModulesRecyclerViewAdapter adapter;
|
||||
private ModulesAdapter adapter;
|
||||
private SwipeRefreshLayout swipeLayout;
|
||||
|
||||
/**
|
||||
@@ -63,7 +63,7 @@ public class ModulesFragment extends Fragment {
|
||||
Context context = view.getContext();
|
||||
RecyclerView recyclerView = view.findViewById(R.id.list);
|
||||
recyclerView.setLayoutManager(new LinearLayoutManager(context));
|
||||
adapter = new ModulesRecyclerViewAdapter(mListener);
|
||||
adapter = new ModulesAdapter(mListener);
|
||||
recyclerView.setAdapter(adapter);
|
||||
|
||||
// Getting SwipeContainerLayout
|
||||
|
||||
@@ -103,7 +103,7 @@ public class ScheduleFragment extends Fragment implements WeekView.EventClickLis
|
||||
// TODO: Rename method, update argument and hook method into UI event
|
||||
public void onButtonPressed(Uri uri) {
|
||||
if (mListener != null) {
|
||||
mListener.onFragmentInteraction(uri);
|
||||
mListener.onScheduleFragmentInteraction(uri);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -172,6 +172,6 @@ public class ScheduleFragment extends Fragment implements WeekView.EventClickLis
|
||||
*/
|
||||
public interface OnFragmentInteractionListener {
|
||||
// TODO: Update argument type and name
|
||||
void onFragmentInteraction(Uri uri);
|
||||
void onScheduleFragmentInteraction(Uri uri);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user