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:
-rw-r--r--source/blender/python/api2_2x/Scene.c5
-rw-r--r--source/blender/python/api2_2x/sceneSequence.c6
2 files changed, 7 insertions, 4 deletions
diff --git a/source/blender/python/api2_2x/Scene.c b/source/blender/python/api2_2x/Scene.c
index ebf50d7dfde..c5bd7ef9056 100644
--- a/source/blender/python/api2_2x/Scene.c
+++ b/source/blender/python/api2_2x/Scene.c
@@ -1093,10 +1093,7 @@ static PyObject *Scene_getRadiosityContext( BPy_Scene * self )
static PyObject *Scene_getSequence( BPy_Scene * self )
{
SCENE_DEL_CHECK_PY(self);
- if (self->scene->ed) /* we should create this if its not there :/ */
- return SceneSeq_CreatePyObject( self->scene, NULL );
- else
- Py_RETURN_NONE;
+ return SceneSeq_CreatePyObject( self->scene, NULL );
}
/* scene.addScriptLink */
diff --git a/source/blender/python/api2_2x/sceneSequence.c b/source/blender/python/api2_2x/sceneSequence.c
index 86e36655c28..6bcf074068d 100644
--- a/source/blender/python/api2_2x/sceneSequence.c
+++ b/source/blender/python/api2_2x/sceneSequence.c
@@ -1099,6 +1099,12 @@ PyObject *SceneSeq_CreatePyObject( struct Scene * scn, struct Sequence * iter)
if( !scn )
Py_RETURN_NONE;
+ if ( !scn->ed ) {
+ Editing *ed;
+ ed= scn->ed= MEM_callocN( sizeof(Editing), "addseq");
+ ed->seqbasep= &ed->seqbase;
+ }
+
pysceseq =
( BPy_SceneSeq * ) PyObject_NEW( BPy_SceneSeq, &SceneSeq_Type );