Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrecht Van Lommel <brechtvanlommel@pandora.be>2010-01-20 18:44:37 +0300
committerBrecht Van Lommel <brechtvanlommel@pandora.be>2010-01-20 18:44:37 +0300
commit0c3e5dec93759f3d557e6c1746e80c2cf5b74f06 (patch)
treedd3755b70c3f213a172232726526fc74b0985e77 /source/blender/editors/space_action/space_action.c
parent939c3ba9cbd0557b93de443e06b7e970984b288a (diff)
Fix action editor now updating when changing the active object. I can't work
out of this was an intentional change or not, but working with two objects became quite tedious because action would have to be changed manually each time. Also fixed missing redraw of header.
Diffstat (limited to 'source/blender/editors/space_action/space_action.c')
-rw-r--r--source/blender/editors/space_action/space_action.c19
1 files changed, 19 insertions, 0 deletions
diff --git a/source/blender/editors/space_action/space_action.c b/source/blender/editors/space_action/space_action.c
index 57a39b3225e..66e6e770ca4 100644
--- a/source/blender/editors/space_action/space_action.c
+++ b/source/blender/editors/space_action/space_action.c
@@ -398,6 +398,24 @@ static void action_listener(ScrArea *sa, wmNotifier *wmn)
}
}
+static void action_header_area_listener(ARegion *ar, wmNotifier *wmn)
+{
+ /* context changes */
+ switch(wmn->category) {
+ case NC_SCENE:
+ switch(wmn->data) {
+ case ND_OB_ACTIVE:
+ ED_region_tag_redraw(ar);
+ break;
+ }
+ break;
+ case NC_ID:
+ if(wmn->action == NA_RENAME)
+ ED_region_tag_redraw(ar);
+ break;
+ }
+}
+
static void action_refresh(const bContext *C, ScrArea *sa)
{
SpaceAction *saction= CTX_wm_space_action(C);
@@ -450,6 +468,7 @@ void ED_spacetype_action(void)
art->init= action_header_area_init;
art->draw= action_header_area_draw;
+ art->listener= action_header_area_listener;
BLI_addhead(&st->regiontypes, art);