Skip to content

Commit

Permalink
Minor code improvement
Browse files Browse the repository at this point in the history
  • Loading branch information
hannesa2 committed Mar 22, 2024
1 parent 6ba0e64 commit 5a0a2c8
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ class FragmentCar : Fragment(), SurfaceHolder.Callback {
override fun onViewCreated(view: View, savedInstanceState: Bundle?) {
mSceneThread = VehicleSceneThread("VehicleSceneThread", requireContext())
// As the activity is not guaranteed to be created in the Fragments onCreate callback call RamsesThreads initRamsesThreadAndLoadScene here
mSceneThread.initRamsesThreadAndLoadScene(activity!!.assets, "G05.ramses", "G05.rlogic")
mSceneThread.initRamsesThreadAndLoadScene(requireActivity().assets, "G05.ramses", "G05.rlogic")

// Add the addOnWindowFocusChangeListener as it is not supported by default by Fragments
mView!!.viewTreeObserver.addOnWindowFocusChangeListener { hasFocus ->
Expand Down

0 comments on commit 5a0a2c8

Please # to comment.