diff options
Diffstat (limited to 'src/interactive/widgets/mod.rs')
-rw-r--r-- | src/interactive/widgets/mod.rs | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/src/interactive/widgets/mod.rs b/src/interactive/widgets/mod.rs index ee6f34c..b9c72f5 100644 --- a/src/interactive/widgets/mod.rs +++ b/src/interactive/widgets/mod.rs @@ -14,8 +14,14 @@ pub use mark::*; use tui::style::Color; -pub const COLOR_BYTESIZE_SELECTED: Color = Color::DarkGray; pub const COLOR_MARKED: Color = Color::Yellow; -pub const COLOR_MARKED_LIGHT: Color = Color::LightYellow; pub const COLOR_MARKED_DARK: Color = Color::Rgb(176, 126, 0); -pub const COLOR_MARKED_DARKER: Color = Color::Rgb(106, 66, 0); + +fn get_name_color(fg: Color, is_file: bool, is_marked: bool) -> Color { + match (is_file, is_marked) { + (true, false) => Color::DarkGray, + (true, true) => COLOR_MARKED_DARK, + (false, true) => COLOR_MARKED, + _ => fg, + } +} |