GPGSDocsUI.cs 2.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. // <copyright file="GPGSDocsUI.cs" company="Google Inc.">
  2. // Copyright (C) 2014 Google Inc.
  3. //
  4. // Licensed under the Apache License, Version 2.0 (the "License");
  5. // you may not use this file except in compliance with the License.
  6. // You may obtain a copy of the License at
  7. //
  8. // http://www.apache.org/licenses/LICENSE-2.0
  9. //
  10. // Unless required by applicable law or agreed to in writing, software
  11. // distributed under the License is distributed on an "AS IS" BASIS,
  12. // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  13. // See the License for the specific language governing permissions and
  14. // limitations under the License.
  15. // </copyright>
  16. namespace GooglePlayGames.Editor
  17. {
  18. using UnityEngine;
  19. using UnityEditor;
  20. public class GPGSDocsUI
  21. {
  22. [MenuItem("Window/Google Play Games/Documentation/Plugin Getting Started Guide...", false, 100)]
  23. public static void MenuItemGettingStartedGuide()
  24. {
  25. Application.OpenURL(GPGSStrings.ExternalLinks.GettingStartedGuideURL);
  26. }
  27. [MenuItem("Window/Google Play Games/Documentation/Google Play Games API...", false, 101)]
  28. public static void MenuItemPlayGamesServicesAPI()
  29. {
  30. Application.OpenURL(GPGSStrings.ExternalLinks.PlayGamesServicesApiURL);
  31. }
  32. [MenuItem("Window/Google Play Games/About/About the Plugin...", false, 300)]
  33. public static void MenuItemAbout()
  34. {
  35. string msg = GPGSStrings.AboutText +
  36. PluginVersion.VersionString + " (" +
  37. string.Format("0x{0:X8}", GooglePlayGames.PluginVersion.VersionInt) + ")";
  38. EditorUtility.DisplayDialog(GPGSStrings.AboutTitle, msg,
  39. GPGSStrings.Ok);
  40. }
  41. [MenuItem("Window/Google Play Games/About/License...", false, 301)]
  42. public static void MenuItemLicense()
  43. {
  44. EditorUtility.DisplayDialog(GPGSStrings.LicenseTitle, GPGSStrings.LicenseText,
  45. GPGSStrings.Ok);
  46. }
  47. }
  48. }