private void OnDrawElementLocation(Rect rect, int index, bool isactive, bool isfocused)
        {
            SaveMethod      saveMethod = settingObject.SaveLocations[index];
            IListItemDrawer itemDrawer = (IListItemDrawer)settingObject.SaveLocations[index];

            EditorGUI.BeginChangeCheck();

            if (itemDrawer != null)
            {
                itemDrawer.OnDrawElement(rect, line_height);
            }
            else if (saveMethod != null)
            {
                GUI.Label(new Rect(rect.position, new Vector2(rect.width - 40, 16)), saveMethod.SaveName);
            }
            else
            {
                settingObject.SaveLocations[index] = (SaveMethod)EditorGUI.ObjectField(
                    new Rect(rect.position, new Vector2(rect.width, line_height)),
                    saveMethod, typeof(SaveMethod), false);
            }


            if (EditorGUI.EndChangeCheck())
            {
                EditorUtility.SetDirty(saveMethod);
                SaveChanges();
            }
        }
        /// <summary>
        /// draw list element
        /// </summary>
        /// <param name="rect"></param>
        /// <param name="index"></param>
        /// <param name="isactive"></param>
        /// <param name="isfocused"></param>
        private void OnDrawElementVariables(Rect rect, int index, bool isactive, bool isfocused)
        {
            SavableVariable saveVar    = settingObject.Data[index];
            IListItemDrawer itemDrawer = (IListItemDrawer)settingObject.Data[index];


            EditorGUI.BeginChangeCheck();

            if (itemDrawer != null)
            {
                itemDrawer.OnDrawElement(rect, line_height);
            }
            else if (saveVar != null)
            {
                GUI.Label(new Rect(new Vector2(rect.position.x, rect.position.y + line_height), new Vector2(rect.width, line_height)), saveVar.ToString());
            }
            else
            {
                saveVar = (SavableVariable)EditorGUI.ObjectField(
                    new Rect(rect.position, new Vector2(rect.width, line_height)),
                    saveVar, typeof(SavableVariable), false);
            }
            if (EditorGUI.EndChangeCheck())
            {
                EditorUtility.SetDirty(saveVar);
                SaveChanges();
            }
        }
        private float GetElementHeightLocation(int index)
        {
            IListItemDrawer itemDrawer = (IListItemDrawer)settingObject.SaveLocations[index];

            if (itemDrawer != null)
            {
                return(itemDrawer.GetElementHeight(line_height) + 6);
            }
            return(line_height + 6);
        }
        private float GetElementHeightVariables(int index)
        {
            IListItemDrawer itemDrawer = (IListItemDrawer)settingObject.Data[index];

            if (itemDrawer != null)
            {
                return(itemDrawer.GetElementHeight(line_height) + 6);
            }
            if (settingObject.Data[index] == null)
            {
                return(line_height + 6);
            }
            return((line_height + 2) * 1 + 6);
        }