summaryrefslogtreecommitdiff
path: root/editor/editor_log.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'editor/editor_log.cpp')
-rw-r--r--editor/editor_log.cpp9
1 files changed, 6 insertions, 3 deletions
diff --git a/editor/editor_log.cpp b/editor/editor_log.cpp
index e301d12214..158eedfb0f 100644
--- a/editor/editor_log.cpp
+++ b/editor/editor_log.cpp
@@ -88,6 +88,7 @@ void EditorLog::_notification(int p_what) {
void EditorLog::_clear_request() {
log->clear();
+ tool_button->set_icon(Ref<Texture>());
}
void EditorLog::clear() {
@@ -103,9 +104,7 @@ void EditorLog::add_message(const String &p_msg, bool p_error) {
Ref<Texture> icon = get_icon("Error", "EditorIcons");
log->add_image(icon);
log->add_text(" ");
- //button->set_icon(icon);
- } else {
- //button->set_icon(Ref<Texture>());
+ tool_button->set_icon(icon);
}
log->add_text(p_msg);
@@ -115,6 +114,10 @@ void EditorLog::add_message(const String &p_msg, bool p_error) {
log->pop();
}
+void EditorLog::set_tool_button(ToolButton *p_tool_button) {
+ tool_button = p_tool_button;
+}
+
/*
void EditorLog::_dragged(const Point2& p_ofs) {