Firstborn/Library/PackageCache/com.unity.ads@3.7.5/Editor/DevX/Settings/GettingStartedUi.cs
Schaken-Mods b486678290 Library -Artifacts
Library -Artifacts
2023-03-28 12:24:16 -05:00

32 lines
951 B
C#

#if SERVICES_SDK_CORE_ENABLED
using UnityEngine.UIElements;
namespace UnityEngine.Advertisements.Editor
{
class GettingStartedUi : VisualElement
{
public GettingStartedUi()
{
var container = UiUtils.GetUiFromTemplate(UiConstants.UiTemplatePaths.GettingStarted);
if (container is null)
{
var message = string.Format(
UiConstants.Formats.TemplateNotFound, nameof(UiConstants.UiTemplatePaths.GettingStarted));
Debug.LogError(message);
return;
}
Add(container);
container.AddOnClickedForElement(OnLearnMoreClicked, UiConstants.UiElementNames.LearnMoreLink);
}
static void OnLearnMoreClicked()
{
EditorGameServiceAnalyticsSender.SendProjectSettingsLearnMoreEvent();
Application.OpenURL(UiConstants.Urls.LearnMore);
}
}
}
#endif