add voice allocator node
This commit is contained in:
@@ -62,6 +62,8 @@ pub enum NodeResponse<UserResponse: UserResponseTrait, NodeData: NodeDataTrait>
|
||||
node: NodeId,
|
||||
drag_delta: Vec2,
|
||||
},
|
||||
/// Emitted when a node's title bar is double-clicked.
|
||||
DoubleClick(NodeId),
|
||||
User(UserResponse),
|
||||
}
|
||||
|
||||
@@ -479,6 +481,9 @@ where
|
||||
}
|
||||
}
|
||||
}
|
||||
NodeResponse::DoubleClick(_) => {
|
||||
// Handled by user code.
|
||||
}
|
||||
NodeResponse::User(_) => {
|
||||
// These are handled by the user code.
|
||||
}
|
||||
@@ -1172,6 +1177,11 @@ where
|
||||
responses.push(NodeResponse::RaiseNode(self.node_id));
|
||||
}
|
||||
|
||||
// Double-click detection (emitted alongside other responses)
|
||||
if window_response.double_clicked() {
|
||||
responses.push(NodeResponse::DoubleClick(self.node_id));
|
||||
}
|
||||
|
||||
responses
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user