[Bf-blender-cvs] [8e8b4ec3a32] master: Fix T73587: Wrong sub-panel animation on double-click

Tobias Langen noreply at git.blender.org
Fri Feb 28 12:39:19 CET 2020


Commit: 8e8b4ec3a32048fe9a43aeb384367ce797ed07ae
Author: Tobias Langen
Date:   Fri Feb 28 12:36:14 2020 +0100
Branches: master
https://developer.blender.org/rB8e8b4ec3a32048fe9a43aeb384367ce797ed07ae

Fix T73587: Wrong sub-panel animation on double-click

Under the special circumstance of double clicking and then opening a
panel with sub-panels again, the parent panel's offset in y-direction
was added twice to the child panels: once inside "get_panel_real_ofsy"
and once within "align_sub_panels".
This introduced a visible glitch.

Reviewed by: Julian Eisel

Differential Revision: https://developer.blender.org/D6942

===================================================================

M	source/blender/editors/interface/interface_panel.c

===================================================================

diff --git a/source/blender/editors/interface/interface_panel.c b/source/blender/editors/interface/interface_panel.c
index cc1b7187e45..17c1455bd81 100644
--- a/source/blender/editors/interface/interface_panel.c
+++ b/source/blender/editors/interface/interface_panel.c
@@ -998,7 +998,7 @@ static int compare_panel(const void *a1, const void *a2)
 static void align_sub_panels(Panel *pa)
 {
   /* Position sub panels. */
-  int ofsy = get_panel_real_ofsy(pa) + pa->sizey - pa->blocksizey;
+  int ofsy = pa->ofsy + pa->sizey - pa->blocksizey;
 
   for (Panel *pachild = pa->children.first; pachild; pachild = pachild->next) {
     if (pachild->runtime_flag & PNL_ACTIVE) {



More information about the Bf-blender-cvs mailing list