[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [50225] trunk/blender/source/blender/ editors/interface/view2d_ops.c: Fix zooming in/out preview in sequencer

Sergey Sharybin sergey.vfx at gmail.com
Sun Aug 26 18:41:03 CEST 2012


Revision: 50225
          http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=50225
Author:   nazgul
Date:     2012-08-26 16:41:03 +0000 (Sun, 26 Aug 2012)
Log Message:
-----------
Fix zooming in/out preview in sequencer

It was a regression since disabling Y-axis zooming in sequencer.
Now check region type and allow all kind of zooming for preview
region.

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

Modified: trunk/blender/source/blender/editors/interface/view2d_ops.c
===================================================================
--- trunk/blender/source/blender/editors/interface/view2d_ops.c	2012-08-26 14:12:09 UTC (rev 50224)
+++ trunk/blender/source/blender/editors/interface/view2d_ops.c	2012-08-26 16:41:03 UTC (rev 50225)
@@ -682,7 +682,10 @@
 	
 	/* default not to zoom the sequencer vertically */
 	if (sa && sa->spacetype == SPACE_SEQ) {
-		do_zoom_y = FALSE;
+		ARegion *ar = CTX_wm_region(C);
+
+		if (ar && ar->regiontype != RGN_TYPE_PREVIEW)
+			do_zoom_y = FALSE;
 	}
 
 	/* set RNA-Props - zooming in by uniform factor */
@@ -727,7 +730,7 @@
 	
 	/* api callbacks */
 	ot->invoke = view_zoomin_invoke;
-//	ot->exec = view_zoomin_exec;  // XXX, needs view_zoomdrag_init called first.
+	ot->exec = view_zoomin_exec;  // XXX, needs view_zoomdrag_init called first.
 	ot->poll = view_zoom_poll;
 	
 	/* rna - must keep these in sync with the other operators */
@@ -748,7 +751,10 @@
 	
 	/* default not to zoom the sequencer vertically */
 	if (sa && sa->spacetype == SPACE_SEQ) {
-		do_zoom_y = FALSE;
+		ARegion *ar = CTX_wm_region(C);
+
+		if (ar && ar->regiontype != RGN_TYPE_PREVIEW)
+			do_zoom_y = FALSE;
 	}
 
 	/* set RNA-Props - zooming in by uniform factor */




More information about the Bf-blender-cvs mailing list