예제 #1
0
        public int UndoableContentScaledToolbar(Rect r, string label, int selected, string[] labels, string undoInfix)
        {
            int newValue = SF_GUI.ContentScaledToolbar(r, label, selected, labels);

            if (newValue != selected)
            {
                string undoName = "set " + undoInfix + " to " + labels[newValue];
                Undo.RecordObject(this, undoName);
                return(newValue);
            }
            return(selected);
        }