mirror of
				https://github.com/ocornut/imgui.git
				synced 2025-10-26 12:27:30 +00:00 
			
		
		
		
	TreeNode: fixed an issue where tree lines are not drawn on node opening frame. (#2920)
This commit is contained in:
		| @@ -6690,7 +6690,7 @@ bool ImGui::TreeNodeBehavior(ImGuiID id, ImGuiTreeNodeFlags flags, const char* l | ||||
|     if ((flags & ImGuiTreeNodeFlags_DrawLinesMask_) == 0) | ||||
|         flags |= g.Style.TreeLinesFlags; | ||||
|     const bool draw_tree_lines = (flags & (ImGuiTreeNodeFlags_DrawLinesFull | ImGuiTreeNodeFlags_DrawLinesToNodes)) && (frame_bb.Min.y < window->ClipRect.Max.y) && (g.Style.TreeLinesSize > 0.0f); | ||||
|     if (is_open && !(flags & ImGuiTreeNodeFlags_NoTreePushOnOpen)) | ||||
|     if (!(flags & ImGuiTreeNodeFlags_NoTreePushOnOpen)) | ||||
|     { | ||||
|         if ((flags & ImGuiTreeNodeFlags_NavLeftJumpsToParent) && !g.NavIdIsAlive) | ||||
|             if (g.NavMoveDir == ImGuiDir_Left && g.NavWindow == window && NavMoveRequestButNoResultYet()) | ||||
| @@ -6889,7 +6889,7 @@ bool ImGui::TreeNodeBehavior(ImGuiID id, ImGuiTreeNodeFlags flags, const char* l | ||||
|             TablePopBackgroundChannel(); | ||||
|     } | ||||
|  | ||||
|     if (store_tree_node_stack_data && is_open) | ||||
|     if (is_open && store_tree_node_stack_data) | ||||
|         TreeNodeStoreStackData(flags, text_pos.x - text_offset_x); // Call before TreePushOverrideID() | ||||
|     if (is_open && !(flags & ImGuiTreeNodeFlags_NoTreePushOnOpen)) | ||||
|         TreePushOverrideID(id); // Could use TreePush(label) but this avoid computing twice | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 ocornut
					ocornut