Added possibility to select file path in diff
This commit is contained in:
parent
2c321e303a
commit
e2cf95712a
@ -795,39 +795,43 @@ private fun DiffHeader(
|
|||||||
val fileName = diffEntry.fileName
|
val fileName = diffEntry.fileName
|
||||||
val dirPath: String = diffEntry.parentDirectoryPath
|
val dirPath: String = diffEntry.parentDirectoryPath
|
||||||
|
|
||||||
Row(Modifier.weight(1f, true)) {
|
SelectionContainer {
|
||||||
if (dirPath.isNotEmpty()) {
|
Row {
|
||||||
Text(
|
if (dirPath.isNotEmpty()) {
|
||||||
text = dirPath.removeSuffix("/"),
|
Text(
|
||||||
style = MaterialTheme.typography.body2,
|
text = dirPath.removeSuffix("/"),
|
||||||
color = MaterialTheme.colors.onBackgroundSecondary,
|
style = MaterialTheme.typography.body2,
|
||||||
maxLines = 1,
|
color = MaterialTheme.colors.onBackgroundSecondary,
|
||||||
softWrap = false,
|
maxLines = 1,
|
||||||
overflow = TextOverflow.Ellipsis,
|
softWrap = false,
|
||||||
fontWeight = FontWeight.Medium,
|
overflow = TextOverflow.Ellipsis,
|
||||||
modifier = Modifier
|
fontWeight = FontWeight.Medium,
|
||||||
.weight(1f, false),
|
modifier = Modifier
|
||||||
)
|
.weight(1f, false),
|
||||||
|
)
|
||||||
|
|
||||||
|
Text(
|
||||||
|
text = "/",
|
||||||
|
maxLines = 1,
|
||||||
|
softWrap = false,
|
||||||
|
style = MaterialTheme.typography.body2,
|
||||||
|
overflow = TextOverflow.Visible,
|
||||||
|
color = MaterialTheme.colors.onBackgroundSecondary,
|
||||||
|
)
|
||||||
|
}
|
||||||
Text(
|
Text(
|
||||||
text = "/",
|
text = fileName,
|
||||||
maxLines = 1,
|
|
||||||
softWrap = false,
|
|
||||||
style = MaterialTheme.typography.body2,
|
style = MaterialTheme.typography.body2,
|
||||||
overflow = TextOverflow.Visible,
|
color = MaterialTheme.colors.onBackground,
|
||||||
color = MaterialTheme.colors.onBackgroundSecondary,
|
fontWeight = FontWeight.Medium,
|
||||||
|
maxLines = 1,
|
||||||
|
modifier = Modifier.padding(end = 16.dp),
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
Text(
|
|
||||||
text = fileName,
|
|
||||||
style = MaterialTheme.typography.body2,
|
|
||||||
color = MaterialTheme.colors.onBackground,
|
|
||||||
fontWeight = FontWeight.Medium,
|
|
||||||
maxLines = 1,
|
|
||||||
modifier = Modifier.padding(end = 16.dp),
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Spacer(Modifier.weight(1f, true))
|
||||||
|
|
||||||
|
|
||||||
Row(
|
Row(
|
||||||
verticalAlignment = Alignment.CenterVertically,
|
verticalAlignment = Alignment.CenterVertically,
|
||||||
|
Loading…
Reference in New Issue
Block a user