You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-04 12:00:25 +00:00
Add file and dir temporary utilities
Co-authored by @Alex2782 for the Android bindings. Many thanks to the reviewers also. Co-authored-by: Alex <alex.hart.278@gmail.com>
This commit is contained in:
@@ -61,6 +61,13 @@ private:
|
||||
bool include_navigational = false;
|
||||
bool include_hidden = false;
|
||||
|
||||
bool _is_temp = false;
|
||||
bool _temp_keep_after_free = false;
|
||||
String _temp_path;
|
||||
void _delete_temp();
|
||||
|
||||
static Ref<DirAccess> _create_temp(const String &p_prefix = "", bool p_keep = false);
|
||||
|
||||
protected:
|
||||
static void _bind_methods();
|
||||
|
||||
@@ -136,6 +143,7 @@ public:
|
||||
}
|
||||
|
||||
static Ref<DirAccess> open(const String &p_path, Error *r_error = nullptr);
|
||||
static Ref<DirAccess> create_temp(const String &p_prefix = "", bool p_keep = false, Error *r_error = nullptr);
|
||||
|
||||
static int _get_drive_count();
|
||||
static String get_drive_name(int p_idx);
|
||||
@@ -161,8 +169,9 @@ public:
|
||||
|
||||
virtual bool is_case_sensitive(const String &p_path) const;
|
||||
|
||||
public:
|
||||
DirAccess() {}
|
||||
virtual ~DirAccess() {}
|
||||
virtual ~DirAccess();
|
||||
};
|
||||
|
||||
#endif // DIR_ACCESS_H
|
||||
|
||||
Reference in New Issue
Block a user