/// <summary>
    /// 绘制委托事件
    /// </summary>

    static public void DrawEvents(string text, Object undoObject, List <EventDelegate> list, string noTarget, string notValid)
    {
        if (!CustomUITweenEditorTools.DrawHeader(text, text, false))
        {
            return;
        }


        CustomUITweenEditorTools.BeginContents();
        GUILayout.BeginHorizontal();
        GUILayout.BeginVertical();

        EventDelegateEditor.Field(undoObject, list, notValid, notValid);

        GUILayout.EndVertical();
        GUILayout.EndHorizontal();
        CustomUITweenEditorTools.EndContents();
    }
    protected void DrawCommonProperties()
    {
        CustomUITweener tw = target as CustomUITweener;

        if (CustomUITweenEditorTools.DrawHeader("Tweener"))
        {
            CustomUITweenEditorTools.BeginContents();
            CustomUITweenEditorTools.SetLabelWidth(110f);

            GUI.changed = false;

            CustomUITweener.Style style = (CustomUITweener.Style)EditorGUILayout.EnumPopup("Play Style", tw.style);
            EaseType       easeType     = (EaseType)EditorGUILayout.EnumPopup("Ease Type", tw.easeType);
            AnimationCurve curve        = EditorGUILayout.CurveField("Animation Curve", tw.animationCurve, GUILayout.Width(170f), GUILayout.Height(62f));
            GUILayout.BeginHorizontal();
            float dur = EditorGUILayout.FloatField("Duration", tw.duration, GUILayout.Width(170f));
            GUILayout.Label("seconds");
            GUILayout.EndHorizontal();

            GUILayout.BeginHorizontal();
            float del = EditorGUILayout.FloatField("Start Delay", tw.delay, GUILayout.Width(170f));
            GUILayout.Label("seconds");
            GUILayout.EndHorizontal();

            int  tg = EditorGUILayout.IntField("Tween Group", tw.tweenGroup, GUILayout.Width(170f));
            bool ts = EditorGUILayout.Toggle("Ignore TimeScale", tw.ignoreTimeScale);

            if (GUI.changed)
            {
                CustomUITweenEditorTools.RegisterUndo("Tween Change", tw);
                tw.easeType        = easeType;
                tw.style           = style;
                tw.ignoreTimeScale = ts;
                tw.tweenGroup      = tg;
                tw.duration        = dur;
                tw.delay           = del;
                CustomUITweenTools.SetDirty(tw);
            }
            CustomUITweenEditorTools.EndContents();
        }

        CustomUITweenEditorTools.SetLabelWidth(80f);
        CustomUITweenEditorTools.DrawEvents("On Finished", tw, tw.onFinished);
    }