mirror of
https://github.com/GraphiteEditor/Graphite.git
synced 2026-09-28 02:28:12 +08:00
Remove warnings from build and satisfied clippy (#1288)
* Prefixed unused functions with underscore * Applied clippy lints * Fixed some warnings and removed some `allow` statements
This commit is contained in:
committed by
Keavon Chambers
parent
054acd3cc9
commit
70fcb35444
@@ -168,8 +168,8 @@ impl NodeGraphMessageHandler {
|
||||
fn collect_nested_addresses(&mut self, document: &Document, responses: &mut VecDeque<Message>) {
|
||||
// // Build path list
|
||||
let mut path = vec![];
|
||||
if let Some(layer) = self.layer_path.as_ref().and_then(|path| document.layer(&path).ok()) {
|
||||
path.push(format!("Layer: {}", layer.name.as_ref().map(|name| name.as_str()).unwrap_or("Untitled Layer")));
|
||||
if let Some(layer) = self.layer_path.as_ref().and_then(|path| document.layer(path).ok()) {
|
||||
path.push(format!("Layer: {}", layer.name.as_deref().unwrap_or("Untitled Layer")));
|
||||
} else {
|
||||
path.push("Document Network".to_string());
|
||||
}
|
||||
|
||||
+4
-2
@@ -1,3 +1,5 @@
|
||||
#![allow(clippy::too_many_arguments)]
|
||||
|
||||
use super::document_node_types::NodePropertiesContext;
|
||||
use super::FrontendGraphDataType;
|
||||
use crate::messages::layout::utility_types::widget_prelude::*;
|
||||
@@ -699,7 +701,7 @@ pub fn brightness_contrast_properties(document_node: &DocumentNode, node_id: Nod
|
||||
]
|
||||
}
|
||||
|
||||
pub fn blur_image_properties(document_node: &DocumentNode, node_id: NodeId, _context: &mut NodePropertiesContext) -> Vec<LayoutGroup> {
|
||||
pub fn _blur_image_properties(document_node: &DocumentNode, node_id: NodeId, _context: &mut NodePropertiesContext) -> Vec<LayoutGroup> {
|
||||
let radius = number_widget(document_node, node_id, 1, "Radius", NumberInput::default().min(0.).max(20.).int(), true);
|
||||
let sigma = number_widget(document_node, node_id, 2, "Sigma", NumberInput::default().min(0.).max(10000.), true);
|
||||
|
||||
@@ -869,7 +871,7 @@ pub fn adjust_selective_color_properties(document_node: &DocumentNode, node_id:
|
||||
}
|
||||
|
||||
#[cfg(feature = "gpu")]
|
||||
pub fn gpu_map_properties(document_node: &DocumentNode, node_id: NodeId, _context: &mut NodePropertiesContext) -> Vec<LayoutGroup> {
|
||||
pub fn _gpu_map_properties(document_node: &DocumentNode, node_id: NodeId, _context: &mut NodePropertiesContext) -> Vec<LayoutGroup> {
|
||||
let map = text_widget(document_node, node_id, 1, "Map", true);
|
||||
|
||||
vec![LayoutGroup::Row { widgets: map }]
|
||||
|
||||
Reference in New Issue
Block a user