Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMartin Poirier <theeth@yahoo.com>2009-03-28 23:46:38 +0300
committerMartin Poirier <theeth@yahoo.com>2009-03-28 23:46:38 +0300
commit145a44135704fa08974cac36de0a87aeb9cc696d (patch)
treede69c72ae1d644d39a6fbb0614252a229e89a591 /source/blender/editors/transform/transform_snap.c
parenta5f32714f77ed2ba7b42163fb55a3dfed6bd29af (diff)
Correctly cancel operator is there's no transform data.
Don't access RegionView3D if region is of the wrong type. Correctly draw extra transform stuff (like snap and pet circles) in multiple 3d regions.
Diffstat (limited to 'source/blender/editors/transform/transform_snap.c')
-rw-r--r--source/blender/editors/transform/transform_snap.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/source/blender/editors/transform/transform_snap.c b/source/blender/editors/transform/transform_snap.c
index 2a945d7de35..bf1169072e1 100644
--- a/source/blender/editors/transform/transform_snap.c
+++ b/source/blender/editors/transform/transform_snap.c
@@ -121,7 +121,7 @@ int BIF_snappingSupported(Object *obedit)
return status;
}
-void drawSnapping(TransInfo *t)
+void drawSnapping(const struct bContext *C, TransInfo *t)
{
if ((t->tsnap.status & (SNAP_ON|POINT_INIT|TARGET_INIT)) == (SNAP_ON|POINT_INIT|TARGET_INIT) &&
(t->modifiers & MOD_SNAP_GEARS))
@@ -132,8 +132,8 @@ void drawSnapping(TransInfo *t)
glColor4ub(col[0], col[1], col[2], 128);
if (t->spacetype == SPACE_VIEW3D) {
- View3D *v3d = t->view;
- RegionView3D *rv3d= t->ar->regiondata;
+ View3D *v3d = CTX_wm_view3d(C);
+ RegionView3D *rv3d = CTX_wm_region_view3d(C);
float tmat[4][4], imat[4][4];
float size;