Disable drawing animations when energy saving

This commit is contained in:
Ilya Laktyushin
2023-03-02 16:37:56 +04:00
parent 1ab3cff8fa
commit c341b1c449
3 changed files with 22 additions and 8 deletions

View File

@@ -1994,6 +1994,7 @@ public class DrawingScreen: ViewController, TGPhotoDrawingInterfaceController, U
var drawingView: DrawingView {
if self._drawingView == nil, let controller = self.controller {
self._drawingView = DrawingView(size: controller.size)
self._drawingView?.animationsEnabled = self.context.sharedContext.energyUsageSettings.fullTranslucency
self._drawingView?.shouldBegin = { [weak self] _ in
if let strongSelf = self {
if strongSelf._entitiesView?.hasSelection == true {