You've already forked UnrealEngineUWP
mirror of
https://github.com/izzy2lost/UnrealEngineUWP.git
synced 2026-03-26 18:15:20 -07:00
//depot/UE4-LauncherDev/... to //depot/UE4/... [CL 2602006 by Antony Carter in Main branch]
55 lines
1.3 KiB
C++
55 lines
1.3 KiB
C++
// Copyright 1998-2015 Epic Games, Inc. All Rights Reserved.
|
|
|
|
#include "FriendsAndChatPrivatePCH.h"
|
|
#include "FriendsFontStyleService.h"
|
|
|
|
class FFriendsFontStyleServiceImpl
|
|
: public FFriendsFontStyleService
|
|
{
|
|
public:
|
|
|
|
virtual void SetFontStyles(const FFriendsFontStyle& InFriendsNormalFontStyle) override
|
|
{
|
|
FriendsNormalFontStyle = InFriendsNormalFontStyle;
|
|
}
|
|
|
|
virtual void SetUserFontSize(EChatFontType::Type InFontSize) override
|
|
{
|
|
FontSize = InFontSize;
|
|
}
|
|
|
|
virtual FSlateFontInfo GetNormalFont() override
|
|
{
|
|
if (FontSize == EChatFontType::Large)
|
|
{
|
|
return FriendsNormalFontStyle.FriendsFontLarge;
|
|
}
|
|
return FriendsNormalFontStyle.FriendsFontNormal;
|
|
}
|
|
|
|
virtual FSlateFontInfo GetNormalBoldFont() override
|
|
{
|
|
if (FontSize == EChatFontType::Large)
|
|
{
|
|
return FriendsNormalFontStyle.FriendsFontLargeBold;
|
|
}
|
|
return FriendsNormalFontStyle.FriendsFontNormalBold;
|
|
}
|
|
|
|
private:
|
|
FFriendsFontStyleServiceImpl()
|
|
{
|
|
FontSize = EChatFontType::Standard;
|
|
}
|
|
|
|
FFriendsFontStyle FriendsNormalFontStyle;
|
|
EChatFontType::Type FontSize;
|
|
|
|
friend FFriendsFontStyleServiceFactory;
|
|
};
|
|
|
|
TSharedRef< FFriendsFontStyleService > FFriendsFontStyleServiceFactory::Create()
|
|
{
|
|
TSharedRef< FFriendsFontStyleServiceImpl > StyleService(new FFriendsFontStyleServiceImpl());
|
|
return StyleService;
|
|
} |