Rename ThemeVariant to Theme (#3252)

This PR renames the `ThemeVariant` type to `Theme`.

This better reflects its purpose, as well as matches the same name as we
had before, which should make porting crates slightly easier.

Release Notes:

- N/A
This commit is contained in:
Marshall Bowers
2023-11-07 10:41:36 -05:00
committed by GitHub
parent 9cb8512603
commit 74853ea55f
22 changed files with 82 additions and 82 deletions
+4 -4
View File
@@ -32,7 +32,7 @@ use std::{
},
time::Duration,
};
use theme2::ThemeVariant;
use theme2::Theme;
#[derive(Deserialize)]
pub struct ItemSettings {
@@ -184,7 +184,7 @@ pub trait Item: Render + EventEmitter {
ToolbarItemLocation::Hidden
}
fn breadcrumbs(&self, _theme: &ThemeVariant, _cx: &AppContext) -> Option<Vec<BreadcrumbText>> {
fn breadcrumbs(&self, _theme: &Theme, _cx: &AppContext) -> Option<Vec<BreadcrumbText>> {
None
}
@@ -270,7 +270,7 @@ pub trait ItemHandle: 'static + Send {
) -> gpui::Subscription;
fn to_searchable_item_handle(&self, cx: &AppContext) -> Option<Box<dyn SearchableItemHandle>>;
fn breadcrumb_location(&self, cx: &AppContext) -> ToolbarItemLocation;
fn breadcrumbs(&self, theme: &ThemeVariant, cx: &AppContext) -> Option<Vec<BreadcrumbText>>;
fn breadcrumbs(&self, theme: &Theme, cx: &AppContext) -> Option<Vec<BreadcrumbText>>;
fn serialized_item_kind(&self) -> Option<&'static str>;
fn show_toolbar(&self, cx: &AppContext) -> bool;
fn pixel_position_of_cursor(&self, cx: &AppContext) -> Option<Point<Pixels>>;
@@ -603,7 +603,7 @@ impl<T: Item> ItemHandle for View<T> {
self.read(cx).breadcrumb_location()
}
fn breadcrumbs(&self, theme: &ThemeVariant, cx: &AppContext) -> Option<Vec<BreadcrumbText>> {
fn breadcrumbs(&self, theme: &Theme, cx: &AppContext) -> Option<Vec<BreadcrumbText>> {
self.read(cx).breadcrumbs(theme, cx)
}