2018-02-14 14:13:42 -05:00
|
|
|
// Copyright 1998-2018 Epic Games, Inc. All Rights Reserved.
|
2017-09-11 10:43:35 -04:00
|
|
|
|
|
|
|
|
#pragma once
|
|
|
|
|
|
|
|
|
|
#include "CoreMinimal.h"
|
|
|
|
|
#include "Input/Reply.h"
|
|
|
|
|
#include "Widgets/DeclarativeSyntaxSupport.h"
|
|
|
|
|
#include "Widgets/SCompoundWidget.h"
|
2018-02-14 14:13:42 -05:00
|
|
|
#include "Misc/SecureHash.h"
|
2017-09-11 10:43:35 -04:00
|
|
|
|
|
|
|
|
class SScrollBox;
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Credit screen widget that displays a scrolling list contributors.
|
|
|
|
|
*/
|
|
|
|
|
class SAndroidLicenseDialog : public SCompoundWidget
|
|
|
|
|
{
|
|
|
|
|
public:
|
|
|
|
|
SLATE_BEGIN_ARGS( SAndroidLicenseDialog )
|
|
|
|
|
{}
|
|
|
|
|
SLATE_END_ARGS()
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Constructs the credits screen widgets
|
|
|
|
|
*/
|
|
|
|
|
void Construct(const FArguments& InArgs);
|
|
|
|
|
|
|
|
|
|
bool HasLicense();
|
|
|
|
|
|
|
|
|
|
void SetLicenseAcceptedCallback(const FSimpleDelegate& InOnLicenseAccepted);
|
|
|
|
|
|
|
|
|
|
private:
|
|
|
|
|
bool bLicenseValid;
|
|
|
|
|
|
|
|
|
|
FReply OnAgree();
|
|
|
|
|
FReply OnCancel();
|
|
|
|
|
|
|
|
|
|
FSHAHash LicenseHash;
|
|
|
|
|
|
|
|
|
|
/** The widget that scrolls the license text */
|
|
|
|
|
TSharedPtr<SScrollBox> ScrollBox;
|
|
|
|
|
|
|
|
|
|
FSimpleDelegate OnLicenseAccepted;
|
|
|
|
|
};
|
|
|
|
|
|