mirror of
https://github.com/element-hq/element-android
synced 2024-11-24 18:35:40 +03:00
Using @AndroidEntryPoint for map fragment
This commit is contained in:
parent
7f2279c8a8
commit
1756fa26e1
2 changed files with 4 additions and 7 deletions
|
@ -64,7 +64,6 @@ import im.vector.app.features.home.room.list.RoomListFragment
|
|||
import im.vector.app.features.home.room.threads.list.views.ThreadListFragment
|
||||
import im.vector.app.features.location.LocationPreviewFragment
|
||||
import im.vector.app.features.location.LocationSharingFragment
|
||||
import im.vector.app.features.location.live.map.LocationLiveMapViewFragment
|
||||
import im.vector.app.features.login.LoginCaptchaFragment
|
||||
import im.vector.app.features.login.LoginFragment
|
||||
import im.vector.app.features.login.LoginGenericTextInputFormFragment
|
||||
|
@ -1006,9 +1005,4 @@ interface FragmentModule {
|
|||
@IntoMap
|
||||
@FragmentKey(LocationPreviewFragment::class)
|
||||
fun bindLocationPreviewFragment(fragment: LocationPreviewFragment): Fragment
|
||||
|
||||
@Binds
|
||||
@IntoMap
|
||||
@FragmentKey(LocationLiveMapViewFragment::class)
|
||||
fun bindLocationLiveMapViewFragment(fragment: LocationLiveMapViewFragment): Fragment
|
||||
}
|
||||
|
|
|
@ -33,6 +33,7 @@ import com.mapbox.mapboxsdk.maps.SupportMapFragment
|
|||
import com.mapbox.mapboxsdk.plugins.annotation.SymbolManager
|
||||
import com.mapbox.mapboxsdk.plugins.annotation.SymbolOptions
|
||||
import com.mapbox.mapboxsdk.style.layers.Property
|
||||
import dagger.hilt.android.AndroidEntryPoint
|
||||
import im.vector.app.R
|
||||
import im.vector.app.core.extensions.addChildFragment
|
||||
import im.vector.app.core.platform.VectorBaseFragment
|
||||
|
@ -48,10 +49,12 @@ import javax.inject.Inject
|
|||
/**
|
||||
* Screen showing a map with all the current users sharing their live location in a room.
|
||||
*/
|
||||
@AndroidEntryPoint
|
||||
class LocationLiveMapViewFragment @Inject constructor(
|
||||
private var urlMapProvider: UrlMapProvider,
|
||||
) : VectorBaseFragment<FragmentSimpleContainerBinding>() {
|
||||
|
||||
@Inject lateinit var urlMapProvider: UrlMapProvider
|
||||
|
||||
private val viewModel: LocationLiveMapViewModel by fragmentViewModel()
|
||||
|
||||
private var mapboxMap: WeakReference<MapboxMap>? = null
|
||||
|
|
Loading…
Reference in a new issue