Wayfinding Instructions
Android v4
private var mRoute: MPRoute? = null
private var mLocation: MPLocation? = nulloverride fun onCreateView(view: View, @Nullable savedInstanceState: Bundle?) {
_binding = FragmentWayfindingBinding.inflate(inflater, container, false)
MapsIndoors.load(requireActivity().applicationContext, "gettingstarted", null)
val routeLegAdapter = RouteCollectionAdapter(this)
val viewPager = binding.stepViewPager
viewPager.adapter = routeLegAdapter
viewPager.registerOnPageChangeCallback(object : ViewPager2.OnPageChangeCallback() {
override fun onPageSelected(position: Int) {
super.onPageSelected(position)
}
})
val root: View = binding.root
val supportMapFragment = childFragmentManager.findFragmentById(R.id.map) as SupportMapFragment
mMapView = supportMapFragment.view
supportMapFragment.getMapAsync(this)
return root
}Last updated
Was this helpful?