Skip to content

Commit dc83aba

Browse files
authored
Make ContentAvoidingLayoutData an immutable data class (#4999)
1 parent f099959 commit dc83aba

File tree

1 file changed

+4
-5
lines changed
  • features/messages/impl/src/main/kotlin/io/element/android/features/messages/impl/timeline/components/layout

1 file changed

+4
-5
lines changed

features/messages/impl/src/main/kotlin/io/element/android/features/messages/impl/timeline/components/layout/ContentAvoidingLayout.kt

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -112,12 +112,11 @@ fun ContentAvoidingLayout(
112112
* @param nonOverlappingContentWidth The width of the part of the content that can't overlap with the timestamp.
113113
* @param nonOverlappingContentHeight The height of the part of the content that can't overlap with the timestamp.
114114
*/
115-
@Suppress("DataClassShouldBeImmutable")
116115
data class ContentAvoidingLayoutData(
117-
var contentWidth: Int = 0,
118-
var contentHeight: Int = 0,
119-
var nonOverlappingContentWidth: Int = contentWidth,
120-
var nonOverlappingContentHeight: Int = contentHeight,
116+
val contentWidth: Int = 0,
117+
val contentHeight: Int = 0,
118+
val nonOverlappingContentWidth: Int = contentWidth,
119+
val nonOverlappingContentHeight: Int = contentHeight,
121120
)
122121

123122
/**

0 commit comments

Comments
 (0)