Stream Chat Unreal SDK
Loading...
Searching...
No Matches
ClientContextWidget.h
1// Copyright 2022 Stream.IO, Inc. All Rights Reserved.
2
3// Fill out your copyright notice in the Description page of Project Settings.
4
5#pragma once
6
7#include "ContextWidget.h"
8#include "CoreMinimal.h"
9#include "StreamChatClientComponent.h"
10
11#include "ClientContextWidget.generated.h"
12
16UCLASS()
17class STREAMCHATUI_API UClientContextWidget final : public UContextWidget
18{
19 GENERATED_BODY()
20
21public:
22 UFUNCTION(BlueprintCallable, Category = "Stream Chat")
23 void Setup(UStreamChatClientComponent* InClient);
24 static UClientContextWidget* Get(const UWidget* Widget);
25 static UStreamChatClientComponent* GetClient(const UWidget* Widget);
26 UStreamChatClientComponent* GetClient() const;
27
28 void SelectChannel(UChatChannel* Channel);
29
30 // TODO A back stack container widget might one day make sense
31 DECLARE_DYNAMIC_MULTICAST_DELEGATE(FBackDelegate);
32 UPROPERTY(BlueprintAssignable)
33 FBackDelegate OnBack;
34
35 DECLARE_DYNAMIC_MULTICAST_DELEGATE_OneParam(FChannelSelected, UChatChannel*, Channel);
36 UPROPERTY(BlueprintAssignable)
37 FChannelSelected OnChannelSelected;
38
39 UPROPERTY(BlueprintReadOnly, Transient, Category = "Stream Chat")
40 UChatChannel* SelectedChannel;
41
42private:
43 UPROPERTY(Transient)
45};
The client-side representation of a Stream Chat channel.
Definition: ChatChannel.h:74
A component which allows for connecting to the Stream Chat API. Should be added to a client-side acto...
Definition: StreamChatClientComponent.h:42