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:
authorTon Roosendaal <ton@blender.org>2008-12-12 19:29:33 +0300
committerTon Roosendaal <ton@blender.org>2008-12-12 19:29:33 +0300
commit2fa23a05941c652228d76c36e8f4d7e927538c8d (patch)
tree4d478b8b1dd6035efbb55478a4c767ca6debbb4d /source/blender/editors/space_outliner
parent05e5e00bc9fb5d0fd8f49d2315d4061cacdb83ab (diff)
2.5
Fixes in view2d: - mask/slider rects were calculated wrong 1 pixel (was overlapping) - found bug with outliner stretching on area-edge-dragging. It required an extra mapping of the 'cur view' via mask to actual region. - added v2d sanity check for uninitialized v2d's - removed cruft in do_versions for headers (gets catched with above) - added header-view2d-initialize function, for new-space calls Fixes in areamanager: - fixes in 'new space' for time/outliner/view2d (unfinished) For Joshua: - Making time window higher shows it doesn't update 'cur'. Not sure what kind of v2d flag should be checked or set?
Diffstat (limited to 'source/blender/editors/space_outliner')
-rw-r--r--source/blender/editors/space_outliner/space_outliner.c24
1 files changed, 23 insertions, 1 deletions
diff --git a/source/blender/editors/space_outliner/space_outliner.c b/source/blender/editors/space_outliner/space_outliner.c
index 4e497ee7b79..ecc25d473d8 100644
--- a/source/blender/editors/space_outliner/space_outliner.c
+++ b/source/blender/editors/space_outliner/space_outliner.c
@@ -480,10 +480,32 @@ static void outliner_header_area_free(ARegion *ar)
static SpaceLink *outliner_new(void)
{
+ ARegion *ar;
SpaceOops *soutliner;
soutliner= MEM_callocN(sizeof(SpaceOops), "initoutliner");
+ /* header */
+ ar= MEM_callocN(sizeof(ARegion), "header for outliner");
+
+ BLI_addtail(&soutliner->regionbase, ar);
+ ar->regiontype= RGN_TYPE_HEADER;
+ ar->alignment= RGN_ALIGN_BOTTOM;
+ UI_view2d_header_default(&ar->v2d);
+
+ /* main area */
+ ar= MEM_callocN(sizeof(ARegion), "main area for outliner");
+
+ BLI_addtail(&soutliner->regionbase, ar);
+ ar->regiontype= RGN_TYPE_WINDOW;
+
+ ar->v2d.scroll |= V2D_SCROLL_RIGHT;
+ ar->v2d.align = (V2D_ALIGN_NO_NEG_X|V2D_ALIGN_NO_POS_Y);
+ ar->v2d.keepzoom |= (V2D_LOCKZOOM_X|V2D_LOCKZOOM_Y);
+ ar->v2d.keepaspect= 1;
+ ar->v2d.keepzoom= 1;
+ ar->v2d.keeptot= 2; /* XXX make define */
+
return (SpaceLink*)soutliner;
}
@@ -515,7 +537,7 @@ static SpaceLink *outliner_duplicate(SpaceLink *sl)
return (SpaceLink *)soutlinern;
}
-/* only called once, from screen/spacetypes.c */
+/* only called once, from space_api/spacetypes.c */
void ED_spacetype_outliner(void)
{
SpaceType *st= MEM_callocN(sizeof(SpaceType), "spacetype time");