[Bf-blender-cvs] [5035eef] GPencil_EditStrokes: Hack: Use same handling logic for finding "active" GPencil block in timeline as for 3D View

Joshua Leung noreply at git.blender.org
Wed Oct 22 15:42:27 CEST 2014


Commit: 5035eef2604ae8e1b8b43252ff119181f1e8c58d
Author: Joshua Leung
Date:   Thu Oct 23 02:41:57 2014 +1300
Branches: GPencil_EditStrokes
https://developer.blender.org/rB5035eef2604ae8e1b8b43252ff119181f1e8c58d

Hack: Use same handling logic for finding "active" GPencil block in timeline as for 3D View

This is not a terribly nice hack, but it gives the behaviour that users expect
more often than not. Namely, this enables:
* GPencil keyframes now show up in timeline
* The next/prev keyframe buttons on the Timeline header work correctly
  (i.e. they can "see" the GPencil keyframes)

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

M	source/blender/editors/gpencil/gpencil_edit.c

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

diff --git a/source/blender/editors/gpencil/gpencil_edit.c b/source/blender/editors/gpencil/gpencil_edit.c
index 8fcfd47..9f7a2a8 100644
--- a/source/blender/editors/gpencil/gpencil_edit.c
+++ b/source/blender/editors/gpencil/gpencil_edit.c
@@ -99,6 +99,7 @@ bGPdata **ED_gpencil_data_get_pointers_direct(ID *screen_id, Scene *scene, ScrAr
 		
 		switch (sa->spacetype) {
 			case SPACE_VIEW3D: /* 3D-View */
+			case SPACE_TIME: /* Timeline - XXX: this is a hack to get it to show GP keyframes for 3D view */
 			{
 				/* default to using scene's data, unless it doesn't exist (and object's does instead) */
 				/* XXX: this will require a toggle switch later to be more predictable */




More information about the Bf-blender-cvs mailing list