Browse Source

New Interface offline

Marino Faggiana 8 years ago
parent
commit
8b63503d71

+ 1 - 3
iOSClient/AppDelegate.m

@@ -164,13 +164,11 @@
     // ico Image Cache
     self.icoImagesCache = [[NSMutableDictionary alloc] init];
     
-    // Page Control
-    /*
+    //
     UIPageControl *pageControl = [UIPageControl appearance];
     pageControl.pageIndicatorTintColor = COLOR_SEPARATOR_TABLE;
     pageControl.currentPageIndicatorTintColor = COLOR_NEXTCLOUD;
     pageControl.backgroundColor = [UIColor clearColor];
-    */
     
     // remove tmp & cache
     dispatch_async(dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_DEFAULT, 0), ^{

+ 23 - 0
iOSClient/Images.xcassets/Icon-Back.imageset/Contents.json

@@ -0,0 +1,23 @@
+{
+  "images" : [
+    {
+      "idiom" : "universal",
+      "filename" : "Icon-Back.png",
+      "scale" : "1x"
+    },
+    {
+      "idiom" : "universal",
+      "filename" : "Icon-Back@2x.png",
+      "scale" : "2x"
+    },
+    {
+      "idiom" : "universal",
+      "filename" : "Icon-Back@3x.png",
+      "scale" : "3x"
+    }
+  ],
+  "info" : {
+    "version" : 1,
+    "author" : "xcode"
+  }
+}

BIN
iOSClient/Images.xcassets/Icon-Back.imageset/Icon-Back.png


BIN
iOSClient/Images.xcassets/Icon-Back.imageset/Icon-Back@2x.png


BIN
iOSClient/Images.xcassets/Icon-Back.imageset/Icon-Back@3x.png


+ 3 - 3
iOSClient/Main/Main.storyboard

@@ -252,7 +252,7 @@
                 <navigationController automaticallyAdjustsScrollViewInsets="NO" id="eZl-ut-xpC" sceneMemberID="viewController">
                     <extendedEdge key="edgesForExtendedLayout"/>
                     <toolbarItems/>
-                    <navigationBar key="navigationBar" contentMode="scaleToFill" misplaced="YES" id="rJe-3o-bpZ">
+                    <navigationBar key="navigationBar" contentMode="scaleToFill" id="rJe-3o-bpZ">
                         <rect key="frame" x="0.0" y="0.0" width="320" height="44"/>
                         <autoresizingMask key="autoresizingMask"/>
                     </navigationBar>
@@ -449,7 +449,7 @@
                 <navigationController storyboardIdentifier="CCMainNC" extendedLayoutIncludesOpaqueBars="YES" automaticallyAdjustsScrollViewInsets="NO" id="bSZ-tE-FEj" customClass="CCControlCenter" sceneMemberID="viewController">
                     <tabBarItem key="tabBarItem" title="File" image="tabBarCryptoCloud" id="Zxv-aS-HGF"/>
                     <toolbarItems/>
-                    <navigationBar key="navigationBar" contentMode="scaleToFill" misplaced="YES" id="cj6-rT-wnB">
+                    <navigationBar key="navigationBar" contentMode="scaleToFill" id="cj6-rT-wnB">
                         <rect key="frame" x="0.0" y="0.0" width="320" height="44"/>
                         <autoresizingMask key="autoresizingMask"/>
                     </navigationBar>
@@ -539,7 +539,7 @@
                 <navigationController extendedLayoutIncludesOpaqueBars="YES" automaticallyAdjustsScrollViewInsets="NO" id="Npr-vu-PSD" sceneMemberID="viewController">
                     <tabBarItem key="tabBarItem" title="Photos" image="tabBarPhotos" id="5cw-bP-7It"/>
                     <toolbarItems/>
-                    <navigationBar key="navigationBar" contentMode="scaleToFill" misplaced="YES" id="ixg-Pw-TNO">
+                    <navigationBar key="navigationBar" contentMode="scaleToFill" id="ixg-Pw-TNO">
                         <rect key="frame" x="0.0" y="0.0" width="320" height="44"/>
                         <autoresizingMask key="autoresizingMask"/>
                     </navigationBar>

+ 0 - 6
iOSClient/Offline/CCOffline.m

@@ -71,9 +71,7 @@
     self.pageViewController.dataSource = self;
     self.pageViewController.delegate = self;
     
-    // Add the first PageContent
     CCOfflinePageContent *startingViewController = [self viewControllerAtIndex:0];
-    
     NSArray *viewControllers = @[startingViewController];
     [self.pageViewController setViewControllers:viewControllers direction:UIPageViewControllerNavigationDirectionForward animated:NO completion:nil];
 
@@ -117,7 +115,6 @@
     return pageContentViewController;
 }
 
-
 - (UIViewController *)pageViewController:(UIPageViewController *)pageViewController viewControllerBeforeViewController:(UIViewController *)viewController
 {
     NSUInteger index = ((CCOfflinePageContent*) viewController).pageIndex;
@@ -145,18 +142,15 @@
     return [self viewControllerAtIndex:index];
 }
 
-/*
 - (NSInteger)presentationCountForPageViewController:(UIPageViewController *)pageViewController
 {
     return [self.pageType count];
 }
 
-
 - (NSInteger)presentationIndexForPageViewController:(UIPageViewController *)pageViewController
 {
     return 0;
 }
-*/
 
 /*
 - (void)pageViewController:(UIPageViewController *)pageViewController willTransitionToViewControllers:(NSArray<UIViewController *> *)pendingViewControllers

+ 1 - 0
iOSClient/Offline/CCOfflinePageContent.h

@@ -30,6 +30,7 @@
 
 @property NSUInteger pageIndex;
 @property (nonatomic, strong) NSString *pageType;
+
 @property (nonatomic, weak) IBOutlet UITableView *tableView;
 
 @property (nonatomic, strong) CCMetadata *metadata;

+ 3 - 0
iOSClient/Offline/CCOfflinePageContent.m

@@ -44,6 +44,9 @@
     if ([self.pageType isEqualToString:pageOfflineLocal] && !_localServerUrl) {
         _localServerUrl = [CCUtility getDirectoryLocal];
     }
+    
+    // Title
+    self.title = [_localServerUrl lastPathComponent];
 }
 
 // Apparirà