add setting

This commit is contained in:
Matt Parker
2025-10-02 21:16:38 +10:00
parent 27d58738bc
commit 24dc7f5b1f
3 changed files with 24 additions and 1 deletions

View File

@@ -0,0 +1,12 @@
using Godot;
namespace SharpIDE.Godot.Features.SlnPicker;
public partial class AutoOpenLastSlnButton : CheckBox
{
public override void _Ready()
{
ButtonPressed = Singletons.AppState.IdeSettings.AutoOpenLastSolution;
Pressed += () => Singletons.AppState.IdeSettings.AutoOpenLastSolution = ButtonPressed;
}
}

View File

@@ -0,0 +1 @@
uid://but0p7xwpfxtg

View File

@@ -1,7 +1,8 @@
[gd_scene load_steps=3 format=3 uid="uid://cwvhbsd1mdl2x"]
[gd_scene load_steps=4 format=3 uid="uid://cwvhbsd1mdl2x"]
[ext_resource type="Script" uid="uid://bjvwb6jg6jpsi" path="res://Features/SlnPicker/SlnPicker.cs" id="1_ciq0g"]
[ext_resource type="PackedScene" uid="uid://x5lhwvh5dium" path="res://Features/SlnPicker/PreviousSlnEntry.tscn" id="2_t7l5q"]
[ext_resource type="Script" uid="uid://but0p7xwpfxtg" path="res://Features/SlnPicker/AutoOpenLastSlnButton.cs" id="4_qs47j"]
[node name="SlnPicker" type="Control"]
layout_mode = 3
@@ -84,6 +85,15 @@ size_flags_vertical = 3
[node name="PreviousSlnEntry" parent="VSplitContainer/Panel/MarginContainer2/VBoxContainer2/ScrollContainer/PreviousSlnsVBoxContainer" instance=ExtResource("2_t7l5q")]
layout_mode = 2
[node name="HBoxContainer2" type="HBoxContainer" parent="VSplitContainer/Panel/MarginContainer2/VBoxContainer2"]
layout_mode = 2
[node name="AutoOpenLastSlnButton" type="CheckBox" parent="VSplitContainer/Panel/MarginContainer2/VBoxContainer2/HBoxContainer2"]
layout_mode = 2
theme_override_font_sizes/font_size = 14
text = "Auto-open last sln"
script = ExtResource("4_qs47j")
[node name="FileDialog" type="FileDialog" parent="."]
unique_name_in_owner = true
oversampling_override = 1.0