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:
authorJoshua Leung <aligorith@gmail.com>2009-07-08 10:32:52 +0400
committerJoshua Leung <aligorith@gmail.com>2009-07-08 10:32:52 +0400
commit665938191df7e831ba22f101b00ab9b99bdde654 (patch)
tree48fb32daaa2ac868d3fb4c259b0fe3cb5869d2af
parentbe5293d3ad38ba5f9f32ac8585d012bc44a9e684 (diff)
NLA SoC: Minor UI-Tweaks
* When influence/time for NLA-strips are animated, settings in the other panels which used to control these are now greyed out to show that they won't have any impact over the result. * NKey panel for Graph Editor now opens on Right-Hand Side, just like for NLA Editor. The small sub-region above the Channels region was too troublesome to work with.
-rw-r--r--source/blender/editors/space_graph/space_graph.c16
-rw-r--r--source/blender/editors/space_nla/nla_buttons.c12
2 files changed, 16 insertions, 12 deletions
diff --git a/source/blender/editors/space_graph/space_graph.c b/source/blender/editors/space_graph/space_graph.c
index b17861dc679..2f3700bc733 100644
--- a/source/blender/editors/space_graph/space_graph.c
+++ b/source/blender/editors/space_graph/space_graph.c
@@ -72,19 +72,19 @@ ARegion *graph_has_buttons_region(ScrArea *sa)
if(ar->regiontype==RGN_TYPE_UI)
return ar;
- /* add subdiv level; after channel */
+ /* add subdiv level; after main window */
for(ar= sa->regionbase.first; ar; ar= ar->next)
- if(ar->regiontype==RGN_TYPE_CHANNELS)
+ if(ar->regiontype==RGN_TYPE_WINDOW)
break;
/* is error! */
if(ar==NULL) return NULL;
- arnew= MEM_callocN(sizeof(ARegion), "buttons for view3d");
+ arnew= MEM_callocN(sizeof(ARegion), "buttons for nla");
BLI_insertlinkafter(&sa->regionbase, ar, arnew);
arnew->regiontype= RGN_TYPE_UI;
- arnew->alignment= RGN_ALIGN_BOTTOM|RGN_SPLIT_PREV;
+ arnew->alignment= RGN_ALIGN_RIGHT;
arnew->flag = RGN_FLAG_HIDDEN;
@@ -117,7 +117,7 @@ static SpaceLink *graph_new(const bContext *C)
ar->alignment= RGN_ALIGN_BOTTOM;
/* channels */
- ar= MEM_callocN(sizeof(ARegion), "main area for graphedit");
+ ar= MEM_callocN(sizeof(ARegion), "channels area for graphedit");
BLI_addtail(&sipo->regionbase, ar);
ar->regiontype= RGN_TYPE_CHANNELS;
@@ -126,11 +126,11 @@ static SpaceLink *graph_new(const bContext *C)
ar->v2d.scroll = (V2D_SCROLL_RIGHT|V2D_SCROLL_BOTTOM);
/* ui buttons */
- ar= MEM_callocN(sizeof(ARegion), "main area for graphedit");
+ ar= MEM_callocN(sizeof(ARegion), "buttons area for graphedit");
BLI_addtail(&sipo->regionbase, ar);
ar->regiontype= RGN_TYPE_UI;
- ar->alignment= RGN_ALIGN_TOP|RGN_SPLIT_PREV;
+ ar->alignment= RGN_ALIGN_RIGHT;
ar->flag = RGN_FLAG_HIDDEN;
/* main area */
@@ -566,7 +566,7 @@ void ED_spacetype_ipo(void)
/* regions: UI buttons */
art= MEM_callocN(sizeof(ARegionType), "spacetype graphedit region");
art->regionid = RGN_TYPE_UI;
- art->minsizey= 200;
+ art->minsizex= 200;
art->keymapflag= ED_KEYMAP_UI;
art->listener= graph_region_listener;
art->init= graph_buttons_area_init;
diff --git a/source/blender/editors/space_nla/nla_buttons.c b/source/blender/editors/space_nla/nla_buttons.c
index d09cc6a1e53..c0a2b9476e3 100644
--- a/source/blender/editors/space_nla/nla_buttons.c
+++ b/source/blender/editors/space_nla/nla_buttons.c
@@ -236,14 +236,17 @@ static void nla_panel_properties(const bContext *C, Panel *pa)
* - blend in/out can only be set when autoblending is off
*/
column= uiLayoutColumn(layout, 1);
+ uiLayoutSetActive(column, RNA_boolean_get(&strip_ptr, "animated_influence")==0);
uiItemR(column, NULL, 0, &strip_ptr, "auto_blending", 0, 0, 0); // XXX as toggle?
- subcol= uiLayoutColumn(column, 1);
- uiLayoutSetActive(subcol, RNA_boolean_get(&strip_ptr, "auto_blending")==0);
- uiItemR(subcol, NULL, 0, &strip_ptr, "blend_in", 0, 0, 0);
- uiItemR(subcol, NULL, 0, &strip_ptr, "blend_out", 0, 0, 0);
+
+ subcol= uiLayoutColumn(column, 1);
+ uiLayoutSetActive(subcol, RNA_boolean_get(&strip_ptr, "auto_blending")==0);
+ uiItemR(subcol, NULL, 0, &strip_ptr, "blend_in", 0, 0, 0);
+ uiItemR(subcol, NULL, 0, &strip_ptr, "blend_out", 0, 0, 0);
/* settings */
column= uiLayoutColumn(layout, 1);
+ uiLayoutSetActive(column, !(RNA_boolean_get(&strip_ptr, "animated_influence") || RNA_boolean_get(&strip_ptr, "animated_time")));
uiItemL(column, "Playback Settings:", 0);
uiItemR(column, NULL, 0, &strip_ptr, "muted", 0, 0, 0);
uiItemR(column, NULL, 0, &strip_ptr, "reversed", 0, 0, 0);
@@ -279,6 +282,7 @@ static void nla_panel_actclip(const bContext *C, Panel *pa)
/* action usage */
column= uiLayoutColumn(layout, 1);
+ uiLayoutSetActive(column, RNA_boolean_get(&strip_ptr, "animated_time")==0);
uiItemL(column, "Playback Settings:", 0);
uiItemR(column, NULL, 0, &strip_ptr, "scale", 0, 0, 0);
uiItemR(column, NULL, 0, &strip_ptr, "repeat", 0, 0, 0);