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>2013-06-25 02:41:33 +0400
committerBrecht Van Lommel <brechtvanlommel@pandora.be>2013-06-25 02:41:33 +0400
commit02fbfa5c70732e691606546ecce60fdfe3f80d9f (patch)
tree9c5e5be02ae4b87b52642d77f264ce1f76d48e41 /source/blender/editors/space_buttons
parent8390aa5181d3dd9c8458fa68c2add910c1cd12e9 (diff)
Fix unnecessary 3D viewport redraws in various cases, in particular when editing
node materials. Area and region listener callbacks now get the screen and area pointers passed, so they can do more fine grained checks to see if redraw is really needed, for example depending on the 3D view drawtype.
Diffstat (limited to 'source/blender/editors/space_buttons')
-rw-r--r--source/blender/editors/space_buttons/space_buttons.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/source/blender/editors/space_buttons/space_buttons.c b/source/blender/editors/space_buttons/space_buttons.c
index e6c6df416bf..b01f653837c 100644
--- a/source/blender/editors/space_buttons/space_buttons.c
+++ b/source/blender/editors/space_buttons/space_buttons.c
@@ -225,7 +225,7 @@ static void buttons_area_redraw(ScrArea *sa, short buttons)
}
/* reused! */
-static void buttons_area_listener(ScrArea *sa, wmNotifier *wmn)
+static void buttons_area_listener(bScreen *UNUSED(sc), ScrArea *sa, wmNotifier *wmn)
{
SpaceButs *sbuts = sa->spacedata.first;
@@ -295,6 +295,7 @@ static void buttons_area_listener(ScrArea *sa, wmNotifier *wmn)
case ND_SHADING:
case ND_SHADING_DRAW:
case ND_SHADING_LINKS:
+ case ND_SHADING_PREVIEW:
/* currently works by redraws... if preview is set, it (re)starts job */
sbuts->preview = 1;
break;
@@ -318,6 +319,7 @@ static void buttons_area_listener(ScrArea *sa, wmNotifier *wmn)
case ND_SHADING:
case ND_SHADING_DRAW:
case ND_SHADING_LINKS:
+ case ND_SHADING_PREVIEW:
case ND_NODES:
/* currently works by redraws... if preview is set, it (re)starts job */
sbuts->preview = 1;