From 253f1fa1fb41790ed7ca46668063e43c8de07aaf Mon Sep 17 00:00:00 2001 From: Luke Hubmayer-Werner Date: Fri, 8 Dec 2023 21:29:09 +1030 Subject: [PATCH] Rename RomSelect and WebFileSelect to FileSelect and FileSelectWeb better alphabetical grouping in editors --- main.gd | 4 ++-- scripts/loaders/RomLoader.gd | 5 +++-- widgets/{RomSelect.gd => FileSelect.gd} | 0 widgets/{RomSelect.tscn => FileSelect.tscn} | 4 ++-- widgets/{WebFileSelect.gd => FileSelectWeb.gd} | 0 widgets/{WebFileSelect.tscn => FileSelectWeb.tscn} | 4 ++-- 6 files changed, 9 insertions(+), 8 deletions(-) rename widgets/{RomSelect.gd => FileSelect.gd} (100%) rename widgets/{RomSelect.tscn => FileSelect.tscn} (97%) rename widgets/{WebFileSelect.gd => FileSelectWeb.gd} (100%) rename widgets/{WebFileSelect.tscn => FileSelectWeb.tscn} (98%) diff --git a/main.gd b/main.gd index b14f149..c6a4690 100644 --- a/main.gd +++ b/main.gd @@ -30,9 +30,9 @@ func _on_saveslot_loaded(dict) -> void: func _ready() -> void: if OS.get_name() != 'HTML5' or !OS.has_feature('JavaScript'): - packed_menus[Menu.LOADER] = preload('res://widgets/RomSelect.tscn') + packed_menus[Menu.LOADER] = preload('res://widgets/FileSelect.tscn') else: - packed_menus[Menu.LOADER] = preload('res://widgets/WebFileSelect.tscn') + packed_menus[Menu.LOADER] = preload('res://widgets/FileSelectWeb.tscn') menus[Menu.LOADER] = packed_menus[Menu.LOADER].instance() push_menu(Menu.LOADER) diff --git a/scripts/loaders/RomLoader.gd b/scripts/loaders/RomLoader.gd index ea35a82..deb5045 100644 --- a/scripts/loaders/RomLoader.gd +++ b/scripts/loaders/RomLoader.gd @@ -19,7 +19,7 @@ var rom_snes := File.new() var snes_data := {} var snes_bytes: PoolByteArray var snes_buffer: StreamPeerBuffer -var thread := Thread.new() +#var thread := Thread.new() func load_snes_structs(buffer: StreamPeerBuffer) -> Dictionary: var data := {} @@ -120,4 +120,5 @@ func _ready(): pass func _exit_tree() -> void: - thread.wait_to_finish() + pass +# thread.wait_to_finish() diff --git a/widgets/RomSelect.gd b/widgets/FileSelect.gd similarity index 100% rename from widgets/RomSelect.gd rename to widgets/FileSelect.gd diff --git a/widgets/RomSelect.tscn b/widgets/FileSelect.tscn similarity index 97% rename from widgets/RomSelect.tscn rename to widgets/FileSelect.tscn index cfc454a..19d69fc 100644 --- a/widgets/RomSelect.tscn +++ b/widgets/FileSelect.tscn @@ -1,9 +1,9 @@ [gd_scene load_steps=3 format=2] [ext_resource path="res://theme/menu_theme.tres" type="Theme" id=1] -[ext_resource path="res://widgets/RomSelect.gd" type="Script" id=2] +[ext_resource path="res://widgets/FileSelect.gd" type="Script" id=2] -[node name="RomSelect" type="PanelContainer"] +[node name="FileSelect" type="PanelContainer"] anchor_right = 1.0 anchor_bottom = 1.0 rect_min_size = Vector2( 384, 240 ) diff --git a/widgets/WebFileSelect.gd b/widgets/FileSelectWeb.gd similarity index 100% rename from widgets/WebFileSelect.gd rename to widgets/FileSelectWeb.gd diff --git a/widgets/WebFileSelect.tscn b/widgets/FileSelectWeb.tscn similarity index 98% rename from widgets/WebFileSelect.tscn rename to widgets/FileSelectWeb.tscn index 7d5dce9..0b98fe5 100644 --- a/widgets/WebFileSelect.tscn +++ b/widgets/FileSelectWeb.tscn @@ -1,9 +1,9 @@ [gd_scene load_steps=3 format=2] [ext_resource path="res://theme/menu_theme.tres" type="Theme" id=1] -[ext_resource path="res://widgets/WebFileSelect.gd" type="Script" id=2] +[ext_resource path="res://widgets/FileSelectWeb.gd" type="Script" id=2] -[node name="WebFileSelect" type="PanelContainer"] +[node name="FileSelect" type="PanelContainer"] anchor_right = 1.0 anchor_bottom = 1.0 rect_min_size = Vector2( 384, 240 )