[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18899] branches/blender2.5/blender/source /blender: 2.5: Silencing MSVC warnings in a few files ( many files still have many to clean out some other

2009-02-10 Thread Joshua Leung
Revision: 18899
  
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=18899
Author:   aligorith
Date: 2009-02-10 10:18:04 +0100 (Tue, 10 Feb 2009)

Log Message:
---
2.5: Silencing MSVC warnings in a few files (many files still have many to 
clean out some other day).

Modified Paths:
--
branches/blender2.5/blender/source/blender/blenkernel/intern/object.c
branches/blender2.5/blender/source/blender/blenlib/intern/arithb.c
branches/blender2.5/blender/source/blender/editors/armature/editarmature.c
branches/blender2.5/blender/source/blender/editors/space_outliner/outliner.c

branches/blender2.5/blender/source/blender/editors/space_outliner/outliner_header.c
branches/blender2.5/blender/source/blender/editors/space_time/space_time.c
branches/blender2.5/blender/source/blender/editors/space_time/time_header.c

branches/blender2.5/blender/source/blender/editors/space_view3d/drawarmature.c

Modified: branches/blender2.5/blender/source/blender/blenkernel/intern/object.c
===
--- branches/blender2.5/blender/source/blender/blenkernel/intern/object.c   
2009-02-10 06:12:35 UTC (rev 18898)
+++ branches/blender2.5/blender/source/blender/blenkernel/intern/object.c   
2009-02-10 09:18:04 UTC (rev 18899)
@@ -699,7 +699,7 @@
 {
Camera *cam = (Camera *)ob->data; 
if (ob->type != OB_CAMERA)
-   return 0.0;
+   return 0.0f;
if (cam->dof_ob) {  
/* too simple, better to return the distance on the view axis 
only
 * return VecLenf(ob->obmat[3], cam->dof_ob->obmat[3]); */
@@ -709,7 +709,7 @@
Mat4Ortho(obmat);
Mat4Invert(ob->imat, obmat);
Mat4MulMat4(mat, cam->dof_ob->obmat, ob->imat);
-   return fabs(mat[3][2]);
+   return (float)fabs(mat[3][2]);
}
return cam->YF_dofdist;
 }
@@ -720,26 +720,26 @@

la=  alloc_libblock(&G.main->lamp, ID_LA, name);

-   la->r= la->g= la->b= la->k= 1.0;
-   la->haint= la->energy= 1.0;
-   la->dist= 20.0;
-   la->spotsize= 45.0;
-   la->spotblend= 0.15;
-   la->att2= 1.0;
+   la->r= la->g= la->b= la->k= 1.0f;
+   la->haint= la->energy= 1.0f;
+   la->dist= 20.0f;
+   la->spotsize= 45.0f;
+   la->spotblend= 0.15f;
+   la->att2= 1.0f;
la->mode= LA_SHAD_BUF;
la->bufsize= 512;
-   la->clipsta= 0.5;
-   la->clipend= 40.0;
-   la->shadspotsize= 45.0;
+   la->clipsta= 0.5f;
+   la->clipend= 40.0f;
+   la->shadspotsize= 45.0f;
la->samp= 3;
-   la->bias= 1.0;
-   la->soft= 3.0;
+   la->bias= 1.0f;
+   la->soft= 3.0f;
la->ray_samp= la->ray_sampy= la->ray_sampz= 1; 
-   la->area_size=la->area_sizey=la->area_sizez= 1.0; 
+   la->area_size=la->area_sizey=la->area_sizez= 1.0f; 
la->buffers= 1;
la->buftype= LA_SHADBUF_HALFWAY;
la->ray_samp_method = LA_SAMP_HALTON;
-   la->adapt_thresh = 0.001;
+   la->adapt_thresh = 0.001f;
la->preview=NULL;
la->falloff_type = LA_FALLOFF_INVLINEAR;
la->curfalloff = curvemapping_add(1, 0.0f, 1.0f, 1.0f, 0.0f);
@@ -748,12 +748,12 @@
la->spread = 1.0;
la->sun_brightness = 1.0;
la->sun_size = 1.0;
-   la->backscattered_light = 1.0;
-   la->atm_turbidity = 2.0;
-   la->atm_inscattering_factor = 1.0;
-   la->atm_extinction_factor = 1.0;
-   la->atm_distance_factor = 1.0;
-   la->sun_intensity = 1.0;
+   la->backscattered_light = 1.0f;
+   la->atm_turbidity = 2.0f;
+   la->atm_inscattering_factor = 1.0f;
+   la->atm_extinction_factor = 1.0f;
+   la->atm_distance_factor = 1.0f;
+   la->sun_intensity = 1.0f;
la->skyblendtype= MA_RAMP_ADD;
la->skyblendfac= 1.0f;
la->sky_colorspace= BLI_CS_CIE;
@@ -1864,7 +1864,6 @@
/* and even worse, it gives bad effects for NLA stride too (try 
ctime != par->ctime, with MBlur) */
pop= 0;
if(no_parent_ipo==0 && stime != par->ctime) {
-   
// only for ipo systems? 
pushdata(par, sizeof(Object));
pop= 1;
@@ -1874,16 +1873,15 @@
}

solve_parenting(scene, ob, par, ob->obmat, slowmat, 0);
-
+   
if(pop) {
poplast(par);
}

if(ob->partype & PARSLOW) {
// include framerate
-
-   fac1= (1.0f/(1.0f+ fabs(give_timeoffset(ob;
-   if(fac1>=1.0) return;
+   fac1= ( 1.0f / (1.0f + 
(float)fabs(give_timeoffset(ob))) );
+   if(fac1 >= 1.0f) return;
 

[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18900] branches/blender2.5/blender/source /blender/editors/interface/interface_regions.c: 2.5

2009-02-10 Thread Ton Roosendaal
Revision: 18900
  
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=18900
Author:   ton
Date: 2009-02-10 10:49:36 +0100 (Tue, 10 Feb 2009)

Log Message:
---
2.5

Bugfix: CTRL+W "Save file" still gave a 'save over' popup when the
file didn't exist yet. It then attempted to free the operator twice.

Modified Paths:
--

branches/blender2.5/blender/source/blender/editors/interface/interface_regions.c

Modified: 
branches/blender2.5/blender/source/blender/editors/interface/interface_regions.c
===
--- 
branches/blender2.5/blender/source/blender/editors/interface/interface_regions.c
2009-02-10 09:18:04 UTC (rev 18899)
+++ 
branches/blender2.5/blender/source/blender/editors/interface/interface_regions.c
2009-02-10 09:49:36 UTC (rev 18900)
@@ -2301,16 +2301,15 @@
if(len==0)
return;
 
-   if(BLI_exists(filename)==0)
-   operator_cb(C, op, 1);
-
if(filename[len-1]=='/' || filename[len-1]=='\\') {
uiPupMenuError(C, "Cannot overwrite a directory");
WM_operator_free(op);
return;
}
-
-   confirm_operator(C, op, "Save over", filename);
+   if(BLI_exists(filename)==0)
+   operator_cb(C, op, 1);
+   else
+   confirm_operator(C, op, "Save over", filename);
 }
 
 void uiPupMenuNotice(bContext *C, char *str, ...)


___
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
http://lists.blender.org/mailman/listinfo/bf-blender-cvs


[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18901] branches/blender2.5/blender/source /blender/editors/armature/editarmature.c: Armature Parenting: Fixing up this operator to use the new contex

2009-02-10 Thread Joshua Leung
Revision: 18901
  
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=18901
Author:   aligorith
Date: 2009-02-10 10:55:46 +0100 (Tue, 10 Feb 2009)

Log Message:
---
Armature Parenting: Fixing up this operator to use the new context iterators 
properly

Modified Paths:
--
branches/blender2.5/blender/source/blender/editors/armature/editarmature.c

Modified: 
branches/blender2.5/blender/source/blender/editors/armature/editarmature.c
===
--- branches/blender2.5/blender/source/blender/editors/armature/editarmature.c  
2009-02-10 09:49:36 UTC (rev 18900)
+++ branches/blender2.5/blender/source/blender/editors/armature/editarmature.c  
2009-02-10 09:55:46 UTC (rev 18901)
@@ -3357,65 +3357,61 @@
 {
Object *ob= CTX_data_edit_object(C);
bArmature *arm= (bArmature *)ob->data;
-   EditBone *flipbone, *flippar;
EditBone *actbone = CTX_data_active_bone(C);
-   short allchildbones= 0, foundselbone= 0;
+   EditBone *actmirb = NULL;
short val = RNA_enum_get(op->ptr, "type");

-   /* find selected bones */
-   CTX_DATA_BEGIN(C, EditBone *, ebone, selected_editable_bones) {
-   if (ebone != actbone) {
-   foundselbone++;
-   if (ebone->parent != actbone) allchildbones= 1; 
-   }   
+   /* there must be an active bone */
+   if (actbone == NULL) {
+   BKE_report(op->reports, RPT_ERROR, "Operation requires an 
Active Bone");
+   return OPERATOR_CANCELLED;
}
-   CTX_DATA_END;
-
-   if (foundselbone==0 && actbone->parent) {
+   else if (arm->flag & ARM_MIRROR_EDIT) {
+   /* For X-Axis Mirror Editing option, we may need a mirror copy 
of actbone
+* - if there's a mirrored copy of selbone, try to find a 
mirrored copy of actbone 
+*  (i.e.  selbone="child.L" and actbone="parent.L", find 
"child.R" and "parent.R").
+*  This is useful for arm-chains, for example parenting 
lower arm to upper arm
+* - if there's no mirrored copy of actbone (i.e. actbone = 
"parent.C" or "parent")
+*  then just use actbone. Useful when doing upper arm to 
spine.
+*/
+   actmirb= ED_armature_bone_get_mirrored(arm->edbo, actbone);
+   if (actmirb == NULL) 
+   actmirb= actbone;
+   }
+   
+   /* if there is only 1 selected bone, we assume that that is the active 
bone, 
+* since a user will need to have clicked on a bone (thus selecting it) 
to make it active
+*/
+   if (CTX_DATA_COUNT(C, selected_editable_bones) <= 1) {
/* When only the active bone is selected, and it has a parent,
 * connect it to the parent, as that is the only possible 
outcome. 
 */
-   bone_connect_to_existing_parent(actbone);
-   
-   if (arm->flag & ARM_MIRROR_EDIT) {
-   flipbone = ED_armature_bone_get_mirrored(arm->edbo, 
actbone);
-   if (flipbone)
-   bone_connect_to_existing_parent(flipbone);
+   if (actbone->parent) {
+   bone_connect_to_existing_parent(actbone);
+   
+   if ((arm->flag & ARM_MIRROR_EDIT) && (actmirb->parent))
+   bone_connect_to_existing_parent(actmirb);
}
}
else {
-   /* loop through all editbones, parenting all selected bones to 
the active bone */
-   CTX_DATA_BEGIN(C, EditBone *, selbone, selected_editable_bones) 
{
-   if (selbone!=actbone) {
-   /* parent selbone to actbone */
-   bone_connect_to_new_parent(arm->edbo, selbone, 
actbone, val);
-   
-   if (arm->flag & ARM_MIRROR_EDIT) {
-   /* - if there's a mirrored copy of 
selbone, try to find a mirrored copy of actbone 
-*  (i.e.  selbone="child.L" and 
actbone="parent.L", find "child.R" and "parent.R").
-*  This is useful for arm-chains, 
for example parenting lower arm to upper arm
-* - if there's no mirrored copy of 
actbone (i.e. actbone = "parent.C" or "parent")
-*  then just use actbone. Useful 
when doing upper arm to spine.
-*/
-   flipbone = 
ED_armature_bone_get_mirrored(arm->edbo, selbone);
-   flippar = 
ED_armature_bone_get_mirrored(ar

[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18902] branches/blender2.5/blender/source /blender: Graph Editor: Restoring 'View All' (HomeKey) and Auto-Set Preview Range ('Ctrl Alt P')

2009-02-10 Thread Joshua Leung
Revision: 18902
  
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=18902
Author:   aligorith
Date: 2009-02-10 11:42:04 +0100 (Tue, 10 Feb 2009)

Log Message:
---
Graph Editor: Restoring 'View All' (HomeKey) and Auto-Set Preview Range ('Ctrl 
Alt P')

Modified Paths:
--
branches/blender2.5/blender/source/blender/blenkernel/BKE_fcurve.h
branches/blender2.5/blender/source/blender/blenkernel/intern/fcurve.c
branches/blender2.5/blender/source/blender/editors/space_graph/graph_edit.c
branches/blender2.5/blender/source/blender/editors/space_graph/graph_ops.c

Modified: branches/blender2.5/blender/source/blender/blenkernel/BKE_fcurve.h
===
--- branches/blender2.5/blender/source/blender/blenkernel/BKE_fcurve.h  
2009-02-10 09:55:46 UTC (rev 18901)
+++ branches/blender2.5/blender/source/blender/blenkernel/BKE_fcurve.h  
2009-02-10 10:42:04 UTC (rev 18902)
@@ -89,6 +89,9 @@
 /* get the time extents for F-Curve */
 void calc_fcurve_range(struct FCurve *fcu, float *min, float *max);
 
+/* get the bounding-box extents for F-Curve */
+void calc_fcurve_bounds(struct FCurve *fcu, float *xmin, float *xmax, float 
*ymin, float *ymax);
+
 /*  Curve Sanity   */
 
 void calchandles_fcurve(struct FCurve *fcu);

Modified: branches/blender2.5/blender/source/blender/blenkernel/intern/fcurve.c
===
--- branches/blender2.5/blender/source/blender/blenkernel/intern/fcurve.c   
2009-02-10 09:55:46 UTC (rev 18901)
+++ branches/blender2.5/blender/source/blender/blenkernel/intern/fcurve.c   
2009-02-10 10:42:04 UTC (rev 18902)
@@ -170,6 +170,73 @@
return NULL;
 }
 
+/* Calculate the extents of F-Curve's data */
+void calc_fcurve_bounds (FCurve *fcu, float *xmin, float *xmax, float *ymin, 
float *ymax)
+{
+   float xminv=9.0f, xmaxv=-9.0f;
+   float yminv=9.0f, ymaxv=-9.0f;
+   short foundvert=0;
+   int i;
+   
+   if (fcu->totvert) {
+   if (fcu->bezt) {
+   /* frame range can be directly calculated from end 
verts */
+   if (xmin || xmax) {
+   xminv= MIN2(xminv, fcu->bezt[0].vec[1][0]);
+   xmaxv= MAX2(xmaxv, 
fcu->bezt[fcu->totvert-1].vec[1][0]);
+   }
+   
+   /* only loop over keyframes to find extents for values 
if needed */
+   if (ymin || ymax) {
+   BezTriple *bezt;
+   
+   for (bezt=fcu->bezt, i=0; i < fcu->totvert; 
bezt++, i++) {
+   yminv= MIN2(yminv, bezt->vec[1][1]);
+   ymaxv= MAX2(ymaxv, bezt->vec[1][1]);
+   }
+   }
+   }
+   else if (fcu->fpt) {
+   /* frame range can be directly calculated from end 
verts */
+   if (xmin || xmax) {
+   xminv= MIN2(xminv, fcu->fpt[0].vec[0]);
+   xmaxv= MAX2(xmaxv, 
fcu->fpt[fcu->totvert-1].vec[0]);
+   }
+   
+   /* only loop over keyframes to find extents for values 
if needed */
+   if (ymin || ymax) {
+   FPoint *fpt;
+   
+   for (fpt=fcu->fpt, i=0; i < fcu->totvert; 
fpt++, i++) {
+   yminv= MIN2(yminv, fpt->vec[1]);
+   ymaxv= MAX2(ymaxv, fpt->vec[1]);
+   }
+   }
+   }
+   
+   foundvert=1;
+   }
+   
+   /* minimum sizes are 1.0f */
+   if (foundvert) {
+   if (xminv == xmaxv) xmaxv += 1.0f;
+   if (yminv == ymaxv) ymaxv += 1.0f;
+   
+   if (xmin) *xmin= xminv;
+   if (xmax) *xmax= xmaxv;
+   
+   if (ymin) *ymin= yminv;
+   if (ymax) *ymax= ymaxv;
+   }
+   else {
+   if (xmin) *xmin= 0.0f;
+   if (xmax) *xmax= 0.0f;
+   
+   if (ymin) *ymin= 1.0f;
+   if (ymax) *ymax= 1.0f;
+   }
+}
+
 /* Calculate the extents of F-Curve's keyframes */
 void calc_fcurve_range (FCurve *fcu, float *start, float *end)
 {

Modified: 
branches/blender2.5/blender/source/blender/editors/space_graph/graph_edit.c
===
--- branches/blender2.5/blender/source/blender/editors/space_graph/graph_edit.c 
2009-02-10 09:55:46 UTC (rev 18901)
+++ branc

[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18903] branches/blender2.5/blender/source /blender/editors: Graph Editor: Visibility toggles

2009-02-10 Thread Joshua Leung
Revision: 18903
  
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=18903
Author:   aligorith
Date: 2009-02-10 12:37:14 +0100 (Tue, 10 Feb 2009)

Log Message:
---
Graph Editor: Visibility toggles

F-Curves can now be hidden/shown in the Graph Editor in one of 3 ways:
* Specialised VKEY toggle hotkey, which alters the visibility of all selected 
F-Curves 
* The setting toggle operators (Shift-W, Alt-W, Ctrl-Shift-W)
* Checkmark (*1) boxes in front of names of F-Curves

This allows irrelevant curves to be hidden from the keyframes area only if you 
want them hidden. By default, all curves are visible. Also note that a separate 
hotkey is used now for toggling visibility (VKEY) instead of lumping it under 
select-all (AKEY) as in the past, which was a major cause of confusion.

Notes:
1) I've used the ICON_BLANK011 and ICON_BLANK012 icons, which in the current 
icon set are two states for a checkbox type thing. These defines should 
probably get renamed sometime, but I'll leave that up to Matt.

Modified Paths:
--
branches/blender2.5/blender/source/blender/editors/animation/anim_channels.c
branches/blender2.5/blender/source/blender/editors/animation/anim_filter.c
branches/blender2.5/blender/source/blender/editors/space_graph/graph_draw.c

Modified: 
branches/blender2.5/blender/source/blender/editors/animation/anim_channels.c
===
--- 
branches/blender2.5/blender/source/blender/editors/animation/anim_channels.c
2009-02-10 10:42:04 UTC (rev 18902)
+++ 
branches/blender2.5/blender/source/blender/editors/animation/anim_channels.c
2009-02-10 11:37:14 UTC (rev 18903)
@@ -608,12 +608,70 @@
 
 #endif // XXX old animation system - needs to be updated for new system...
 
+
+/*  Toggle Channel Visibility Operator 
*** */
+
+static int animchannels_visibility_toggle_exec(bContext *C, wmOperator *op)
+{
+   bAnimContext ac;
+   ListBase anim_data = {NULL, NULL};
+   bAnimListElem *ale;
+   int filter;
+   short vis= ACHANNEL_SETFLAG_ADD;
+   
+   /* get editor data */
+   if (ANIM_animdata_get_context(C, &ac) == 0)
+   return OPERATOR_CANCELLED;
+   
+   /* filter data */
+   filter= (ANIMFILTER_VISIBLE | ANIMFILTER_SEL | ANIMFILTER_CURVESONLY);
+   ANIM_animdata_filter(&ac, &anim_data, filter, ac.data, ac.datatype);
+   
+   /* See if we should be making showing all selected or hiding */
+   for (ale= anim_data.first; ale; ale= ale->next) {
+   if (vis == ACHANNEL_SETFLAG_CLEAR) 
+   break;
+   
+   if (ale->flag & FCURVE_VISIBLE)
+   vis= ACHANNEL_SETFLAG_CLEAR;
+   }
+   
+   /* Now set the flags */
+   for (ale= anim_data.first; ale; ale= ale->next) {
+   FCurve *fcu= (FCurve *)ale->data;
+   ACHANNEL_SET_FLAG(fcu, vis, FCURVE_VISIBLE);
+   }
+   
+   /* cleanup */
+   BLI_freelistN(&anim_data);
+   
+   /* set notifier tha things have changed */
+   ANIM_animdata_send_notifiers(C, &ac, ANIM_CHANGED_CHANNELS);
+   
+   return OPERATOR_FINISHED;
+}
+ 
+void ANIM_OT_channels_visibility_toggle (wmOperatorType *ot)
+{
+   /* identifiers */
+   ot->name= "Toggle Visibility";
+   ot->idname= "ANIM_OT_channels_visibility_toggle";
+   
+   /* api callbacks */
+   ot->exec= animchannels_visibility_toggle_exec;
+   ot->poll= ED_operator_ipo_active;
+   
+   /* flags */
+   ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO;
+}
+
 /* ** Set Flags Operator *** */
 
 enum {
 // ACHANNEL_SETTING_SELECT = 0,
ACHANNEL_SETTING_PROTECT = 1,
ACHANNEL_SETTING_MUTE,
+   ACHANNEL_SETTING_VISIBLE,
 } eAnimChannel_Settings;
 
 /* defines for setting animation-channel flags */
@@ -672,6 +730,9 @@
else if (setting == ACHANNEL_SETTING_PROTECT) {
ACHANNEL_SET_FLAG(fcu, mode, 
FCURVE_PROTECTED);
}
+   else if (setting == ACHANNEL_SETTING_VISIBLE) {
+   ACHANNEL_SET_FLAG(fcu, mode, 
FCURVE_VISIBLE);
+   }
}
break;
case ANIMTYPE_GPLAYER:
@@ -1120,6 +1181,7 @@
case ANIMTYPE_FCURVE: 
{
FCurve *fcu= (FCurve *)ale->data;
+   short offset= (ac->datatype != ANIMCONT_ACTION)? 18 : 0;

if (x >= (ACHANNEL_NAMEWIDTH-ACHANNEL_BUTTON_WIDTH)) {
/* toggle protection */
@@ -1129,6 +1191,11 @@
   

[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18904] branches/blender2.5/blender/source /blender: 2.5

2009-02-10 Thread Ton Roosendaal
Revision: 18904
  
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=18904
Author:   ton
Date: 2009-02-10 16:38:00 +0100 (Tue, 10 Feb 2009)

Log Message:
---
2.5

*** Proof of concept! 

3D window Panels back, in own designated region for now.
Activate or hide it with Nkey.

Note that Background Image doesn't work yet,  Transform
Orientations probably need tests by Martin, Sculpt options
have to be recoded there by Nicholas.

The UI design sessions will of course review all of this!
We'll have to solve a lot of related topics;
- navigation (where) and context (what)
- non-overlapping layouts vs floating panels/bars
- properties vs tools (toolbars)
- drop panels and make nice (semi-automated) list views?

I've also done experiments with making the main 3d view
stay 'behind' the buttons region. That makes popping buttons
in and out less distracting, but also makes it obscuring
the view... it's not in this commit, it didn't work proper :)
To get that work it has to be handled by the internal
compositor, then it even can have fancy transparency in back.

Anyhoo, time enough to play with this a while. Especially for
Image window (paint) it can work well too.

Modified Paths:
--
branches/blender2.5/blender/source/blender/blenlib/BLI_rect.h
branches/blender2.5/blender/source/blender/blenlib/intern/rct.c

branches/blender2.5/blender/source/blender/editors/armature/armature_intern.h
branches/blender2.5/blender/source/blender/editors/include/ED_armature.h
branches/blender2.5/blender/source/blender/editors/include/UI_view2d.h

branches/blender2.5/blender/source/blender/editors/interface/interface_panel.c
branches/blender2.5/blender/source/blender/editors/interface/view2d.c
branches/blender2.5/blender/source/blender/editors/interface/view2d_ops.c
branches/blender2.5/blender/source/blender/editors/screen/area.c
branches/blender2.5/blender/source/blender/editors/space_node/drawnode.c

branches/blender2.5/blender/source/blender/editors/space_view3d/space_view3d.c

branches/blender2.5/blender/source/blender/editors/space_view3d/view3d_edit.c

branches/blender2.5/blender/source/blender/editors/space_view3d/view3d_header.c

branches/blender2.5/blender/source/blender/editors/space_view3d/view3d_intern.h
branches/blender2.5/blender/source/blender/editors/space_view3d/view3d_ops.c

branches/blender2.5/blender/source/blender/editors/space_view3d/view3d_view.c
branches/blender2.5/blender/source/blender/editors/space_view3d/vpaint.c
branches/blender2.5/blender/source/blender/makesdna/DNA_screen_types.h

Added Paths:
---

branches/blender2.5/blender/source/blender/editors/space_view3d/view3d_buttons.c

Modified: branches/blender2.5/blender/source/blender/blenlib/BLI_rect.h
===
--- branches/blender2.5/blender/source/blender/blenlib/BLI_rect.h   
2009-02-10 11:37:14 UTC (rev 18903)
+++ branches/blender2.5/blender/source/blender/blenlib/BLI_rect.h   
2009-02-10 15:38:00 UTC (rev 18904)
@@ -57,6 +57,7 @@
 int  BLI_isect_rctf(struct rctf *src1, struct rctf *src2, struct rctf *dest);
 int  BLI_isect_rcti(struct rcti *src1, struct rcti *src2, struct rcti *dest);
 void BLI_union_rctf(struct rctf *rcta, struct rctf *rctb);
+void BLI_union_rcti(struct rcti *rct1, struct rcti *rct2);
 
 #ifdef __cplusplus
 }

Modified: branches/blender2.5/blender/source/blender/blenlib/intern/rct.c
===
--- branches/blender2.5/blender/source/blender/blenlib/intern/rct.c 
2009-02-10 11:37:14 UTC (rev 18903)
+++ branches/blender2.5/blender/source/blender/blenlib/intern/rct.c 
2009-02-10 15:38:00 UTC (rev 18904)
@@ -70,7 +70,16 @@
 
 void BLI_union_rctf(rctf *rct1, rctf *rct2)
 {
+   
+   if(rct1->xmin>rct2->xmin) rct1->xmin= rct2->xmin;
+   if(rct1->xmaxxmax) rct1->xmax= rct2->xmax;
+   if(rct1->ymin>rct2->ymin) rct1->ymin= rct2->ymin;
+   if(rct1->ymaxymax) rct1->ymax= rct2->ymax;
+}
 
+void BLI_union_rcti(rcti *rct1, rcti *rct2)
+{
+   
if(rct1->xmin>rct2->xmin) rct1->xmin= rct2->xmin;
if(rct1->xmaxxmax) rct1->xmax= rct2->xmax;
if(rct1->ymin>rct2->ymin) rct1->ymin= rct2->ymin;

Modified: 
branches/blender2.5/blender/source/blender/editors/armature/armature_intern.h
===
--- 
branches/blender2.5/blender/source/blender/editors/armature/armature_intern.h   
2009-02-10 11:37:14 UTC (rev 18903)
+++ 
branches/blender2.5/blender/source/blender/editors/armature/armature_intern.h   
2009-02-10 15:38:00 UTC (rev 18904)
@@ -32,7 +32,6 @@
 struct wmOperatorType;
 
 /* editarmature.c */
-void armature_bone_rename(Object *ob, char *oldnamep, char *newnamep);
 
 void ARMATURE_OT_align_bones(struct wmOperatorType *ot);
 void ARMATURE_OT_calculate_roll(struct wm

[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18905] branches/blender2.5/blender/source /blender/editors/screen/screen_ops.c: 2.5

2009-02-10 Thread Ton Roosendaal
Revision: 18905
  
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=18905
Author:   ton
Date: 2009-02-10 16:51:33 +0100 (Tue, 10 Feb 2009)

Log Message:
---
2.5

Bugfix: Node operators were called in empty node editor, causing
NULL reading. Prevented it from happening with more strict poll()

Modified Paths:
--
branches/blender2.5/blender/source/blender/editors/screen/screen_ops.c

Modified: branches/blender2.5/blender/source/blender/editors/screen/screen_ops.c
===
--- branches/blender2.5/blender/source/blender/editors/screen/screen_ops.c  
2009-02-10 15:38:00 UTC (rev 18904)
+++ branches/blender2.5/blender/source/blender/editors/screen/screen_ops.c  
2009-02-10 15:51:33 UTC (rev 18905)
@@ -148,7 +148,12 @@
 
 int ED_operator_node_active(bContext *C)
 {
-   return ed_spacetype_test(C, SPACE_NODE);
+   if(ed_spacetype_test(C, SPACE_NODE)) {
+   SpaceNode *snode= (SpaceNode *)CTX_wm_space_data(C);
+   if(snode->edittree)
+   return 1;
+   }
+   return 0;
 }
 
 int ED_operator_ipo_active(bContext *C)


___
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
http://lists.blender.org/mailman/listinfo/bf-blender-cvs


[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18906] branches/blender2.5/blender/source /blender/blenlib/BLI_rect.h: 2.5

2009-02-10 Thread Ton Roosendaal
Revision: 18906
  
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=18906
Author:   ton
Date: 2009-02-10 17:51:04 +0100 (Tue, 10 Feb 2009)

Log Message:
---
2.5

Somehow this file was DOS linefeed... and I edited in adding a unix LF?
No idea, windows didnt compile it at least. :)

Modified Paths:
--
branches/blender2.5/blender/source/blender/blenlib/BLI_rect.h

Modified: branches/blender2.5/blender/source/blender/blenlib/BLI_rect.h
===
--- branches/blender2.5/blender/source/blender/blenlib/BLI_rect.h   
2009-02-10 15:51:33 UTC (rev 18905)
+++ branches/blender2.5/blender/source/blender/blenlib/BLI_rect.h   
2009-02-10 16:51:04 UTC (rev 18906)
@@ -1,66 +1,66 @@
-/*
- * $Id: BLI_blenlib.h 17433 2008-11-12 21:16:53Z blendix $
- *
- * * 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) 2001-2002 by NaN Holding BV.
- * All rights reserved.
- *
- * The Original Code is: all of this file.
- *
- * Contributor(s): none yet.
- *
- * * END GPL LICENSE BLOCK *
- *
- * $Id:  $ 
-*/
-
-#ifndef BLI_RECT_H
-#define BLI_RECT_H
-
-struct rctf;
-struct rcti;
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/* BLI_rct.c */
-/**
- * Determine if a rect is empty. An empty
- * rect is one with a zero (or negative)
- * width or height.
- *
- * @return True if @a rect is empty.
- */
-int  BLI_rcti_is_empty(struct rcti *rect);
-void BLI_init_rctf(struct rctf *rect, float xmin, float xmax, float ymin, 
float ymax);
-void BLI_init_rcti(struct rcti *rect, int xmin, int xmax, int ymin, int ymax);
-void BLI_translate_rctf(struct rctf *rect, float x, float y);
-void BLI_translate_rcti(struct rcti *rect, int x, int y);
-int  BLI_in_rcti(struct rcti *rect, int x, int y);
-int  BLI_in_rctf(struct rctf *rect, float x, float y);
-int  BLI_isect_rctf(struct rctf *src1, struct rctf *src2, struct rctf *dest);
-int  BLI_isect_rcti(struct rcti *src1, struct rcti *src2, struct rcti *dest);
-void BLI_union_rctf(struct rctf *rcta, struct rctf *rctb);
-void BLI_union_rcti(struct rcti *rct1, struct rcti *rct2);
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif
+/*
+ * $Id: BLI_blenlib.h 17433 2008-11-12 21:16:53Z blendix $
+ *
+ * * 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) 2001-2002 by NaN Holding BV.
+ * All rights reserved.
+ *
+ * The Original Code is: all of this file.
+ *
+ * Contributor(s): none yet.
+ *
+ * * END GPL LICENSE BLOCK *
+ *
+ * $Id:  $ 
+*/
+
+#ifndef BLI_RECT_H
+#define BLI_RECT_H
+
+struct rctf;
+struct rcti;
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+/* BLI_rct.c */
+/**
+ * Determine if a rect is empty. An empty
+ * rect is one with a zero (or negative)
+ * width or height.
+ *
+ * @return True if @a rect is empty.
+ */
+int  BLI_rcti_is_empty(struct rcti *rect);
+void BLI_init_rctf(struct rctf *rect, float xmin, float xmax, float ymin, 
float ymax);
+void BLI_init_rcti(struct rcti *rect, int xmin, int xmax, int ymin, int ymax);
+void BLI_translate_rctf(struct rctf *rect, float x, float y);
+void BLI_translate_rcti(struct rcti *rect, int x, int y);
+int  BLI_in_rcti(struct rcti *rect, int x, int y);
+int  BLI_in_rctf(struct rctf *rect, float x, float y);
+int  BLI_isect_rctf(struct rctf *src1, struct rctf *src2, struct rctf *dest);
+int  BLI_isect_rcti(struct rcti *src1, struct rcti *src2, struct rcti *dest);
+void BLI_union_rctf(struct rctf *rcta, struct rctf *rctb);
+void BL

[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18907] branches/blender2.5/blender/source /blender/blenlib: removed dos line endings on some other files.

2009-02-10 Thread Kent Mein
Revision: 18907
  
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=18907
Author:   sirdude
Date: 2009-02-10 17:53:42 +0100 (Tue, 10 Feb 2009)

Log Message:
---
removed dos line endings on some other files.

Kent

Modified Paths:
--
branches/blender2.5/blender/source/blender/blenlib/BLI_listbase.h
branches/blender2.5/blender/source/blender/blenlib/BLI_noise.h
branches/blender2.5/blender/source/blender/blenlib/BLI_string.h

Modified: branches/blender2.5/blender/source/blender/blenlib/BLI_listbase.h
===
--- branches/blender2.5/blender/source/blender/blenlib/BLI_listbase.h   
2009-02-10 16:51:04 UTC (rev 18906)
+++ branches/blender2.5/blender/source/blender/blenlib/BLI_listbase.h   
2009-02-10 16:53:42 UTC (rev 18907)
@@ -1,63 +1,63 @@
-/*
- * $Id: BLI_blenlib.h 17433 2008-11-12 21:16:53Z blendix $
- *
- * * 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) 2001-2002 by NaN Holding BV.
- * All rights reserved.
- *
- * The Original Code is: all of this file.
- *
- * Contributor(s): none yet.
- *
- * * END GPL LICENSE BLOCK *
- * 
- * $Id: $ 
-*/
-
-#ifndef BLI_LISTBASE_H
-#define BLI_LISTBASE_H
-
-//#include "DNA_listbase.h"
-struct ListBase;
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-void addlisttolist(struct ListBase *list1, struct ListBase *list2);
-void BLI_insertlink(struct ListBase *listbase, void *vprevlink, void 
*vnewlink);
-void *BLI_findlink(struct ListBase *listbase, int number);
-int BLI_findindex(struct ListBase *listbase, void *vlink);
-void BLI_freelistN(struct ListBase *listbase);
-void BLI_addtail(struct ListBase *listbase, void *vlink);
-void BLI_remlink(struct ListBase *listbase, void *vlink);
-
-void BLI_addhead(struct ListBase *listbase, void *vlink);
-void BLI_insertlinkbefore(struct ListBase *listbase, void *vnextlink, void 
*vnewlink);
-void BLI_insertlinkafter(struct ListBase *listbase, void *vprevlink, void 
*vnewlink);
-void BLI_sortlist(struct ListBase *listbase, int (*cmp)(void *, void *));
-void BLI_freelist(struct ListBase *listbase);
-int BLI_countlist(struct ListBase *listbase);
-void BLI_freelinkN(struct ListBase *listbase, void *vlink);
-void BLI_duplicatelist(struct ListBase *list1, struct ListBase *list2);  /* 
copy from 2 to 1 */
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif
+/*
+ * $Id: BLI_blenlib.h 17433 2008-11-12 21:16:53Z blendix $
+ *
+ * * 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) 2001-2002 by NaN Holding BV.
+ * All rights reserved.
+ *
+ * The Original Code is: all of this file.
+ *
+ * Contributor(s): none yet.
+ *
+ * * END GPL LICENSE BLOCK *
+ * 
+ * $Id: $ 
+*/
+
+#ifndef BLI_LISTBASE_H
+#define BLI_LISTBASE_H
+
+//#include "DNA_listbase.h"
+struct ListBase;
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void addlisttolist(struct ListBase *list1, struct ListBase *list2);
+void BLI_insertlink(struct ListBase *listbase, void *vprevlink, void 
*vnewlink);
+void *BLI_findlink(struct ListBase *listbase, int number);
+int BLI_findindex(struct ListBase *listbase, void *vlink);
+void BLI_freelistN(struct ListBase *listbase);
+void BLI_addtail(struct ListBase *listbase, void *vlink);
+void BLI_remlink(struct ListBase *listbase, void *vlink);
+
+void BLI_addhead(struct ListBase *listbase, void *vlink);
+void BLI_insertlinkbefore(struct ListBase *listbase, void *vnextlink, void 
*vnewlink);
+void BLI_insertlin

[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18908] branches/blender2.5/blender: A few more files with dos line endings.

2009-02-10 Thread Kent Mein
Revision: 18908
  
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=18908
Author:   sirdude
Date: 2009-02-10 18:06:43 +0100 (Tue, 10 Feb 2009)

Log Message:
---
A few more files with dos line endings.

Kent

Modified Paths:
--
branches/blender2.5/blender/extern/libopenjpeg/opj_malloc.h
branches/blender2.5/blender/source/blender/blenkernel/BKE_animsys.h
branches/blender2.5/blender/source/blender/blenkernel/BKE_fcurve.h
branches/blender2.5/blender/source/blender/blenkernel/intern/anim_sys.c
branches/blender2.5/blender/source/blender/blenkernel/intern/fcurve.c
branches/blender2.5/blender/source/blender/blenlib/intern/dynamiclist.c
branches/blender2.5/blender/source/blender/blenlib/intern/dynamiclist.h
branches/blender2.5/blender/source/blender/blenlib/intern/listbase.c
branches/blender2.5/blender/source/blender/blenlib/intern/string.c
branches/blender2.5/blender/source/blender/editors/animation/anim_filter.c

branches/blender2.5/blender/source/blender/editors/animation/keyframes_edit.c

branches/blender2.5/blender/source/blender/editors/animation/keyframes_general.c
branches/blender2.5/blender/source/blender/editors/animation/keyframing.c

branches/blender2.5/blender/source/blender/editors/datafiles/blenderbuttons.c

branches/blender2.5/blender/source/blender/editors/include/ED_keyframes_draw.h

branches/blender2.5/blender/source/blender/editors/include/ED_keyframes_edit.h
branches/blender2.5/blender/source/blender/editors/include/ED_keyframing.h

branches/blender2.5/blender/source/blender/editors/space_action/action_edit.c
branches/blender2.5/blender/source/blender/editors/space_action/action_ops.c

branches/blender2.5/blender/source/blender/editors/space_action/action_select.c
branches/blender2.5/blender/source/blender/editors/space_graph/graph_edit.c
branches/blender2.5/blender/source/blender/editors/space_graph/graph_ops.c

branches/blender2.5/blender/source/blender/editors/space_graph/graph_select.c
branches/blender2.5/blender/source/blender/makesdna/DNA_anim_types.h
branches/blender2.5/blender/source/blender/makesrna/intern/rna_constraint.c

Modified: branches/blender2.5/blender/extern/libopenjpeg/opj_malloc.h
===
--- branches/blender2.5/blender/extern/libopenjpeg/opj_malloc.h 2009-02-10 
16:53:42 UTC (rev 18907)
+++ branches/blender2.5/blender/extern/libopenjpeg/opj_malloc.h 2009-02-10 
17:06:43 UTC (rev 18908)
@@ -1,147 +1,147 @@
-/*
- * Copyright (c) 2005, Herv\xE9 Drolon, FreeImage Team
- * Copyright (c) 2007, Callum Lerwick 
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *notice, this list of conditions and the following disclaimer in the
- *documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS `AS IS'
- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
- * ARE DISCLAIMED.  IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
- * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
- * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
- * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
- * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
- * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
- * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
- * POSSIBILITY OF SUCH DAMAGE.
- */
-#ifndef __OPJ_MALLOC_H
-#define __OPJ_MALLOC_H
-/**
-...@file opj_malloc.h
-...@brief Internal functions
-
-The functions in opj_malloc.h are internal utilities used for memory 
management.
-*/
-
-/** @defgroup MISC MISC - Miscellaneous internal functions */
-/*...@{*/
-
-/** @name Exported functions */
-/*...@{*/
-/* --- */
-
-/**
-Allocate an uninitialized memory block
-...@param size Bytes to allocate
-...@return Returns a void pointer to the allocated space, or NULL if there is 
insufficient memory available
-*/
-#define opj_malloc(size) malloc(size)
-
-/**
-Allocate a memory block with elements initialized to 0
-...@param num Blocks to allocate
-...@param size Bytes per block to allocate
-...@return Returns a void pointer to the allocated space, or NULL if there is 
insufficient memory available
-*/
-#define opj_calloc(num, size) calloc(num, si

[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18909] branches/blender2.5/blender/source /blender/editors/space_file: 2.5

2009-02-10 Thread Ton Roosendaal
Revision: 18909
  
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=18909
Author:   ton
Date: 2009-02-10 18:53:10 +0100 (Tue, 10 Feb 2009)

Log Message:
---
2.5

File Window:

- Added PKEY parent directory
- Made "P" button work
- Removed confused theme colors for text, it caused
  selected text to print greyish.

Modified Paths:
--
branches/blender2.5/blender/source/blender/editors/space_file/file_draw.c
branches/blender2.5/blender/source/blender/editors/space_file/file_intern.h
branches/blender2.5/blender/source/blender/editors/space_file/file_ops.c
branches/blender2.5/blender/source/blender/editors/space_file/space_file.c

Modified: 
branches/blender2.5/blender/source/blender/editors/space_file/file_draw.c
===
--- branches/blender2.5/blender/source/blender/editors/space_file/file_draw.c   
2009-02-10 17:06:43 UTC (rev 18908)
+++ branches/blender2.5/blender/source/blender/editors/space_file/file_draw.c   
2009-02-10 17:53:10 UTC (rev 18909)
@@ -85,6 +85,7 @@
B_REDR  = 0,
B_FS_LOAD,
B_FS_CANCEL,
+   B_FS_PARENT,
 } eFile_ButEvents;
 
 static void do_file_buttons(bContext *C, void *arg, int event)
@@ -96,6 +97,9 @@
case B_FS_CANCEL:
file_cancel_exec(C, NULL); /* file_ops.c */
break;
+   case B_FS_PARENT:
+   file_parent_exec(C, NULL); /* file_ops.c */
+   break;
}
 }
 
@@ -168,7 +172,7 @@
 
MEM_freeN(menu);
 
-   uiDefBut(block, BUT, 0 /* XXX B_FS_PARDIR */, "P", xmin, filebuty2, 
parentbut_width, 21, 0, 0, 0, 0, 0, "Move to the parent directory (PKEY)"); 
+   uiDefBut(block, BUT, B_FS_PARENT, "P", xmin, filebuty2, 
parentbut_width, 21, 0, 0, 0, 0, 0, "Move to the parent directory (PKEY)"); 
uiEndBlock(C, block);
uiDrawBlock(C, block);
 }
@@ -502,27 +506,10 @@
glColor4f(1.0f, 1.0f, 1.0f, 1.0f);  
}
else {
-   if (S_ISDIR(file->type)) {
-   glColor4f(1.0f, 1.0f, 0.9f, 1.0f);
-   }
-   else if (file->flags & IMAGEFILE) {
-   UI_ThemeColor(TH_SEQ_IMAGE);
-   }
-   else if (file->flags & MOVIEFILE) {
-   UI_ThemeColor(TH_SEQ_MOVIE);
-   }
-   else if (file->flags & BLENDERFILE) {
-   UI_ThemeColor(TH_SEQ_SCENE);
-   }
-   else {
-   if (params->active_file == i) {
-   UI_ThemeColor(TH_GRID); /* grid used 
for active text */
-   } else if (file->flags & ACTIVE) {
-   UI_ThemeColor(TH_TEXT_HI);  

-   } else {
-   UI_ThemeColor(TH_TEXT);
-   }
-   }
+   if (S_ISDIR(file->type))
+   UI_ThemeColor4(TH_TEXT_HI); 
+   else
+   UI_ThemeColor4(TH_TEXT);
}

sw = UI_GetStringWidth(G.font, file->size, 0);

Modified: 
branches/blender2.5/blender/source/blender/editors/space_file/file_intern.h
===
--- branches/blender2.5/blender/source/blender/editors/space_file/file_intern.h 
2009-02-10 17:06:43 UTC (rev 18908)
+++ branches/blender2.5/blender/source/blender/editors/space_file/file_intern.h 
2009-02-10 17:53:10 UTC (rev 18909)
@@ -57,9 +57,11 @@
 void ED_FILE_OT_loadimages(struct wmOperatorType *ot);
 void ED_FILE_OT_load(struct wmOperatorType *ot);
 void ED_FILE_OT_cancel(struct wmOperatorType *ot);
+void ED_FILE_OT_parent(struct wmOperatorType *ot);
 
 int file_load_exec(bContext *C, struct wmOperator *unused);
 int file_cancel_exec(bContext *C, struct wmOperator *unused);
+int file_parent_exec(bContext *C, struct wmOperator *unused);
 int file_hilight_set(SpaceFile *sfile, ARegion *ar, int mx, int my);
 
 #endif /* ED_FILE_INTERN_H */

Modified: 
branches/blender2.5/blender/source/blender/editors/space_file/file_ops.c
===
--- branches/blender2.5/blender/source/blender/editors/space_file/file_ops.c
2009-02-10 17:06:43 UTC (rev 18908)
+++ branches/blender2.5/blender/source/blender/editors/space_file/file_ops.c
2009-02-10 17:53:10 UTC (rev 18909)
@@ -514,5 +514,32 @@
ot->poll= ED_operator_file_active; /* <- important, handler is on 
window level */
 }
 
+int file_parent_e

[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18910] branches/blender2.5/blender/source /blender/blenlib/BLI_rect.h: 2.5

2009-02-10 Thread Ton Roosendaal
Revision: 18910
  
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=18910
Author:   ton
Date: 2009-02-10 18:56:15 +0100 (Tue, 10 Feb 2009)

Log Message:
---
2.5

Third attempt to get the invisible character going!

Modified Paths:
--
branches/blender2.5/blender/source/blender/blenlib/BLI_rect.h

Modified: branches/blender2.5/blender/source/blender/blenlib/BLI_rect.h
===
--- branches/blender2.5/blender/source/blender/blenlib/BLI_rect.h   
2009-02-10 17:53:10 UTC (rev 18909)
+++ branches/blender2.5/blender/source/blender/blenlib/BLI_rect.h   
2009-02-10 17:56:15 UTC (rev 18910)
@@ -59,6 +59,7 @@
 void BLI_union_rctf(struct rctf *rcta, struct rctf *rctb);
 void BLI_union_rcti(struct rcti *rct1, struct rcti *rct2);
 
+
 #ifdef __cplusplus
 }
 #endif


___
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
http://lists.blender.org/mailman/listinfo/bf-blender-cvs


[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18911] branches/blender2.5/blender/source /gameengine/Converter/BL_ActionActuator.cpp: 2.5

2009-02-10 Thread Ton Roosendaal
Revision: 18911
  
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=18911
Author:   ton
Date: 2009-02-10 19:06:26 +0100 (Tue, 10 Feb 2009)

Log Message:
---
2.5

Made GE compile again

Modified Paths:
--

branches/blender2.5/blender/source/gameengine/Converter/BL_ActionActuator.cpp

Modified: 
branches/blender2.5/blender/source/gameengine/Converter/BL_ActionActuator.cpp
===
--- 
branches/blender2.5/blender/source/gameengine/Converter/BL_ActionActuator.cpp   
2009-02-10 17:56:15 UTC (rev 18910)
+++ 
branches/blender2.5/blender/source/gameengine/Converter/BL_ActionActuator.cpp   
2009-02-10 18:06:26 UTC (rev 18911)
@@ -371,7 +371,7 @@
obj->GetPose(&m_pose);

/* Override the necessary channels with ones from the 
action */
-   extract_pose_from_action(m_pose, m_action, m_localtime);
+   // XXX extract_pose_from_action(m_pose, m_action, 
m_localtime);
 
/* Perform the user override (if any) */
if (m_userpose){


___
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
http://lists.blender.org/mailman/listinfo/bf-blender-cvs


[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18912] branches/blender2.5/blender/source /blender/editors/space_view3d/view3d_buttons.c: 2.5

2009-02-10 Thread Ton Roosendaal
Revision: 18912
  
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=18912
Author:   ton
Date: 2009-02-10 19:33:32 +0100 (Tue, 10 Feb 2009)

Log Message:
---
2.5

snprintf should be BLI_snprintf

Modified Paths:
--

branches/blender2.5/blender/source/blender/editors/space_view3d/view3d_buttons.c

Modified: 
branches/blender2.5/blender/source/blender/editors/space_view3d/view3d_buttons.c
===
--- 
branches/blender2.5/blender/source/blender/editors/space_view3d/view3d_buttons.c
2009-02-10 18:06:26 UTC (rev 18911)
+++ 
branches/blender2.5/blender/source/blender/editors/space_view3d/view3d_buttons.c
2009-02-10 18:33:32 UTC (rev 18912)
@@ -187,7 +187,7 @@
for (i=0; itotweight; i++){
dg = BLI_findlink (&ob->defbase, 
dvert->dw[i].def_nr);
if(dg) {
-   max+= snprintf(str, sizeof(str), "%s 
%%x%d|", dg->name, dvert->dw[i].def_nr); 
+   max+= BLI_snprintf(str, sizeof(str), 
"%s %%x%d|", dg->name, dvert->dw[i].def_nr); 
if(max<320) strcat(defstr, str);
}
else printf("oh no!\n");


___
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
http://lists.blender.org/mailman/listinfo/bf-blender-cvs


[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18913] branches/blender2.5/blender/source /blender/blenlib/BLI_rect.h: 2.5

2009-02-10 Thread Ton Roosendaal
Revision: 18913
  
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=18913
Author:   ton
Date: 2009-02-10 19:36:34 +0100 (Tue, 10 Feb 2009)

Log Message:
---
2.5

Fourth trial to get the invisible character gone!
(I have to add/remove enters to get it committed even)

Thanks to Thomas for retyping the faulty line entirely :)

Modified Paths:
--
branches/blender2.5/blender/source/blender/blenlib/BLI_rect.h

Modified: branches/blender2.5/blender/source/blender/blenlib/BLI_rect.h
===
--- branches/blender2.5/blender/source/blender/blenlib/BLI_rect.h   
2009-02-10 18:33:32 UTC (rev 18912)
+++ branches/blender2.5/blender/source/blender/blenlib/BLI_rect.h   
2009-02-10 18:36:34 UTC (rev 18913)
@@ -59,7 +59,6 @@
 void BLI_union_rctf(struct rctf *rcta, struct rctf *rctb);
 void BLI_union_rcti(struct rcti *rct1, struct rcti *rct2);
 
-
 #ifdef __cplusplus
 }
 #endif


___
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
http://lists.blender.org/mailman/listinfo/bf-blender-cvs


[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18914] branches/blender2.5/blender/source /blender/blenlib/BLI_rect.h: 2.5

2009-02-10 Thread Ton Roosendaal
Revision: 18914
  
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=18914
Author:   ton
Date: 2009-02-10 19:50:40 +0100 (Tue, 10 Feb 2009)

Log Message:
---
2.5

Fifth attempt! Previous commit was wrong file :(

Modified Paths:
--
branches/blender2.5/blender/source/blender/blenlib/BLI_rect.h

Modified: branches/blender2.5/blender/source/blender/blenlib/BLI_rect.h
===
--- branches/blender2.5/blender/source/blender/blenlib/BLI_rect.h   
2009-02-10 18:36:34 UTC (rev 18913)
+++ branches/blender2.5/blender/source/blender/blenlib/BLI_rect.h   
2009-02-10 18:50:40 UTC (rev 18914)
@@ -57,8 +57,9 @@
 int  BLI_isect_rctf(struct rctf *src1, struct rctf *src2, struct rctf *dest);
 int  BLI_isect_rcti(struct rcti *src1, struct rcti *src2, struct rcti *dest);
 void BLI_union_rctf(struct rctf *rcta, struct rctf *rctb);
-void BLI_union_rcti(struct rcti *rct1, struct rcti *rct2);
+void BLI_union_rcti(struct rcti *rcti1, struct rcti *rcti2);
 
+
 #ifdef __cplusplus
 }
 #endif


___
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
http://lists.blender.org/mailman/listinfo/bf-blender-cvs


[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18915] branches/blender2.5/blender/source /blender/blenfont/intern: commit to continue in my home.

2009-02-10 Thread Diego Borghetti
Revision: 18915
  
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=18915
Author:   bdiego
Date: 2009-02-10 22:41:14 +0100 (Tue, 10 Feb 2009)

Log Message:
---
commit to continue in my home.

Also I remove some of the #if 0.

Modified Paths:
--
branches/blender2.5/blender/source/blender/blenfont/intern/blf_dir.c
branches/blender2.5/blender/source/blender/blenfont/intern/blf_font.c
branches/blender2.5/blender/source/blender/blenfont/intern/blf_glyph.c
branches/blender2.5/blender/source/blender/blenfont/intern/blf_internal.h

branches/blender2.5/blender/source/blender/blenfont/intern/blf_internal_types.h

Added Paths:
---
branches/blender2.5/blender/source/blender/blenfont/intern/blf_util.c

Modified: branches/blender2.5/blender/source/blender/blenfont/intern/blf_dir.c
===
--- branches/blender2.5/blender/source/blender/blenfont/intern/blf_dir.c
2009-02-10 18:50:40 UTC (rev 18914)
+++ branches/blender2.5/blender/source/blender/blenfont/intern/blf_dir.c
2009-02-10 21:41:14 UTC (rev 18915)
@@ -25,8 +25,6 @@
  * * END GPL LICENSE BLOCK *
  */
 
-#if 0
-
 #include 
 #include 
 #include 
@@ -167,5 +165,3 @@
}
return(0);
 }
-
-#endif /* zero!! */

Modified: branches/blender2.5/blender/source/blender/blenfont/intern/blf_font.c
===
--- branches/blender2.5/blender/source/blender/blenfont/intern/blf_font.c   
2009-02-10 18:50:40 UTC (rev 18914)
+++ branches/blender2.5/blender/source/blender/blenfont/intern/blf_font.c   
2009-02-10 21:41:14 UTC (rev 18915)
@@ -48,6 +48,7 @@
 #include "BLI_string.h"
 
 #include "blf_internal_types.h"
+#include "blf_internal.h"
 
 
 /* freetype2 handle. */

Modified: branches/blender2.5/blender/source/blender/blenfont/intern/blf_glyph.c
===
--- branches/blender2.5/blender/source/blender/blenfont/intern/blf_glyph.c  
2009-02-10 18:50:40 UTC (rev 18914)
+++ branches/blender2.5/blender/source/blender/blenfont/intern/blf_glyph.c  
2009-02-10 21:41:14 UTC (rev 18915)
@@ -48,22 +48,9 @@
 #include "BLI_string.h"
 
 #include "blf_internal_types.h"
+#include "blf_internal.h"
 
 
-unsigned int blf_glyph_hash(unsigned int val)
-{
-   unsigned int key;
-
-   key= val;
-   key += ~(key << 16);
-   key ^= (key >> 5);
-   key += (key << 3);
-   key ^= (key >> 13);
-   key += ~(key << 9);
-   key ^= (key >> 17);
-   return(key % 257);
-}
-
 GlyphCacheBLF *blf_glyph_cache_find(FontBLF *font, int size, int dpi)
 {
GlyphCacheBLF *p;
@@ -169,7 +156,7 @@
GlyphBLF *p;
unsigned int key;
 
-   key= blf_glyph_hash(idx);
+   key= blf_hash(idx);
p= gc->bucket[key].first;
while (p) {
if (p->index == idx)
@@ -260,9 +247,37 @@
g->uv[1][0]= ((float)(g->xoff + g->width)) / ((float)g->p2_width);
g->uv[1][1]= ((float)(g->yoff + g->height)) / ((float)g->p2_height);
 
-   key= blf_glyph_hash(g->index);
+   /* update the x offset for the next glyph. */
+   gc->x_offs += (int)(g->box.xmax - g->box.xmin + gc->pad);
+
+   key= blf_hash(g->index);
BLI_addhead(&gc->bucket[key], g);
return(g);
 }
 
+void blf_glyph_render(GlyphBLF *g, float x, float y)
+{
+   GLint cur_tex;
+   float dx;
+
+   glGetIntegerv(GL_TEXTURE_2D_BINDING_EXT, &cur_tex);
+   if (cur_tex != g->tex)
+   glBindTexture(GL_TEXTURE_2D, &g->tex);
+
+   dx= floor(x + g->pos_x);
+   glBegin(GL_QUADS);
+   glTexCoord2f(g->uv[0][0], g->uv[0][1]);
+   glVertex2f(dx, y + g->pos_y);
+
+   glTexCoord2f(g->uv[0][0], g->uv[1][1]);
+   glVertex2f(dx, y + g->pos_y - g->height);
+
+   glTexCoord2f(g->uv[1][0], g->uv[1][1]);
+   glVertex2f(dx + g->width, y + g->pos_y - g->height);
+
+   glTexCoord2f(g->uv[1][0], g->uv[0][1]);
+   glVertex2f(dx + g->width, y + g->pos_y);
+   glEnd();
+}
+
 #endif /* zero!! */

Modified: 
branches/blender2.5/blender/source/blender/blenfont/intern/blf_internal.h
===
--- branches/blender2.5/blender/source/blender/blenfont/intern/blf_internal.h   
2009-02-10 18:50:40 UTC (rev 18914)
+++ branches/blender2.5/blender/source/blender/blenfont/intern/blf_internal.h   
2009-02-10 21:41:14 UTC (rev 18915)
@@ -28,11 +28,11 @@
 #ifndef BLF_INTERNAL_H
 #define BLF_INTERNAL_H
 
-#if 0
+unsigned int blf_next_p2(unsigned int x);
+unsigned int blf_hash(unsigned int val);
+int blf_utf8_next(unsigned char *buf, int *iindex);
 
 char *blf_dir_search(const char *file);
 int blf_dir_split(const char *str, char *file, int *size);
 
-#endif /* zero! */
-
 #endif /* BLF_INTERNAL_H */

Modified: 
branches/blender2.5/blender/source/blender/blenfont/in

[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18916] branches/blender2.5/blender/source /blender: Setting svn-property 'eol-style' to 'native' for all animation-related files.

2009-02-10 Thread Joshua Leung
Revision: 18916
  
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=18916
Author:   aligorith
Date: 2009-02-10 23:45:20 +0100 (Tue, 10 Feb 2009)

Log Message:
---
Setting svn-property 'eol-style' to 'native' for all animation-related files. 
No more need to do save overs in text editors or with fancy UNIX tools.

Modified Paths:
--
branches/blender2.5/blender/source/blender/editors/object/object_edit.c

Property Changed:

branches/blender2.5/blender/source/blender/blenkernel/BKE_animsys.h
branches/blender2.5/blender/source/blender/blenkernel/BKE_fcurve.h
branches/blender2.5/blender/source/blender/blenkernel/intern/anim_sys.c
branches/blender2.5/blender/source/blender/blenkernel/intern/fcurve.c
branches/blender2.5/blender/source/blender/editors/animation/anim_channels.c
branches/blender2.5/blender/source/blender/editors/animation/anim_draw.c
branches/blender2.5/blender/source/blender/editors/animation/anim_filter.c

branches/blender2.5/blender/source/blender/editors/animation/anim_ipo_utils.c
branches/blender2.5/blender/source/blender/editors/animation/anim_ops.c

branches/blender2.5/blender/source/blender/editors/animation/keyframes_draw.c

branches/blender2.5/blender/source/blender/editors/animation/keyframes_edit.c

branches/blender2.5/blender/source/blender/editors/animation/keyframes_general.c
branches/blender2.5/blender/source/blender/editors/animation/keyframing.c
branches/blender2.5/blender/source/blender/editors/include/ED_anim_api.h
branches/blender2.5/blender/source/blender/editors/include/ED_armature.h

branches/blender2.5/blender/source/blender/editors/include/ED_keyframes_draw.h

branches/blender2.5/blender/source/blender/editors/include/ED_keyframes_edit.h
branches/blender2.5/blender/source/blender/editors/include/ED_keyframing.h
branches/blender2.5/blender/source/blender/editors/include/UI_view2d.h
branches/blender2.5/blender/source/blender/editors/interface/view2d.c
branches/blender2.5/blender/source/blender/editors/interface/view2d_ops.c

branches/blender2.5/blender/source/blender/editors/space_action/action_draw.c

branches/blender2.5/blender/source/blender/editors/space_action/action_edit.c

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/action_ops.c

branches/blender2.5/blender/source/blender/editors/space_action/action_select.c

branches/blender2.5/blender/source/blender/editors/space_action/space_action.c
branches/blender2.5/blender/source/blender/editors/space_graph/graph_draw.c
branches/blender2.5/blender/source/blender/editors/space_graph/graph_edit.c

branches/blender2.5/blender/source/blender/editors/space_graph/graph_header.c

branches/blender2.5/blender/source/blender/editors/space_graph/graph_intern.h
branches/blender2.5/blender/source/blender/editors/space_graph/graph_ops.c

branches/blender2.5/blender/source/blender/editors/space_graph/graph_select.c
branches/blender2.5/blender/source/blender/editors/space_graph/space_graph.c
branches/blender2.5/blender/source/blender/makesdna/DNA_anim_types.h


Property changes on: 
branches/blender2.5/blender/source/blender/blenkernel/BKE_animsys.h
___
Name: svn:eol-style
   + native


Property changes on: 
branches/blender2.5/blender/source/blender/blenkernel/BKE_fcurve.h
___
Name: svn:eol-style
   + native


Property changes on: 
branches/blender2.5/blender/source/blender/blenkernel/intern/anim_sys.c
___
Name: svn:eol-style
   + native


Property changes on: 
branches/blender2.5/blender/source/blender/blenkernel/intern/fcurve.c
___
Name: svn:eol-style
   + native


Property changes on: 
branches/blender2.5/blender/source/blender/editors/animation/anim_channels.c
___
Name: svn:eol-style
   + native


Property changes on: 
branches/blender2.5/blender/source/blender/editors/animation/anim_draw.c
___
Name: svn:eol-style
   + native


Property changes on: 
branches/blender2.5/blender/source/blender/editors/animation/anim_filter.c
___
Name: svn:eol-style
   + native


Property changes on: 
branches/blender2.5/blender/source/blender/editors/animation/anim_ipo_utils.c
___
Name: svn:eol-style
   + native


Property changes on: 
branches/b

[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18917] branches/blender2.5/blender/source /blender/editors: DopeSheet/Action Editor: Fixed display and expand-widget of 'Group' channels

2009-02-10 Thread Joshua Leung
Revision: 18917
  
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=18917
Author:   aligorith
Date: 2009-02-11 00:08:53 +0100 (Wed, 11 Feb 2009)

Log Message:
---
DopeSheet/Action Editor: Fixed display and expand-widget of 'Group' channels

Modified Paths:
--
branches/blender2.5/blender/source/blender/editors/animation/anim_channels.c

branches/blender2.5/blender/source/blender/editors/space_action/action_draw.c

Modified: 
branches/blender2.5/blender/source/blender/editors/animation/anim_channels.c
===
--- 
branches/blender2.5/blender/source/blender/editors/animation/anim_channels.c
2009-02-10 22:45:20 UTC (rev 18916)
+++ 
branches/blender2.5/blender/source/blender/editors/animation/anim_channels.c
2009-02-10 23:08:53 UTC (rev 18917)
@@ -1136,7 +1136,7 @@
case ANIMTYPE_GROUP: 
{
bActionGroup *agrp= (bActionGroup *)ale->data;
-   short offset= (ac->datatype == ANIMCONT_DOPESHEET)? 18 
: 0;
+   short offset= (ELEM3(ac->datatype, ANIMCONT_DOPESHEET, 
ANIMCONT_FCURVES, ANIMCONT_DRIVERS))? 18 : 0;

if ((x < (offset+17)) && (agrp->channels.first)) {
/* toggle expand */

Modified: 
branches/blender2.5/blender/source/blender/editors/space_action/action_draw.c
===
--- 
branches/blender2.5/blender/source/blender/editors/space_action/action_draw.c   
2009-02-10 22:45:20 UTC (rev 18916)
+++ 
branches/blender2.5/blender/source/blender/editors/space_action/action_draw.c   
2009-02-10 23:08:53 UTC (rev 18917)
@@ -594,7 +594,7 @@
indent= 0;
special= -1;

-   offset= (ale->id) ? 16 : 0;
+   offset= (ac->datatype == 
ANIMCONT_DOPESHEET) ? 16 : 0;

/* only show expand if there are any 
channels */
if (agrp->channels.first) {


___
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
http://lists.blender.org/mailman/listinfo/bf-blender-cvs


[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18918] branches/blender2.5/blender/source /blender: 2.5: Image window operators, quite a few of these still have

2009-02-10 Thread Brecht Van Lommel
Revision: 18918
  
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=18918
Author:   blendix
Date: 2009-02-11 00:17:58 +0100 (Wed, 11 Feb 2009)

Log Message:
---
2.5: Image window operators, quite a few of these still have
missing parts and are work in progress.

Set 3D Cursor
Set Tile
Sample Color
New
Open
Replace
Reload
Save (As)
Save Sequence
Pack
Unpack
Record Composite

The file select operators have context issues still. They need
to get the image space in the context on exec() but it's not
there currently, not sure how to solve that yet.

Also added name parameter to uiMenuItemEnumO, and fixed "mute"
argument in ED_update_for_newframe calls in fluidsim bake.

Modified Paths:
--
branches/blender2.5/blender/source/blender/editors/armature/editarmature.c
branches/blender2.5/blender/source/blender/editors/include/ED_image.h
branches/blender2.5/blender/source/blender/editors/include/UI_interface.h

branches/blender2.5/blender/source/blender/editors/interface/interface_regions.c
branches/blender2.5/blender/source/blender/editors/object/object_edit.c
branches/blender2.5/blender/source/blender/editors/physics/ed_fluidsim.c
branches/blender2.5/blender/source/blender/editors/space_image/image_draw.c

branches/blender2.5/blender/source/blender/editors/space_image/image_header.c

branches/blender2.5/blender/source/blender/editors/space_image/image_intern.h
branches/blender2.5/blender/source/blender/editors/space_image/image_ops.c
branches/blender2.5/blender/source/blender/editors/space_image/space_image.c

branches/blender2.5/blender/source/blender/editors/space_view3d/view3d_header.c

branches/blender2.5/blender/source/blender/editors/transform/transform_orientations.c
branches/blender2.5/blender/source/blender/editors/uvedit/uvedit_ops.c
branches/blender2.5/blender/source/blender/makesrna/intern/rna_space.c

Modified: 
branches/blender2.5/blender/source/blender/editors/armature/editarmature.c
===
--- branches/blender2.5/blender/source/blender/editors/armature/editarmature.c  
2009-02-10 23:08:53 UTC (rev 18917)
+++ branches/blender2.5/blender/source/blender/editors/armature/editarmature.c  
2009-02-10 23:17:58 UTC (rev 18918)
@@ -3429,11 +3429,11 @@
}
CTX_DATA_END;
 
-   uiMenuItemEnumO(head, 0, "ARMATURE_OT_set_parent", "type", 
ARM_PAR_CONNECT);
+   uiMenuItemEnumO(head, "", 0, "ARMATURE_OT_set_parent", "type", 
ARM_PAR_CONNECT);

/* ob becomes parent, make the associated menus */
if (allchildbones)
-   uiMenuItemEnumO(head, 0, "ARMATURE_OT_set_parent", "type", 
ARM_PAR_OFFSET); 
+   uiMenuItemEnumO(head, "", 0, "ARMATURE_OT_set_parent", "type", 
ARM_PAR_OFFSET); 

uiPupMenuEnd(C, head);


Modified: branches/blender2.5/blender/source/blender/editors/include/ED_image.h
===
--- branches/blender2.5/blender/source/blender/editors/include/ED_image.h   
2009-02-10 23:08:53 UTC (rev 18917)
+++ branches/blender2.5/blender/source/blender/editors/include/ED_image.h   
2009-02-10 23:17:58 UTC (rev 18918)
@@ -33,7 +33,7 @@
 
 /* space_image.c, exported for transform */
 struct Image *ED_space_image(struct SpaceImage *sima);
-void ED_space_image_set(struct SpaceImage *sima, struct Scene *scene, struct 
Object *obedit, struct Image *ima);
+void ED_space_image_set(struct bContext *C, struct SpaceImage *sima, struct 
Scene *scene, struct Object *obedit, struct Image *ima);
 
 struct ImBuf *ED_space_image_buffer(struct SpaceImage *sima);
 void ED_space_image_size(struct SpaceImage *sima, int *width, int *height);

Modified: 
branches/blender2.5/blender/source/blender/editors/include/UI_interface.h
===
--- branches/blender2.5/blender/source/blender/editors/include/UI_interface.h   
2009-02-10 23:08:53 UTC (rev 18917)
+++ branches/blender2.5/blender/source/blender/editors/include/UI_interface.h   
2009-02-10 23:17:58 UTC (rev 18918)
@@ -212,7 +212,7 @@
 
 void uiMenuItemVal(uiMenuItem *head, const char *name, int icon, int argval);
 
-void uiMenuItemEnumO(uiMenuItem *head, int icon, char *opname, char *propname, 
int value);
+void uiMenuItemEnumO(uiMenuItem *head, const char *name, int icon, char 
*opname, char *propname, int value);
 void uiMenuItemBooleanO(uiMenuItem *head, const char *name, int icon, char 
*opname, char *propname, int value);
 void uiMenuItemsEnumO(uiMenuItem *head, char *opname, char *propname);
 void uiMenuItemIntO(uiMenuItem *head, const char *name, int icon, char 
*opname, char *propname, int value);

Modified: 
branches/blender2.5/blender/source/blender/editors/interface/interface_regions.c
===
--- 
branches

[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18919] branches/blender2.5/blender/source /blender/editors: Names from uiMenuItemEnumO were not being used.

2009-02-10 Thread Campbell Barton
Revision: 18919
  
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=18919
Author:   campbellbarton
Date: 2009-02-11 03:09:41 +0100 (Wed, 11 Feb 2009)

Log Message:
---
Names from uiMenuItemEnumO were not being used.
Changed some of the sequencer menus to use uiMenuItem's

Modified Paths:
--

branches/blender2.5/blender/source/blender/editors/interface/interface_regions.c

branches/blender2.5/blender/source/blender/editors/space_action/action_header.c

branches/blender2.5/blender/source/blender/editors/space_sequencer/sequencer_header.c

Modified: 
branches/blender2.5/blender/source/blender/editors/interface/interface_regions.c
===
--- 
branches/blender2.5/blender/source/blender/editors/interface/interface_regions.c
2009-02-10 23:17:58 UTC (rev 18918)
+++ 
branches/blender2.5/blender/source/blender/editors/interface/interface_regions.c
2009-02-11 02:09:41 UTC (rev 18919)
@@ -1835,8 +1835,13 @@
else if(item->type==MENU_ITEM_OPNAME_ENUM) {
const char *name;
char bname[64];
-
-   name= ui_menu_enumpropname(item->opname, 
item->propname, item->enumval);
+   
+   /* If no name is given, use the enum name */
+   if (item->name[0] == '\0')
+   name= ui_menu_enumpropname(item->opname, 
item->propname, item->enumval);
+   else
+   name= item->name;
+   
BLI_strncpy(bname, name, sizeof(bname));

but= uiDefIconTextButO(block, BUTM, item->opname, 
item->opcontext, item->icon, bname, x1, y1, width+16, MENU_BUTTON_HEIGHT-1, "");

Modified: 
branches/blender2.5/blender/source/blender/editors/space_action/action_header.c
===
--- 
branches/blender2.5/blender/source/blender/editors/space_action/action_header.c 
2009-02-10 23:17:58 UTC (rev 18918)
+++ 
branches/blender2.5/blender/source/blender/editors/space_action/action_header.c 
2009-02-11 02:09:41 UTC (rev 18919)
@@ -42,6 +42,7 @@
 
 #include "BLI_blenlib.h"
 
+#include "BKE_animsys.h"
 #include "BKE_context.h"
 #include "BKE_screen.h"
 

Modified: 
branches/blender2.5/blender/source/blender/editors/space_sequencer/sequencer_header.c
===
--- 
branches/blender2.5/blender/source/blender/editors/space_sequencer/sequencer_header.c
   2009-02-10 23:17:58 UTC (rev 18918)
+++ 
branches/blender2.5/blender/source/blender/editors/space_sequencer/sequencer_header.c
   2009-02-11 02:09:41 UTC (rev 18919)
@@ -91,7 +91,6 @@
uiDefIconTextBut(block, BUTM, 1, ICON_MENU_PANEL,
 "Grease Pencil...", 0, yco-=20,
 menuwidth, 19, NULL, 0.0, 0.0, 1, 7, "");
-
uiDefMenuSep(block);
 
uiDefIconTextBut(block, BUTM, 1, ICON_BLANK1,
@@ -144,46 +143,23 @@
return block;
 }
 
-static uiBlock *seq_selectmenu(bContext *C, ARegion *ar, void *arg_unused)
+//static uiBlock *seq_selectmenu(bContext *C, ARegion *ar, void *arg_unused)
+static void seq_selectmenu(bContext *C, uiMenuItem *head, void *arg_unused)
 {
-   ScrArea *sa= CTX_wm_area(C);
+   uiMenuContext(head, WM_OP_INVOKE_DEFAULT);
 
-   uiBlock *block= uiBeginBlock(C, ar, "seq_selectmenu", UI_EMBOSSP, 
UI_HELV);
-   uiBut *but;
-
-   but= uiDefMenuButO(block, "SEQUENCER_OT_select_active_side", "Strips to 
the Left");
-   RNA_enum_set(uiButGetOperatorPtrRNA(but), "side", 'l');
-   but= uiDefMenuButO(block, "SEQUENCER_OT_select_active_side", "Strips to 
the Right");
-   RNA_enum_set(uiButGetOperatorPtrRNA(but), "side", 'r');
-   uiDefMenuSep(block);
-   but= uiDefMenuButO(block, "SEQUENCER_OT_select_handles", "Surrounding 
Handles");
-   RNA_enum_set(uiButGetOperatorPtrRNA(but), "side", SEQ_SIDE_BOTH);
-   but= uiDefMenuButO(block, "SEQUENCER_OT_select_handles", "Left 
Handles");
-   RNA_enum_set(uiButGetOperatorPtrRNA(but), "side", SEQ_SIDE_LEFT);
-   but= uiDefMenuButO(block, "SEQUENCER_OT_select_handles", "Right 
Handles");
-   RNA_enum_set(uiButGetOperatorPtrRNA(but), "side", SEQ_SIDE_RIGHT);
-   uiDefMenuSep(block);
-   uiDefMenuButO(block, "SEQUENCER_OT_borderselect", NULL);
-   uiDefMenuSep(block);
-   uiDefMenuButO(block, "SEQUENCER_OT_select_linked", NULL);
-   uiDefMenuButO(block, "SEQUENCER_OT_deselect_all", NULL);
-   uiDefMenuButO(block, "SEQUENCER_OT_select_invert", NULL);
-
-
-   if(sa->headertype==HEADERTOP) {
-   uiBlockSetDirection(block, UI_DOWN);
-   }
-   else {
-   uiBlockSetDirection(block, UI_T

[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [18920] branches/blender2.5/blender/source /blender/editors/armature: 2.5

2009-02-10 Thread Michael Fox
Revision: 18920
  
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=18920
Author:   mfoxdogg
Date: 2009-02-11 04:46:14 +0100 (Wed, 11 Feb 2009)

Log Message:
---
  2.5
**
-ported (de)select all for editarmature and pose mode
- please review my loops and notifiers as i think they are pretty ugly

Modified Paths:
--

branches/blender2.5/blender/source/blender/editors/armature/armature_intern.h
branches/blender2.5/blender/source/blender/editors/armature/armature_ops.c
branches/blender2.5/blender/source/blender/editors/armature/editarmature.c

Modified: 
branches/blender2.5/blender/source/blender/editors/armature/armature_intern.h
===
--- 
branches/blender2.5/blender/source/blender/editors/armature/armature_intern.h   
2009-02-11 02:09:41 UTC (rev 18919)
+++ 
branches/blender2.5/blender/source/blender/editors/armature/armature_intern.h   
2009-02-11 03:46:14 UTC (rev 18920)
@@ -41,12 +41,14 @@
 void ARMATURE_OT_subdivide_multi(struct wmOperatorType *ot);
 void ARMATURE_OT_parent_set(struct wmOperatorType *ot);
 void ARMATURE_OT_parent_clear(struct wmOperatorType *ot);
+void ARMATURE_OT_de_select_all(struct wmOperatorType *ot);
 
 void POSE_OT_hide(struct wmOperatorType *ot);
 void POSE_OT_reveil(struct wmOperatorType *ot);
 void POSE_OT_rot_clear(struct wmOperatorType *ot);
 void POSE_OT_loc_clear(struct wmOperatorType *ot);
 void POSE_OT_scale_clear(struct wmOperatorType *ot);
+void POSE_OT_de_select_all(struct wmOperatorType *ot);
 
 #endif /* ED_ARMATURE_INTERN_H */
 

Modified: 
branches/blender2.5/blender/source/blender/editors/armature/armature_ops.c
===
--- branches/blender2.5/blender/source/blender/editors/armature/armature_ops.c  
2009-02-11 02:09:41 UTC (rev 18919)
+++ branches/blender2.5/blender/source/blender/editors/armature/armature_ops.c  
2009-02-11 03:46:14 UTC (rev 18920)
@@ -107,6 +107,7 @@
 /* Both operators ARMATURE_OT_xxx and POSE_OT_xxx here */
 void ED_operatortypes_armature(void)
 {
+   /* EDIT ARMATURE */
WM_operatortype_append(ARMATURE_OT_align_bones);
WM_operatortype_append(ARMATURE_OT_calculate_roll);
WM_operatortype_append(ARMATURE_OT_switch_direction);
@@ -117,12 +118,18 @@
WM_operatortype_append(ARMATURE_OT_parent_set);
WM_operatortype_append(ARMATURE_OT_parent_clear);

+   WM_operatortype_append(ARMATURE_OT_de_select_all);
+   
+   /* POSE */
WM_operatortype_append(POSE_OT_hide);
WM_operatortype_append(POSE_OT_reveil);
+   
WM_operatortype_append(POSE_OT_rot_clear);
WM_operatortype_append(POSE_OT_loc_clear);
WM_operatortype_append(POSE_OT_scale_clear);

+   WM_operatortype_append(POSE_OT_de_select_all);
+   
WM_operatortype_append(ARMATURE_OT_test); // XXX temp test for context 
iterators... to be removed
 }
 
@@ -147,6 +154,8 @@
WM_keymap_add_item(keymap, "ARMATURE_OT_set_parent", PKEY, KM_PRESS, 
KM_CTRL, 0);
WM_keymap_add_item(keymap, "ARMATURE_OT_clear_parent", PKEY, KM_PRESS, 
KM_ALT, 0);

+   WM_keymap_add_item(keymap, "ARMATURE_OT_de_select_all", AKEY, KM_PRESS, 
0, 0);
+   
WM_keymap_add_item(keymap, "ARMATURE_OT_test", TKEY, KM_PRESS, 0, 0);  
// XXX temp test for context iterators... to be removed

/* Pose  */
@@ -161,5 +170,7 @@
WM_keymap_add_item(keymap, "POSE_OT_rot_clear", RKEY, KM_PRESS, KM_ALT, 
0);
WM_keymap_add_item(keymap, "POSE_OT_loc_clear", GKEY, KM_PRESS, KM_ALT, 
0);
WM_keymap_add_item(keymap, "POSE_OT_scale_clear", SKEY, KM_PRESS, 
KM_ALT, 0);
+   
+   WM_keymap_add_item(keymap, "POSE_OT_de_select_all", AKEY, KM_PRESS, 0, 
0);
 }
 

Modified: 
branches/blender2.5/blender/source/blender/editors/armature/editarmature.c
===
--- branches/blender2.5/blender/source/blender/editors/armature/editarmature.c  
2009-02-11 02:09:41 UTC (rev 18919)
+++ branches/blender2.5/blender/source/blender/editors/armature/editarmature.c  
2009-02-11 03:46:14 UTC (rev 18920)
@@ -3509,7 +3509,62 @@

RNA_def_enum(ot->srna, "type", prop_editarm_clear_parent_types, 0, 
"ClearType", "What way to clear parenting");
 }
+/* ** (de)select All ***/
 
+static int armature_de_select_all_exec(bContext *C, wmOperator *op)
+{
+   Object *obedit = CTX_data_edit_object(C);
+   bArmature *arm= obedit->data;
+   EditBone *ebone;
+   int sel=1;
+
+   /*  Determine if there are any selected bones
+   And therefore whether we are selecting or deselecting */
+   CTX_DATA_BEGIN(C, EditBone *, selbone, selected_editable_bones) {
+   if (selbone->flag & (BONE_SELECTED | BONE_TIPSEL | 
BONE_ROOTSEL)){
+