mirror of
https://github.com/Orama-Interactive/Pixelorama.git
synced 2025-02-12 08:43:08 +00:00
Toggled autosave on by default, and open last project off by default
This commit is contained in:
parent
5424472c95
commit
62a695366a
|
@ -43,7 +43,7 @@ var can_draw := false
|
||||||
|
|
||||||
var has_focus := false
|
var has_focus := false
|
||||||
var pressure_sensitivity_mode = Pressure_Sensitivity.NONE
|
var pressure_sensitivity_mode = Pressure_Sensitivity.NONE
|
||||||
var open_last_project := true
|
var open_last_project := false
|
||||||
var smooth_zoom := true
|
var smooth_zoom := true
|
||||||
var cursor_image = preload("res://assets/graphics/cursor_icons/cursor.png")
|
var cursor_image = preload("res://assets/graphics/cursor_icons/cursor.png")
|
||||||
var left_cursor_tool_texture : ImageTexture
|
var left_cursor_tool_texture : ImageTexture
|
||||||
|
|
|
@ -15,7 +15,7 @@ func _ready() -> void:
|
||||||
autosave_timer.connect("timeout", self, "_on_Autosave_timeout")
|
autosave_timer.connect("timeout", self, "_on_Autosave_timeout")
|
||||||
add_child(autosave_timer)
|
add_child(autosave_timer)
|
||||||
set_autosave_interval(default_autosave_interval)
|
set_autosave_interval(default_autosave_interval)
|
||||||
toggle_autosave(false) # Gets started from preferences dialog
|
toggle_autosave(true) # Gets started from preferences dialog
|
||||||
|
|
||||||
|
|
||||||
func open_pxo_file(path : String, untitled_backup : bool = false) -> void:
|
func open_pxo_file(path : String, untitled_backup : bool = false) -> void:
|
||||||
|
|
|
@ -168,7 +168,6 @@ func _ready() -> void:
|
||||||
$QuitAndSaveDialog.add_button("Save & Exit", false, "Save")
|
$QuitAndSaveDialog.add_button("Save & Exit", false, "Save")
|
||||||
$QuitAndSaveDialog.get_ok().text = "Exit without saving"
|
$QuitAndSaveDialog.get_ok().text = "Exit without saving"
|
||||||
|
|
||||||
|
|
||||||
if not Global.config_cache.has_section_key("preferences", "startup"):
|
if not Global.config_cache.has_section_key("preferences", "startup"):
|
||||||
Global.config_cache.set_value("preferences", "startup", true)
|
Global.config_cache.set_value("preferences", "startup", true)
|
||||||
|
|
||||||
|
@ -180,11 +179,6 @@ func _ready() -> void:
|
||||||
else:
|
else:
|
||||||
Global.can_draw = true
|
Global.can_draw = true
|
||||||
|
|
||||||
if not Global.config_cache.has_section_key("preferences", "open_last_project"):
|
|
||||||
Global.config_cache.set_value("preferences", "open_last_project", true)
|
|
||||||
if Global.config_cache.get_value("preferences", "open_last_project"):
|
|
||||||
Global.open_last_project = Global.config_cache.get_value("preferences", "open_last_project")
|
|
||||||
|
|
||||||
# If backup file exists then Pixelorama was not closed properly (probably crashed) - reopen backup
|
# If backup file exists then Pixelorama was not closed properly (probably crashed) - reopen backup
|
||||||
$BackupConfirmation.get_cancel().text = tr("Delete")
|
$BackupConfirmation.get_cancel().text = tr("Delete")
|
||||||
if Global.config_cache.has_section("backups"):
|
if Global.config_cache.has_section("backups"):
|
||||||
|
|
|
@ -147,7 +147,6 @@ margin_right = 494.0
|
||||||
margin_bottom = 124.0
|
margin_bottom = 124.0
|
||||||
hint_tooltip = "Opens last opened project on startup"
|
hint_tooltip = "Opens last opened project on startup"
|
||||||
mouse_default_cursor_shape = 2
|
mouse_default_cursor_shape = 2
|
||||||
pressed = true
|
|
||||||
text = "Open last project on startup"
|
text = "Open last project on startup"
|
||||||
|
|
||||||
[node name="EnableAutosave" type="CheckBox" parent="HSplitContainer/ScrollContainer/VBoxContainer/General"]
|
[node name="EnableAutosave" type="CheckBox" parent="HSplitContainer/ScrollContainer/VBoxContainer/General"]
|
||||||
|
@ -155,6 +154,7 @@ margin_top = 128.0
|
||||||
margin_right = 494.0
|
margin_right = 494.0
|
||||||
margin_bottom = 152.0
|
margin_bottom = 152.0
|
||||||
mouse_default_cursor_shape = 2
|
mouse_default_cursor_shape = 2
|
||||||
|
pressed = true
|
||||||
text = "Enable autosave"
|
text = "Enable autosave"
|
||||||
__meta__ = {
|
__meta__ = {
|
||||||
"_edit_use_anchors_": false
|
"_edit_use_anchors_": false
|
||||||
|
|
Loading…
Reference in a new issue