Commit Graph

11 Commits

Author SHA1 Message Date
Matt Peters
7ad238a806 AssetRegistry includes (Engine/Source): change #include "AssetData.h" -> #include "AssetRegistry/AssetData.h", and similar for the other moved AssetRegistry headers.
#rb Zousar.Shaker
#rnx
#preflight 6270509a220f89f0ad573030

[CL 20016982 by Matt Peters in ue5-main branch]
2022-05-02 18:06:48 -04:00
Phillip Kavan
e553054a40 Child Blueprint classes will now inherit assigned namespaces all the way through the native parent class hierarchy.
Also changed the UX to not show the auto-import alert unless a namespace was added into the current editor context. We technically auto-import a namespace once it's used but we don't necessarily need to tell the user about it in certain scenarios (e.g. when it's already part of the default set). The reason we do it that way is that if it is no longer present in the default set (e.g. after reparenting the child BP), the child will then display it as an explicit import.

#rnx
#jira UE-149265
#rb Benjamin.Fox
#preflight 6259e39db53385f954a62802

[CL 19778028 by Phillip Kavan in ue5-main branch]
2022-04-15 17:34:19 -04:00
Phillip Kavan
095e7eff1b Fix source of a potential for an editor crash during Blueprint namespace harvesting.
#jira None
#rb None (trivial)
#preflight 624ef5141016cf9a19e00aee

[CL 19669099 by Phillip Kavan in ue5-main branch]
2022-04-07 10:46:45 -04:00
Phillip Kavan
c90d0a40bb Consider Blueprint objects to be authoritative for namespace queries.
#jira UE-142190
#rb None (trivial)
#preflight 624b48a0c51908059aec1d3b

[CL 19614045 by Phillip Kavan in ue5-main branch]
2022-04-04 15:51:25 -04:00
Phillip Kavan
f64e3e18d7 Some minor refactoring to assist with auto-importing external type object dependency namespaces into the Blueprint editor context in response to user actions.
Change summary:
- Moved base definition of UK2Node::HasExternalDependencies() up one level to UEdGraphNode (to avoid blind casts in a context where we may not necessarily have a UK2Node subtype).
- Updated subtype headers that override HasExternalDependencies() to relocate the declaration into the class declaration's 'UEdGraphNode overrides' section (for clarity).
- Reverted previous UBlueprintNodeSpawner::ImportTarget solution in favor of using node dependencies; this allows auto-import actions to scale more easily to all existing node subtypes and avoids data duplication.
- Modified SBlueprintActionMenu::OnActionSelected() to utilize the new method for determining which namespace(s) to auto-import after executing a node spawner action in response to a context menu item selection (UE-146803).
- Reverted FBlueprintNamespaceUtilities::GetPropertyValueNamespaces() back to its original 5.0 signature so that it uses a TSet<FString> for the output rather than a TArray<FString>; this fits in better with input to other APIs.
- Renamed FBlueprintEditor::FImportNamespaceParameters to FImportNamespaceExParameters (for clarity).
- Changed the 'FBlueprintEditor::FImportNamespaceParameters::AdditionalNamespaces' member to a TSet<FString> containing *all* namespaces to import rather than limiting to only additional ones.
- Reverted FBlueprintEditor::ImportNamespace() back to its original 5.0 signature and added/implemented FBlueprintEditor::ImportNamespaceEx() as the "extended" version that allows for batched imports and future customizations.
- Revised existing FBlueprintEditor::ImportNamespace() call sites to utilize and/or conform to the extended ImportNamespaceEx() API where appropriate.

#jira UE-146803
#rb Benjamin.Fox
#preflight 623cf3a433709ff50128e8d4

[CL 19505118 by Phillip Kavan in ue5-main branch]
2022-03-24 19:50:46 -04:00
Phillip Kavan
a1cfef837c Update the Blueprint namespace registry on removal/replacement of an assigned namespace.
This may occur during one of the following events:
- Reverting or reassigning a Blueprint asset's namespace.
- Removing a Blueprint asset (i.e. deleting it in the browser).
- Renaming a Blueprint asset (i.e. moving it to another location).
  - Note: this only applies when using package paths as a default namespace identifier (which is currently disabled by default).

Change summary:
- Added FBlueprintNamespaceRegistry::Rebuild().
- Exposed FBlueprintNamespaceUtilities::ConvertPackagePathToNamespacePath().
- Implemented FBlueprintNamespaceRegistry::OnAssetRemoved() and OnAssetRenamed().
- Modified FBlueprintNamespaceRegistry::FindAndRegisterAllNamespaces() with an exclusion set (to assist with asset removal).
- Added FBlueprintGlobalOptionsDetails::HandleNamespaceValueChange() to consolidate shared logic between reverting and reassignment.
- Extended Blueprint namespace member property details customization to refresh the namespace registry and editor context after updating the value.

#jira UE-142190
#rb Benjamin.Fox
#preflight 6238ea0a10251d53d564b55a

[CL 19466203 by Phillip Kavan in ue5-main branch]
2022-03-22 10:18:21 -04:00
Phillip Kavan
b5863c2b95 Some minor refactoring to assist with handling removal/reassignment of Blueprint namespaces.
Change summary:
- Added a code path for removing a namespace from the BP editor context.
- Consolidated namespace helper instances into a single BP editor context.
- Extended the FBlueprintEditor::ImportNamespace() API to accept additional options and a post-import callback.
- Refactored the auto-import code path to fix issues with reassignment to/from an imported namespace.
- Decoupled SSubobjectBlueprintEditor from a namespace-aware callback in favor of a generalized "add" callback.
- Linked the CVar for inheriting parent BP imports to a transient BP setting (experimental/not user-facing).
- Consolidated code to gather global/default imports into a utility API so that namespace sets are consistent.
- Modified "Imports" view to include a "default imports" section (similar to inherited interfaces) - these are not removable.
- Moved "Inherited Interfaces" section to be sorted above the "Implemented Interfaces" section for consistency.
- Fixed SBlueprintNamespaceEntry to query for the current text rather than only setting it at construction time.

#jira UE-133288
#rb Ben.Hoffman
#preflight 621ff4b337049be51738bafe

[CL 19236263 by Phillip Kavan in ue5-main branch]
2022-03-02 20:48:04 -05:00
phillip kavan
648232be02 Expose an editor setting that will more easily allow users to toggle Blueprint namespace-related editor features on/off.
#jira UE-139971
#rb Benjamin.Fox
#preflight 61eeef014018b3d62e6e902b

#ROBOMERGE-AUTHOR: phillip.kavan
#ROBOMERGE-SOURCE: CL 18712084 in //UE5/Release-5.0/... via CL 18712094 via CL 18712339
#ROBOMERGE-BOT: UE5 (Release-Engine-Test -> Main) (v903-18687472)

[CL 18712359 by phillip kavan in ue5-main branch]
2022-01-24 14:14:32 -05:00
phillip kavan
4266aae5f3 Add non-imported class type filtering to the "Add Component" type selection UI in the Blueprint editor.
Additionally auto-import any namespace associated with the selected component class type when a new component is added.

Change summary:
- Modified the component type registry to internally create/store unloaded BP data to assist with unloaded BP component type filtering.
- Added FEditorClassUtils::GetImplementedInterfaceClassPathsFromAsset() to move BP interface asset tag processing into a shared utility API.
- Modified SComponentClassCombo to work with IClassViewFilter-style filtering and added a filter options menu (currently only visible when namespace filtering features are enabled via CVar).
- A few minor modifications/additions to SSubobjectEditor/SSubobjectBlueprintEditor to assist with interfacing with the owning FBlueprintEditor context for filtering, updating etc.

#jira UE-133294
#rb Ben.Hoffman
#preflight 61b7c0601a4451f7ba1d0c46

#ROBOMERGE-AUTHOR: phillip.kavan
#ROBOMERGE-SOURCE: CL 18449755 in //UE5/Release-5.0/... via CL 18449768
#ROBOMERGE-BOT: STARSHIP (Release-Engine-Staging -> Release-Engine-Test) (v897-18405271)

[CL 18449772 by phillip kavan in ue5-release-engine-test branch]
2021-12-13 17:39:02 -05:00
phillip kavan
4bcc1f9f76 Auto-import associated namespace(s) after a value change on reference types in the Blueprint property editor.
#jira UE-133293
#rb Ben.Hoffman
#preflight 61a7c08eca183f8de47a6136

#ROBOMERGE-AUTHOR: phillip.kavan
#ROBOMERGE-SOURCE: CL 18342696 in //UE5/Release-5.0/... via CL 18342803
#ROBOMERGE-BOT: STARSHIP (Release-Engine-Staging -> Release-Engine-Test) (v895-18170469)

[CL 18342887 by phillip kavan in ue5-release-engine-test branch]
2021-12-01 14:33:14 -05:00
aurel cordonnier
fc542f6cfd Merge from Release-Engine-Staging @ 18081189 to Release-Engine-Test
This represents UE4/Main @18073326, Release-5.0 @18081140 and Dev-PerfTest @18045971

[CL 18081471 by aurel cordonnier in ue5-release-engine-test branch]
2021-11-07 23:43:01 -05:00