Combine LabelColor
and IconColor
into TextColor
This commit is contained in:
parent
dc56a7b12b
commit
76c15229c1
25 changed files with 152 additions and 220 deletions
|
@ -6,7 +6,7 @@ use gpui::{
|
|||
};
|
||||
use theme2::ActiveTheme;
|
||||
|
||||
use crate::{Icon, IconColor, IconElement, Selection};
|
||||
use crate::{Icon, IconElement, Selection, TextColor};
|
||||
|
||||
pub type CheckHandler<V> = Arc<dyn Fn(Selection, &mut V, &mut ViewContext<V>) + Send + Sync>;
|
||||
|
||||
|
@ -58,9 +58,9 @@ impl<V: 'static> Checkbox<V> {
|
|||
.color(
|
||||
// If the checkbox is disabled we change the color of the icon.
|
||||
if self.disabled {
|
||||
IconColor::Disabled
|
||||
TextColor::Disabled
|
||||
} else {
|
||||
IconColor::Selected
|
||||
TextColor::Selected
|
||||
},
|
||||
),
|
||||
)
|
||||
|
@ -73,9 +73,9 @@ impl<V: 'static> Checkbox<V> {
|
|||
.color(
|
||||
// If the checkbox is disabled we change the color of the icon.
|
||||
if self.disabled {
|
||||
IconColor::Disabled
|
||||
TextColor::Disabled
|
||||
} else {
|
||||
IconColor::Selected
|
||||
TextColor::Selected
|
||||
},
|
||||
),
|
||||
)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue