public override void OnInspectorGUI()
        {
            DrawSeperator();
            UIItemPanel b = style as UIItemPanel;

            if (b != null)
            {
                EditorGUI.BeginChangeCheck();
                b.skinIndex = EditorGUILayout.DelayedIntField("Skin Index", b.skinIndex);
                _skinListDrawer.Draw(serializedObject);
                if (b.skinCount == 0)
                {
                    EditorGUILayout.HelpBox("No Skin Picked", MessageType.Error);
                }
                else
                {
                    for (int i = 0; i < b.skinCount; i++)
                    {
                        GameObject o = b.GetSkinAt(i);
                        if (!o)
                        {
                            EditorGUILayout.HelpBox("skin 丢失", MessageType.Error);
                        }
                        else if (!UIPrefabUtility.IsFilterStyle(o, UIType.CellSkin))
                        {
                            EditorGUILayout.HelpBox(string.Format("{0}不是cell skill", o.name), MessageType.Error);
                        }
                    }
                }
                EditorGUI.BeginChangeCheck();
                int count = EditorGUILayout.DelayedIntField("Test Count:", b.length);
                if (EditorGUI.EndChangeCheck())
                {
                    if (count < 0)
                    {
                        count = 1;
                    }
                    object[] nt = new object[count];
                    for (int i = 0; i < count; i++)
                    {
                        nt[i] = new DataPaneTestData {
                            name = "test_" + i
                        };
                    }
                    b.SetList(nt);
                }
                b.selectable            = EditorGUILayout.Toggle("Selectable", b.selectable);
                b.allowMultipleSelecton = EditorGUILayout.Toggle("Multi Selectable", b.allowMultipleSelecton);
                if (EditorGUI.EndChangeCheck())
                {
                    EditorUtility.SetDirty(b);
                }
                if (!b.GetComponent <GridLayoutCore>())
                {
                    EditorGUILayout.HelpBox("Layout 丢失", MessageType.Error);
                }
                GUILayout.Space(10);
            }
        }
        public override void OnInspectorGUI()
        {
            EditorGUI.BeginChangeCheck();
            _debuger.hero = (GameObject)EditorGUILayout.ObjectField("Host", _debuger.hero, typeof(GameObject), true);
            if (EditorGUI.EndChangeCheck())
            {
                UpdateHost();
            }
            EditorGUI.BeginChangeCheck();
            _listDrawer.Draw(serializedObject);
            FireFxCanvas canvas = TreeCenter.currCanvas as FireFxCanvas;

            if (canvas != null)
            {
                TreeCell main = TreeCenter.selection.main;
                if (main != null)
                {
                    EditStyles.DrawHorizontalSeperator();
                    GUILayout.Label("Current Cell : " + main.cellType, EditStyles.boldLabel);
                    PInspectorCore[] ps = main.GetProperties();
                    PInspectorCore.BeginLabelWidth(ps);
                    EditorGUI.BeginChangeCheck();
                    GUILayout.BeginHorizontal();
                    GUILayout.Label("Name", GUILayout.Width(PInspectorCore.labelWidth));
                    main.editName = EditorGUILayout.DelayedTextField(main.editName);
                    GUILayout.EndHorizontal();
                    if (EditorGUI.EndChangeCheck())
                    {
                        PPaintCenter.RepaintClients();
                    }
                    PInspectorCore.useLabelString = TreeCenter.useChn;
                    for (int i = 0; i < ps.Length; i++)
                    {
                        if (!main.OnInspectorDraw(ps[i], _debuger) && !ps[i].hideInInspector)
                        {
                            ps[i].Draw();
                        }
                        main.AfterInspectorDraw(ps[i]);
                    }
                    PInspectorCore.useLabelString = false;
                    PInspectorCore.EndLabelWidth();
                }
                if (Application.isPlaying)
                {
                    if (main != null)
                    {
                        EditStyles.DrawHorizontalSeperator();
                    }
                    GUILayout.Space(10);
                    GUILayout.BeginHorizontal();
                    GUILayout.FlexibleSpace();
                    if (GUILayout.Button("Play", GUILayout.Width(100)))
                    {
                        _debuger.Play(canvas);
                    }
                    GUILayout.FlexibleSpace();
                    GUILayout.EndHorizontal();
                }
            }
            if (EditorGUI.EndChangeCheck())
            {
                EditorUtility.SetDirty(_debuger);
            }
        }
        public override void OnInspectorGUI()
        {
            _picker.Draw(style);
            DrawSeperator();
            UIDataPane b = style as UIDataPane;

            if (b != null)
            {
                EditorGUI.BeginChangeCheck();
                _scrollDrawer.Draw(b.scrollSetting, b);
                DrawSeperator();
                b.skinIndex = EditorGUILayout.DelayedIntField("Skin Index", b.skinIndex);
                _listDrawer.Draw(serializedObject);
                if (b.skinCount == 0)
                {
                    EditorGUILayout.HelpBox("No Skin Picked", MessageType.Error);
                }
                else
                {
                    for (int i = 0; i < b.skinCount; i++)
                    {
                        GameObject o = b.GetSkinAt(i);
                        if (!o)
                        {
                            EditorGUILayout.HelpBox("skin 丢失", MessageType.Error);
                        }
                        else if (!UIPrefabUtility.IsFilterStyle(o, UIType.CellSkin))
                        {
                            EditorGUILayout.HelpBox(string.Format("{0}不是cell skill", o.name), MessageType.Error);
                        }
                    }
                }
                DrawSeperator();
                EditorGUI.BeginChangeCheck();
                int count = EditorGUILayout.DelayedIntField("Test Count:", b.length);
                if (EditorGUI.EndChangeCheck())
                {
                    if (count < 0)
                    {
                        count = 1;
                    }
                    object[] nt = new object[count];
                    for (int i = 0; i < count; i++)
                    {
                        nt[i] = new DataPaneTestData {
                            name = "test_" + i
                        };
                    }
                    b.SetList(nt);
                }
                b.selectable            = EditorGUILayout.Toggle("Selectable", b.selectable);
                b.allowMultipleSelecton = EditorGUILayout.Toggle("Multi Selectable", b.allowMultipleSelecton);
                EditorGUILayout.LabelField("Border (Left, Top, Right, Bottom)");
                b.border = EditorGUILayout.Vector4Field("", b.border);
                GUILayout.Space(10);
                b.controlObj = (UICore)EditorGUILayout.ObjectField("Pager Host", b.controlObj, typeof(UICore), true);
                if (b.controlObj && !(b.controlObj is ISelectableContainer))
                {
                    EditorGUILayout.HelpBox(
                        "control host must be typeof (ISelectableUIContainer) include:\r\n\tTabNavigaor\r\n\tDataPane\r\r\tItemPane",
                        MessageType.Warning);
                }
                if (!b.GetComponent <GridLayoutCore>())
                {
                    EditorGUILayout.HelpBox("Layout 丢失", MessageType.Error);
                }
                GUILayout.Space(10);
            }
        }