File tree Expand file tree Collapse file tree
addons/android-device-explorer Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -4,7 +4,7 @@ extends EditorPlugin
44var dock
55
66func _enter_tree ():
7- var dock_control = preload ("res://addons/android-device-explorer/device_explorer.gd" ).new ()
7+ var dock_control = preload ("res://addons/android-device-explorer/scripts/ device_explorer.gd" ).new ()
88 dock = EditorDock .new ()
99 dock .add_child (dock_control )
1010 dock .title = "Device Explorer"
Original file line number Diff line number Diff line change @@ -77,10 +77,7 @@ func _setup_ui() -> void:
7777 popup .id_pressed .connect (_on_dock_menu_item_pressed )
7878 topbar .add_child (dock_menu_button )
7979
80- tree = Tree .new ()
81- tree .size_flags_vertical = Control .SIZE_EXPAND_FILL
82- tree .hide_root = true
83- tree .allow_rmb_select = true
80+ tree = preload ("res://addons/android-device-explorer/scripts/root_tree.gd" ).new ()
8481 tree .item_collapsed .connect (_on_item_collapsed )
8582 tree .item_mouse_selected .connect (_on_item_mouse_selected )
8683 add_child (tree )
@@ -179,6 +176,8 @@ func _on_item_collapsed(item: TreeItem) -> void:
179176
180177
181178func _on_dir_expanded (item : TreeItem , refresh := false ) -> void :
179+ if not item : return
180+
182181 var meta = item .get_metadata (0 )
183182 if not meta or not meta .is_dir : return
184183
File renamed without changes.
Original file line number Diff line number Diff line change 1+ @tool
2+ extends Tree
3+
4+ func _init () -> void :
5+ size_flags_vertical = Control .SIZE_EXPAND_FILL
6+ hide_root = true
7+ allow_rmb_select = true
8+
9+
10+ func _can_drop_data (_at_position : Vector2 , data : Variant ) -> bool :
11+ return data is Dictionary and data .has ("files" )
12+
13+ func _drop_data (at_position : Vector2 , data : Variant ) -> void :
14+ var dropped_files = data ["files" ]
15+ var target_item = get_item_at_position (at_position )
16+ var path : String = target_item .get_metadata (0 ).path
17+ if not path or path .is_empty (): return
18+
19+ for file_path in dropped_files :
20+ get_parent ()._push (ProjectSettings .globalize_path (file_path ), path .path_join (file_path .get_file ()))
21+ get_parent ()._on_dir_expanded (target_item , true )
Original file line number Diff line number Diff line change 1+ uid://dhjew7oj35plt
Original file line number Diff line number Diff line change 1+ [remap]
2+
3+ importer="texture"
4+ type="CompressedTexture2D"
5+ uid="uid://7flgybwpfm42"
6+ path="res://.godot/imported/device-explorer-thumbnail.webp-25dbad2710012db9ff6aa0c20bc78c53.ctex"
7+ metadata={
8+ "vram_texture": false
9+ }
10+
11+ [deps]
12+
13+ source_file="res://device-explorer-thumbnail.webp"
14+ dest_files=["res://.godot/imported/device-explorer-thumbnail.webp-25dbad2710012db9ff6aa0c20bc78c53.ctex"]
15+
16+ [params]
17+
18+ compress/mode=0
19+ compress/high_quality=false
20+ compress/lossy_quality=0.7
21+ compress/uastc_level=0
22+ compress/rdo_quality_loss=0.0
23+ compress/hdr_compression=1
24+ compress/normal_map=0
25+ compress/channel_pack=0
26+ mipmaps/generate=false
27+ mipmaps/limit=-1
28+ roughness/mode=0
29+ roughness/src_normal=""
30+ process/channel_remap/red=0
31+ process/channel_remap/green=1
32+ process/channel_remap/blue=2
33+ process/channel_remap/alpha=3
34+ process/fix_alpha_border=true
35+ process/premult_alpha=false
36+ process/normal_map_invert_y=false
37+ process/hdr_as_srgb=false
38+ process/hdr_clamp_exposure=false
39+ process/size_limit=0
40+ detect_3d/compress_to=1
You can’t perform that action at this time.
0 commit comments