summaryrefslogtreecommitdiff
path: root/Library/PackageCache/com.unity.textmeshpro@2.0.1/Scripts/Editor/TMP_ResourcesLoader.cs
diff options
context:
space:
mode:
authorAndrew Lee <alee14498@protonmail.com>2020-04-19 17:19:32 -0400
committerAndrew Lee <alee14498@protonmail.com>2020-04-19 17:19:32 -0400
commitc55fba8ab2a1c9d3df65eda4a5a1e957f4aa1f78 (patch)
treeee4d51c7c1d633e11f46453ef1edd3c77c4ef9f7 /Library/PackageCache/com.unity.textmeshpro@2.0.1/Scripts/Editor/TMP_ResourcesLoader.cs
downloadProject-Sandbox-c55fba8ab2a1c9d3df65eda4a5a1e957f4aa1f78.tar.gz
Project-Sandbox-c55fba8ab2a1c9d3df65eda4a5a1e957f4aa1f78.tar.bz2
Project-Sandbox-c55fba8ab2a1c9d3df65eda4a5a1e957f4aa1f78.zip
Inital commit
Diffstat (limited to 'Library/PackageCache/com.unity.textmeshpro@2.0.1/Scripts/Editor/TMP_ResourcesLoader.cs')
-rw-r--r--Library/PackageCache/com.unity.textmeshpro@2.0.1/Scripts/Editor/TMP_ResourcesLoader.cs68
1 files changed, 68 insertions, 0 deletions
diff --git a/Library/PackageCache/com.unity.textmeshpro@2.0.1/Scripts/Editor/TMP_ResourcesLoader.cs b/Library/PackageCache/com.unity.textmeshpro@2.0.1/Scripts/Editor/TMP_ResourcesLoader.cs
new file mode 100644
index 0000000..16cbd76
--- /dev/null
+++ b/Library/PackageCache/com.unity.textmeshpro@2.0.1/Scripts/Editor/TMP_ResourcesLoader.cs
@@ -0,0 +1,68 @@
+using UnityEditor;
+using UnityEngine;
+using System.Collections;
+
+namespace TMPro.EditorUtilities
+{
+
+ //[InitializeOnLoad]
+ class TMP_ResourcesLoader
+ {
+
+ /// <summary>
+ /// Function to pre-load the TMP Resources
+ /// </summary>
+ public static void LoadTextMeshProResources()
+ {
+ //TMP_Settings.LoadDefaultSettings();
+ //TMP_StyleSheet.LoadDefaultStyleSheet();
+ }
+
+
+ static TMP_ResourcesLoader()
+ {
+ //Debug.Log("Loading TMP Resources...");
+
+ // Get current targetted platform
+
+
+ //string Settings = PlayerSettings.GetScriptingDefineSymbolsForGroup(BuildTargetGroup.Standalone);
+ //TMPro.TMP_Settings.LoadDefaultSettings();
+ //TMPro.TMP_StyleSheet.LoadDefaultStyleSheet();
+ }
+
+
+
+ //[RuntimeInitializeOnLoadMethod(RuntimeInitializeLoadType.BeforeSceneLoad)]
+ //static void OnBeforeSceneLoaded()
+ //{
+ //Debug.Log("Before scene is loaded.");
+
+ // //TMPro.TMP_Settings.LoadDefaultSettings();
+ // //TMPro.TMP_StyleSheet.LoadDefaultStyleSheet();
+
+ // //ShaderVariantCollection collection = new ShaderVariantCollection();
+ // //Shader s0 = Shader.Find("TextMeshPro/Mobile/Distance Field");
+ // //ShaderVariantCollection.ShaderVariant tmp_Variant = new ShaderVariantCollection.ShaderVariant(s0, UnityEngine.Rendering.PassType.Normal, string.Empty);
+
+ // //collection.Add(tmp_Variant);
+ // //collection.WarmUp();
+ //}
+
+ }
+
+ //static class TMP_ProjectSettings
+ //{
+ // [InitializeOnLoadMethod]
+ // static void SetProjectDefineSymbols()
+ // {
+ // string currentBuildSettings = PlayerSettings.GetScriptingDefineSymbolsForGroup(EditorUserBuildSettings.selectedBuildTargetGroup);
+
+ // //Check for and inject TMP_INSTALLED
+ // if (!currentBuildSettings.Contains("TMP_PRESENT"))
+ // {
+ // PlayerSettings.SetScriptingDefineSymbolsForGroup(EditorUserBuildSettings.selectedBuildTargetGroup, currentBuildSettings + ";TMP_PRESENT");
+ // }
+ // }
+ //}
+}