Formating & remove unused comments

This commit is contained in:
ariskotsomitopoulos 2022-01-31 14:52:09 +02:00
parent ec9b6aa993
commit f07c23fdda
2 changed files with 1 additions and 21 deletions

View File

@ -1796,7 +1796,6 @@ class TimelineFragment @Inject constructor(
} }
// TimelineEventController.Callback ************************************************************ // TimelineEventController.Callback ************************************************************
override fun onUrlClicked(url: String, title: String): Boolean { override fun onUrlClicked(url: String, title: String): Boolean {
viewLifecycleOwner.lifecycleScope.launch { viewLifecycleOwner.lifecycleScope.launch {
val isManaged = permalinkHandler val isManaged = permalinkHandler
@ -1906,28 +1905,12 @@ class TimelineFragment @Inject constructor(
} }
} }
// override fun onFileMessageClicked(eventId: String, messageFileContent: MessageFileContent) {
// val isEncrypted = messageFileContent.encryptedFileInfo != null
// val action = RoomDetailAction.DownloadOrOpen(eventId, messageFileContent, isEncrypted)
// // We need WRITE_EXTERNAL permission
// // if (!isEncrypted || checkPermissions(PERMISSIONS_FOR_WRITING_FILES, this, PERMISSION_REQUEST_CODE_DOWNLOAD_FILE)) {
// showSnackWithMessage(getString(R.string.downloading_file, messageFileContent.getFileName()))
// roomDetailViewModel.handle(action)
// // } else {
// // roomDetailViewModel.pendingAction = action
// // }
// }
private fun cleanUpAfterPermissionNotGranted() { private fun cleanUpAfterPermissionNotGranted() {
// Reset all pending data // Reset all pending data
timelineViewModel.pendingAction = null timelineViewModel.pendingAction = null
attachmentsHelper.pendingType = null attachmentsHelper.pendingType = null
} }
// override fun onAudioMessageClicked(messageAudioContent: MessageAudioContent) {
// vectorBaseActivity.notImplemented("open audio file")
// }
override fun onLoadMore(direction: Timeline.Direction) { override fun onLoadMore(direction: Timeline.Direction) {
timelineViewModel.handle(RoomDetailAction.LoadMoreTimelineEvents(direction)) timelineViewModel.handle(RoomDetailAction.LoadMoreTimelineEvents(direction))
} }
@ -2377,7 +2360,6 @@ class TimelineFragment @Inject constructor(
} }
// VectorInviteView.Callback // VectorInviteView.Callback
override fun onAcceptInvite() { override fun onAcceptInvite() {
notificationDrawerManager.updateEvents { it.clearMemberShipNotificationForRoom(timelineArgs.roomId) } notificationDrawerManager.updateEvents { it.clearMemberShipNotificationForRoom(timelineArgs.roomId) }
timelineViewModel.handle(RoomDetailAction.AcceptInvite) timelineViewModel.handle(RoomDetailAction.AcceptInvite)
@ -2398,7 +2380,6 @@ class TimelineFragment @Inject constructor(
} }
// AttachmentTypeSelectorView.Callback // AttachmentTypeSelectorView.Callback
private val typeSelectedActivityResultLauncher = registerForPermissionsResult { allGranted, deniedPermanently -> private val typeSelectedActivityResultLauncher = registerForPermissionsResult { allGranted, deniedPermanently ->
if (allGranted) { if (allGranted) {
val pendingType = attachmentsHelper.pendingType val pendingType = attachmentsHelper.pendingType
@ -2449,7 +2430,6 @@ class TimelineFragment @Inject constructor(
} }
// AttachmentsHelper.Callback // AttachmentsHelper.Callback
override fun onContentAttachmentsReady(attachments: List<ContentAttachmentData>) { override fun onContentAttachmentsReady(attachments: List<ContentAttachmentData>) {
val grouped = attachments.toGroupedContentAttachmentData() val grouped = attachments.toGroupedContentAttachmentData()
if (grouped.notPreviewables.isNotEmpty()) { if (grouped.notPreviewables.isNotEmpty()) {