mirror of
https://github.com/gitui-org/gitui
synced 2026-05-23 17:08:21 +00:00
give file list more screenspace share compared to commit message (#436)
This commit is contained in:
parent
8bee1f57cc
commit
c0b8c5a0a6
1 changed files with 10 additions and 2 deletions
|
|
@ -115,12 +115,20 @@ impl DrawableComponent for CommitDetailsComponent {
|
|||
f: &mut Frame<B>,
|
||||
rect: Rect,
|
||||
) -> Result<()> {
|
||||
let percentages = if self.file_tree.focused() {
|
||||
(40, 60)
|
||||
} else if self.details.focused() {
|
||||
(60, 40)
|
||||
} else {
|
||||
(40, 60)
|
||||
};
|
||||
|
||||
let chunks = Layout::default()
|
||||
.direction(Direction::Vertical)
|
||||
.constraints(
|
||||
[
|
||||
Constraint::Percentage(60),
|
||||
Constraint::Percentage(40),
|
||||
Constraint::Percentage(percentages.0),
|
||||
Constraint::Percentage(percentages.1),
|
||||
]
|
||||
.as_ref(),
|
||||
)
|
||||
|
|
|
|||
Loading…
Reference in a new issue