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--release/ui/space_sequencer.py24
-rw-r--r--source/blender/editors/include/ED_sound.h35
-rw-r--r--source/blender/editors/sound/sound_intern.h2
-rw-r--r--source/blender/editors/sound/sound_ops.c6
-rw-r--r--source/blender/editors/space_api/spacetypes.c2
-rw-r--r--source/blender/editors/space_image/image_ops.c2
6 files changed, 66 insertions, 5 deletions
diff --git a/release/ui/space_sequencer.py b/release/ui/space_sequencer.py
index 1498c37d761..6b86ea5dabe 100644
--- a/release/ui/space_sequencer.py
+++ b/release/ui/space_sequencer.py
@@ -455,6 +455,29 @@ class SEQUENCER_PT_input(SequencerButtonsPanel):
col.itemR(strip, "animation_start_offset", text="Start")
col.itemR(strip, "animation_end_offset", text="End")
+class SEQUENCER_PT_sound(SequencerButtonsPanel):
+ __label__ = "Sound"
+
+ def poll(self, context):
+ if context.space_data.display_mode != 'SEQUENCER':
+ return False
+
+ strip = act_strip(context)
+ if not strip:
+ return False
+
+ return strip.type in ('SOUND')
+
+ def draw(self, context):
+ layout = self.layout
+
+ strip = act_strip(context)
+
+ layout.template_ID(strip, "sound", new="sound.open")
+
+ layout.itemR(strip.sound, "filename")
+ layout.itemR(strip.sound, "caching")
+
class SEQUENCER_PT_filter(SequencerButtonsPanel):
__label__ = "Filter"
@@ -558,6 +581,7 @@ bpy.types.register(SEQUENCER_MT_strip)
bpy.types.register(SEQUENCER_PT_edit) # sequencer panels
bpy.types.register(SEQUENCER_PT_effect)
bpy.types.register(SEQUENCER_PT_input)
+bpy.types.register(SEQUENCER_PT_sound)
bpy.types.register(SEQUENCER_PT_filter)
bpy.types.register(SEQUENCER_PT_proxy)
diff --git a/source/blender/editors/include/ED_sound.h b/source/blender/editors/include/ED_sound.h
new file mode 100644
index 00000000000..584370bc738
--- /dev/null
+++ b/source/blender/editors/include/ED_sound.h
@@ -0,0 +1,35 @@
+/**
+ * $Id:$
+ *
+ * ***** BEGIN GPL LICENSE BLOCK *****
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software Foundation,
+ * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+ *
+ * The Original Code is Copyright (C) 2008 Blender Foundation.
+ * All rights reserved.
+ *
+ *
+ * Contributor(s): Blender Foundation
+ *
+ * ***** END GPL LICENSE BLOCK *****
+ */
+
+#ifndef ED_SOUND_H
+#define ED_SOUND_H
+
+void ED_operatortypes_sound(void);
+
+#endif /* ED_SOUND_H */
+
diff --git a/source/blender/editors/sound/sound_intern.h b/source/blender/editors/sound/sound_intern.h
index b0d6abb3f00..eb793a0b661 100644
--- a/source/blender/editors/sound/sound_intern.h
+++ b/source/blender/editors/sound/sound_intern.h
@@ -33,7 +33,5 @@ struct wmOperatorType;
void SOUND_OT_open(wmOperatorType *ot);
-void sound_operatortype_init(void);
-
#endif /* ED_SOUND_INTERN_H */
diff --git a/source/blender/editors/sound/sound_ops.c b/source/blender/editors/sound/sound_ops.c
index 59bb9c5319c..a23a28423ef 100644
--- a/source/blender/editors/sound/sound_ops.c
+++ b/source/blender/editors/sound/sound_ops.c
@@ -38,6 +38,8 @@
#include "BKE_report.h"
#include "BKE_sound.h"
+#include "ED_sound.h"
+
#include "RNA_access.h"
#include "RNA_define.h"
@@ -84,7 +86,7 @@ static int open_invoke(bContext *C, wmOperator *op, wmEvent *event)
void SOUND_OT_open(wmOperatorType *ot)
{
/* identifiers */
- ot->name= "Open";
+ ot->name= "Open Sound";
ot->idname= "SOUND_OT_open";
ot->description= "Load a sound file into blender";
@@ -101,7 +103,7 @@ void SOUND_OT_open(wmOperatorType *ot)
/* ******************************************************* */
-void sound_operatortype_init(void)
+void ED_operatortypes_sound(void)
{
WM_operatortype_append(SOUND_OT_open);
}
diff --git a/source/blender/editors/space_api/spacetypes.c b/source/blender/editors/space_api/spacetypes.c
index 61b6fe391ae..0d702144959 100644
--- a/source/blender/editors/space_api/spacetypes.c
+++ b/source/blender/editors/space_api/spacetypes.c
@@ -51,6 +51,7 @@
#include "ED_screen.h"
#include "ED_sculpt.h"
#include "ED_space_api.h"
+#include "ED_sound.h"
#include "ED_uvedit.h"
#include "ED_mball.h"
@@ -99,6 +100,7 @@ void ED_spacetypes_init(void)
ED_operatortypes_metaball();
ED_operatortypes_boids();
ED_operatortypes_gpencil();
+ ED_operatortypes_sound();
ui_view2d_operatortypes();
diff --git a/source/blender/editors/space_image/image_ops.c b/source/blender/editors/space_image/image_ops.c
index d9f02a35142..7a39cd587eb 100644
--- a/source/blender/editors/space_image/image_ops.c
+++ b/source/blender/editors/space_image/image_ops.c
@@ -650,7 +650,7 @@ static int open_invoke(bContext *C, wmOperator *op, wmEvent *event)
void IMAGE_OT_open(wmOperatorType *ot)
{
/* identifiers */
- ot->name= "Open";
+ ot->name= "Open Image";
ot->idname= "IMAGE_OT_open";
/* api callbacks */