diff options
| author | Rémi Verschelde | 2017-03-05 16:44:50 +0100 |
|---|---|---|
| committer | Rémi Verschelde | 2017-03-05 16:44:50 +0100 |
| commit | 5dbf1809c6e3e905b94b8764e99491e608122261 (patch) | |
| tree | 5e5a5360db15d86d59ec8c6e4f7eb511388c5a9a /editor/connections_dialog.h | |
| parent | 45438e9918d421b244bfd7776a30e67dc7f2d3e3 (diff) | |
| download | godot-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/connections_dialog.h')
| -rw-r--r-- | editor/connections_dialog.h | 34 |
1 files changed, 14 insertions, 20 deletions
diff --git a/editor/connections_dialog.h b/editor/connections_dialog.h index 6407b83f6..240e3655e 100644 --- a/editor/connections_dialog.h +++ b/editor/connections_dialog.h @@ -29,15 +29,15 @@ #ifndef CONNECTIONS_DIALOG_H #define CONNECTIONS_DIALOG_H -#include "scene/gui/popup.h" +#include "editor/property_editor.h" +#include "editor/scene_tree_editor.h" #include "scene/gui/button.h" #include "scene/gui/check_button.h" -#include "scene/gui/tree.h" #include "scene/gui/dialogs.h" -#include "scene/gui/menu_button.h" #include "scene/gui/line_edit.h" -#include "editor/scene_tree_editor.h" -#include "editor/property_editor.h" +#include "scene/gui/menu_button.h" +#include "scene/gui/popup.h" +#include "scene/gui/tree.h" #include "undo_redo.h" /** @@ -48,8 +48,7 @@ class ConnectDialogBinds; class ConnectDialog : public ConfirmationDialog { - GDCLASS( ConnectDialog, ConfirmationDialog ); - + GDCLASS(ConnectDialog, ConfirmationDialog); ConfirmationDialog *error; LineEdit *dst_path; @@ -71,20 +70,18 @@ class ConnectDialog : public ConfirmationDialog { void _remove_bind(); protected: - void _notification(int p_what); static void _bind_methods(); -public: - +public: bool get_make_callback() { return make_callback->is_visible() && make_callback->is_pressed(); } NodePath get_dst_path() const; StringName get_dst_method() const; bool get_deferred() const; bool get_oneshot() const; Vector<Variant> get_binds() const; - void set_dst_method(const StringName& p_method); - void set_dst_node(Node* p_node); + void set_dst_method(const StringName &p_method); + void set_dst_node(Node *p_node); //Button *get_ok() { return ok; } //Button *get_cancel() { return cancel; } @@ -92,12 +89,11 @@ public: ConnectDialog(); ~ConnectDialog(); - }; class ConnectionsDock : public VBoxContainer { - GDCLASS( ConnectionsDock , VBoxContainer ); + GDCLASS(ConnectionsDock, VBoxContainer); Button *connect_button; EditorNode *editor; @@ -115,20 +111,18 @@ class ConnectionsDock : public VBoxContainer { UndoRedo *undo_redo; protected: - void _connect_pressed(); void _notification(int p_what); static void _bind_methods(); -public: - void set_undoredo(UndoRedo *p_undo_redo) { undo_redo=p_undo_redo; } +public: + void set_undoredo(UndoRedo *p_undo_redo) { undo_redo = p_undo_redo; } - void set_node(Node* p_node); + void set_node(Node *p_node); String get_selected_type(); - ConnectionsDock(EditorNode *p_editor=NULL); + ConnectionsDock(EditorNode *p_editor = NULL); ~ConnectionsDock(); - }; #endif |
