You've already forked UnrealEngineUWP
mirror of
https://github.com/izzy2lost/UnrealEngineUWP.git
synced 2026-03-26 18:15:20 -07:00
#rnx #rb none #ROBOMERGE-SOURCE: CL 10869241 via CL 10869527 via CL 10869904 #ROBOMERGE-BOT: (v613-10869866) [CL 10870586 by ryan durand in Main branch]
51 lines
1.7 KiB
C++
51 lines
1.7 KiB
C++
// Copyright Epic Games, Inc. All Rights Reserved.
|
|
|
|
#pragma once
|
|
|
|
#include "CoreMinimal.h"
|
|
#include "Widgets/DeclarativeSyntaxSupport.h"
|
|
#include "SGraphPin.h"
|
|
#include "SGraphNodeDefault.h"
|
|
|
|
class SCommentBubble;
|
|
|
|
/** The visual representation of a control point meant to adjust how connections are routed, also known as a Reroute node.
|
|
* The input knot node should have properly implemented ShouldDrawNodeAsControlPointOnly to return true with valid indices for its pins.
|
|
*/
|
|
class GRAPHEDITOR_API SGraphNodeKnot : public SGraphNodeDefault
|
|
{
|
|
public:
|
|
SLATE_BEGIN_ARGS(SGraphNodeKnot) {}
|
|
SLATE_END_ARGS()
|
|
|
|
void Construct(const FArguments& InArgs, class UEdGraphNode* InKnot);
|
|
|
|
// SGraphNode interface
|
|
virtual void UpdateGraphNode() override;
|
|
virtual const FSlateBrush* GetShadowBrush(bool bSelected) const override;
|
|
virtual TSharedPtr<SGraphPin> CreatePinWidget(UEdGraphPin* Pin) const override;
|
|
virtual void AddPin(const TSharedRef<SGraphPin>& PinToAdd) override;
|
|
virtual void RequestRenameOnSpawn() override { }
|
|
// End of SGraphNode interface
|
|
|
|
protected:
|
|
/** Returns Offset to center comment on the node's only pin */
|
|
FVector2D GetCommentOffset() const;
|
|
protected:
|
|
|
|
/** Toggles the hovered visibility state */
|
|
virtual void OnCommentBubbleToggled(bool bInCommentBubbleVisible) override;
|
|
|
|
/** If bHoveredCommentVisibility is true, hides the comment bubble after a change is committed */
|
|
virtual void OnCommentTextCommitted(const FText& NewComment, ETextCommit::Type CommitInfo) override;
|
|
|
|
/** The hovered visibility state. If false, comment bubble will only appear on hover. */
|
|
bool bAlwaysShowCommentBubble;
|
|
|
|
/** SharedPtr to comment bubble */
|
|
TSharedPtr<SCommentBubble> CommentBubble;
|
|
|
|
const FSlateBrush* ShadowBrush;
|
|
const FSlateBrush* ShadowBrushSelected;
|
|
};
|