mirror of
https://github.com/GraphiteEditor/Graphite.git
synced 2026-09-16 14:58:05 +08:00
Add secondary inputs to nodes UI (#863)
* Add secondary inputs to UI * Fix add node * Dragging nodes * Add ParameterExposeButton component Co-authored-by: Keavon Chambers <keavon@keavon.com>
This commit is contained in:
@@ -98,7 +98,7 @@ impl<Reader: std::io::Read> Node<Reader> for BufferNode {
|
||||
}
|
||||
}
|
||||
|
||||
#[derive(Clone, Debug, PartialEq, DynAny)]
|
||||
#[derive(Clone, Debug, PartialEq, DynAny, Default)]
|
||||
#[cfg_attr(feature = "serde", derive(serde::Serialize, serde::Deserialize))]
|
||||
pub struct Image {
|
||||
pub width: u32,
|
||||
@@ -106,6 +106,16 @@ pub struct Image {
|
||||
pub data: Vec<Color>,
|
||||
}
|
||||
|
||||
impl Image {
|
||||
pub const fn empty() -> Self {
|
||||
Self {
|
||||
width: 0,
|
||||
height: 0,
|
||||
data: Vec::new(),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
impl IntoIterator for Image {
|
||||
type Item = Color;
|
||||
type IntoIter = std::vec::IntoIter<Color>;
|
||||
|
||||
Reference in New Issue
Block a user