From 09b6ff19726c453c0ee3fc04785501b0fbb53471 Mon Sep 17 00:00:00 2001 From: Arnold Tang Date: Tue, 15 May 2018 13:54:47 +0800 Subject: [PATCH] Do not perform present animation if sender view is not set --- Classes/IDMPhotoBrowser.m | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Classes/IDMPhotoBrowser.m b/Classes/IDMPhotoBrowser.m index 9cd39f32..f3d0643b 100644 --- a/Classes/IDMPhotoBrowser.m +++ b/Classes/IDMPhotoBrowser.m @@ -613,7 +613,9 @@ - (void)viewDidLoad { [self.view addSubview:_pagingScrollView]; // Transition animation - [self performPresentAnimation]; + if (_senderViewForAnimation) { + [self performPresentAnimation]; + } UIInterfaceOrientation currentOrientation = [UIApplication sharedApplication].statusBarOrientation;