Chromium Code Reviews| Index: ash/rotator/screen_rotation_animator.cc |
| diff --git a/ash/rotator/screen_rotation_animator.cc b/ash/rotator/screen_rotation_animator.cc |
| index 31a54537dd859ca1f3d8535baabb1442e81af0d6..9858e7eb3d12b6683115d14deaf11ba462dbf696 100644 |
| --- a/ash/rotator/screen_rotation_animator.cc |
| +++ b/ash/rotator/screen_rotation_animator.cc |
| @@ -225,6 +225,11 @@ void ScreenRotationAnimator::SetRotation( |
| display::Display::Rotation old_rotation, |
| display::Display::Rotation new_rotation, |
| display::Display::RotationSource source) { |
| + // Allow compositor locks to extend timeout, so that screen rotation only |
| + // takes output copy after contents are properlly resized, such as wallpaper |
| + // and ARC apps. |
| + ui::Compositor* compositor = root_window_->layer()->GetCompositor(); |
| + compositor->set_allow_locks_to_extend_timeout(true); |
| Shell::Get()->display_manager()->SetDisplayRotation(display_id_, new_rotation, |
| source); |
| const display::Display display = |
| @@ -232,6 +237,7 @@ void ScreenRotationAnimator::SetRotation( |
| old_layer_tree_owner_->root()->SetTransform( |
| CreateScreenRotationOldLayerTransformForDisplay(old_rotation, |
| new_rotation, display)); |
| + compositor->set_allow_locks_to_extend_timeout(false); |
|
oshima
2017/05/10 05:27:50
move this to 235, after SetDisplayRotation
wutao
2017/05/10 21:07:55
Done.
|
| } |
| void ScreenRotationAnimator::RequestCopyScreenRotationContainerLayer( |