This commit is contained in:
1 parent
09f707b139
commit
dc593978d8
4 files changed
+147
-45
No files matched your search
@@ -1405,7 +1405,8 @@ fn texture_asset_ref_candidates(world: &World) -> Vec<AssetRefCandidate> {
|
||||
record.id.as_string(),
|
||||
"texture:source",
|
||||
asset.label.clone(),
|
||||
),
|
||||
)
|
||||
.with_source_path(path),
|
||||
label: asset.label.clone(),
|
||||
detail: path.to_string(),
|
||||
selection: AssetSelection::File(path.to_string()),
|
||||
@@ -1449,7 +1450,8 @@ fn brush_face_material_ref_candidates(world: &mut World) -> Vec<AssetRefCandidat
|
||||
let Some(record) = find_asset_by_path(registry, path) else {
|
||||
continue;
|
||||
};
|
||||
let reference = EditorAssetRef::new(record.id.as_string(), "material:source", &asset.label);
|
||||
let reference = EditorAssetRef::new(record.id.as_string(), "material:source", &asset.label)
|
||||
.with_source_path(path);
|
||||
let key = (reference.asset_id.clone(), reference.sub_asset_id.clone());
|
||||
if !seen.insert(key) {
|
||||
continue;
|
||||
@@ -1490,7 +1492,8 @@ fn asset_ref_candidate_from_selection(
|
||||
record.id.as_string(),
|
||||
"material:source",
|
||||
asset.label.clone(),
|
||||
),
|
||||
)
|
||||
.with_source_path(path),
|
||||
label: asset.label.clone(),
|
||||
detail: path.clone(),
|
||||
selection: selection.clone(),
|
||||
@@ -1514,7 +1517,8 @@ fn asset_ref_candidate_from_selection(
|
||||
record.id.as_string(),
|
||||
"texture:source",
|
||||
asset.label.clone(),
|
||||
),
|
||||
)
|
||||
.with_source_path(path),
|
||||
label: asset.label.clone(),
|
||||
detail: path.clone(),
|
||||
selection: selection.clone(),
|
||||
@@ -1564,7 +1568,8 @@ fn asset_ref_candidate_from_selection(
|
||||
record.id.as_string(),
|
||||
sub_asset_id.clone(),
|
||||
label.clone(),
|
||||
),
|
||||
)
|
||||
.with_source_path(source_path.clone().unwrap_or_else(|| parent_path.clone())),
|
||||
label: label.clone(),
|
||||
detail: source_path.clone().unwrap_or_else(|| parent_path.clone()),
|
||||
selection: selection.clone(),
|
||||
|
||||
Reference in new issue
Block a user