1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-24 15:26:15 +00:00

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
This commit is contained in:
Rémi Verschelde
2017-03-05 16:44:50 +01:00
parent 45438e9918
commit 5dbf1809c6
1318 changed files with 140051 additions and 166004 deletions

View File

@@ -28,7 +28,6 @@
/*************************************************************************/
#include "gi_probe_editor_plugin.h"
void GIProbeEditorPlugin::_bake() {
if (gi_probe) {
@@ -36,14 +35,13 @@ void GIProbeEditorPlugin::_bake() {
}
}
void GIProbeEditorPlugin::edit(Object *p_object) {
GIProbe * s = p_object->cast_to<GIProbe>();
GIProbe *s = p_object->cast_to<GIProbe>();
if (!s)
return;
gi_probe=s;
gi_probe = s;
}
bool GIProbeEditorPlugin::handles(Object *p_object) const {
@@ -59,25 +57,23 @@ void GIProbeEditorPlugin::make_visible(bool p_visible) {
bake->hide();
}
}
void GIProbeEditorPlugin::_bind_methods() {
ClassDB::bind_method("_bake",&GIProbeEditorPlugin::_bake);
ClassDB::bind_method("_bake", &GIProbeEditorPlugin::_bake);
}
GIProbeEditorPlugin::GIProbeEditorPlugin(EditorNode *p_node) {
editor=p_node;
bake = memnew( Button );
bake->set_icon(editor->get_gui_base()->get_icon("BakedLight","EditorIcons"));
editor = p_node;
bake = memnew(Button);
bake->set_icon(editor->get_gui_base()->get_icon("BakedLight", "EditorIcons"));
bake->hide();
bake->connect("pressed",this,"_bake");
add_control_to_container(CONTAINER_SPATIAL_EDITOR_MENU,bake);
gi_probe=NULL;
bake->connect("pressed", this, "_bake");
add_control_to_container(CONTAINER_SPATIAL_EDITOR_MENU, bake);
gi_probe = NULL;
}
GIProbeEditorPlugin::~GIProbeEditorPlugin() {
}