Merge pull request #6667 from vector-im/feature/bma/group_cleanup_2

Group cleanup
This commit is contained in:
Benoit Marty 2022-07-29 15:32:05 +02:00 committed by GitHub
commit fa8f110579
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 9 additions and 5 deletions

View File

@ -31,21 +31,25 @@ import im.vector.app.core.extensions.cleanup
import im.vector.app.core.extensions.configureWith import im.vector.app.core.extensions.configureWith
import im.vector.app.core.platform.StateView import im.vector.app.core.platform.StateView
import im.vector.app.core.platform.VectorBaseFragment import im.vector.app.core.platform.VectorBaseFragment
import im.vector.app.databinding.FragmentGroupListBinding import im.vector.app.databinding.FragmentSpaceListBinding
import im.vector.app.features.home.HomeActivitySharedAction import im.vector.app.features.home.HomeActivitySharedAction
import im.vector.app.features.home.HomeSharedActionViewModel import im.vector.app.features.home.HomeSharedActionViewModel
import org.matrix.android.sdk.api.session.room.model.RoomSummary import org.matrix.android.sdk.api.session.room.model.RoomSummary
import javax.inject.Inject import javax.inject.Inject
/**
* This Fragment is displayed in the navigation drawer [im.vector.app.features.home.HomeDrawerFragment] and
* is displaying the space hierarchy, with some actions on Spaces.
*/
class SpaceListFragment @Inject constructor( class SpaceListFragment @Inject constructor(
private val spaceController: SpaceSummaryController private val spaceController: SpaceSummaryController
) : VectorBaseFragment<FragmentGroupListBinding>(), SpaceSummaryController.Callback { ) : VectorBaseFragment<FragmentSpaceListBinding>(), SpaceSummaryController.Callback {
private lateinit var sharedActionViewModel: HomeSharedActionViewModel private lateinit var sharedActionViewModel: HomeSharedActionViewModel
private val viewModel: SpaceListViewModel by fragmentViewModel() private val viewModel: SpaceListViewModel by fragmentViewModel()
override fun getBinding(inflater: LayoutInflater, container: ViewGroup?): FragmentGroupListBinding { override fun getBinding(inflater: LayoutInflater, container: ViewGroup?): FragmentSpaceListBinding {
return FragmentGroupListBinding.inflate(inflater, container, false) return FragmentSpaceListBinding.inflate(inflater, container, false)
} }
override fun onViewCreated(view: View, savedInstanceState: Bundle?) { override fun onViewCreated(view: View, savedInstanceState: Bundle?) {

View File

@ -10,6 +10,6 @@
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="match_parent"
android:overScrollMode="always" android:overScrollMode="always"
tools:listitem="@layout/item_group" /> tools:listitem="@layout/item_space" />
</im.vector.app.core.platform.StateView> </im.vector.app.core.platform.StateView>