mirror of
https://github.com/lacerta-doc/Lacerta.git
synced 2024-11-23 00:13:16 +00:00
parent
113a2fd3d2
commit
d8d8a5932b
|
@ -3,22 +3,17 @@ package one.nem.lacerta.feature.library;
|
||||||
import android.os.Bundle;
|
import android.os.Bundle;
|
||||||
|
|
||||||
import androidx.fragment.app.Fragment;
|
import androidx.fragment.app.Fragment;
|
||||||
import androidx.fragment.app.FragmentContainerView;
|
|
||||||
|
|
||||||
import android.view.LayoutInflater;
|
import android.view.LayoutInflater;
|
||||||
import android.view.View;
|
import android.view.View;
|
||||||
import android.view.ViewGroup;
|
import android.view.ViewGroup;
|
||||||
|
|
||||||
import one.nem.lacerta.model.FragmentNavigation;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* A simple {@link Fragment} subclass.
|
* A simple {@link Fragment} subclass.
|
||||||
* Use the {@link LibraryContainerFragment#newInstance} factory method to
|
* Use the {@link LibraryContainerFragment#newInstance} factory method to
|
||||||
* create an instance of this fragment.
|
* create an instance of this fragment.
|
||||||
*/
|
*/
|
||||||
public class LibraryContainerFragment extends Fragment implements FragmentNavigation {
|
public class LibraryContainerFragment extends Fragment {
|
||||||
|
|
||||||
FragmentContainerView fragmentContainerView;
|
|
||||||
|
|
||||||
public LibraryContainerFragment() {
|
public LibraryContainerFragment() {
|
||||||
// Required empty public constructor
|
// Required empty public constructor
|
||||||
|
@ -42,31 +37,4 @@ public class LibraryContainerFragment extends Fragment implements FragmentNaviga
|
||||||
// Inflate the layout for this fragment
|
// Inflate the layout for this fragment
|
||||||
return inflater.inflate(R.layout.fragment_library_container, container, false);
|
return inflater.inflate(R.layout.fragment_library_container, container, false);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
|
||||||
public void onViewCreated(View view, Bundle savedInstanceState) {
|
|
||||||
super.onViewCreated(view, savedInstanceState);
|
|
||||||
fragmentContainerView = view.findViewById(R.id.fragmentContainerView);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void navigateToFragment(Fragment fragment) {
|
|
||||||
this.navigateToFragment(fragment, true);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void navigateToFragment(Fragment fragment, boolean addToBackStack) {
|
|
||||||
this.navigateToFragment(fragment, addToBackStack, false);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void navigateToFragment(Fragment fragment, boolean addToBackStack, boolean clearBackStack) {
|
|
||||||
if (fragmentContainerView != null) {
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void navigateToFragmentAlternate(Fragment fragment, boolean addToBackStack) {
|
|
||||||
|
|
||||||
}
|
|
||||||
}
|
}
|
|
@ -3,10 +3,10 @@
|
||||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
xmlns:tools="http://schemas.android.com/tools"
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
android:id="@+id/feature_library_navigation"
|
android:id="@+id/feature_library_navigation"
|
||||||
app:startDestination="@id/libraryContainerFragment">
|
app:startDestination="@id/feature_library_top_fragment">
|
||||||
<fragment
|
<fragment
|
||||||
android:id="@+id/libraryContainerFragment"
|
android:id="@+id/feature_library_top_fragment"
|
||||||
android:name="one.nem.lacerta.feature.library.LibraryContainerFragment"
|
android:name="one.nem.lacerta.feature.library.LibraryPageFragment"
|
||||||
android:label="fragment_library_container"
|
android:label="fragment_library_top"
|
||||||
tools:layout="@layout/fragment_library_container" />
|
tools:layout="@layout/fragment_library_top" />
|
||||||
</navigation>
|
</navigation>
|
|
@ -1,5 +1,3 @@
|
||||||
<resources>
|
<resources>
|
||||||
<string name="app_name">Library</string>
|
<string name="app_name">Library</string>
|
||||||
<!-- TODO: Remove or change this placeholder text -->
|
|
||||||
<string name="hello_blank_fragment">Hello blank fragment</string>
|
|
||||||
</resources>
|
</resources>
|
|
@ -8,7 +8,7 @@ public class FeatureSwitch {
|
||||||
|
|
||||||
public static class FeatureMaster {
|
public static class FeatureMaster {
|
||||||
public static boolean enableSearch = false;
|
public static boolean enableSearch = false;
|
||||||
public static boolean enableDebugMenu = true;
|
public static boolean enableDebugMenu = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
public static class Setting {
|
public static class Setting {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user