Revision: 17849 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=17849 Author: ton Date: 2008-12-14 15:43:08 +0100 (Sun, 14 Dec 2008)
Log Message: ----------- 2.5 Basics for the remaining 6 spacetypes. Note: Andrea prefers to merge SpaceImaSel with SpaceFile for that I'll provide a good readfile.c patch later Modified Paths: -------------- branches/blender2.5/blender/source/Makefile branches/blender2.5/blender/source/blender/blenloader/intern/readfile.c branches/blender2.5/blender/source/blender/editors/Makefile branches/blender2.5/blender/source/blender/editors/SConscript branches/blender2.5/blender/source/blender/editors/include/ED_space_api.h branches/blender2.5/blender/source/blender/editors/space_api/spacetypes.c Added Paths: ----------- branches/blender2.5/blender/source/blender/editors/space_action/ branches/blender2.5/blender/source/blender/editors/space_action/Makefile branches/blender2.5/blender/source/blender/editors/space_action/SConscript branches/blender2.5/blender/source/blender/editors/space_action/action_header.c branches/blender2.5/blender/source/blender/editors/space_action/action_intern.h branches/blender2.5/blender/source/blender/editors/space_action/space_action.c branches/blender2.5/blender/source/blender/editors/space_nla/ branches/blender2.5/blender/source/blender/editors/space_nla/Makefile branches/blender2.5/blender/source/blender/editors/space_nla/SConscript branches/blender2.5/blender/source/blender/editors/space_nla/nla_header.c branches/blender2.5/blender/source/blender/editors/space_nla/nla_intern.h branches/blender2.5/blender/source/blender/editors/space_nla/space_nla.c branches/blender2.5/blender/source/blender/editors/space_script/ branches/blender2.5/blender/source/blender/editors/space_script/Makefile branches/blender2.5/blender/source/blender/editors/space_script/SConscript branches/blender2.5/blender/source/blender/editors/space_script/script_header.c branches/blender2.5/blender/source/blender/editors/space_script/script_intern.h branches/blender2.5/blender/source/blender/editors/space_script/space_script.c branches/blender2.5/blender/source/blender/editors/space_sequencer/ branches/blender2.5/blender/source/blender/editors/space_sequencer/Makefile branches/blender2.5/blender/source/blender/editors/space_sequencer/SConscript branches/blender2.5/blender/source/blender/editors/space_sequencer/sequencer_header.c branches/blender2.5/blender/source/blender/editors/space_sequencer/sequencer_intern.h branches/blender2.5/blender/source/blender/editors/space_sequencer/space_sequencer.c branches/blender2.5/blender/source/blender/editors/space_sound/ branches/blender2.5/blender/source/blender/editors/space_sound/Makefile branches/blender2.5/blender/source/blender/editors/space_sound/SConscript branches/blender2.5/blender/source/blender/editors/space_sound/sound_header.c branches/blender2.5/blender/source/blender/editors/space_sound/sound_intern.h branches/blender2.5/blender/source/blender/editors/space_sound/space_sound.c branches/blender2.5/blender/source/blender/editors/space_text/ branches/blender2.5/blender/source/blender/editors/space_text/Makefile branches/blender2.5/blender/source/blender/editors/space_text/SConscript branches/blender2.5/blender/source/blender/editors/space_text/space_text.c branches/blender2.5/blender/source/blender/editors/space_text/text_header.c branches/blender2.5/blender/source/blender/editors/space_text/text_intern.h Modified: branches/blender2.5/blender/source/Makefile =================================================================== --- branches/blender2.5/blender/source/Makefile 2008-12-14 13:59:34 UTC (rev 17848) +++ branches/blender2.5/blender/source/Makefile 2008-12-14 14:43:08 UTC (rev 17849) @@ -235,6 +235,12 @@ PULIB += $(NAN_ELBEEM)/lib/$(DEBUG_DIR)libelbeem.a PULIB += $(OCGDIR)/blender/readblenfile/$(DEBUG_DIR)libreadblenfile.a PULIB += $(OCGDIR)/blender/ed_space/libed_space.a +PULIB += $(OCGDIR)/blender/ed_sound/libed_sound.a +PULIB += $(OCGDIR)/blender/ed_action/libed_action.a +PULIB += $(OCGDIR)/blender/ed_nla/libed_nla.a +PULIB += $(OCGDIR)/blender/ed_script/libed_script.a +PULIB += $(OCGDIR)/blender/ed_text/libed_text.a +PULIB += $(OCGDIR)/blender/ed_sequencer/libed_sequencer.a PULIB += $(OCGDIR)/blender/ed_file/libed_file.a PULIB += $(OCGDIR)/blender/ed_info/libed_info.a PULIB += $(OCGDIR)/blender/ed_buttons/libed_buttons.a Modified: branches/blender2.5/blender/source/blender/blenloader/intern/readfile.c =================================================================== --- branches/blender2.5/blender/source/blender/blenloader/intern/readfile.c 2008-12-14 13:59:34 UTC (rev 17848) +++ branches/blender2.5/blender/source/blender/blenloader/intern/readfile.c 2008-12-14 14:43:08 UTC (rev 17849) @@ -5090,8 +5090,16 @@ break; case SPACE_ACTION: + ar= MEM_callocN(sizeof(ARegion), "area region from do_versions"); + BLI_addtail(lb, ar); + ar->regiontype= RGN_TYPE_CHANNELS; + ar->alignment= RGN_ALIGN_LEFT; break; case SPACE_NLA: + ar= MEM_callocN(sizeof(ARegion), "area region from do_versions"); + BLI_addtail(lb, ar); + ar->regiontype= RGN_TYPE_CHANNELS; + ar->alignment= RGN_ALIGN_LEFT; break; } } @@ -5141,6 +5149,42 @@ ar->v2d.scroll |= (V2D_SCROLL_LEFT|V2D_SCROLL_SCALE_LEFT); break; } + case SPACE_SOUND: + { + SpaceSound *ssound= (SpaceSound *)sl; + memcpy(&ar->v2d, &ssound->v2d, sizeof(View2D)); + + ar->v2d.scroll |= (V2D_SCROLL_BOTTOM|V2D_SCROLL_SCALE_BOTTOM); + ar->v2d.scroll |= (V2D_SCROLL_LEFT); + break; + } + case SPACE_NLA: + { + SpaceNla *snla= (SpaceNla *)sl; + memcpy(&ar->v2d, &snla->v2d, sizeof(View2D)); + + ar->v2d.scroll |= (V2D_SCROLL_BOTTOM|V2D_SCROLL_SCALE_BOTTOM); + ar->v2d.scroll |= (V2D_SCROLL_RIGHT); + break; + } + case SPACE_ACTION: + { + SpaceAction *saction= (SpaceAction *)sl; + memcpy(&ar->v2d, &saction->v2d, sizeof(View2D)); + + ar->v2d.scroll |= (V2D_SCROLL_BOTTOM|V2D_SCROLL_SCALE_BOTTOM); + ar->v2d.scroll |= (V2D_SCROLL_RIGHT); + break; + } + case SPACE_SEQ: + { + SpaceSeq *sseq= (SpaceSeq *)sl; + memcpy(&ar->v2d, &sseq->v2d, sizeof(View2D)); + + ar->v2d.scroll |= (V2D_SCROLL_BOTTOM|V2D_SCROLL_SCALE_BOTTOM); + ar->v2d.scroll |= (V2D_SCROLL_RIGHT|V2D_SCROLL_SCALE_RIGHT); + break; + } case SPACE_NODE: { SpaceNode *snode= (SpaceNode *)sl; Modified: branches/blender2.5/blender/source/blender/editors/Makefile =================================================================== --- branches/blender2.5/blender/source/blender/editors/Makefile 2008-12-14 13:59:34 UTC (rev 17848) +++ branches/blender2.5/blender/source/blender/editors/Makefile 2008-12-14 14:43:08 UTC (rev 17849) @@ -29,6 +29,6 @@ # Bounces make to subdirectories. SOURCEDIR = source/blender/editors -DIRS = datafiles screen space_outliner space_time space_view3d interface util space_api space_ipo space_image space_node space_buttons space_info space_file +DIRS = datafiles screen space_outliner space_time space_view3d interface util space_api space_ipo space_image space_node space_buttons space_info space_file space_sound space_action space_nla space_script space_text space_sequencer include nan_subdirs.mk Modified: branches/blender2.5/blender/source/blender/editors/SConscript =================================================================== --- branches/blender2.5/blender/source/blender/editors/SConscript 2008-12-14 13:59:34 UTC (rev 17848) +++ branches/blender2.5/blender/source/blender/editors/SConscript 2008-12-14 14:43:08 UTC (rev 17849) @@ -17,5 +17,11 @@ 'space_outliner/SConscript', 'space_time/SConscript', 'space_view3d/SConscript', + 'space_sound/SConscript', + 'space_action/SConscript', + 'space_nla/SConscript', + 'space_script/SConscript', + 'space_text/SConscript', + 'space_sequencer/SConscript', 'transform/SConscript', 'screen/SConscript']) Modified: branches/blender2.5/blender/source/blender/editors/include/ED_space_api.h =================================================================== --- branches/blender2.5/blender/source/blender/editors/include/ED_space_api.h 2008-12-14 13:59:34 UTC (rev 17848) +++ branches/blender2.5/blender/source/blender/editors/include/ED_space_api.h 2008-12-14 14:43:08 UTC (rev 17849) @@ -41,6 +41,12 @@ void ED_spacetype_buttons(void); void ED_spacetype_info(void); void ED_spacetype_file(void); +void ED_spacetype_sound(void); +void ED_spacetype_action(void); +void ED_spacetype_nla(void); +void ED_spacetype_script(void); +void ED_spacetype_text(void); +void ED_spacetype_sequencer(void); #endif /* ED_AREA_H */ Added: branches/blender2.5/blender/source/blender/editors/space_action/Makefile =================================================================== --- branches/blender2.5/blender/source/blender/editors/space_action/Makefile (rev 0) +++ branches/blender2.5/blender/source/blender/editors/space_action/Makefile 2008-12-14 14:43:08 UTC (rev 17849) @@ -0,0 +1,53 @@ +# +# $Id: Makefile 14 2002-10-13 15:57:19Z hans $ +# +# ***** 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) 2007 Blender Foundation +# All rights reserved. +# +# The Original Code is: all of this file. +# +# Contributor(s): none yet. +# +# ***** END GPL LICENSE BLOCK ***** +# +# Makes module object directory and bounces make to subdirectories. + +LIBNAME = ed_action +DIR = $(OCGDIR)/blender/$(LIBNAME) + +include nan_compile.mk + +CFLAGS += $(LEVEL_1_C_WARNINGS) + +CPPFLAGS += -I$(NAN_GLEW)/include +CPPFLAGS += -I$(OPENGL_HEADERS) + +# not very neat.... +CPPFLAGS += -I../../windowmanager +CPPFLAGS += -I../../blenloader +CPPFLAGS += -I../../blenkernel +CPPFLAGS += -I../../blenlib +CPPFLAGS += -I../../makesdna +CPPFLAGS += -I../../imbuf +CPPFLAGS += -I../../python +CPPFLAGS += -I$(NAN_GUARDEDALLOC)/include + +# own include + +CPPFLAGS += -I../include Added: branches/blender2.5/blender/source/blender/editors/space_action/SConscript =================================================================== --- branches/blender2.5/blender/source/blender/editors/space_action/SConscript (rev 0) +++ branches/blender2.5/blender/source/blender/editors/space_action/SConscript 2008-12-14 14:43:08 UTC (rev 17849) @@ -0,0 +1,9 @@ +#!/usr/bin/python +Import ('env') + +sources = env.Glob('*.c') + +incs = '../include ../../blenlib ../../blenkernel ../../makesdna ../../imbuf' +incs += ' ../../windowmanager #/intern/guardedalloc #/extern/glew/include' + +env.BlenderLib ( 'bf_editors_space_action', sources, Split(incs), [], libtype=['core','intern'], priority=[35, 40] ) Added: branches/blender2.5/blender/source/blender/editors/space_action/action_header.c =================================================================== --- branches/blender2.5/blender/source/blender/editors/space_action/action_header.c (rev 0) +++ branches/blender2.5/blender/source/blender/editors/space_action/action_header.c 2008-12-14 14:43:08 UTC (rev 17849) @@ -0,0 +1,132 @@ +/** + * $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 ***** + */ + +#include <string.h> +#include <stdio.h> + +#include "DNA_space_types.h" +#include "DNA_scene_types.h" +#include "DNA_screen_types.h" +#include "DNA_windowmanager_types.h" + +#include "MEM_guardedalloc.h" + +#include "BLI_blenlib.h" + +#include "BKE_global.h" +#include "BKE_screen.h" + +#include "ED_screen.h" +#include "ED_util.h" + +#include "WM_api.h" +#include "WM_types.h" + +#include "BIF_gl.h" +#include "BIF_glutil.h" + +#include "UI_interface.h" +#include "UI_resources.h" +#include "UI_view2d.h" + +#include "action_intern.h" + + +/* ************************ header area region *********************** */ + +static void do_viewmenu(bContext *C, void *arg, int event) +{ + +} + +static uiBlock *dummy_viewmenu(bContext *C, uiMenuBlockHandle *handle, void *arg_unused) +{ + ScrArea *curarea= C->area; + uiBlock *block; + short yco= 0, menuwidth=120; + + block= uiBeginBlock(C, handle->region, "dummy_viewmenu", UI_EMBOSSP, UI_HELV); + uiBlockSetButmFunc(block, do_viewmenu, NULL); + + uiDefIconTextBut(block, BUTM, 1, ICON_BLANK1, "Nothing yet", 0, yco-=20, + menuwidth, 19, NULL, 0.0, 0.0, 1, 3, ""); + @@ Diff output truncated at 10240 characters. @@ _______________________________________________ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs