Changeset View
Changeset View
Standalone View
Standalone View
source/blender/windowmanager/intern/wm_draw.c
| Show First 20 Lines • Show All 92 Lines • ▼ Show 20 Lines | |||||
| } | } | ||||
| screen->do_draw = false; | screen->do_draw = false; | ||||
| } | } | ||||
| /****************** main update call **********************/ | /****************** main update call **********************/ | ||||
| /* quick test to prevent changing window drawable */ | /* quick test to prevent changing window drawable */ | ||||
| static bool wm_draw_update_test_window(Main *bmain, wmWindow *win) | static bool wm_draw_update_test_window(wmWindow *win) | ||||
| { | { | ||||
| Scene *scene = WM_window_get_active_scene(win); | Scene *scene = WM_window_get_active_scene(win); | ||||
| ViewLayer *view_layer = WM_window_get_active_view_layer(win); | ViewLayer *view_layer = WM_window_get_active_view_layer(win); | ||||
| struct Depsgraph *depsgraph = BKE_scene_get_depsgraph(bmain, scene, view_layer, true); | struct Depsgraph *depsgraph = BKE_scene_get_depsgraph(scene, view_layer, true); | ||||
| bScreen *screen = WM_window_get_active_screen(win); | bScreen *screen = WM_window_get_active_screen(win); | ||||
| ARegion *ar; | ARegion *ar; | ||||
| bool do_draw = false; | bool do_draw = false; | ||||
| for (ar = screen->regionbase.first; ar; ar = ar->next) { | for (ar = screen->regionbase.first; ar; ar = ar->next) { | ||||
| if (ar->do_draw_overlay) { | if (ar->do_draw_overlay) { | ||||
| screen->do_draw_paintcursor = true; | screen->do_draw_paintcursor = true; | ||||
| ar->do_draw_overlay = false; | ar->do_draw_overlay = false; | ||||
| ▲ Show 20 Lines • Show All 84 Lines • ▼ Show 20 Lines | |||||
| /* do not update minimized windows, gives issues on Intel (see T33223) | /* do not update minimized windows, gives issues on Intel (see T33223) | ||||
| * and AMD (see T50856). it seems logical to skip update for invisible | * and AMD (see T50856). it seems logical to skip update for invisible | ||||
| * window anyway. | * window anyway. | ||||
| */ | */ | ||||
| continue; | continue; | ||||
| } | } | ||||
| #endif | #endif | ||||
| if (wm_draw_update_test_window(bmain, win)) { | if (wm_draw_update_test_window(win)) { | ||||
| bScreen *screen = WM_window_get_active_screen(win); | bScreen *screen = WM_window_get_active_screen(win); | ||||
| CTX_wm_window_set(C, win); | CTX_wm_window_set(C, win); | ||||
| /* sets context window+screen */ | /* sets context window+screen */ | ||||
| wm_window_make_drawable(wm, win); | wm_window_make_drawable(wm, win); | ||||
| /* notifiers for screen redraw */ | /* notifiers for screen redraw */ | ||||
| ▲ Show 20 Lines • Show All 75 Lines • Show Last 20 Lines | |||||