Skip to content

Commit

Permalink
Merge pull request #4659 from nextcloud/changing-btn-layout-date-time…
Browse files Browse the repository at this point in the history
…-fragment

Switched the "Close" and "Set" Buttons in the remind-me-later dialog
  • Loading branch information
mahibi authored Jan 28, 2025
2 parents 0918cdd + 25df519 commit c58df32
Showing 1 changed file with 9 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -151,29 +151,29 @@ class DateTimeCompose(val bundle: Bundle) {

TextButton(
onClick = {
val user = userManager.currentUser.blockingGet()
val roomToken = bundle.getString(BundleKeys.KEY_ROOM_TOKEN)!!
val messageId = bundle.getString(BundleKeys.KEY_MESSAGE_ID)!!
val apiVersion = bundle.getInt(BundleKeys.KEY_CHAT_API_VERSION)
val offset = timeState.value.atZone(ZoneOffset.systemDefault()).offset
val timeVal = timeState.value.toEpochSecond(offset)
chatViewModel.setReminder(user, roomToken, messageId, timeVal.toInt(), apiVersion)
shouldDismiss.value = true
},
modifier = Modifier
.weight(CUBED_PADDING)
) {
Text(stringResource(R.string.set))
Text(stringResource(R.string.close))
}

TextButton(
onClick = {
val user = userManager.currentUser.blockingGet()
val roomToken = bundle.getString(BundleKeys.KEY_ROOM_TOKEN)!!
val messageId = bundle.getString(BundleKeys.KEY_MESSAGE_ID)!!
val apiVersion = bundle.getInt(BundleKeys.KEY_CHAT_API_VERSION)
val offset = timeState.value.atZone(ZoneOffset.systemDefault()).offset
val timeVal = timeState.value.toEpochSecond(offset)
chatViewModel.setReminder(user, roomToken, messageId, timeVal.toInt(), apiVersion)
shouldDismiss.value = true
},
modifier = Modifier
.weight(CUBED_PADDING)
) {
Text(stringResource(R.string.close))
Text(stringResource(R.string.set))
}
}
}
Expand Down

0 comments on commit c58df32

Please sign in to comment.