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:
authorBrecht Van Lommel <brechtvanlommel@pandora.be>2009-08-18 16:58:51 +0400
committerBrecht Van Lommel <brechtvanlommel@pandora.be>2009-08-18 16:58:51 +0400
commit990dcd0f7f362828eddeaca191640c1680808a6c (patch)
treec49767c528436e9153fe496b26dd5b6314f19572 /source/blender
parentac2451c6be437fba14f9c0ceeeaeab382fd9ad58 (diff)
2.5:
* Split Info and User preferences into two separate spaces. * Renamed Buttons Window to Properties also in RNA identifiers.
Diffstat (limited to 'source/blender')
-rw-r--r--source/blender/blenkernel/BKE_context.h1
-rw-r--r--source/blender/blenkernel/intern/context.c7
-rw-r--r--source/blender/blenloader/intern/writefile.c4
-rw-r--r--source/blender/editors/Makefile1
-rw-r--r--source/blender/editors/SConscript1
-rw-r--r--source/blender/editors/include/ED_space_api.h1
-rw-r--r--source/blender/editors/interface/interface_panel.c2
-rw-r--r--source/blender/editors/interface/resources.c9
-rw-r--r--source/blender/editors/screen/area.c3
-rw-r--r--source/blender/editors/space_api/spacetypes.c1
-rw-r--r--source/blender/editors/space_buttons/buttons_context.c3
-rw-r--r--source/blender/editors/space_buttons/buttons_ops.c2
-rw-r--r--source/blender/editors/space_info/info_intern.h3
-rw-r--r--source/blender/editors/space_userpref/Makefile55
-rw-r--r--source/blender/editors/space_userpref/SConscript14
-rw-r--r--source/blender/editors/space_userpref/space_userpref.c188
-rw-r--r--source/blender/editors/space_userpref/userpref_intern.h34
-rw-r--r--source/blender/editors/space_userpref/userpref_ops.c33
-rw-r--r--source/blender/makesdna/DNA_space_types.h10
-rw-r--r--source/blender/makesdna/DNA_userdef_types.h1
-rw-r--r--source/blender/makesrna/RNA_access.h22
-rw-r--r--source/blender/makesrna/intern/rna_space.c68
-rw-r--r--source/blender/makesrna/intern/rna_userdef.c32
-rw-r--r--source/blender/windowmanager/intern/wm_window.c4
24 files changed, 464 insertions, 35 deletions
diff --git a/source/blender/blenkernel/BKE_context.h b/source/blender/blenkernel/BKE_context.h
index 035b7e2e5b9..09e13c2930e 100644
--- a/source/blender/blenkernel/BKE_context.h
+++ b/source/blender/blenkernel/BKE_context.h
@@ -152,6 +152,7 @@ struct SpaceLogic *CTX_wm_space_logic(const bContext *C);
struct SpaceIpo *CTX_wm_space_graph(const bContext *C);
struct SpaceAction *CTX_wm_space_action(const bContext *C);
struct SpaceInfo *CTX_wm_space_info(const bContext *C);
+struct SpaceUserPref *CTX_wm_space_userpref(const bContext *C);
void CTX_wm_manager_set(bContext *C, struct wmWindowManager *wm);
void CTX_wm_window_set(bContext *C, struct wmWindow *win);
diff --git a/source/blender/blenkernel/intern/context.c b/source/blender/blenkernel/intern/context.c
index c38b994849a..bbfe077c15e 100644
--- a/source/blender/blenkernel/intern/context.c
+++ b/source/blender/blenkernel/intern/context.c
@@ -338,6 +338,13 @@ struct SpaceInfo *CTX_wm_space_info(const bContext *C)
return NULL;
}
+struct SpaceUserPref *CTX_wm_space_userpref(const bContext *C)
+{
+ if(C->wm.area && C->wm.area->spacetype==SPACE_USERPREF)
+ return C->wm.area->spacedata.first;
+ return NULL;
+}
+
void CTX_wm_manager_set(bContext *C, wmWindowManager *wm)
{
C->wm.manager= wm;
diff --git a/source/blender/blenloader/intern/writefile.c b/source/blender/blenloader/intern/writefile.c
index 9d059af9887..62ec1b71938 100644
--- a/source/blender/blenloader/intern/writefile.c
+++ b/source/blender/blenloader/intern/writefile.c
@@ -2023,6 +2023,10 @@ static void write_screens(WriteData *wd, ListBase *scrbase)
else if(sl->spacetype==SPACE_CONSOLE) {
writestruct(wd, DATA, "SpaceConsole", 1, sl);
}
+ else if(sl->spacetype==SPACE_USERPREF) {
+ writestruct(wd, DATA, "SpaceUserPref", 1, sl);
+ }
+
sl= sl->next;
}
}
diff --git a/source/blender/editors/Makefile b/source/blender/editors/Makefile
index dbd0ca779aa..bbbb3fb985f 100644
--- a/source/blender/editors/Makefile
+++ b/source/blender/editors/Makefile
@@ -65,5 +65,6 @@ DIRS = armature \
space_text \
space_sequencer \
space_logic \
+ space_userpref \
include nan_subdirs.mk
diff --git a/source/blender/editors/SConscript b/source/blender/editors/SConscript
index 0a13082faaf..05f17dae1a1 100644
--- a/source/blender/editors/SConscript
+++ b/source/blender/editors/SConscript
@@ -32,6 +32,7 @@ SConscript(['datafiles/SConscript',
'space_sequencer/SConscript',
'space_logic/SConscript',
'space_console/SConscript',
+ 'space_userpref/SConscript',
'transform/SConscript',
'screen/SConscript',
'sculpt_paint/SConscript',
diff --git a/source/blender/editors/include/ED_space_api.h b/source/blender/editors/include/ED_space_api.h
index efaf0f56f92..04b6be3bcaa 100644
--- a/source/blender/editors/include/ED_space_api.h
+++ b/source/blender/editors/include/ED_space_api.h
@@ -52,6 +52,7 @@ void ED_spacetype_text(void);
void ED_spacetype_sequencer(void);
void ED_spacetype_logic(void);
void ED_spacetype_console(void);
+void ED_spacetype_userpref(void);
/* calls for instancing and freeing spacetype static data
called in WM_init_exit */
diff --git a/source/blender/editors/interface/interface_panel.c b/source/blender/editors/interface/interface_panel.c
index efff5b8f39c..05001109b53 100644
--- a/source/blender/editors/interface/interface_panel.c
+++ b/source/blender/editors/interface/interface_panel.c
@@ -104,7 +104,7 @@ static int panel_aligned(ScrArea *sa, ARegion *ar)
SpaceButs *sbuts= sa->spacedata.first;
return sbuts->align;
}
- else if(sa->spacetype==SPACE_INFO && ar->regiontype == RGN_TYPE_WINDOW)
+ else if(sa->spacetype==SPACE_USERPREF && ar->regiontype == RGN_TYPE_WINDOW)
return BUT_VERTICAL;
else if(sa->spacetype==SPACE_FILE && ar->regiontype == RGN_TYPE_CHANNELS)
return BUT_VERTICAL;
diff --git a/source/blender/editors/interface/resources.c b/source/blender/editors/interface/resources.c
index 297e22610a6..5b51d898235 100644
--- a/source/blender/editors/interface/resources.c
+++ b/source/blender/editors/interface/resources.c
@@ -150,6 +150,9 @@ char *UI_ThemeGetColorPtr(bTheme *btheme, int spacetype, int colorid)
case SPACE_INFO:
ts= &btheme->tinfo;
break;
+ case SPACE_USERPREF:
+ ts= &btheme->tuserpref;
+ break;
case SPACE_TIME:
ts= &btheme->ttime;
break;
@@ -402,6 +405,7 @@ static void ui_theme_init_new(bTheme *btheme)
ui_theme_init_new_do(&btheme->ttime);
ui_theme_init_new_do(&btheme->tnode);
ui_theme_init_new_do(&btheme->tlogic);
+ ui_theme_init_new_do(&btheme->tuserpref);
}
@@ -583,6 +587,10 @@ void ui_theme_init_userdef(void)
btheme->tinfo= btheme->tv3d;
SETCOLF(btheme->tinfo.back, 0.45, 0.45, 0.45, 1.0);
+ /* space user preferences */
+ btheme->tuserpref= btheme->tv3d;
+ SETCOLF(btheme->tuserpref.back, 0.45, 0.45, 0.45, 1.0);
+
/* space sound */
btheme->tsnd= btheme->tv3d;
SETCOLF(btheme->tsnd.back, 0.45, 0.45, 0.45, 1.0);
@@ -1233,6 +1241,7 @@ void init_userdef_do_versions(void)
}
SETCOLF(btheme->tinfo.back, 0.45, 0.45, 0.45, 1.0);
+ SETCOLF(btheme->tuserpref.back, 0.45, 0.45, 0.45, 1.0);
}
}
diff --git a/source/blender/editors/screen/area.c b/source/blender/editors/screen/area.c
index ff84542a7cd..ea1541a4e02 100644
--- a/source/blender/editors/screen/area.c
+++ b/source/blender/editors/screen/area.c
@@ -1066,8 +1066,9 @@ static char *windowtype_pup(void)
"|%l"
"|Properties %x4"
- "|User Preferences %x7"
"|Outliner %x3"
+ "|User Preferences %x19"
+ "|Info%x7"
"|%l"
"|%l"
diff --git a/source/blender/editors/space_api/spacetypes.c b/source/blender/editors/space_api/spacetypes.c
index 5c33b648947..041e6a09323 100644
--- a/source/blender/editors/space_api/spacetypes.c
+++ b/source/blender/editors/space_api/spacetypes.c
@@ -77,6 +77,7 @@ void ED_spacetypes_init(void)
ED_spacetype_sequencer();
ED_spacetype_logic();
ED_spacetype_console();
+ ED_spacetype_userpref();
// ...
/* register operator types for screen and all spaces */
diff --git a/source/blender/editors/space_buttons/buttons_context.c b/source/blender/editors/space_buttons/buttons_context.c
index 6b89532cdaf..530500cfafa 100644
--- a/source/blender/editors/space_buttons/buttons_context.c
+++ b/source/blender/editors/space_buttons/buttons_context.c
@@ -311,7 +311,6 @@ static int buttons_context_path_brush(const bContext *C, ButsContextPath *path)
ToolSettings *ts;
Brush *br= NULL;
PointerRNA *ptr= &path->ptr[path->len-1];
- const Object *obact = CTX_data_active_object(C);
/* if we already have a (pinned) brush, we're done */
if(RNA_struct_is_a(ptr->type, &RNA_Brush)) {
@@ -333,7 +332,7 @@ static int buttons_context_path_brush(const bContext *C, ButsContextPath *path)
}
}
- /* no path to a world possible */
+ /* no path to a brush possible */
return 0;
}
diff --git a/source/blender/editors/space_buttons/buttons_ops.c b/source/blender/editors/space_buttons/buttons_ops.c
index e52efe8508d..057f35a2487 100644
--- a/source/blender/editors/space_buttons/buttons_ops.c
+++ b/source/blender/editors/space_buttons/buttons_ops.c
@@ -916,7 +916,7 @@ static int toolbox_invoke(bContext *C, wmOperator *op, wmEvent *event)
uiPopupMenu *pup;
uiLayout *layout;
- RNA_pointer_create(&sc->id, &RNA_SpaceButtonsWindow, sbuts, &ptr);
+ RNA_pointer_create(&sc->id, &RNA_SpaceProperties, sbuts, &ptr);
pup= uiPupMenuBegin(C, "Align", 0);
layout= uiPupMenuLayout(pup);
diff --git a/source/blender/editors/space_info/info_intern.h b/source/blender/editors/space_info/info_intern.h
index 519364b58d9..070b627af07 100644
--- a/source/blender/editors/space_info/info_intern.h
+++ b/source/blender/editors/space_info/info_intern.h
@@ -32,9 +32,6 @@
struct wmOperatorType;
-/* info_header.c */
-void info_header_buttons(const bContext *C, ARegion *ar);
-
void FILE_OT_pack_all(struct wmOperatorType *ot);
void FILE_OT_unpack_all(struct wmOperatorType *ot);
void FILE_OT_make_paths_relative(struct wmOperatorType *ot);
diff --git a/source/blender/editors/space_userpref/Makefile b/source/blender/editors/space_userpref/Makefile
new file mode 100644
index 00000000000..be7206f51ce
--- /dev/null
+++ b/source/blender/editors/space_userpref/Makefile
@@ -0,0 +1,55 @@
+#
+# $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) 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_userpref
+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../../makesrna
+CPPFLAGS += -I../../imbuf
+CPPFLAGS += -I../../python
+CPPFLAGS += -I../../blenfont
+CPPFLAGS += -I$(NAN_GUARDEDALLOC)/include
+
+# own include
+
+CPPFLAGS += -I../include
diff --git a/source/blender/editors/space_userpref/SConscript b/source/blender/editors/space_userpref/SConscript
new file mode 100644
index 00000000000..1b808a5a7c0
--- /dev/null
+++ b/source/blender/editors/space_userpref/SConscript
@@ -0,0 +1,14 @@
+#!/usr/bin/python
+Import ('env')
+
+sources = env.Glob('*.c')
+
+incs = '../include ../../blenlib ../../blenkernel ../../makesdna ../../makesrna ../../imbuf ../../blenfont'
+incs += ' ../../windowmanager #/intern/guardedalloc #/extern/glew/include'
+
+defs = []
+
+if env['WITH_BF_GAMEENGINE']:
+ defs.append('GAMEBLENDER=1')
+
+env.BlenderLib ( 'bf_editors_space_userpref', sources, Split(incs), defs, libtype=['core'], priority=[70] )
diff --git a/source/blender/editors/space_userpref/space_userpref.c b/source/blender/editors/space_userpref/space_userpref.c
new file mode 100644
index 00000000000..8c9d723ce2c
--- /dev/null
+++ b/source/blender/editors/space_userpref/space_userpref.c
@@ -0,0 +1,188 @@
+/**
+ * $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_screen_types.h"
+
+#include "MEM_guardedalloc.h"
+
+#include "BLI_blenlib.h"
+
+#include "BKE_context.h"
+#include "BKE_screen.h"
+
+#include "ED_space_api.h"
+#include "ED_screen.h"
+
+#include "BIF_gl.h"
+
+#include "WM_api.h"
+#include "WM_types.h"
+
+#include "userpref_intern.h" // own include
+
+/* ******************** default callbacks for userpref space ***************** */
+
+static SpaceLink *userpref_new(const bContext *C)
+{
+ ARegion *ar;
+ SpaceUserPref *spref;
+
+ spref= MEM_callocN(sizeof(SpaceUserPref), "inituserpref");
+ spref->spacetype= SPACE_USERPREF;
+
+ /* header */
+ ar= MEM_callocN(sizeof(ARegion), "header for userpref");
+
+ BLI_addtail(&spref->regionbase, ar);
+ ar->regiontype= RGN_TYPE_HEADER;
+ ar->alignment= RGN_ALIGN_BOTTOM;
+
+ /* main area */
+ ar= MEM_callocN(sizeof(ARegion), "main area for userpref");
+
+ BLI_addtail(&spref->regionbase, ar);
+ ar->regiontype= RGN_TYPE_WINDOW;
+
+ return (SpaceLink *)spref;
+}
+
+/* not spacelink itself */
+static void userpref_free(SpaceLink *sl)
+{
+// SpaceUserPref *spref= (SpaceUserPref*) sl;
+
+}
+
+
+/* spacetype; init callback */
+static void userpref_init(struct wmWindowManager *wm, ScrArea *sa)
+{
+
+}
+
+static SpaceLink *userpref_duplicate(SpaceLink *sl)
+{
+ SpaceUserPref *sprefn= MEM_dupallocN(sl);
+
+ /* clear or remove stuff from old */
+
+ return (SpaceLink *)sprefn;
+}
+
+
+
+/* add handlers, stuff you only do once or on area/region changes */
+static void userpref_main_area_init(wmWindowManager *wm, ARegion *ar)
+{
+ ED_region_panels_init(wm, ar);
+}
+
+static void userpref_main_area_draw(const bContext *C, ARegion *ar)
+{
+ ED_region_panels(C, ar, 1, NULL, -1);
+}
+
+void userpref_operatortypes(void)
+{
+}
+
+void userpref_keymap(struct wmWindowManager *wm)
+{
+
+}
+
+/* add handlers, stuff you only do once or on area/region changes */
+static void userpref_header_area_init(wmWindowManager *wm, ARegion *ar)
+{
+ ED_region_header_init(ar);
+}
+
+static void userpref_header_area_draw(const bContext *C, ARegion *ar)
+{
+ ED_region_header(C, ar);
+}
+
+static void userpref_main_area_listener(ARegion *ar, wmNotifier *wmn)
+{
+ /* context changes */
+}
+
+static void userpref_header_listener(ARegion *ar, wmNotifier *wmn)
+{
+ /* context changes */
+ switch(wmn->category) {
+ default:
+ break;
+ }
+
+}
+
+/* only called once, from space/spacetypes.c */
+void ED_spacetype_userpref(void)
+{
+ SpaceType *st= MEM_callocN(sizeof(SpaceType), "spacetype userpref");
+ ARegionType *art;
+
+ st->spaceid= SPACE_USERPREF;
+
+ st->new= userpref_new;
+ st->free= userpref_free;
+ st->init= userpref_init;
+ st->duplicate= userpref_duplicate;
+ st->operatortypes= userpref_operatortypes;
+ st->keymap= userpref_keymap;
+
+ /* regions: main window */
+ art= MEM_callocN(sizeof(ARegionType), "spacetype userpref region");
+ art->regionid = RGN_TYPE_WINDOW;
+ art->init= userpref_main_area_init;
+ art->draw= userpref_main_area_draw;
+ art->listener= userpref_main_area_listener;
+ art->keymapflag= ED_KEYMAP_UI|ED_KEYMAP_VIEW2D;
+
+ BLI_addhead(&st->regiontypes, art);
+
+ /* regions: header */
+ art= MEM_callocN(sizeof(ARegionType), "spacetype userpref region");
+ art->regionid = RGN_TYPE_HEADER;
+ art->minsizey= HEADERY;
+ art->keymapflag= ED_KEYMAP_UI|ED_KEYMAP_VIEW2D;
+ art->listener= userpref_header_listener;
+ art->init= userpref_header_area_init;
+ art->draw= userpref_header_area_draw;
+
+ BLI_addhead(&st->regiontypes, art);
+
+
+ BKE_spacetype_register(st);
+}
+
diff --git a/source/blender/editors/space_userpref/userpref_intern.h b/source/blender/editors/space_userpref/userpref_intern.h
new file mode 100644
index 00000000000..596c2675b01
--- /dev/null
+++ b/source/blender/editors/space_userpref/userpref_intern.h
@@ -0,0 +1,34 @@
+/**
+ * $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_USERPREF_INTERN_H
+#define ED_USERPREF_INTERN_H
+
+/* internal exports only */
+
+#endif /* ED_USERPREF_INTERN_H */
+
diff --git a/source/blender/editors/space_userpref/userpref_ops.c b/source/blender/editors/space_userpref/userpref_ops.c
new file mode 100644
index 00000000000..91a6651bd92
--- /dev/null
+++ b/source/blender/editors/space_userpref/userpref_ops.c
@@ -0,0 +1,33 @@
+/**
+ * $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 "userpref_intern.h"
+
diff --git a/source/blender/makesdna/DNA_space_types.h b/source/blender/makesdna/DNA_space_types.h
index 6eb5afbd6ac..37f28cfeaa6 100644
--- a/source/blender/makesdna/DNA_space_types.h
+++ b/source/blender/makesdna/DNA_space_types.h
@@ -508,6 +508,13 @@ typedef struct SpaceConsole {
} SpaceConsole;
+typedef struct SpaceUserPref {
+ SpaceLink *next, *prev;
+ ListBase regionbase; /* storage of regions for inactive spaces */
+ int spacetype;
+
+ int pad;
+} SpaceUserPref;
/* view3d Now in DNA_view3d_types.h */
@@ -861,7 +868,8 @@ enum {
SPACE_NODE,
SPACE_LOGIC,
SPACE_CONSOLE,
- SPACEICONMAX = SPACE_CONSOLE
+ SPACE_USERPREF,
+ SPACEICONMAX = SPACE_USERPREF
};
#endif
diff --git a/source/blender/makesdna/DNA_userdef_types.h b/source/blender/makesdna/DNA_userdef_types.h
index 019dad4eed5..c2314e1e3a2 100644
--- a/source/blender/makesdna/DNA_userdef_types.h
+++ b/source/blender/makesdna/DNA_userdef_types.h
@@ -260,6 +260,7 @@ typedef struct bTheme {
ThemeSpace ttime;
ThemeSpace tnode;
ThemeSpace tlogic;
+ ThemeSpace tuserpref;
/* 20 sets of bone colors for this theme */
ThemeWireColor tarm[20];
diff --git a/source/blender/makesrna/RNA_access.h b/source/blender/makesrna/RNA_access.h
index d5680ac77ba..e08bc734242 100644
--- a/source/blender/makesrna/RNA_access.h
+++ b/source/blender/makesrna/RNA_access.h
@@ -252,6 +252,7 @@ extern StructRNA RNA_MarbleTexture;
extern StructRNA RNA_MaskModifier;
extern StructRNA RNA_Material;
extern StructRNA RNA_MaterialHalo;
+extern StructRNA RNA_MaterialPhysics;
extern StructRNA RNA_MaterialRaytraceMirror;
extern StructRNA RNA_MaterialRaytraceTransparency;
extern StructRNA RNA_MaterialSlot;
@@ -304,8 +305,11 @@ extern StructRNA RNA_OperatorStrokeElement;
extern StructRNA RNA_OrController;
extern StructRNA RNA_OutflowFluidSettings;
extern StructRNA RNA_PackedFile;
+extern StructRNA RNA_Paint;
extern StructRNA RNA_Panel;
extern StructRNA RNA_Particle;
+extern StructRNA RNA_ParticleBrush;
+extern StructRNA RNA_ParticleEdit;
extern StructRNA RNA_ParticleFluidSettings;
extern StructRNA RNA_ParticleHairKey;
extern StructRNA RNA_ParticleInstanceModifier;
@@ -328,6 +332,7 @@ extern StructRNA RNA_RadarSensor;
extern StructRNA RNA_RandomSensor;
extern StructRNA RNA_RaySensor;
extern StructRNA RNA_Region;
+extern StructRNA RNA_RenderEngine;
extern StructRNA RNA_RenderLayer;
extern StructRNA RNA_RenderPass;
extern StructRNA RNA_RenderResult;
@@ -378,6 +383,9 @@ extern StructRNA RNA_ShapeKeyPoint;
extern StructRNA RNA_ShrinkwrapConstraint;
extern StructRNA RNA_ShrinkwrapModifier;
extern StructRNA RNA_SimpleDeformModifier;
+extern StructRNA RNA_SmokeCollSettings;
+extern StructRNA RNA_SmokeDomainSettings;
+extern StructRNA RNA_SmokeFlowSettings;
extern StructRNA RNA_SmokeModifier;
extern StructRNA RNA_SmoothModifier;
extern StructRNA RNA_SoftBodyModifier;
@@ -386,18 +394,22 @@ extern StructRNA RNA_Sound;
extern StructRNA RNA_SoundSequence;
extern StructRNA RNA_Space;
extern StructRNA RNA_Space3DView;
-extern StructRNA RNA_SpaceButtonsWindow;
extern StructRNA RNA_SpaceConsole;
extern StructRNA RNA_SpaceDopeSheetEditor;
extern StructRNA RNA_SpaceFileBrowser;
extern StructRNA RNA_SpaceGraphEditor;
extern StructRNA RNA_SpaceImageEditor;
+extern StructRNA RNA_SpaceInfo;
+extern StructRNA RNA_SpaceLogicEditor;
extern StructRNA RNA_SpaceNLA;
-extern StructRNA RNA_SpaceTimeline;
+extern StructRNA RNA_SpaceNodeEditor;
extern StructRNA RNA_SpaceOutliner;
+extern StructRNA RNA_SpaceProperties;
extern StructRNA RNA_SpaceSequenceEditor;
extern StructRNA RNA_SpaceTextEditor;
+extern StructRNA RNA_SpaceTimeline;
extern StructRNA RNA_SpaceUVEditor;
+extern StructRNA RNA_SpaceUserPreferences;
extern StructRNA RNA_SpeedControlSequence;
extern StructRNA RNA_SpotLamp;
extern StructRNA RNA_StretchToConstraint;
@@ -443,16 +455,17 @@ extern StructRNA RNA_TextureSlot;
extern StructRNA RNA_Theme;
extern StructRNA RNA_ThemeAudioWindow;
extern StructRNA RNA_ThemeBoneColorSet;
-extern StructRNA RNA_ThemeButtonsWindow;
extern StructRNA RNA_ThemeDopeSheet;
extern StructRNA RNA_ThemeFileBrowser;
extern StructRNA RNA_ThemeFontStyle;
extern StructRNA RNA_ThemeGraphEditor;
extern StructRNA RNA_ThemeImageEditor;
+extern StructRNA RNA_ThemeInfo;
extern StructRNA RNA_ThemeLogicEditor;
extern StructRNA RNA_ThemeNLAEditor;
extern StructRNA RNA_ThemeNodeEditor;
extern StructRNA RNA_ThemeOutliner;
+extern StructRNA RNA_ThemeProperties;
extern StructRNA RNA_ThemeSequenceEditor;
extern StructRNA RNA_ThemeStyle;
extern StructRNA RNA_ThemeTextEditor;
@@ -474,17 +487,16 @@ extern StructRNA RNA_UVProjectModifier;
extern StructRNA RNA_UnitSettings;
extern StructRNA RNA_UnknownType;
extern StructRNA RNA_UserPreferences;
-extern StructRNA RNA_UserPreferencesAutosave;
extern StructRNA RNA_UserPreferencesEdit;
extern StructRNA RNA_UserPreferencesFilePaths;
extern StructRNA RNA_UserPreferencesLanguage;
extern StructRNA RNA_UserPreferencesSystem;
extern StructRNA RNA_UserPreferencesView;
extern StructRNA RNA_UserSolidLight;
-extern StructRNA RNA_VertexPaint;
extern StructRNA RNA_VectorFont;
extern StructRNA RNA_VertexGroup;
extern StructRNA RNA_VertexGroupElement;
+extern StructRNA RNA_VertexPaint;
extern StructRNA RNA_VoronoiTexture;
extern StructRNA RNA_WaveModifier;
extern StructRNA RNA_Window;
diff --git a/source/blender/makesrna/intern/rna_space.c b/source/blender/makesrna/intern/rna_space.c
index 991b50afa5a..e5332d32f13 100644
--- a/source/blender/makesrna/intern/rna_space.c
+++ b/source/blender/makesrna/intern/rna_space.c
@@ -49,7 +49,7 @@ EnumPropertyItem space_type_items[] = {
{SPACE_BUTS, "PROPERTIES", 0, "Properties", ""},
{SPACE_FILE, "FILE_BROWSER", 0, "File Browser", ""},
{SPACE_IMAGE, "IMAGE_EDITOR", 0, "Image Editor", ""},
- {SPACE_INFO, "USER_PREFERENCES", 0, "User Preferences", ""},
+ {SPACE_INFO, "INFO", 0, "Info", ""},
{SPACE_SEQ, "SEQUENCE_EDITOR", 0, "Sequence Editor", ""},
{SPACE_TEXT, "TEXT_EDITOR", 0, "Text Editor", ""},
//{SPACE_IMASEL, "IMAGE_BROWSER", 0, "Image Browser", ""},
@@ -61,6 +61,7 @@ EnumPropertyItem space_type_items[] = {
{SPACE_NODE, "NODE_EDITOR", 0, "Node Editor", ""},
{SPACE_LOGIC, "LOGIC_EDITOR", 0, "Logic Editor", ""},
{SPACE_CONSOLE, "CONSOLE", 0, "Console", ""},
+ {SPACE_USERPREF, "USER_PREFERENCES", 0, "User Preferences", ""},
{0, NULL, 0, NULL, NULL}};
#define DC_RGB {0, "COLOR", ICON_IMAGE_RGB, "Color", "Draw image with RGB colors."}
@@ -101,13 +102,13 @@ static StructRNA* rna_Space_refine(struct PointerRNA *ptr)
case SPACE_OUTLINER:
return &RNA_SpaceOutliner;
case SPACE_BUTS:
- return &RNA_SpaceButtonsWindow;
+ return &RNA_SpaceProperties;
case SPACE_FILE:
return &RNA_SpaceFileBrowser;
case SPACE_IMAGE:
return &RNA_SpaceImageEditor;
- /*case SPACE_INFO:
- return &RNA_SpaceUserPreferences;*/
+ case SPACE_INFO:
+ return &RNA_SpaceInfo;
case SPACE_SEQ:
return &RNA_SpaceSequenceEditor;
case SPACE_TEXT:
@@ -124,12 +125,14 @@ static StructRNA* rna_Space_refine(struct PointerRNA *ptr)
return &RNA_SpaceScriptsWindow;*/
case SPACE_TIME:
return &RNA_SpaceTimeline;
- /*case SPACE_NODE:
+ case SPACE_NODE:
return &RNA_SpaceNodeEditor;
case SPACE_LOGIC:
- return &RNA_SpaceLogicEditor;*/
+ return &RNA_SpaceLogicEditor;
case SPACE_CONSOLE:
return &RNA_SpaceConsole;
+ case SPACE_USERPREF:
+ return &RNA_SpaceUserPreferences;
default:
return &RNA_Space;
}
@@ -230,9 +233,9 @@ void rna_SpaceFileBrowser_params_set(PointerRNA *ptr, PointerRNA value)
sfile->params= value.data;
}
-/* Space Buttons */
+/* Space Properties */
-StructRNA *rna_SpaceButtonsWindow_pin_id_typef(PointerRNA *ptr)
+StructRNA *rna_SpaceProperties_pin_id_typef(PointerRNA *ptr)
{
SpaceButs *sbuts= (SpaceButs*)(ptr->data);
@@ -242,7 +245,7 @@ StructRNA *rna_SpaceButtonsWindow_pin_id_typef(PointerRNA *ptr)
return &RNA_ID;
}
-void rna_SpaceButtonsWindow_align_set(PointerRNA *ptr, int value)
+void rna_SpaceProperties_align_set(PointerRNA *ptr, int value)
{
SpaceButs *sbuts= (SpaceButs*)(ptr->data);
@@ -718,9 +721,9 @@ static void rna_def_space_buttons(BlenderRNA *brna)
{BUT_VERTICAL, "VERTICAL", 0, "Vertical", ""},
{0, NULL, 0, NULL, NULL}};
- srna= RNA_def_struct(brna, "SpaceButtonsWindow", "Space");
+ srna= RNA_def_struct(brna, "SpaceProperties", "Space");
RNA_def_struct_sdna(srna, "SpaceButs");
- RNA_def_struct_ui_text(srna, "Buttons Space", "Buttons Window space data");
+ RNA_def_struct_ui_text(srna, "Properties Space", "Properties space data");
prop= RNA_def_property(srna, "context", PROP_ENUM, PROP_NONE);
RNA_def_property_enum_sdna(prop, NULL, "mainb");
@@ -731,7 +734,7 @@ static void rna_def_space_buttons(BlenderRNA *brna)
prop= RNA_def_property(srna, "align", PROP_ENUM, PROP_NONE);
RNA_def_property_enum_sdna(prop, NULL, "align");
RNA_def_property_enum_items(prop, align_items);
- RNA_def_property_enum_funcs(prop, NULL, "rna_SpaceButtonsWindow_align_set", NULL);
+ RNA_def_property_enum_funcs(prop, NULL, "rna_SpaceProperties_align_set", NULL);
RNA_def_property_ui_text(prop, "Align", "Arrangement of the panels.");
RNA_def_property_update(prop, NC_WINDOW, NULL);
@@ -744,7 +747,7 @@ static void rna_def_space_buttons(BlenderRNA *brna)
prop= RNA_def_property(srna, "pin_id", PROP_POINTER, PROP_NONE);
RNA_def_property_pointer_sdna(prop, NULL, "pinid");
RNA_def_property_struct_type(prop, "ID");
- RNA_def_property_pointer_funcs(prop, NULL, NULL, "rna_SpaceButtonsWindow_pin_id_typef");
+ RNA_def_property_pointer_funcs(prop, NULL, NULL, "rna_SpaceProperties_pin_id_typef");
RNA_def_property_flag(prop, PROP_EDITABLE);
}
@@ -1377,7 +1380,42 @@ static void rna_def_space_filebrowser(BlenderRNA *brna)
RNA_def_property_pointer_sdna(prop, NULL, "params");
RNA_def_property_pointer_funcs(prop, NULL, "rna_SpaceFileBrowser_params_set", NULL);
RNA_def_property_ui_text(prop, "Filebrowser Parameter", "Parameters and Settings for the Filebrowser.");
+}
+
+static void rna_def_space_info(BlenderRNA *brna)
+{
+ StructRNA *srna;
+
+ srna= RNA_def_struct(brna, "SpaceInfo", "Space");
+ RNA_def_struct_sdna(srna, "SpaceInfo");
+ RNA_def_struct_ui_text(srna, "Space Info", "Info space data.");
+}
+
+static void rna_def_space_userpref(BlenderRNA *brna)
+{
+ StructRNA *srna;
+
+ srna= RNA_def_struct(brna, "SpaceUserPreferences", "Space");
+ RNA_def_struct_sdna(srna, "SpaceUserPref");
+ RNA_def_struct_ui_text(srna, "Space User Preferences", "User preferences space data.");
+}
+
+static void rna_def_space_node(BlenderRNA *brna)
+{
+ StructRNA *srna;
+
+ srna= RNA_def_struct(brna, "SpaceNodeEditor", "Space");
+ RNA_def_struct_sdna(srna, "SpaceNode");
+ RNA_def_struct_ui_text(srna, "Space Node Editor", "Node editor space data.");
+}
+
+static void rna_def_space_logic(BlenderRNA *brna)
+{
+ StructRNA *srna;
+ srna= RNA_def_struct(brna, "SpaceLogicEditor", "Space");
+ RNA_def_struct_sdna(srna, "SpaceLogic");
+ RNA_def_struct_ui_text(srna, "Space Logic Editor", "Logic editor space data.");
}
void RNA_def_space(BlenderRNA *brna)
@@ -1398,6 +1436,10 @@ void RNA_def_space(BlenderRNA *brna)
rna_def_space_time(brna);
rna_def_space_console(brna);
rna_def_console_line(brna);
+ rna_def_space_info(brna);
+ rna_def_space_userpref(brna);
+ rna_def_space_node(brna);
+ rna_def_space_logic(brna);
}
#endif
diff --git a/source/blender/makesrna/intern/rna_userdef.c b/source/blender/makesrna/intern/rna_userdef.c
index 836e6a2fda7..d1245528100 100644
--- a/source/blender/makesrna/intern/rna_userdef.c
+++ b/source/blender/makesrna/intern/rna_userdef.c
@@ -690,7 +690,7 @@ static void rna_def_userdef_theme_space_graph(BlenderRNA *brna)
srna= RNA_def_struct(brna, "ThemeGraphEditor", NULL);
RNA_def_struct_sdna(srna, "ThemeSpace");
- RNA_def_struct_ui_text(srna, "Theme Graph Editor", "Theme settings for the Ipo Editor.");
+ RNA_def_struct_ui_text(srna, "Theme Graph Editor", "Theme settings for the graph editor.");
rna_def_userdef_theme_spaces_main(srna, SPACE_IPO);
@@ -827,19 +827,33 @@ static void rna_def_userdef_theme_space_outliner(BlenderRNA *brna)
rna_def_userdef_theme_spaces_main(srna, SPACE_OUTLINER);
}
-static void rna_def_userdef_theme_space_info(BlenderRNA *brna)
+static void rna_def_userdef_theme_space_userpref(BlenderRNA *brna)
{
StructRNA *srna;
- /* space_info */
+ /* space_userpref */
srna= RNA_def_struct(brna, "ThemeUserPreferences", NULL);
RNA_def_struct_sdna(srna, "ThemeSpace");
RNA_def_struct_ui_text(srna, "Theme User Preferences", "Theme settings for the User Preferences.");
+ rna_def_userdef_theme_spaces_main(srna, SPACE_USERPREF);
+}
+
+static void rna_def_userdef_theme_space_info(BlenderRNA *brna)
+{
+ StructRNA *srna;
+
+ /* space_info */
+
+ srna= RNA_def_struct(brna, "ThemeInfo", NULL);
+ RNA_def_struct_sdna(srna, "ThemeSpace");
+ RNA_def_struct_ui_text(srna, "Theme Info", "Theme settings for Info.");
+
rna_def_userdef_theme_spaces_main(srna, SPACE_INFO);
}
+
static void rna_def_userdef_theme_space_text(BlenderRNA *brna)
{
StructRNA *srna;
@@ -997,7 +1011,7 @@ static void rna_def_userdef_theme_space_buts(BlenderRNA *brna)
/* space_buts */
- srna= RNA_def_struct(brna, "ThemeButtonsWindow", NULL);
+ srna= RNA_def_struct(brna, "ThemeProperties", NULL);
RNA_def_struct_sdna(srna, "ThemeSpace");
RNA_def_struct_ui_text(srna, "Theme Properties", "Theme settings for the Properties.");
@@ -1402,7 +1416,7 @@ static void rna_def_userdef_themes(BlenderRNA *brna)
prop= RNA_def_property(srna, "properties", PROP_POINTER, PROP_NEVER_NULL);
RNA_def_property_pointer_sdna(prop, NULL, "tbuts");
- RNA_def_property_struct_type(prop, "ThemeButtonsWindow");
+ RNA_def_property_struct_type(prop, "ThemeProperties");
RNA_def_property_ui_text(prop, "Properties", "");
prop= RNA_def_property(srna, "text_editor", PROP_POINTER, PROP_NEVER_NULL);
@@ -1430,8 +1444,13 @@ static void rna_def_userdef_themes(BlenderRNA *brna)
RNA_def_property_struct_type(prop, "ThemeOutliner");
RNA_def_property_ui_text(prop, "Outliner", "");
- prop= RNA_def_property(srna, "user_preferences", PROP_POINTER, PROP_NEVER_NULL);
+ prop= RNA_def_property(srna, "info", PROP_POINTER, PROP_NEVER_NULL);
RNA_def_property_pointer_sdna(prop, NULL, "tinfo");
+ RNA_def_property_struct_type(prop, "ThemeInfo");
+ RNA_def_property_ui_text(prop, "Info", "");
+
+ prop= RNA_def_property(srna, "user_preferences", PROP_POINTER, PROP_NEVER_NULL);
+ RNA_def_property_pointer_sdna(prop, NULL, "tuserpref");
RNA_def_property_struct_type(prop, "ThemeUserPreferences");
RNA_def_property_ui_text(prop, "User Preferences", "");
@@ -1460,6 +1479,7 @@ static void rna_def_userdef_dothemes(BlenderRNA *brna)
rna_def_userdef_theme_space_node(brna);
rna_def_userdef_theme_space_outliner(brna);
rna_def_userdef_theme_space_info(brna);
+ rna_def_userdef_theme_space_userpref(brna);
rna_def_userdef_theme_space_sound(brna);
rna_def_userdef_theme_space_logic(brna);
rna_def_userdef_theme_colorset(brna);
diff --git a/source/blender/windowmanager/intern/wm_window.c b/source/blender/windowmanager/intern/wm_window.c
index a6fbb0515bc..d6bde9a468c 100644
--- a/source/blender/windowmanager/intern/wm_window.c
+++ b/source/blender/windowmanager/intern/wm_window.c
@@ -446,14 +446,14 @@ void WM_window_open_temp(bContext *C, rcti *position, int type)
ED_area_newspace(C, sa, SPACE_IMAGE);
}
else {
- ED_area_newspace(C, sa, SPACE_INFO);
+ ED_area_newspace(C, sa, SPACE_USERPREF);
}
ED_screen_set(C, win->screen);
if(sa->spacetype==SPACE_IMAGE)
GHOST_SetTitle(win->ghostwin, "Blender Render");
- else if(ELEM(sa->spacetype, SPACE_OUTLINER, SPACE_INFO))
+ else if(ELEM(sa->spacetype, SPACE_OUTLINER, SPACE_USERPREF))
GHOST_SetTitle(win->ghostwin, "Blender User Preferences");
else if(sa->spacetype==SPACE_FILE)
GHOST_SetTitle(win->ghostwin, "Blender File View");