mirror of
https://github.com/extrawurst/gitui.git
synced 2024-11-27 00:14:52 +03:00
cleanup
This commit is contained in:
parent
aaf0e4cfbf
commit
3b5d43ecb2
@ -6,7 +6,7 @@ use super::{
|
||||
use crate::{
|
||||
keys::SharedKeyConfig,
|
||||
queue::{InternalEvent, Queue},
|
||||
strings::{self, order},
|
||||
strings::{self, order, symbol},
|
||||
ui::{self, common_nav, style::SharedTheme},
|
||||
AsyncAppNotification, AsyncNotification,
|
||||
};
|
||||
@ -27,10 +27,6 @@ use tui::{
|
||||
Frame,
|
||||
};
|
||||
|
||||
const FOLDER_ICON_COLLAPSED: &str = "\u{25b8}"; //▸
|
||||
const FOLDER_ICON_EXPANDED: &str = "\u{25be}"; //▾
|
||||
const EMPTY_STR: &str = "";
|
||||
|
||||
enum Focus {
|
||||
Tree,
|
||||
File,
|
||||
@ -117,12 +113,12 @@ impl RevisionFilesComponent {
|
||||
let is_path = item.kind().is_path();
|
||||
let path_arrow = if is_path {
|
||||
if item.kind().is_path_collapsed() {
|
||||
FOLDER_ICON_COLLAPSED
|
||||
symbol::FOLDER_ICON_COLLAPSED
|
||||
} else {
|
||||
FOLDER_ICON_EXPANDED
|
||||
symbol::FOLDER_ICON_EXPANDED
|
||||
}
|
||||
} else {
|
||||
EMPTY_STR
|
||||
symbol::EMPTY_STR
|
||||
};
|
||||
|
||||
let path = format!("{}{}{}", indent_str, path_arrow, path);
|
||||
|
@ -27,6 +27,9 @@ pub mod symbol {
|
||||
pub const CHECKMARK: &str = "\u{2713}"; //✓
|
||||
pub const SPACE: &str = "\u{02FD}"; //˽
|
||||
pub const EMPTY_SPACE: &str = " ";
|
||||
pub const FOLDER_ICON_COLLAPSED: &str = "\u{25b8}"; //▸
|
||||
pub const FOLDER_ICON_EXPANDED: &str = "\u{25be}"; //▾
|
||||
pub const EMPTY_STR: &str = "";
|
||||
}
|
||||
|
||||
pub fn title_branches() -> String {
|
||||
|
Loading…
Reference in New Issue
Block a user