Ejemplo n.º 1
0
        private static void GetPathFromLocation()
        {
            ScriptsPathData data = ToolCacheManager.GetCacheObject <ScriptsPathData>(PathManager.StrangeIOCDataPath);

            m_ViewPath     = data.ViewPath;
            m_MediatorPath = data.MediatorPath;
        }
Ejemplo n.º 2
0
        private static void GetPathFromLocation()
        {
            ScriptsPathData data = ToolCacheManager.GetCacheObject <ScriptsPathData>(PathManager.FrameScriptDataPath + m_DataName);

            m_ViewPath     = data.ViewPath;
            m_MediatorPath = data.MediatorPath;
        }
Ejemplo n.º 3
0
        private void SavePathToLocation()
        {
            ScriptsPathData data = new ScriptsPathData();

            data.ViewPath     = m_ViewPath;
            data.MediatorPath = m_MediatorPath;
            ToolCacheManager.SaveCacheObject(PathManager.StrangeIOCDataPath, data);
        }
Ejemplo n.º 4
0
        private void SavePathToLocation()
        {
            Directory.CreateDirectory(PathManager.FrameScriptDataPath);
            ScriptsPathData data = new ScriptsPathData();

            data.ViewPath     = m_ViewPath;
            data.MediatorPath = m_MediatorPath;
            ToolCacheManager.SaveCacheObject(PathManager.FrameScriptDataPath + m_DataName, data);
        }
Ejemplo n.º 5
0
 private static void ChangeDefaultFont()
 {
     if (Selection.activeGameObject != null)
     {
         Text text = Selection.activeGameObject.Get <Text>();
         if (text != null)
         {
             text.font = ToolCacheManager.GetFont();
         }
     }
 }
Ejemplo n.º 6
0
 private static void ChangeDefaultFont()
 {
     if (Selection.activeGameObject != null)
     {
         Text text = Selection.activeGameObject.Get <Text>();
         if (text != null)
         {
             text.font = ToolCacheManager.GetCacheObject <FontData>(PathManager.FontDataPath).defaultFont;
         }
     }
 }
Ejemplo n.º 7
0
        //保存数据到本地
        public static void SaveDataToLocal()
        {
            EntitasData data = new EntitasData();

            data.ViewPath           = ViewPath;
            data.ServicePath        = ServicePath;
            data.SystemPath         = SystemPath;
            data.ServiceManagerPath = ServiceManagerPath;
            data.GameFeaturePath    = GameFeaturePath;
            data.InputFeaturePath   = InputFeaturePath;
            data.ViewFeaturePath    = ViewFeaturePath;
            ToolCacheManager.SaveCacheObject(PathManager.EntitasDataPath, data);
        }
Ejemplo n.º 8
0
 private void OnGUI()
 {
     EditorGUILayout.Space();
     EditorGUILayout.LabelField("选择默认字体");
     EditorGUILayout.Space();
     m_font = (Font)EditorGUILayout.ObjectField(m_font, typeof(Font), true);
     EditorGUILayout.Space();
     if (GUILayout.Button("确定"))
     {
         ToolCacheManager.SaveFont(m_font);
         window.Close();
     }
 }
Ejemplo n.º 9
0
        private void OnGUI()
        {
            GUILayout.Label("命名空间名称");
            Rect rect = EditorGUILayout.GetControlRect(GUILayout.Width(200));

            _isOn = GUILayout.Toggle(_isOn, "是否开启插件");

            if (GUILayout.Button("完成", GUILayout.MaxWidth(100)))
            {
                NamespaceData data = new NamespaceData();
                data.IsOn = _isOn;

                ToolCacheManager.SaveCacheObject(PathManager.NameSpaceDataPath, data);
            }
        }
Ejemplo n.º 10
0
        //从本地读取数据
        private static void ReadDataFromLocal()
        {
            EntitasData data = ToolCacheManager.GetCacheObject <EntitasData>(PathManager.EntitasDataPath);

            if (data != null)
            {
                ViewPath           = data.ViewPath;
                ServicePath        = data.ServicePath;
                SystemPath         = data.SystemPath;
                ServiceManagerPath = data.ServiceManagerPath;
                GameFeaturePath    = data.GameFeaturePath;
                InputFeaturePath   = data.InputFeaturePath;
                ViewFeaturePath    = data.ViewFeaturePath;
            }
        }
Ejemplo n.º 11
0
 private void OnGUI()
 {
     EditorGUILayout.Space();
     EditorGUILayout.LabelField("选择默认字体");
     EditorGUILayout.Space();
     m_font = (Font)EditorGUILayout.ObjectField(m_font, typeof(Font), true);
     EditorGUILayout.Space();
     if (GUILayout.Button("确定"))
     {
         FontData data = new FontData();
         data.defaultFont = m_font;
         ToolCacheManager.SaveCacheObject(PathManager.FontDataPath, data);
         window.Close();
     }
 }
Ejemplo n.º 12
0
        private void OnGUI()
        {
            GUILayout.Label("命名空间名称");
            Rect rect = EditorGUILayout.GetControlRect(GUILayout.Width(200));

            _name = EditorGUI.TextField(rect, _name);

            if (GUILayout.Button("完成", GUILayout.MaxWidth(100)))
            {
                NameSpaceData data = new NameSpaceData();
                data.NameSpaceName = _name;
                ToolCacheManager.SaveCacheObject(PathManager.NameSpaceDataPath, data);
                _window.Close();
            }
        }
Ejemplo n.º 13
0
 public static void OpenWindow()
 {
     window         = GetWindow(typeof(SetDefaultFont));
     window.minSize = new Vector2(500, 300);
     m_font         = ToolCacheManager.GetFont();
 }
Ejemplo n.º 14
0
 public static void OpenWindow()
 {
     window         = GetWindow(typeof(SetDefaultFont));
     window.minSize = new Vector2(500, 300);
     m_font         = ToolCacheManager.GetCacheObject <FontData>(PathManager.FontDataPath).defaultFont;
 }
Ejemplo n.º 15
0
 private static void Init()
 {
     _name = ToolCacheManager.GetCacheObject <NameSpaceData>(PathManager.NameSpaceDataPath).NameSpaceName;
 }
Ejemplo n.º 16
0
 private static string GetNamespaceName()
 {
     return(ToolCacheManager.GetCacheObject <NameSpaceData>(PathManager.NameSpaceDataPath).NameSpaceName);
 }
Ejemplo n.º 17
0
 public static NamespaceData GetData()
 {
     return(ToolCacheManager.GetCacheObject <NamespaceData>(PathManager.NameSpaceDataPath));
 }