Merge pull request #24160 from YeldhamDev/graph_tooltips
Add tooltips to GraphEdit node
This commit is contained in:
commit
31384a56b5
|
@ -798,7 +798,7 @@ VisualShaderEditor::VisualShaderEditor() {
|
|||
|
||||
add_node = memnew(MenuButton);
|
||||
graph->get_zoom_hbox()->add_child(add_node);
|
||||
add_node->set_text(TTR("Add Node.."));
|
||||
add_node->set_text(TTR("Add Node..."));
|
||||
graph->get_zoom_hbox()->move_child(add_node, 0);
|
||||
add_node->get_popup()->connect("id_pressed", this, "_add_node");
|
||||
|
||||
|
|
|
@ -1339,21 +1339,25 @@ GraphEdit::GraphEdit() {
|
|||
|
||||
zoom_minus = memnew(ToolButton);
|
||||
zoom_hb->add_child(zoom_minus);
|
||||
zoom_minus->set_tooltip(RTR("Zoom Out"));
|
||||
zoom_minus->connect("pressed", this, "_zoom_minus");
|
||||
zoom_minus->set_focus_mode(FOCUS_NONE);
|
||||
|
||||
zoom_reset = memnew(ToolButton);
|
||||
zoom_hb->add_child(zoom_reset);
|
||||
zoom_reset->set_tooltip(RTR("Zoom Reset"));
|
||||
zoom_reset->connect("pressed", this, "_zoom_reset");
|
||||
zoom_reset->set_focus_mode(FOCUS_NONE);
|
||||
|
||||
zoom_plus = memnew(ToolButton);
|
||||
zoom_hb->add_child(zoom_plus);
|
||||
zoom_plus->set_tooltip(RTR("Zoom In"));
|
||||
zoom_plus->connect("pressed", this, "_zoom_plus");
|
||||
zoom_plus->set_focus_mode(FOCUS_NONE);
|
||||
|
||||
snap_button = memnew(ToolButton);
|
||||
snap_button->set_toggle_mode(true);
|
||||
snap_button->set_tooltip(RTR("Enable snap and show grid."));
|
||||
snap_button->connect("pressed", this, "_snap_toggled");
|
||||
snap_button->set_pressed(true);
|
||||
snap_button->set_focus_mode(FOCUS_NONE);
|
||||
|
|
Loading…
Reference in New Issue