[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [36248] trunk/blender/source/blender/ editors/space_outliner/outliner.c: Bugfix #27026

Ton Roosendaal ton at blender.org
Wed Apr 20 18:19:50 CEST 2011


Revision: 36248
          http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=36248
Author:   ton
Date:     2011-04-20 16:19:49 +0000 (Wed, 20 Apr 2011)
Log Message:
-----------
Bugfix #27026

Outliner objects showed "active" or "selected" in confusing
ways. Now the display is simply binary, and more in line with
how other items in outliner draw:

- text is white = item is active
- color circle behind icon: shows selection state

Modified Paths:
--------------
    trunk/blender/source/blender/editors/space_outliner/outliner.c

Modified: trunk/blender/source/blender/editors/space_outliner/outliner.c
===================================================================
--- trunk/blender/source/blender/editors/space_outliner/outliner.c	2011-04-20 14:47:00 UTC (rev 36247)
+++ trunk/blender/source/blender/editors/space_outliner/outliner.c	2011-04-20 16:19:49 UTC (rev 36248)
@@ -4667,16 +4667,24 @@
 				Object *ob= (Object *)tselem->id;
 				
 				if(ob==OBACT || (ob->flag & SELECT)) {
-					char col[4];
+					char col[4]= {0, 0, 0, 0};
 					
-					active= 2;
+					/* outliner active ob: always white text, circle color now similar to view3d */
+					
+					active= 2; /* means it draws a color circle */
 					if(ob==OBACT) {
-						UI_GetThemeColorType4ubv(TH_ACTIVE, SPACE_VIEW3D, col);
-						/* so black text is drawn when active and not selected */
-						if (ob->flag & SELECT) active= 1;
+						if(ob->flag & SELECT) {
+							UI_GetThemeColorType4ubv(TH_ACTIVE, SPACE_VIEW3D, col);
+							col[3]= 100;
+						}
+						
+						active= 1; /* means it draws white text */
 					}
-					else UI_GetThemeColorType4ubv(TH_SELECT, SPACE_VIEW3D, col);
-					col[3]= 100;
+					else if(ob->flag & SELECT) {
+						UI_GetThemeColorType4ubv(TH_SELECT, SPACE_VIEW3D, col);
+						col[3]= 100;
+					}
+					
 					glColor4ubv((GLubyte *)col);
 				}
 




More information about the Bf-blender-cvs mailing list