private void Settings_ButtonClicked() { _settingsDialog.GetNode <SpinBox>("VBoxContainer/HBoxContainer/ResolutionSpinBox").Value = _polygonizer.Resolution; _settingsDialog.GetNode <SpinBox>("VBoxContainer/HBoxContainer2/MarginSpinBox").Value = _polygonizer.Margin; _settingsDialog.GetNode <CheckBox>("VBoxContainer/PreviewCheckBox").Pressed = _enablePreview; _settingsDialog.PopupCentered(); }
private void SaveButtonPressed() { GUICommon.Instance.PlayButtonPressSound(); var name = GetSaveName(); if (FileHelpers.Exists(PathUtils.Join(Constants.SAVE_FOLDER, name))) { overwriteConfirm.DialogText = $"The chosen filename ({name}) already exists. Overwrite?"; overwriteConfirm.PopupCentered(); } else { OnConfirmSaveName(); } }
private void SaveButtonPressed() { GUICommon.Instance.PlayButtonPressSound(); var name = GetSaveName(); if (FileHelpers.Exists(PathUtils.Join(Constants.SAVE_FOLDER, name))) { // The chosen filename ({0}) already exists. Overwrite? overwriteConfirm.DialogText = string.Format(CultureInfo.CurrentCulture, TranslationServer.Translate("THE_CHOSEN_FILENAME_ALREADY_EXISTS"), name); overwriteConfirm.PopupCentered(); } else { OnConfirmSaveName(); } }
public void PopupAddStation() { NewStation.PopupCentered(); }
public void _on_SettingsButton_pressed() { _settingsWindow.PopupCentered(); }
private void _on_Quit_pressed() { GD.Print("Quit? Popup"); // open PopUp Dialog (size: 300, 100) myQuitDialog.PopupCentered(new Vector2(300, 100)); }