[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [40720] trunk/blender/source/blender/ editors/interface/interface.c: Fix #28432: Scrolling lists respond incorrectly if mouse is not moved

Sergey Sharybin g.ulairi at gmail.com
Fri Sep 30 17:42:04 CEST 2011


Revision: 40720
          http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=40720
Author:   nazgul
Date:     2011-09-30 15:42:04 +0000 (Fri, 30 Sep 2011)
Log Message:
-----------
Fix #28432: Scrolling lists respond incorrectly if mouse is not moved

Copy hardmin for LISTROW and ROW buttons when updating button
from old block due to list item index is stored in this value.

Modified Paths:
--------------
    trunk/blender/source/blender/editors/interface/interface.c

Modified: trunk/blender/source/blender/editors/interface/interface.c
===================================================================
--- trunk/blender/source/blender/editors/interface/interface.c	2011-09-30 15:22:13 UTC (rev 40719)
+++ trunk/blender/source/blender/editors/interface/interface.c	2011-09-30 15:42:04 UTC (rev 40720)
@@ -678,6 +678,11 @@
 					SWAP(void *, oldbut->func_argN, but->func_argN)
 				}
 				
+				/* copy hardmin for list rows to prevent 'sticking' highlight to mouse position
+				   when scrolling without moving mouse (see [#28432]) */
+				if(ELEM(oldbut->type, ROW, LISTROW))
+					oldbut->hardmax= but->hardmax;
+				
 				ui_but_update_linklines(block, oldbut, but);
 				
 				BLI_remlink(&block->buttons, but);




More information about the Bf-blender-cvs mailing list