Skip to content

Commit

Permalink
feat: implement Copy for Theme
Browse files Browse the repository at this point in the history
Theme isn't big enough for a clone to generate a memcpy call on 64-bit architectures, so it should be Copy.

Closes #8
  • Loading branch information
Stonks3141 authored May 26, 2023
1 parent b5c3d66 commit 97934d1
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -95,10 +95,8 @@ fn make_widget_visual(
}
}

// FIXME: Theme should be `Copy` since it isn't big enough to generate a call to `memcpy`,
// do this when egui releases a minor version
/// The colors for a theme variant.
#[derive(Debug, Clone, Hash, PartialEq, Eq)]
#[derive(Debug, Clone, Copy, Hash, PartialEq, Eq)]
pub struct Theme {
pub rosewater: Color32,
pub flamingo: Color32,
Expand Down

0 comments on commit 97934d1

Please sign in to comment.