Fix T39323: Animation playback is not synchronized when Screen Layout changes.

Own regression in rBd2a5ea04ed84.

This commit should be included if we do a 2.70 'a' release.
This commit is contained in:
Bastien Montagne 2014-03-21 15:15:24 +01:00
parent daccaa713b
commit 54a8753df3
Notes: blender-bot 2023-02-14 10:56:46 +01:00
Referenced by issue #39323, Animation playback is interrupted when you toggle an editor window full screen.
1 changed files with 12 additions and 9 deletions

View File

@ -1514,19 +1514,22 @@ void ED_screen_set(bContext *C, bScreen *sc)
/* we put timer to sleep, so screen_exit has to think there's no timer */
oldscreen->animtimer = NULL;
if (wt)
if (wt) {
WM_event_timer_sleep(wm, win, wt, true);
}
ED_screen_exit(C, win, oldscreen);
/* Same scene, "transfer" playback to new screen. */
if (oldscene == sc->scene) {
sc->animtimer = wt;
}
/* Else, stop playback. */
else {
oldscreen->animtimer = wt;
ED_screen_animation_play(C, 0, 0);
if (wt) {
if (oldscene == sc->scene) {
sc->animtimer = wt;
}
/* Else, stop playback. */
else {
oldscreen->animtimer = wt;
ED_screen_animation_play(C, 0, 0);
}
}
win->screen = sc;