From 72a945ac1327114881a60b19dfacbe4e3ea3ae31 Mon Sep 17 00:00:00 2001 From: ariskotsomitopoulos Date: Mon, 16 May 2022 13:32:30 +0300 Subject: [PATCH] PR remarks --- library/ui-styles/src/main/res/values/colors.xml | 4 ++-- .../app/features/home/room/detail/TimelineFragment.kt | 6 +++++- .../home/room/detail/search/SearchResultItem.kt | 10 +++++----- vector/src/main/res/layout/item_search_result.xml | 2 +- 4 files changed, 13 insertions(+), 9 deletions(-) diff --git a/library/ui-styles/src/main/res/values/colors.xml b/library/ui-styles/src/main/res/values/colors.xml index 3217622ed0..80541b1803 100644 --- a/library/ui-styles/src/main/res/values/colors.xml +++ b/library/ui-styles/src/main/res/values/colors.xml @@ -138,7 +138,7 @@ - #FFFFFF - #21262C + @color/palette_white + @color/palette_black_950 diff --git a/vector/src/main/java/im/vector/app/features/home/room/detail/TimelineFragment.kt b/vector/src/main/java/im/vector/app/features/home/room/detail/TimelineFragment.kt index 9d36fdc580..de8955256d 100644 --- a/vector/src/main/java/im/vector/app/features/home/room/detail/TimelineFragment.kt +++ b/vector/src/main/java/im/vector/app/features/home/room/detail/TimelineFragment.kt @@ -2443,7 +2443,11 @@ class TimelineFragment @Inject constructor( private fun onReplyInThreadClicked(action: EventSharedAction.ReplyInThread) { if (vectorPreferences.areThreadMessagesEnabled()) { - navigateToThreadTimeline(action.eventId, action.startsThread, true) + navigateToThreadTimeline( + rootThreadEventId = action.eventId, + startsThread = action.startsThread, + showKeyboard = true + ) } else { displayThreadsBetaOptInDialog() } diff --git a/vector/src/main/java/im/vector/app/features/home/room/detail/search/SearchResultItem.kt b/vector/src/main/java/im/vector/app/features/home/room/detail/search/SearchResultItem.kt index 1fd099aced..d92dcdd3ef 100644 --- a/vector/src/main/java/im/vector/app/features/home/room/detail/search/SearchResultItem.kt +++ b/vector/src/main/java/im/vector/app/features/home/room/detail/search/SearchResultItem.kt @@ -67,24 +67,24 @@ abstract class SearchResultItem : VectorEpoxyModel() { val displayName = it.threadSummarySenderInfo?.displayName val avatarUrl = it.threadSummarySenderInfo?.avatarUrl avatarRenderer.render(MatrixItem.UserItem(userId, displayName, avatarUrl), holder.threadSummaryAvatarImageView) - holder.threadSummaryConstraintLayout.onClick(threadSummaryListener) + holder.threadSummaryContainer.onClick(threadSummaryListener) } else { showFromThread(holder) } } ?: run { - holder.threadSummaryConstraintLayout.isVisible = false + holder.threadSummaryContainer.isVisible = false holder.fromThreadConstraintLayout.isVisible = false } } } private fun showThreadSummary(holder: Holder, show: Boolean = true) { - holder.threadSummaryConstraintLayout.isVisible = show + holder.threadSummaryContainer.isVisible = show holder.fromThreadConstraintLayout.isVisible = !show } private fun showFromThread(holder: Holder, show: Boolean = true) { - holder.threadSummaryConstraintLayout.isVisible = !show + holder.threadSummaryContainer.isVisible = !show holder.fromThreadConstraintLayout.isVisible = show } @@ -93,7 +93,7 @@ abstract class SearchResultItem : VectorEpoxyModel() { val memberNameView by bind(R.id.messageMemberNameView) val timeView by bind(R.id.messageTimeView) val contentView by bind(R.id.messageContentView) - val threadSummaryConstraintLayout by bind(R.id.searchThreadSummaryConstraintLayout) + val threadSummaryContainer by bind(R.id.searchThreadSummaryContainer) val threadSummaryCounterTextView by bind(R.id.messageThreadSummaryCounterTextView) val threadSummaryAvatarImageView by bind(R.id.messageThreadSummaryAvatarImageView) val threadSummaryInfoTextView by bind(R.id.messageThreadSummaryInfoTextView) diff --git a/vector/src/main/res/layout/item_search_result.xml b/vector/src/main/res/layout/item_search_result.xml index 3264a7d230..6f6528c93b 100644 --- a/vector/src/main/res/layout/item_search_result.xml +++ b/vector/src/main/res/layout/item_search_result.xml @@ -63,7 +63,7 @@ tools:text="@sample/messages.json/data/message" />