Removed some unnecessary parentheses and braces. (#409)
This commit is contained in:
parent
428519994c
commit
3efa8b9477
@ -97,7 +97,7 @@ mod timeout;
|
||||
lazy_static! {
|
||||
/// Static instance of `InternalEventReader`.
|
||||
/// This needs to be static because there can be one event reader.
|
||||
static ref INTERNAL_EVENT_READER: RwLock<read::InternalEventReader> = { RwLock::new(read::InternalEventReader::default()) };
|
||||
static ref INTERNAL_EVENT_READER: RwLock<read::InternalEventReader> = RwLock::new(read::InternalEventReader::default());
|
||||
}
|
||||
|
||||
/// Checks if there is an [`Event`](enum.Event.html) available.
|
||||
|
@ -133,6 +133,7 @@ impl From<Colored> for u16 {
|
||||
|
||||
const REMOVE_BG_MASK: u16 = BG_INTENSITY | BG_RED | BG_GREEN | BG_BLUE;
|
||||
// remove all background values from the original color, we don't want to reset those.
|
||||
|
||||
original_color & !REMOVE_BG_MASK
|
||||
}
|
||||
|
||||
@ -165,6 +166,7 @@ impl From<Colored> for u16 {
|
||||
|
||||
const REMOVE_FG_MASK: u16 = FG_INTENSITY | FG_RED | FG_GREEN | FG_BLUE;
|
||||
// remove all foreground values from the original color, we don't want to reset those.
|
||||
|
||||
original_color & !REMOVE_FG_MASK
|
||||
}
|
||||
/* WinApi will be used for systems that do not support ANSI, those are windows version less then 10. RGB and 255 (AnsiBValue) colors are not supported in that case.*/
|
||||
|
Loading…
Reference in New Issue
Block a user