1
0

UiConstants.cs 2.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778
  1. #if SERVICES_SDK_CORE_ENABLED
  2. using UnityEditor;
  3. namespace UnityEngine.Advertisements.Editor
  4. {
  5. /// <summary>
  6. /// Helper to store all constants used in Ads service UI.
  7. /// </summary>
  8. /// <remarks>
  9. /// This helper has been created to avoid adding too much noise in UI classes.
  10. /// </remarks>
  11. static class UiConstants
  12. {
  13. public static class ClassNames
  14. {
  15. public const string Ads = "ads";
  16. }
  17. public static class StyleSheetPaths
  18. {
  19. public const string Common = "Packages/com.unity.ads/Editor/DevX/StyleSheets/AdsService.uss";
  20. }
  21. public static class UiTemplatePaths
  22. {
  23. public const string GameIds = "Packages/com.unity.ads/Editor/DevX/UXML/AdsServiceGameIds.uxml";
  24. public const string GettingStarted = "Packages/com.unity.ads/Editor/DevX/UXML/AdsServiceGettingStarted.uxml";
  25. public const string TestMode = "Packages/com.unity.ads/Editor/DevX/UXML/AdsServiceTestMode.uxml";
  26. }
  27. public static class UiElementNames
  28. {
  29. public const string TestModeToggle = "ToggleTestMode";
  30. public const string LearnMoreLink = "LearnMore";
  31. public const string AppleGameId = "AppleGameId";
  32. public const string AndroidGameId = "AndroidGameId";
  33. }
  34. public static class LocalizedStrings
  35. {
  36. public static readonly string Ads = L10n.Tr("Ads");
  37. public static readonly string Description = L10n.Tr("Monetize your games");
  38. public static readonly string AssetStorePackageInstalledMessage = L10n.Tr(
  39. "The Asset Store Package is installed.\n" +
  40. "Usage of Package Manager is recommended.");
  41. public static readonly string Unavailable = L10n.Tr("N/A");
  42. public static readonly string Yes = L10n.Tr("Yes");
  43. public static readonly string No = L10n.Tr("No");
  44. }
  45. public static class Formats
  46. {
  47. public const string TemplateNotFound = "No UI template found for Ads Service {0}.";
  48. }
  49. public static class Urls
  50. {
  51. public const string LearnMore = "https://unityads.unity3d.com/help/index";
  52. }
  53. public static readonly string[] SupportedPlatforms =
  54. {
  55. "Android",
  56. "iOS"
  57. };
  58. }
  59. }
  60. #endif