public virtual void ImportStandardText(Localization localization)
        {
            string path = EditorUtility.OpenFilePanel("Import Standard Text", "Assets/", "txt");
            if (path.Length == 0)
            {
                return;
            }

            localization.ClearLocalizeableCache();

            string textData = File.ReadAllText(path);
            localization.SetStandardText(textData);

            ShowNotification(localization);
        }
        public virtual void ExportStandardText(Localization localization)
        {
            string path = EditorUtility.SaveFilePanel("Export Standard Text", "Assets/", "standard.txt", "");
            if (path.Length == 0)
            {
                return;
            }

            localization.ClearLocalizeableCache();

            string textData = localization.GetStandardText();
            File.WriteAllText(path, textData);
            AssetDatabase.Refresh();

            ShowNotification(localization);
        }
Beispiel #3
0
        public virtual void ImportStandardText(Localization localization)
        {
            string path = EditorUtility.OpenFilePanel("Import Standard Text", "Assets/", "txt");

            if (path.Length == 0)
            {
                return;
            }

            localization.ClearLocalizeableCache();

            string textData = File.ReadAllText(path);

            localization.SetStandardText(textData);

            ShowNotification(localization);
        }
Beispiel #4
0
        public virtual void ExportStandardText(Localization localization)
        {
            string path = EditorUtility.SaveFilePanel("Export Standard Text", "Assets/", "standard.txt", "");

            if (path.Length == 0)
            {
                return;
            }

            localization.ClearLocalizeableCache();

            string textData = localization.GetStandardText();

            File.WriteAllText(path, textData);
            AssetDatabase.Refresh();

            ShowNotification(localization);
        }