Revision: 20634 http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=20634 Author: yukishiro Date: 2009-06-04 21:35:03 +0200 (Thu, 04 Jun 2009)
Log Message: ----------- merge from 20612 to 20632 Modified Paths: -------------- branches/soc-2009-yukishiro/source/blender/blenloader/intern/readfile.c branches/soc-2009-yukishiro/source/blender/editors/include/UI_resources.h branches/soc-2009-yukishiro/source/blender/editors/interface/interface_layout.c branches/soc-2009-yukishiro/source/blender/editors/interface/interface_panel.c branches/soc-2009-yukishiro/source/blender/editors/interface/interface_utils.c branches/soc-2009-yukishiro/source/blender/editors/interface/interface_widgets.c branches/soc-2009-yukishiro/source/blender/editors/preview/previewrender.c branches/soc-2009-yukishiro/source/blender/editors/screen/area.c branches/soc-2009-yukishiro/source/blender/editors/screen/screen_ops.c branches/soc-2009-yukishiro/source/blender/editors/space_buttons/buttons_context.c branches/soc-2009-yukishiro/source/blender/editors/space_buttons/buttons_intern.h branches/soc-2009-yukishiro/source/blender/editors/space_buttons/space_buttons.c branches/soc-2009-yukishiro/source/blender/editors/space_info/info_header.c branches/soc-2009-yukishiro/source/blender/editors/space_outliner/outliner.c branches/soc-2009-yukishiro/source/blender/makesdna/DNA_space_types.h branches/soc-2009-yukishiro/source/blender/makesrna/RNA_access.h branches/soc-2009-yukishiro/source/blender/makesrna/RNA_define.h branches/soc-2009-yukishiro/source/blender/makesrna/intern/makesrna.c branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_ID.c branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_access.c branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_action.c branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_armature.c branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_brush.c branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_camera.c branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_curve.c branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_define.c branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_fcurve.c branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_group.c branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_image.c branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_internal.h branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_internal_types.h branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_key.c branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_lamp.c branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_lattice.c branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_main.c branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_material.c branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_mesh.c branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_meta.c branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_modifier.c branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_nodetree.c branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_nodetree_types.h branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_object.c branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_object_force.c branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_particle.c branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_rna.c branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_scene.c branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_screen.c branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_scriptlink.c branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_sound.c branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_text.c branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_texture.c branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_vfont.c branches/soc-2009-yukishiro/source/blender/makesrna/intern/rna_world.c branches/soc-2009-yukishiro/source/blender/windowmanager/intern/wm_operators.c Modified: branches/soc-2009-yukishiro/source/blender/blenloader/intern/readfile.c =================================================================== --- branches/soc-2009-yukishiro/source/blender/blenloader/intern/readfile.c 2009-06-04 19:18:21 UTC (rev 20633) +++ branches/soc-2009-yukishiro/source/blender/blenloader/intern/readfile.c 2009-06-04 19:35:03 UTC (rev 20634) @@ -4190,6 +4190,7 @@ SpaceButs *sbuts= (SpaceButs *)sl; sbuts->lockpoin= NULL; sbuts->ri= NULL; + sbuts->pinid= newlibadr(fd, sc->id.lib, sbuts->pinid); if(main->versionfile<132) butspace_version_132(sbuts); } @@ -4391,6 +4392,7 @@ else if(sl->spacetype==SPACE_BUTS) { SpaceButs *sbuts= (SpaceButs *)sl; sbuts->lockpoin= NULL; + sbuts->pinid = restore_pointer_by_name(newmain, sbuts->pinid, 0); //XXX if (sbuts->ri) sbuts->ri->curtile = 0; } else if(sl->spacetype==SPACE_FILE) { @@ -4674,6 +4676,10 @@ direct_link_gpencil(fd, sseq->gpd); } } + else if(sl->spacetype==SPACE_BUTS) { + SpaceButs *sbuts= (SpaceButs *)sl; + sbuts->path= NULL; + } } sa->actionzones.first= sa->actionzones.last= NULL; @@ -6744,26 +6750,26 @@ if(sbuts->mainb==BUTS_LAMP) { sbuts->mainb= CONTEXT_SHADING; - sbuts->tab[CONTEXT_SHADING]= TAB_SHADING_LAMP; + //sbuts->tab[CONTEXT_SHADING]= TAB_SHADING_LAMP; } else if(sbuts->mainb==BUTS_MAT) { sbuts->mainb= CONTEXT_SHADING; - sbuts->tab[CONTEXT_SHADING]= TAB_SHADING_MAT; + //sbuts->tab[CONTEXT_SHADING]= TAB_SHADING_MAT; } else if(sbuts->mainb==BUTS_TEX) { sbuts->mainb= CONTEXT_SHADING; - sbuts->tab[CONTEXT_SHADING]= TAB_SHADING_TEX; + //sbuts->tab[CONTEXT_SHADING]= TAB_SHADING_TEX; } else if(sbuts->mainb==BUTS_ANIM) { sbuts->mainb= CONTEXT_OBJECT; } else if(sbuts->mainb==BUTS_WORLD) { sbuts->mainb= CONTEXT_SCENE; - sbuts->tab[CONTEXT_SCENE]= TAB_SCENE_WORLD; + //sbuts->tab[CONTEXT_SCENE]= TAB_SCENE_WORLD; } else if(sbuts->mainb==BUTS_RENDER) { sbuts->mainb= CONTEXT_SCENE; - sbuts->tab[CONTEXT_SCENE]= TAB_SCENE_RENDER; + //sbuts->tab[CONTEXT_SCENE]= TAB_SCENE_RENDER; } else if(sbuts->mainb==BUTS_GAME) { sbuts->mainb= CONTEXT_LOGIC; @@ -6773,7 +6779,7 @@ } else if(sbuts->mainb==BUTS_RADIO) { sbuts->mainb= CONTEXT_SHADING; - sbuts->tab[CONTEXT_SHADING]= TAB_SHADING_RAD; + //sbuts->tab[CONTEXT_SHADING]= TAB_SHADING_RAD; } else if(sbuts->mainb==BUTS_CONSTRAINT) { sbuts->mainb= CONTEXT_OBJECT; Modified: branches/soc-2009-yukishiro/source/blender/editors/include/UI_resources.h =================================================================== --- branches/soc-2009-yukishiro/source/blender/editors/include/UI_resources.h 2009-06-04 19:18:21 UTC (rev 20633) +++ branches/soc-2009-yukishiro/source/blender/editors/include/UI_resources.h 2009-06-04 19:35:03 UTC (rev 20634) @@ -1098,9 +1098,6 @@ // get a 3 byte color, blended and shaded between two other char color pointers void UI_GetColorPtrBlendShade3ubv(char *cp1, char *cp2, char *col, float fac, int offset); -// get pointer from RNA pointer -int UI_GetIconRNA(struct PointerRNA *ptr); - // internal (blender) usage only, for init and set active void UI_SetTheme(int spacetype, int regionid); Modified: branches/soc-2009-yukishiro/source/blender/editors/interface/interface_layout.c =================================================================== --- branches/soc-2009-yukishiro/source/blender/editors/interface/interface_layout.c 2009-06-04 19:18:21 UTC (rev 20633) +++ branches/soc-2009-yukishiro/source/blender/editors/interface/interface_layout.c 2009-06-04 19:35:03 UTC (rev 20634) @@ -213,7 +213,7 @@ static int ui_layout_vary_direction(uiLayout *layout) { - return (layout->root->type == UI_LAYOUT_HEADER)? UI_ITEM_VARY_X: UI_ITEM_VARY_Y; + return (layout->root->type == UI_LAYOUT_HEADER || layout->alignment != UI_LAYOUT_ALIGN_EXPAND)? UI_ITEM_VARY_X: UI_ITEM_VARY_Y; } /* estimated size of text + icon */ @@ -224,9 +224,9 @@ if(icon && strcmp(name, "") == 0) return UI_UNIT_X; /* icon only */ else if(icon) - return (variable)? UI_GetStringWidth(name) + UI_UNIT_X: 10*UI_UNIT_X; /* icon + text */ + return (variable)? UI_GetStringWidth(name) + 4 + UI_UNIT_X: 10*UI_UNIT_X; /* icon + text */ else - return (variable)? UI_GetStringWidth(name) + UI_UNIT_X: 10*UI_UNIT_X; /* text only */ + return (variable)? UI_GetStringWidth(name) + 4 + UI_UNIT_X: 10*UI_UNIT_X; /* text only */ } static void ui_item_size(uiItem *item, int *r_w, int *r_h) Modified: branches/soc-2009-yukishiro/source/blender/editors/interface/interface_panel.c =================================================================== --- branches/soc-2009-yukishiro/source/blender/editors/interface/interface_panel.c 2009-06-04 19:18:21 UTC (rev 20633) +++ branches/soc-2009-yukishiro/source/blender/editors/interface/interface_panel.c 2009-06-04 19:35:03 UTC (rev 20634) @@ -119,7 +119,7 @@ SpaceButs *sbuts= sa->spacedata.first; if(sbuts->align) - if(sbuts->re_align || sbuts->mainbo!=sbuts->mainb || sbuts->tabo!=sbuts->tab[sbuts->mainb]) + if(sbuts->re_align || sbuts->mainbo!=sbuts->mainb) return 1; } else if(ar->regiontype==RGN_TYPE_UI) Modified: branches/soc-2009-yukishiro/source/blender/editors/interface/interface_utils.c =================================================================== --- branches/soc-2009-yukishiro/source/blender/editors/interface/interface_utils.c 2009-06-04 19:18:21 UTC (rev 20633) +++ branches/soc-2009-yukishiro/source/blender/editors/interface/interface_utils.c 2009-06-04 19:35:03 UTC (rev 20634) @@ -65,186 +65,6 @@ /*************************** RNA Utilities ******************************/ -int UI_GetIconRNA(PointerRNA *ptr) -{ - StructRNA *rnatype= ptr->type; - - if(rnatype == &RNA_Scene) - return ICON_SCENE_DATA; - else if(rnatype == &RNA_World) - return ICON_WORLD_DATA; - else if(rnatype == &RNA_Object) - return ICON_OBJECT_DATA; - else if(rnatype == &RNA_Mesh) - return ICON_MESH_DATA; - else if(rnatype == &RNA_MeshVertex) - return ICON_VERTEXSEL; - else if(rnatype == &RNA_MeshEdge) - return ICON_EDGESEL; - else if(rnatype == &RNA_MeshFace) - return ICON_FACESEL; - else if(rnatype == &RNA_MeshTextureFace) - return ICON_FACESEL_HLT; - else if(rnatype == &RNA_VertexGroup) - return ICON_GROUP_VERTEX; - else if(rnatype == &RNA_VertexGroupElement) - return ICON_GROUP_VERTEX; - else if(rnatype == &RNA_Curve) - return ICON_CURVE_DATA; - else if(rnatype == &RNA_MetaBall) - return ICON_META_DATA; - else if(rnatype == &RNA_MetaElement) - return ICON_OUTLINER_DATA_META; - else if(rnatype == &RNA_Lattice) - return ICON_LATTICE_DATA; - else if(rnatype == &RNA_Armature) - return ICON_ARMATURE_DATA; - else if(rnatype == &RNA_Bone) - return ICON_BONE_DATA; - else if(rnatype == &RNA_Camera) - return ICON_CAMERA_DATA; - else if(rnatype == &RNA_LocalLamp) - return ICON_LAMP_DATA; - else if(rnatype == &RNA_AreaLamp) - return ICON_LAMP_DATA; - else if(rnatype == &RNA_SpotLamp) - return ICON_LAMP_DATA; - else if(rnatype == &RNA_SunLamp) - return ICON_LAMP_DATA; - else if(rnatype == &RNA_HemiLamp) - return ICON_LAMP_DATA; - else if(rnatype == &RNA_Lamp) - return ICON_LAMP_DATA; - else if(rnatype == &RNA_Group) - return ICON_GROUP; - else if(rnatype == &RNA_ParticleSystem) - return ICON_PARTICLE_DATA; - else if(rnatype == &RNA_ParticleSettings) - return ICON_PARTICLE_DATA; - else if(rnatype == &RNA_Material) - return ICON_MATERIAL_DATA; - else if(rnatype == &RNA_Texture) - return ICON_TEXTURE_DATA; - else if(rnatype == &RNA_TextureSlot) - return ICON_TEXTURE_DATA; - else if(rnatype == &RNA_WorldTextureSlot) - return ICON_TEXTURE_DATA; - else if(rnatype == &RNA_MaterialTextureSlot) - return ICON_TEXTURE_DATA; - else if(rnatype == &RNA_Image) - return ICON_IMAGE_DATA; - else if(rnatype == &RNA_Screen) - return ICON_SPLITSCREEN; - else if(rnatype == &RNA_NodeTree) - return ICON_NODE; - else if(rnatype == &RNA_Text) - return ICON_TEXT; - else if(rnatype == &RNA_Sound) - return ICON_SOUND; - else if(rnatype == &RNA_Brush) - return ICON_BRUSH_DATA; - else if(rnatype == &RNA_VectorFont) - return ICON_FONT_DATA; - else if(rnatype == &RNA_Library) - return ICON_LIBRARY_DATA_DIRECT; - else if(rnatype == &RNA_Action) - return ICON_ACTION; - else if(rnatype == &RNA_FCurve) - return ICON_ANIM_DATA; - //else if(rnatype == &RNA_Ipo) - // return ICON_ANIM_DATA; - else if(rnatype == &RNA_Key) - return ICON_SHAPEKEY_DATA; - else if(rnatype == &RNA_Main) - return ICON_BLENDER; - else if(rnatype == &RNA_Struct) - return ICON_RNA; - else if(rnatype == &RNA_Property) - return ICON_RNA; - else if(rnatype == &RNA_BooleanProperty) - return ICON_RNA; - else if(rnatype == &RNA_IntProperty) - return ICON_RNA; - else if(rnatype == &RNA_FloatProperty) - return ICON_RNA; - else if(rnatype == &RNA_StringProperty) - return ICON_RNA; - else if(rnatype == &RNA_EnumProperty) - return ICON_RNA; - else if(rnatype == &RNA_EnumPropertyItem) - return ICON_RNA; - else if(rnatype == &RNA_PointerProperty) - return ICON_RNA; - else if(rnatype == &RNA_CollectionProperty) - return ICON_RNA; - else if(rnatype == &RNA_GameObjectSettings) - return ICON_GAME; - else if(rnatype == &RNA_ScriptLink) - return ICON_PYTHON; - - /* modifiers */ - else if(rnatype == &RNA_SubsurfModifier) - return ICON_MOD_SUBSURF; - else if(rnatype == &RNA_ArmatureModifier) - return ICON_MOD_ARMATURE; - else if(rnatype == &RNA_LatticeModifier) - return ICON_MOD_LATTICE; - else if(rnatype == &RNA_CurveModifier) - return ICON_MOD_CURVE; - else if(rnatype == &RNA_BuildModifier) - return ICON_MOD_BUILD; - else if(rnatype == &RNA_MirrorModifier) - return ICON_MOD_MIRROR; - else if(rnatype == &RNA_DecimateModifier) - return ICON_MOD_DECIM; - else if(rnatype == &RNA_WaveModifier) - return ICON_MOD_WAVE; - else if(rnatype == &RNA_HookModifier) - return ICON_HOOK; - else if(rnatype == &RNA_SoftbodyModifier) - return ICON_MOD_SOFT; - else if(rnatype == &RNA_BooleanModifier) - return ICON_MOD_BOOLEAN; - else if(rnatype == &RNA_ParticleInstanceModifier) - return ICON_MOD_PARTICLES; - else if(rnatype == &RNA_ParticleSystemModifier) - return ICON_MOD_PARTICLES; - else if(rnatype == &RNA_EdgeSplitModifier) @@ 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