void Awake() { setResistorValuePanel = SliderValuePanel.Instance(); resistorSaveAction = new UnityAction(resistorSaveFunction); resistorCancelAction = new UnityAction(resistorCancelFunction); deleteConfirmPanel = DeleteConfirmPanel.Instance(); resetAllYesAction = new UnityAction(resetAllYesFunction); resetAllCancelAction = new UnityAction(resetAllCancelFunction); selectCapacitorValuePanel = SelectValuePanel.Instance(); capacitorSaveAction = new UnityAction(capacitorSaveFunction); capacitorCancelAction = new UnityAction(capacitorCancelFunction); selectInductorValuePanel = SelectValuePanel.Instance(); inductorSaveAction = new UnityAction(inductorSaveFunction); inductorCancelAction = new UnityAction(inductorCancelFunction); settingAwgPanel = SelectSingleValuePanel.Instance(); awgOnAction = new UnityAction(awgOnFunction); awgCloseAction = new UnityAction(awgCloseFunction); readVoltmeterPanel = VoltmeterPanel.Instance(); adcRefreshAction = new UnityAction(adcRefreshFunction); editTogglePanel = EditTogglePanel.Instance(); resetAllStateAction = new UnityAction(HandleDeleteMode); //constraintsSaveAction = new UnityAction (constraintsSaveFunction); }
//private float minValue; //private float maxValue; public static SliderValuePanel Instance() { if (!modalPanel) { modalPanel = FindObjectOfType(typeof(SliderValuePanel)) as SliderValuePanel; if (!modalPanel) { Debug.LogError("There needs to be one active ModalPanel script on a GameObject in your scene."); } } return(modalPanel); }