aboutsummaryrefslogtreecommitdiff
path: root/editor/plugins/resource_preloader_editor_plugin.h
diff options
context:
space:
mode:
authorRémi Verschelde2017-03-05 16:44:50 +0100
committerRémi Verschelde2017-03-05 16:44:50 +0100
commit5dbf1809c6e3e905b94b8764e99491e608122261 (patch)
tree5e5a5360db15d86d59ec8c6e4f7eb511388c5a9a /editor/plugins/resource_preloader_editor_plugin.h
parent45438e9918d421b244bfd7776a30e67dc7f2d3e3 (diff)
downloadgodot-5dbf180.tar.gz
godot-5dbf180.tar.zst
godot-5dbf180.zip
A Whole New World (clang-format edition)
I can show you the code Pretty, with proper whitespace Tell me, coder, now when did You last write readable code? I can open your eyes Make you see your bad indent Force you to respect the style The core devs agreed upon A whole new world A new fantastic code format A de facto standard With some sugar Enforced with clang-format A whole new world A dazzling style we all dreamed of And when we read it through It's crystal clear That now we're in a whole new world of code
Diffstat (limited to 'editor/plugins/resource_preloader_editor_plugin.h')
-rw-r--r--editor/plugins/resource_preloader_editor_plugin.h31
1 files changed, 12 insertions, 19 deletions
diff --git a/editor/plugins/resource_preloader_editor_plugin.h b/editor/plugins/resource_preloader_editor_plugin.h
index 54ccad434..946a3887e 100644
--- a/editor/plugins/resource_preloader_editor_plugin.h
+++ b/editor/plugins/resource_preloader_editor_plugin.h
@@ -29,18 +29,16 @@
#ifndef RESOURCE_PRELOADER_EDITOR_PLUGIN_H
#define RESOURCE_PRELOADER_EDITOR_PLUGIN_H
-
-#include "editor/editor_plugin.h"
#include "editor/editor_node.h"
+#include "editor/editor_plugin.h"
+#include "scene/gui/dialogs.h"
+#include "scene/gui/file_dialog.h"
#include "scene/gui/tree.h"
#include "scene/main/resource_preloader.h"
-#include "scene/gui/file_dialog.h"
-#include "scene/gui/dialogs.h"
-
class ResourcePreloaderEditor : public PanelContainer {
- GDCLASS(ResourcePreloaderEditor, PanelContainer );
+ GDCLASS(ResourcePreloaderEditor, PanelContainer);
Button *load;
Button *_delete;
@@ -48,17 +46,15 @@ class ResourcePreloaderEditor : public PanelContainer {
Tree *tree;
bool loading_scene;
-
EditorFileDialog *file;
AcceptDialog *dialog;
ResourcePreloader *preloader;
-
void _load_pressed();
void _load_scene_pressed();
- void _files_load_request(const Vector<String>& p_paths);
+ void _files_load_request(const Vector<String> &p_paths);
void _paste_pressed();
void _delete_pressed();
void _delete_confirm_pressed();
@@ -67,33 +63,31 @@ class ResourcePreloaderEditor : public PanelContainer {
UndoRedo *undo_redo;
- Variant get_drag_data_fw(const Point2& p_point,Control* p_from);
- bool can_drop_data_fw(const Point2& p_point,const Variant& p_data,Control* p_from) const;
- void drop_data_fw(const Point2& p_point,const Variant& p_data,Control* p_from);
-
+ Variant get_drag_data_fw(const Point2 &p_point, Control *p_from);
+ bool can_drop_data_fw(const Point2 &p_point, const Variant &p_data, Control *p_from) const;
+ void drop_data_fw(const Point2 &p_point, const Variant &p_data, Control *p_from);
protected:
void _notification(int p_what);
void _gui_input(InputEvent p_event);
static void _bind_methods();
-public:
- void set_undo_redo(UndoRedo *p_undo_redo) {undo_redo=p_undo_redo; }
+public:
+ void set_undo_redo(UndoRedo *p_undo_redo) { undo_redo = p_undo_redo; }
- void edit(ResourcePreloader* p_preloader);
+ void edit(ResourcePreloader *p_preloader);
ResourcePreloaderEditor();
};
class ResourcePreloaderEditorPlugin : public EditorPlugin {
- GDCLASS( ResourcePreloaderEditorPlugin, EditorPlugin );
+ GDCLASS(ResourcePreloaderEditorPlugin, EditorPlugin);
ResourcePreloaderEditor *preloader_editor;
EditorNode *editor;
Button *button;
public:
-
virtual String get_name() const { return "ResourcePreloader"; }
bool has_main_screen() const { return false; }
virtual void edit(Object *p_node);
@@ -102,7 +96,6 @@ public:
ResourcePreloaderEditorPlugin(EditorNode *p_node);
~ResourcePreloaderEditorPlugin();
-
};
#endif // RESOURCE_PRELOADER_EDITOR_PLUGIN_H