Răsfoiți Sursa

new view image

marinofaggiana 4 ani în urmă
părinte
comite
57eb811c30

+ 25 - 4
iOSClient/Viewer/NCViewerImage/NCViewerImagePageContainer.swift

@@ -1,4 +1,25 @@
-
+//
+//  NCViewerImagePageContainer.swift
+//  Nextcloud
+//
+//  Created by Marino Faggiana on 24/10/2020.
+//  Copyright © 2020 Marino Faggiana. All rights reserved.
+//
+//  Author Marino Faggiana <marino.faggiana@nextcloud.com>
+//
+//  This program is free software: you can redistribute it and/or modify
+//  it under the terms of the GNU General Public License as published by
+//  the Free Software Foundation, either version 3 of the License, or
+//  (at your option) any later version.
+//
+//  This program is distributed in the hope that it will be useful,
+//  but WITHOUT ANY WARRANTY; without even the implied warranty of
+//  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+//  GNU General Public License for more details.
+//
+//  You should have received a copy of the GNU General Public License
+//  along with this program.  If not, see <http://www.gnu.org/licenses/>.
+//
 
 import UIKit
 
@@ -33,12 +54,12 @@ class NCViewerImagePageContainer: UIViewController, UIGestureRecognizerDelegate
     override func viewDidLoad() {
         super.viewDidLoad()
         
+        singleTapGestureRecognizer = UITapGestureRecognizer(target: self, action: #selector(didSingleTapWith(gestureRecognizer:)))
+        panGestureRecognizer = UIPanGestureRecognizer(target: self, action: #selector(didPanWith(gestureRecognizer:)))
+
         pageViewController.delegate = self
         pageViewController.dataSource = self
-        panGestureRecognizer = UIPanGestureRecognizer(target: self, action: #selector(didPanWith(gestureRecognizer:)))
-        panGestureRecognizer.delegate = self
         pageViewController.view.addGestureRecognizer(self.panGestureRecognizer)
-        singleTapGestureRecognizer = UITapGestureRecognizer(target: self, action: #selector(didSingleTapWith(gestureRecognizer:)))
         pageViewController.view.addGestureRecognizer(self.singleTapGestureRecognizer)
         
         let viewerImageZoom = UIStoryboard(name: "NCViewerImage", bundle: nil).instantiateViewController(withIdentifier: "NCViewerImageZoom") as! NCViewerImageZoom

+ 22 - 1
iOSClient/Viewer/NCViewerImage/NCViewerImageZoom.swift

@@ -1,4 +1,25 @@
-
+//
+//  NCViewerImageZoom.swift
+//  Nextcloud
+//
+//  Created by Marino Faggiana on 24/10/2020.
+//  Copyright © 2020 Marino Faggiana. All rights reserved.
+//
+//  Author Marino Faggiana <marino.faggiana@nextcloud.com>
+//
+//  This program is free software: you can redistribute it and/or modify
+//  it under the terms of the GNU General Public License as published by
+//  the Free Software Foundation, either version 3 of the License, or
+//  (at your option) any later version.
+//
+//  This program is distributed in the hope that it will be useful,
+//  but WITHOUT ANY WARRANTY; without even the implied warranty of
+//  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+//  GNU General Public License for more details.
+//
+//  You should have received a copy of the GNU General Public License
+//  along with this program.  If not, see <http://www.gnu.org/licenses/>.
+//
 import UIKit
 
 class NCViewerImageZoom: UIViewController {