Introduce Custom variants for every style in the built-in Theme
This commit is contained in:
parent
8102f96f12
commit
18fb74f200
34 changed files with 576 additions and 286 deletions
|
|
@ -22,16 +22,16 @@ pub struct Scroller {
|
|||
|
||||
/// A set of rules that dictate the style of a scrollable.
|
||||
pub trait StyleSheet {
|
||||
type Style: Default + Copy;
|
||||
type Style: Default;
|
||||
|
||||
/// Produces the style of an active scrollbar.
|
||||
fn active(&self, style: Self::Style) -> Scrollbar;
|
||||
fn active(&self, style: &Self::Style) -> Scrollbar;
|
||||
|
||||
/// Produces the style of an hovered scrollbar.
|
||||
fn hovered(&self, style: Self::Style) -> Scrollbar;
|
||||
fn hovered(&self, style: &Self::Style) -> Scrollbar;
|
||||
|
||||
/// Produces the style of a scrollbar that is being dragged.
|
||||
fn dragging(&self, style: Self::Style) -> Scrollbar {
|
||||
fn dragging(&self, style: &Self::Style) -> Scrollbar {
|
||||
self.hovered(style)
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue