diff --git a/Kiwix-iOS/Controller/SearchTabController.swift b/Kiwix-iOS/Controller/SearchTabController.swift index 258d78cd..b8ab9a22 100644 --- a/Kiwix-iOS/Controller/SearchTabController.swift +++ b/Kiwix-iOS/Controller/SearchTabController.swift @@ -10,7 +10,7 @@ import UIKit class SearchTabController: UIViewController, UIScrollViewDelegate { - @IBOutlet weak var tabsContainer: UIView! + @IBOutlet weak var tabsContainer: TabsContainerView! @IBOutlet weak var scrollView: UIScrollView! private let indicatorView = UIView() @@ -37,11 +37,6 @@ class SearchTabController: UIViewController, UIScrollViewDelegate { tabsContainer.addSubview(indicatorView) indicatorView.backgroundColor = UIColor.themeColor - tabsContainer.layer.masksToBounds = false - tabsContainer.layer.shadowOffset = CGSizeMake(0, 0) - tabsContainer.layer.shadowOpacity = 0.5 - tabsContainer.layer.shadowRadius = 2.0 - buttons = [mainPageButton, historyButton, settingButton] mainPageButton.setImage(UIImage(named: "MainPage")?.imageWithRenderingMode(.AlwaysTemplate), forState: .Normal) mainPageButton.setImage(UIImage(named: "MainPage_filled")?.imageWithRenderingMode(.AlwaysTemplate), forState: .Selected) diff --git a/Kiwix-iOS/Info.plist b/Kiwix-iOS/Info.plist index 4679670c..7ebbe88a 100644 --- a/Kiwix-iOS/Info.plist +++ b/Kiwix-iOS/Info.plist @@ -36,7 +36,7 @@ CFBundleSignature ???? CFBundleVersion - 35 + 46 ITSAppUsesNonExemptEncryption LSRequiresIPhoneOS diff --git a/Kiwix-iOS/Storyboard/Main.storyboard b/Kiwix-iOS/Storyboard/Main.storyboard index 03827454..d04eb0ff 100644 --- a/Kiwix-iOS/Storyboard/Main.storyboard +++ b/Kiwix-iOS/Storyboard/Main.storyboard @@ -984,7 +984,7 @@ - + diff --git a/Kiwix-iOS/View/ShadowView.swift b/Kiwix-iOS/View/ShadowView.swift new file mode 100644 index 00000000..09b4fb29 --- /dev/null +++ b/Kiwix-iOS/View/ShadowView.swift @@ -0,0 +1,27 @@ +// +// ShadowView.swift +// Kiwix +// +// Created by Chris Li on 6/14/16. +// Copyright © 2016 Chris. All rights reserved. +// + +import UIKit + +class TabsContainerView: UIView { + + override func drawRect(rect: CGRect) { + layer.masksToBounds = false + + layer.shadowOffset = CGSizeMake(0, 0) + layer.shadowRadius = 4.0 + layer.shadowOpacity = 0.5 + layer.shadowRadius = 2.0 + } + + override func layoutSubviews() { + super.layoutSubviews() + layer.shadowPath = UIBezierPath(rect: bounds).CGPath + } + +} diff --git a/Kiwix.xcodeproj/project.pbxproj b/Kiwix.xcodeproj/project.pbxproj index 4bdd6abc..471b6e4f 100644 --- a/Kiwix.xcodeproj/project.pbxproj +++ b/Kiwix.xcodeproj/project.pbxproj @@ -270,6 +270,7 @@ 97E609F41D103DED00EBCB9D /* TodayViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 97E609F31D103DED00EBCB9D /* TodayViewController.swift */; }; 97E609F71D103DED00EBCB9D /* MainInterface.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97E609F51D103DED00EBCB9D /* MainInterface.storyboard */; }; 97E609FB1D103DED00EBCB9D /* Kiwix-iOSWidget.appex in Embed App Extensions */ = {isa = PBXBuildFile; fileRef = 97E609EF1D103DED00EBCB9D /* Kiwix-iOSWidget.appex */; settings = {ATTRIBUTES = (RemoveHeadersOnCopy, ); }; }; + 97E60A021D10423A00EBCB9D /* ShadowView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 97E60A011D10423A00EBCB9D /* ShadowView.swift */; }; 97E891691CA976E90001CA32 /* FileManager.swift in Sources */ = {isa = PBXBuildFile; fileRef = 97E891681CA976E90001CA32 /* FileManager.swift */; }; AEFF409D8D5B53BC90700424 /* Pods_Kiwix_OSX.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = DBAF14EE0505901A1570F23F /* Pods_Kiwix_OSX.framework */; }; BECDBCEF4720E3E86FE63989 /* Pods_Kiwix_iOS.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 6CEA715EBFC96C75E73447A7 /* Pods_Kiwix_iOS.framework */; }; @@ -304,13 +305,6 @@ remoteGlobalIDString = 97A2AB871C1B80FF00052E74; remoteInfo = Kiwix; }; - 97E609F91D103DED00EBCB9D /* PBXContainerItemProxy */ = { - isa = PBXContainerItemProxy; - containerPortal = 97A2AB801C1B80FF00052E74 /* Project object */; - proxyType = 1; - remoteGlobalIDString = 97E609EE1D103DED00EBCB9D; - remoteInfo = "Kiwix-iOSWidget"; - }; /* End PBXContainerItemProxy section */ /* Begin PBXCopyFilesBuildPhase section */ @@ -554,6 +548,7 @@ 97E609F31D103DED00EBCB9D /* TodayViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TodayViewController.swift; sourceTree = ""; }; 97E609F61D103DED00EBCB9D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/MainInterface.storyboard; sourceTree = ""; }; 97E609F81D103DED00EBCB9D /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + 97E60A011D10423A00EBCB9D /* ShadowView.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = ShadowView.swift; sourceTree = ""; }; 97E891681CA976E90001CA32 /* FileManager.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = FileManager.swift; path = Kiwix/FileManager.swift; sourceTree = ""; }; B14E5F8A97964014F99EAD4E /* Pods-Kiwix-iOS.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Kiwix-iOS.debug.xcconfig"; path = "Pods/Target Support Files/Pods-Kiwix-iOS/Pods-Kiwix-iOS.debug.xcconfig"; sourceTree = ""; }; B3B41D59F4B010C559B18D3D /* Pods-Kiwix-iOS.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Kiwix-iOS.release.xcconfig"; path = "Pods/Target Support Files/Pods-Kiwix-iOS/Pods-Kiwix-iOS.release.xcconfig"; sourceTree = ""; }; @@ -830,6 +825,7 @@ 971A10281D022AD5007FC62C /* LTBarButtonItem.swift */, 971A10291D022AD5007FC62C /* RefreshHUD.swift */, 971A102A1D022AD5007FC62C /* SearchBar.swift */, + 97E60A011D10423A00EBCB9D /* ShadowView.swift */, ); path = View; sourceTree = ""; @@ -1377,7 +1373,6 @@ buildRules = ( ); dependencies = ( - 97E609FA1D103DED00EBCB9D /* PBXTargetDependency */, ); name = "Kiwix-iOS"; productName = Kiwix; @@ -1848,6 +1843,7 @@ 979CB6591D05C44F005E1BA1 /* UserNotificationCapability.swift in Sources */, 97254FDF1C2644560056950B /* ZIMMultiReader.swift in Sources */, 971A105A1D022DAD007FC62C /* LibraryLocalTBVC.swift in Sources */, + 97E60A021D10423A00EBCB9D /* ShadowView.swift in Sources */, 979CB6BD1D05C520005E1BA1 /* Operation.swift in Sources */, 971A10441D022C54007FC62C /* SettingTBVCD.swift in Sources */, 971A10671D022E0A007FC62C /* MainVCOtherD.swift in Sources */, @@ -1975,11 +1971,6 @@ target = 97A2AB871C1B80FF00052E74 /* Kiwix-iOS */; targetProxy = 97A2ABAB1C1B810000052E74 /* PBXContainerItemProxy */; }; - 97E609FA1D103DED00EBCB9D /* PBXTargetDependency */ = { - isa = PBXTargetDependency; - target = 97E609EE1D103DED00EBCB9D /* Kiwix-iOSWidget */; - targetProxy = 97E609F91D103DED00EBCB9D /* PBXContainerItemProxy */; - }; /* End PBXTargetDependency section */ /* Begin PBXVariantGroup section */ @@ -2343,7 +2334,7 @@ INFOPLIST_FILE = "Kiwix-iOSWidget/Info.plist"; IPHONEOS_DEPLOYMENT_TARGET = 9.0; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @executable_path/../../Frameworks"; - PRODUCT_BUNDLE_IDENTIFIER = org.kiwix.iOSWidget; + PRODUCT_BUNDLE_IDENTIFIER = self.Kiwix.iOSWidget; PRODUCT_NAME = "$(TARGET_NAME)"; SKIP_INSTALL = YES; }; @@ -2358,7 +2349,7 @@ INFOPLIST_FILE = "Kiwix-iOSWidget/Info.plist"; IPHONEOS_DEPLOYMENT_TARGET = 9.0; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @executable_path/../../Frameworks"; - PRODUCT_BUNDLE_IDENTIFIER = org.kiwix.iOSWidget; + PRODUCT_BUNDLE_IDENTIFIER = self.Kiwix.iOSWidget; PRODUCT_NAME = "$(TARGET_NAME)"; SKIP_INSTALL = YES; }; diff --git a/README.md b/README.md index 2467b43c..1bf62f13 100644 --- a/README.md +++ b/README.md @@ -6,6 +6,7 @@ Kiwix for iOS is an offline reader for wikipedia. Our mission is to give people ## What's to come in version 1.6 - Table of contents - Some iPad search interface design changes +- Spotlight search integration (will index opened / read articles) ### Stuff may be added in 1.6 - Library enhancement