├── .gitignore ├── .swift-version ├── ACBRadialCollectionView.podspec ├── ACBRadialCollectionView.xcodeproj ├── project.pbxproj ├── project.xcworkspace │ ├── contents.xcworkspacedata │ └── xcshareddata │ │ └── IDEWorkspaceChecks.plist └── xcshareddata │ └── xcschemes │ ├── ACBRadialCollectionView.xcscheme │ └── ACBRadialCollectionViewFramework.xcscheme ├── ACBRadialCollectionView ├── Assets.xcassets │ ├── AppIcon.appiconset │ │ ├── Contents.json │ │ ├── Icon-App-20x20@1x.png │ │ ├── Icon-App-20x20@2x.png │ │ ├── Icon-App-20x20@3x.png │ │ ├── Icon-App-29x29@1x.png │ │ ├── Icon-App-29x29@2x.png │ │ ├── Icon-App-29x29@3x.png │ │ ├── Icon-App-40x40@1x.png │ │ ├── Icon-App-40x40@2x.png │ │ ├── Icon-App-40x40@3x.png │ │ ├── Icon-App-57x57@1x.png │ │ ├── Icon-App-57x57@2x.png │ │ ├── Icon-App-60x60@2x.png │ │ ├── Icon-App-60x60@3x.png │ │ ├── Icon-App-76x76@1x.png │ │ ├── Icon-App-76x76@2x.png │ │ ├── Icon-App-83.5x83.5@2x.png │ │ └── ItunesArtwork@2x.png │ ├── Contents.json │ ├── Icon-60.imageset │ │ ├── Contents.json │ │ └── Icon-60.png │ ├── Icon-72.imageset │ │ ├── Contents.json │ │ ├── Icon-72.png │ │ └── Icon-72@2x.png │ ├── Icon-Small-50.imageset │ │ ├── Contents.json │ │ ├── Icon-Small-50.png │ │ └── Icon-Small-50@2x.png │ ├── Icon.imageset │ │ ├── Contents.json │ │ ├── Icon.png │ │ └── Icon@2x.png │ └── ItunesArtwork.imageset │ │ ├── Contents.json │ │ ├── ItunesArtwork.png │ │ └── ItunesArtwork@2x.png ├── Base.lproj │ ├── LaunchScreen.storyboard │ └── Main.storyboard ├── Classes │ ├── General │ │ └── AppDelegate.swift │ ├── Source │ │ ├── Extensions │ │ │ ├── UICollectionView+ACBRadialCollectionView.swift │ │ │ └── UIScrollView+ACBRadialScrollBar.swift │ │ ├── Helper │ │ │ └── ACBRadialCollectionViewLayout.swift │ │ └── Views │ │ │ ├── ACBInternalRadialScrollBar.swift │ │ │ └── ACBRadialScrollBar.swift │ ├── Viewcontrollers │ │ └── ACBViewController.swift │ └── Views │ │ └── ACBCollectionViewCell.swift ├── Info.plist └── Screenshots │ ├── ACBRadialCVgif1.gif │ ├── ACBRadialCVgif2.gif │ ├── ACBRadialCVgif3.gif │ ├── ACBRadialCollectionViewFirst.png │ ├── ACBRadialCollectionViewSecond.png │ └── ACBRadialCollectionViewThird.png ├── ACBRadialCollectionViewFramework ├── ACBRadialCollectionViewFramework.h └── Info.plist ├── ACBRadialCollectionViewFrameworkTests ├── ACBRadialCollectionViewFrameworkTests.m └── Info.plist ├── LICENSE └── README.md /.gitignore: -------------------------------------------------------------------------------- 1 | # Xcode 2 | 3 | ## Build generated 4 | build/ 5 | DerivedData/ 6 | 7 | ## Various settings 8 | *.pbxuser 9 | !default.pbxuser 10 | *.mode1v3 11 | !default.mode1v3 12 | *.mode2v3 13 | !default.mode2v3 14 | *.perspectivev3 15 | !default.perspectivev3 16 | xcuserdata/ 17 | 18 | ## Other 19 | *.moved-aside 20 | *.xccheckout 21 | *.xcscmblueprint 22 | 23 | ## Obj-C/Swift specific 24 | *.hmap 25 | *.ipa 26 | *.dSYM.zip 27 | *.dSYM 28 | 29 | ## CocoaPods 30 | Pods/ 31 | 32 | ## Carthage 33 | Carthage/Checkouts 34 | Carthage/Build -------------------------------------------------------------------------------- /.swift-version: -------------------------------------------------------------------------------- 1 | 3.2 2 | -------------------------------------------------------------------------------- /ACBRadialCollectionView.podspec: -------------------------------------------------------------------------------- 1 | Pod::Spec.new do |s| 2 | s.name = "ACBRadialCollectionView" 3 | s.version = "2.0" 4 | s.summary = "An extension on UICollectionView which automatically transforms collection view cells to a radial path." 5 | s.description = <<-DESC 6 | This is an extension on UICollectionView which automatically transforms collection view cells to a radial path with minimal code. This is written in Swift language. No need to subclass UICollectionView for this. CollectionView will also display an arc shaped scroll bar next to the cells which acts similar to the normal scroll bar. 7 | DESC 8 | s.homepage = "https://github.com/akhilcb/ACBRadialCollectionView" 9 | s.license = "MIT" 10 | s.author = "Akhil" 11 | s.platform = :ios, '10.0' 12 | s.source = { :git => "https://github.com/akhilcb/ACBRadialCollectionView.git", :tag => "2.0" } 13 | s.source_files = "ACBRadialCollectionView", "ACBRadialCollectionView/Classes/Source/**/*.{swift}" 14 | end 15 | -------------------------------------------------------------------------------- /ACBRadialCollectionView.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 54; 7 | objects = { 8 | 9 | /* Begin PBXBuildFile section */ 10 | E930116720035D9B00E454A6 /* ACBRadialCollectionView.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = E930115E20035D9B00E454A6 /* ACBRadialCollectionView.framework */; }; 11 | E930116E20035D9B00E454A6 /* ACBRadialCollectionViewFrameworkTests.m in Sources */ = {isa = PBXBuildFile; fileRef = E930116D20035D9B00E454A6 /* ACBRadialCollectionViewFrameworkTests.m */; }; 12 | E930117020035D9B00E454A6 /* ACBRadialCollectionViewFramework.h in Headers */ = {isa = PBXBuildFile; fileRef = E930116020035D9B00E454A6 /* ACBRadialCollectionViewFramework.h */; settings = {ATTRIBUTES = (Public, ); }; }; 13 | E930117320035D9B00E454A6 /* ACBRadialCollectionView.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = E930115E20035D9B00E454A6 /* ACBRadialCollectionView.framework */; }; 14 | E930117520035D9B00E454A6 /* ACBRadialCollectionView.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = E930115E20035D9B00E454A6 /* ACBRadialCollectionView.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; 15 | E93011912003661B00E454A6 /* ACBRadialCollectionViewLayout.swift in Sources */ = {isa = PBXBuildFile; fileRef = E930118A2003661B00E454A6 /* ACBRadialCollectionViewLayout.swift */; }; 16 | E93011922003661B00E454A6 /* ACBRadialScrollBar.swift in Sources */ = {isa = PBXBuildFile; fileRef = E930118C2003661B00E454A6 /* ACBRadialScrollBar.swift */; }; 17 | E93011932003661B00E454A6 /* ACBInternalRadialScrollBar.swift in Sources */ = {isa = PBXBuildFile; fileRef = E930118D2003661B00E454A6 /* ACBInternalRadialScrollBar.swift */; }; 18 | E93011942003661B00E454A6 /* UICollectionView+ACBRadialCollectionView.swift in Sources */ = {isa = PBXBuildFile; fileRef = E930118F2003661B00E454A6 /* UICollectionView+ACBRadialCollectionView.swift */; }; 19 | E93011952003661B00E454A6 /* UIScrollView+ACBRadialScrollBar.swift in Sources */ = {isa = PBXBuildFile; fileRef = E93011902003661B00E454A6 /* UIScrollView+ACBRadialScrollBar.swift */; }; 20 | E93011962003662700E454A6 /* UICollectionView+ACBRadialCollectionView.swift in Sources */ = {isa = PBXBuildFile; fileRef = E930118F2003661B00E454A6 /* UICollectionView+ACBRadialCollectionView.swift */; }; 21 | E93011972003662A00E454A6 /* UIScrollView+ACBRadialScrollBar.swift in Sources */ = {isa = PBXBuildFile; fileRef = E93011902003661B00E454A6 /* UIScrollView+ACBRadialScrollBar.swift */; }; 22 | E93011982003662C00E454A6 /* ACBRadialCollectionViewLayout.swift in Sources */ = {isa = PBXBuildFile; fileRef = E930118A2003661B00E454A6 /* ACBRadialCollectionViewLayout.swift */; }; 23 | E93011992003662E00E454A6 /* ACBRadialScrollBar.swift in Sources */ = {isa = PBXBuildFile; fileRef = E930118C2003661B00E454A6 /* ACBRadialScrollBar.swift */; }; 24 | E930119A2003663100E454A6 /* ACBInternalRadialScrollBar.swift in Sources */ = {isa = PBXBuildFile; fileRef = E930118D2003661B00E454A6 /* ACBInternalRadialScrollBar.swift */; }; 25 | E930119B2003665700E454A6 /* UICollectionView+ACBRadialCollectionView.swift in Headers */ = {isa = PBXBuildFile; fileRef = E930118F2003661B00E454A6 /* UICollectionView+ACBRadialCollectionView.swift */; settings = {ATTRIBUTES = (Public, ); }; }; 26 | E930119C2003665700E454A6 /* UIScrollView+ACBRadialScrollBar.swift in Headers */ = {isa = PBXBuildFile; fileRef = E93011902003661B00E454A6 /* UIScrollView+ACBRadialScrollBar.swift */; settings = {ATTRIBUTES = (Public, ); }; }; 27 | E9551FD81ED290B700DCA7C1 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = E9551FD61ED290B700DCA7C1 /* Main.storyboard */; }; 28 | E9551FDA1ED290B700DCA7C1 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = E9551FD91ED290B700DCA7C1 /* Assets.xcassets */; }; 29 | E9551FDD1ED290B700DCA7C1 /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = E9551FDB1ED290B700DCA7C1 /* LaunchScreen.storyboard */; }; 30 | E9551FF51ED2A0AF00DCA7C1 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = E9551FE91ED2A0AF00DCA7C1 /* AppDelegate.swift */; }; 31 | E9551FF71ED2A0AF00DCA7C1 /* ACBViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = E9551FED1ED2A0AF00DCA7C1 /* ACBViewController.swift */; }; 32 | E9551FF81ED2A0AF00DCA7C1 /* ACBCollectionViewCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = E9551FEF1ED2A0AF00DCA7C1 /* ACBCollectionViewCell.swift */; }; 33 | /* End PBXBuildFile section */ 34 | 35 | /* Begin PBXContainerItemProxy section */ 36 | E930116820035D9B00E454A6 /* PBXContainerItemProxy */ = { 37 | isa = PBXContainerItemProxy; 38 | containerPortal = E9551FC71ED290B700DCA7C1 /* Project object */; 39 | proxyType = 1; 40 | remoteGlobalIDString = E930115D20035D9B00E454A6; 41 | remoteInfo = ACBRadialCollectionViewFramework; 42 | }; 43 | E930116A20035D9B00E454A6 /* PBXContainerItemProxy */ = { 44 | isa = PBXContainerItemProxy; 45 | containerPortal = E9551FC71ED290B700DCA7C1 /* Project object */; 46 | proxyType = 1; 47 | remoteGlobalIDString = E9551FCE1ED290B700DCA7C1; 48 | remoteInfo = ACBRadialCollectionView; 49 | }; 50 | E930117120035D9B00E454A6 /* PBXContainerItemProxy */ = { 51 | isa = PBXContainerItemProxy; 52 | containerPortal = E9551FC71ED290B700DCA7C1 /* Project object */; 53 | proxyType = 1; 54 | remoteGlobalIDString = E930115D20035D9B00E454A6; 55 | remoteInfo = ACBRadialCollectionViewFramework; 56 | }; 57 | /* End PBXContainerItemProxy section */ 58 | 59 | /* Begin PBXCopyFilesBuildPhase section */ 60 | E930117420035D9B00E454A6 /* Embed Frameworks */ = { 61 | isa = PBXCopyFilesBuildPhase; 62 | buildActionMask = 2147483647; 63 | dstPath = ""; 64 | dstSubfolderSpec = 10; 65 | files = ( 66 | E930117520035D9B00E454A6 /* ACBRadialCollectionView.framework in Embed Frameworks */, 67 | ); 68 | name = "Embed Frameworks"; 69 | runOnlyForDeploymentPostprocessing = 0; 70 | }; 71 | /* End PBXCopyFilesBuildPhase section */ 72 | 73 | /* Begin PBXFileReference section */ 74 | E930115E20035D9B00E454A6 /* ACBRadialCollectionView.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = ACBRadialCollectionView.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 75 | E930116020035D9B00E454A6 /* ACBRadialCollectionViewFramework.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = ACBRadialCollectionViewFramework.h; sourceTree = ""; }; 76 | E930116120035D9B00E454A6 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 77 | E930116620035D9B00E454A6 /* ACBRadialCollectionViewFrameworkTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = ACBRadialCollectionViewFrameworkTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; 78 | E930116D20035D9B00E454A6 /* ACBRadialCollectionViewFrameworkTests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = ACBRadialCollectionViewFrameworkTests.m; sourceTree = ""; }; 79 | E930116F20035D9B00E454A6 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 80 | E930118A2003661B00E454A6 /* ACBRadialCollectionViewLayout.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = ACBRadialCollectionViewLayout.swift; sourceTree = ""; }; 81 | E930118C2003661B00E454A6 /* ACBRadialScrollBar.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = ACBRadialScrollBar.swift; sourceTree = ""; }; 82 | E930118D2003661B00E454A6 /* ACBInternalRadialScrollBar.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = ACBInternalRadialScrollBar.swift; sourceTree = ""; }; 83 | E930118F2003661B00E454A6 /* UICollectionView+ACBRadialCollectionView.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = "UICollectionView+ACBRadialCollectionView.swift"; sourceTree = ""; }; 84 | E93011902003661B00E454A6 /* UIScrollView+ACBRadialScrollBar.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = "UIScrollView+ACBRadialScrollBar.swift"; sourceTree = ""; }; 85 | E9551FCF1ED290B700DCA7C1 /* ACBRadialCollectionView.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = ACBRadialCollectionView.app; sourceTree = BUILT_PRODUCTS_DIR; }; 86 | E9551FD71ED290B700DCA7C1 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; 87 | E9551FD91ED290B700DCA7C1 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; 88 | E9551FDC1ED290B700DCA7C1 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; 89 | E9551FDE1ED290B700DCA7C1 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 90 | E9551FE91ED2A0AF00DCA7C1 /* AppDelegate.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; 91 | E9551FED1ED2A0AF00DCA7C1 /* ACBViewController.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = ACBViewController.swift; sourceTree = ""; }; 92 | E9551FEF1ED2A0AF00DCA7C1 /* ACBCollectionViewCell.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = ACBCollectionViewCell.swift; sourceTree = ""; }; 93 | /* End PBXFileReference section */ 94 | 95 | /* Begin PBXFrameworksBuildPhase section */ 96 | E930115A20035D9B00E454A6 /* Frameworks */ = { 97 | isa = PBXFrameworksBuildPhase; 98 | buildActionMask = 2147483647; 99 | files = ( 100 | ); 101 | runOnlyForDeploymentPostprocessing = 0; 102 | }; 103 | E930116320035D9B00E454A6 /* Frameworks */ = { 104 | isa = PBXFrameworksBuildPhase; 105 | buildActionMask = 2147483647; 106 | files = ( 107 | E930116720035D9B00E454A6 /* ACBRadialCollectionView.framework in Frameworks */, 108 | ); 109 | runOnlyForDeploymentPostprocessing = 0; 110 | }; 111 | E9551FCC1ED290B700DCA7C1 /* Frameworks */ = { 112 | isa = PBXFrameworksBuildPhase; 113 | buildActionMask = 2147483647; 114 | files = ( 115 | E930117320035D9B00E454A6 /* ACBRadialCollectionView.framework in Frameworks */, 116 | ); 117 | runOnlyForDeploymentPostprocessing = 0; 118 | }; 119 | /* End PBXFrameworksBuildPhase section */ 120 | 121 | /* Begin PBXGroup section */ 122 | E930115F20035D9B00E454A6 /* ACBRadialCollectionViewFramework */ = { 123 | isa = PBXGroup; 124 | children = ( 125 | E930116020035D9B00E454A6 /* ACBRadialCollectionViewFramework.h */, 126 | E930116120035D9B00E454A6 /* Info.plist */, 127 | ); 128 | path = ACBRadialCollectionViewFramework; 129 | sourceTree = ""; 130 | }; 131 | E930116C20035D9B00E454A6 /* ACBRadialCollectionViewFrameworkTests */ = { 132 | isa = PBXGroup; 133 | children = ( 134 | E930116D20035D9B00E454A6 /* ACBRadialCollectionViewFrameworkTests.m */, 135 | E930116F20035D9B00E454A6 /* Info.plist */, 136 | ); 137 | path = ACBRadialCollectionViewFrameworkTests; 138 | sourceTree = ""; 139 | }; 140 | E9301188200365E000E454A6 /* Source */ = { 141 | isa = PBXGroup; 142 | children = ( 143 | E930118E2003661B00E454A6 /* Extensions */, 144 | E93011892003661B00E454A6 /* Helper */, 145 | E930118B2003661B00E454A6 /* Views */, 146 | ); 147 | path = Source; 148 | sourceTree = ""; 149 | }; 150 | E93011892003661B00E454A6 /* Helper */ = { 151 | isa = PBXGroup; 152 | children = ( 153 | E930118A2003661B00E454A6 /* ACBRadialCollectionViewLayout.swift */, 154 | ); 155 | path = Helper; 156 | sourceTree = ""; 157 | }; 158 | E930118B2003661B00E454A6 /* Views */ = { 159 | isa = PBXGroup; 160 | children = ( 161 | E930118C2003661B00E454A6 /* ACBRadialScrollBar.swift */, 162 | E930118D2003661B00E454A6 /* ACBInternalRadialScrollBar.swift */, 163 | ); 164 | path = Views; 165 | sourceTree = ""; 166 | }; 167 | E930118E2003661B00E454A6 /* Extensions */ = { 168 | isa = PBXGroup; 169 | children = ( 170 | E930118F2003661B00E454A6 /* UICollectionView+ACBRadialCollectionView.swift */, 171 | E93011902003661B00E454A6 /* UIScrollView+ACBRadialScrollBar.swift */, 172 | ); 173 | path = Extensions; 174 | sourceTree = ""; 175 | }; 176 | E9551FC61ED290B700DCA7C1 = { 177 | isa = PBXGroup; 178 | children = ( 179 | E9551FD11ED290B700DCA7C1 /* ACBRadialCollectionView */, 180 | E930115F20035D9B00E454A6 /* ACBRadialCollectionViewFramework */, 181 | E930116C20035D9B00E454A6 /* ACBRadialCollectionViewFrameworkTests */, 182 | E9551FD01ED290B700DCA7C1 /* Products */, 183 | ); 184 | sourceTree = ""; 185 | }; 186 | E9551FD01ED290B700DCA7C1 /* Products */ = { 187 | isa = PBXGroup; 188 | children = ( 189 | E9551FCF1ED290B700DCA7C1 /* ACBRadialCollectionView.app */, 190 | E930115E20035D9B00E454A6 /* ACBRadialCollectionView.framework */, 191 | E930116620035D9B00E454A6 /* ACBRadialCollectionViewFrameworkTests.xctest */, 192 | ); 193 | name = Products; 194 | sourceTree = ""; 195 | }; 196 | E9551FD11ED290B700DCA7C1 /* ACBRadialCollectionView */ = { 197 | isa = PBXGroup; 198 | children = ( 199 | E9551FE41ED2A0AF00DCA7C1 /* Classes */, 200 | E9551FFC1ED2A0C400DCA7C1 /* Resources */, 201 | ); 202 | path = ACBRadialCollectionView; 203 | sourceTree = ""; 204 | }; 205 | E9551FE41ED2A0AF00DCA7C1 /* Classes */ = { 206 | isa = PBXGroup; 207 | children = ( 208 | E9301188200365E000E454A6 /* Source */, 209 | E9551FE81ED2A0AF00DCA7C1 /* General */, 210 | E9551FEC1ED2A0AF00DCA7C1 /* Viewcontrollers */, 211 | E9551FEE1ED2A0AF00DCA7C1 /* Views */, 212 | ); 213 | path = Classes; 214 | sourceTree = ""; 215 | }; 216 | E9551FE81ED2A0AF00DCA7C1 /* General */ = { 217 | isa = PBXGroup; 218 | children = ( 219 | E9551FE91ED2A0AF00DCA7C1 /* AppDelegate.swift */, 220 | ); 221 | path = General; 222 | sourceTree = ""; 223 | }; 224 | E9551FEC1ED2A0AF00DCA7C1 /* Viewcontrollers */ = { 225 | isa = PBXGroup; 226 | children = ( 227 | E9551FED1ED2A0AF00DCA7C1 /* ACBViewController.swift */, 228 | ); 229 | path = Viewcontrollers; 230 | sourceTree = ""; 231 | }; 232 | E9551FEE1ED2A0AF00DCA7C1 /* Views */ = { 233 | isa = PBXGroup; 234 | children = ( 235 | E9551FEF1ED2A0AF00DCA7C1 /* ACBCollectionViewCell.swift */, 236 | ); 237 | path = Views; 238 | sourceTree = ""; 239 | }; 240 | E9551FFC1ED2A0C400DCA7C1 /* Resources */ = { 241 | isa = PBXGroup; 242 | children = ( 243 | E9551FD61ED290B700DCA7C1 /* Main.storyboard */, 244 | E9551FD91ED290B700DCA7C1 /* Assets.xcassets */, 245 | E9551FDB1ED290B700DCA7C1 /* LaunchScreen.storyboard */, 246 | E9551FDE1ED290B700DCA7C1 /* Info.plist */, 247 | ); 248 | name = Resources; 249 | sourceTree = ""; 250 | }; 251 | /* End PBXGroup section */ 252 | 253 | /* Begin PBXHeadersBuildPhase section */ 254 | E930115B20035D9B00E454A6 /* Headers */ = { 255 | isa = PBXHeadersBuildPhase; 256 | buildActionMask = 2147483647; 257 | files = ( 258 | E930117020035D9B00E454A6 /* ACBRadialCollectionViewFramework.h in Headers */, 259 | E930119B2003665700E454A6 /* UICollectionView+ACBRadialCollectionView.swift in Headers */, 260 | E930119C2003665700E454A6 /* UIScrollView+ACBRadialScrollBar.swift in Headers */, 261 | ); 262 | runOnlyForDeploymentPostprocessing = 0; 263 | }; 264 | /* End PBXHeadersBuildPhase section */ 265 | 266 | /* Begin PBXNativeTarget section */ 267 | E930115D20035D9B00E454A6 /* ACBRadialCollectionViewFramework */ = { 268 | isa = PBXNativeTarget; 269 | buildConfigurationList = E930117620035D9B00E454A6 /* Build configuration list for PBXNativeTarget "ACBRadialCollectionViewFramework" */; 270 | buildPhases = ( 271 | E930115920035D9B00E454A6 /* Sources */, 272 | E930115A20035D9B00E454A6 /* Frameworks */, 273 | E930115B20035D9B00E454A6 /* Headers */, 274 | E930115C20035D9B00E454A6 /* Resources */, 275 | ); 276 | buildRules = ( 277 | ); 278 | dependencies = ( 279 | ); 280 | name = ACBRadialCollectionViewFramework; 281 | productName = ACBRadialCollectionViewFramework; 282 | productReference = E930115E20035D9B00E454A6 /* ACBRadialCollectionView.framework */; 283 | productType = "com.apple.product-type.framework"; 284 | }; 285 | E930116520035D9B00E454A6 /* ACBRadialCollectionViewFrameworkTests */ = { 286 | isa = PBXNativeTarget; 287 | buildConfigurationList = E930117920035D9B00E454A6 /* Build configuration list for PBXNativeTarget "ACBRadialCollectionViewFrameworkTests" */; 288 | buildPhases = ( 289 | E930116220035D9B00E454A6 /* Sources */, 290 | E930116320035D9B00E454A6 /* Frameworks */, 291 | E930116420035D9B00E454A6 /* Resources */, 292 | ); 293 | buildRules = ( 294 | ); 295 | dependencies = ( 296 | E930116920035D9B00E454A6 /* PBXTargetDependency */, 297 | E930116B20035D9B00E454A6 /* PBXTargetDependency */, 298 | ); 299 | name = ACBRadialCollectionViewFrameworkTests; 300 | productName = ACBRadialCollectionViewFrameworkTests; 301 | productReference = E930116620035D9B00E454A6 /* ACBRadialCollectionViewFrameworkTests.xctest */; 302 | productType = "com.apple.product-type.bundle.unit-test"; 303 | }; 304 | E9551FCE1ED290B700DCA7C1 /* ACBRadialCollectionView */ = { 305 | isa = PBXNativeTarget; 306 | buildConfigurationList = E9551FE11ED290B700DCA7C1 /* Build configuration list for PBXNativeTarget "ACBRadialCollectionView" */; 307 | buildPhases = ( 308 | E9551FCB1ED290B700DCA7C1 /* Sources */, 309 | E9551FCC1ED290B700DCA7C1 /* Frameworks */, 310 | E9551FCD1ED290B700DCA7C1 /* Resources */, 311 | E930117420035D9B00E454A6 /* Embed Frameworks */, 312 | ); 313 | buildRules = ( 314 | ); 315 | dependencies = ( 316 | E930117220035D9B00E454A6 /* PBXTargetDependency */, 317 | ); 318 | name = ACBRadialCollectionView; 319 | productName = ACBRadialCollectionView; 320 | productReference = E9551FCF1ED290B700DCA7C1 /* ACBRadialCollectionView.app */; 321 | productType = "com.apple.product-type.application"; 322 | }; 323 | /* End PBXNativeTarget section */ 324 | 325 | /* Begin PBXProject section */ 326 | E9551FC71ED290B700DCA7C1 /* Project object */ = { 327 | isa = PBXProject; 328 | attributes = { 329 | BuildIndependentTargetsInParallel = YES; 330 | LastSwiftUpdateCheck = 0830; 331 | LastUpgradeCheck = 1540; 332 | ORGANIZATIONNAME = akhil; 333 | TargetAttributes = { 334 | E930115D20035D9B00E454A6 = { 335 | CreatedOnToolsVersion = 9.2; 336 | ProvisioningStyle = Automatic; 337 | }; 338 | E930116520035D9B00E454A6 = { 339 | CreatedOnToolsVersion = 9.2; 340 | ProvisioningStyle = Automatic; 341 | TestTargetID = E9551FCE1ED290B700DCA7C1; 342 | }; 343 | E9551FCE1ED290B700DCA7C1 = { 344 | CreatedOnToolsVersion = 8.3.2; 345 | ProvisioningStyle = Automatic; 346 | }; 347 | }; 348 | }; 349 | buildConfigurationList = E9551FCA1ED290B700DCA7C1 /* Build configuration list for PBXProject "ACBRadialCollectionView" */; 350 | compatibilityVersion = "Xcode 3.2"; 351 | developmentRegion = English; 352 | hasScannedForEncodings = 0; 353 | knownRegions = ( 354 | English, 355 | en, 356 | Base, 357 | ); 358 | mainGroup = E9551FC61ED290B700DCA7C1; 359 | productRefGroup = E9551FD01ED290B700DCA7C1 /* Products */; 360 | projectDirPath = ""; 361 | projectRoot = ""; 362 | targets = ( 363 | E9551FCE1ED290B700DCA7C1 /* ACBRadialCollectionView */, 364 | E930115D20035D9B00E454A6 /* ACBRadialCollectionViewFramework */, 365 | E930116520035D9B00E454A6 /* ACBRadialCollectionViewFrameworkTests */, 366 | ); 367 | }; 368 | /* End PBXProject section */ 369 | 370 | /* Begin PBXResourcesBuildPhase section */ 371 | E930115C20035D9B00E454A6 /* Resources */ = { 372 | isa = PBXResourcesBuildPhase; 373 | buildActionMask = 2147483647; 374 | files = ( 375 | ); 376 | runOnlyForDeploymentPostprocessing = 0; 377 | }; 378 | E930116420035D9B00E454A6 /* Resources */ = { 379 | isa = PBXResourcesBuildPhase; 380 | buildActionMask = 2147483647; 381 | files = ( 382 | ); 383 | runOnlyForDeploymentPostprocessing = 0; 384 | }; 385 | E9551FCD1ED290B700DCA7C1 /* Resources */ = { 386 | isa = PBXResourcesBuildPhase; 387 | buildActionMask = 2147483647; 388 | files = ( 389 | E9551FDD1ED290B700DCA7C1 /* LaunchScreen.storyboard in Resources */, 390 | E9551FDA1ED290B700DCA7C1 /* Assets.xcassets in Resources */, 391 | E9551FD81ED290B700DCA7C1 /* Main.storyboard in Resources */, 392 | ); 393 | runOnlyForDeploymentPostprocessing = 0; 394 | }; 395 | /* End PBXResourcesBuildPhase section */ 396 | 397 | /* Begin PBXSourcesBuildPhase section */ 398 | E930115920035D9B00E454A6 /* Sources */ = { 399 | isa = PBXSourcesBuildPhase; 400 | buildActionMask = 2147483647; 401 | files = ( 402 | E93011982003662C00E454A6 /* ACBRadialCollectionViewLayout.swift in Sources */, 403 | E930119A2003663100E454A6 /* ACBInternalRadialScrollBar.swift in Sources */, 404 | E93011972003662A00E454A6 /* UIScrollView+ACBRadialScrollBar.swift in Sources */, 405 | E93011992003662E00E454A6 /* ACBRadialScrollBar.swift in Sources */, 406 | E93011962003662700E454A6 /* UICollectionView+ACBRadialCollectionView.swift in Sources */, 407 | ); 408 | runOnlyForDeploymentPostprocessing = 0; 409 | }; 410 | E930116220035D9B00E454A6 /* Sources */ = { 411 | isa = PBXSourcesBuildPhase; 412 | buildActionMask = 2147483647; 413 | files = ( 414 | E930116E20035D9B00E454A6 /* ACBRadialCollectionViewFrameworkTests.m in Sources */, 415 | ); 416 | runOnlyForDeploymentPostprocessing = 0; 417 | }; 418 | E9551FCB1ED290B700DCA7C1 /* Sources */ = { 419 | isa = PBXSourcesBuildPhase; 420 | buildActionMask = 2147483647; 421 | files = ( 422 | E9551FF51ED2A0AF00DCA7C1 /* AppDelegate.swift in Sources */, 423 | E93011942003661B00E454A6 /* UICollectionView+ACBRadialCollectionView.swift in Sources */, 424 | E93011952003661B00E454A6 /* UIScrollView+ACBRadialScrollBar.swift in Sources */, 425 | E93011922003661B00E454A6 /* ACBRadialScrollBar.swift in Sources */, 426 | E93011932003661B00E454A6 /* ACBInternalRadialScrollBar.swift in Sources */, 427 | E9551FF81ED2A0AF00DCA7C1 /* ACBCollectionViewCell.swift in Sources */, 428 | E93011912003661B00E454A6 /* ACBRadialCollectionViewLayout.swift in Sources */, 429 | E9551FF71ED2A0AF00DCA7C1 /* ACBViewController.swift in Sources */, 430 | ); 431 | runOnlyForDeploymentPostprocessing = 0; 432 | }; 433 | /* End PBXSourcesBuildPhase section */ 434 | 435 | /* Begin PBXTargetDependency section */ 436 | E930116920035D9B00E454A6 /* PBXTargetDependency */ = { 437 | isa = PBXTargetDependency; 438 | target = E930115D20035D9B00E454A6 /* ACBRadialCollectionViewFramework */; 439 | targetProxy = E930116820035D9B00E454A6 /* PBXContainerItemProxy */; 440 | }; 441 | E930116B20035D9B00E454A6 /* PBXTargetDependency */ = { 442 | isa = PBXTargetDependency; 443 | target = E9551FCE1ED290B700DCA7C1 /* ACBRadialCollectionView */; 444 | targetProxy = E930116A20035D9B00E454A6 /* PBXContainerItemProxy */; 445 | }; 446 | E930117220035D9B00E454A6 /* PBXTargetDependency */ = { 447 | isa = PBXTargetDependency; 448 | target = E930115D20035D9B00E454A6 /* ACBRadialCollectionViewFramework */; 449 | targetProxy = E930117120035D9B00E454A6 /* PBXContainerItemProxy */; 450 | }; 451 | /* End PBXTargetDependency section */ 452 | 453 | /* Begin PBXVariantGroup section */ 454 | E9551FD61ED290B700DCA7C1 /* Main.storyboard */ = { 455 | isa = PBXVariantGroup; 456 | children = ( 457 | E9551FD71ED290B700DCA7C1 /* Base */, 458 | ); 459 | name = Main.storyboard; 460 | sourceTree = ""; 461 | }; 462 | E9551FDB1ED290B700DCA7C1 /* LaunchScreen.storyboard */ = { 463 | isa = PBXVariantGroup; 464 | children = ( 465 | E9551FDC1ED290B700DCA7C1 /* Base */, 466 | ); 467 | name = LaunchScreen.storyboard; 468 | sourceTree = ""; 469 | }; 470 | /* End PBXVariantGroup section */ 471 | 472 | /* Begin XCBuildConfiguration section */ 473 | E930117720035D9B00E454A6 /* Debug */ = { 474 | isa = XCBuildConfiguration; 475 | buildSettings = { 476 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; 477 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 478 | CLANG_WARN_COMMA = YES; 479 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 480 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 481 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 482 | CLANG_WARN_STRICT_PROTOTYPES = YES; 483 | CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; 484 | CODE_SIGN_IDENTITY = ""; 485 | CODE_SIGN_STYLE = Automatic; 486 | CURRENT_PROJECT_VERSION = 1; 487 | DEFINES_MODULE = YES; 488 | DEVELOPMENT_TEAM = ""; 489 | DYLIB_COMPATIBILITY_VERSION = 1; 490 | DYLIB_CURRENT_VERSION = 1; 491 | DYLIB_INSTALL_NAME_BASE = "@rpath"; 492 | ENABLE_MODULE_VERIFIER = YES; 493 | GCC_C_LANGUAGE_STANDARD = gnu11; 494 | INFOPLIST_FILE = ACBRadialCollectionViewFramework/Info.plist; 495 | INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; 496 | IPHONEOS_DEPLOYMENT_TARGET = 14.0; 497 | LD_RUNPATH_SEARCH_PATHS = ( 498 | "$(inherited)", 499 | "@executable_path/Frameworks", 500 | "@loader_path/Frameworks", 501 | ); 502 | MODULE_VERIFIER_SUPPORTED_LANGUAGE_STANDARDS = "gnu11 gnu++14"; 503 | PRODUCT_BUNDLE_IDENTIFIER = com.akhil.ACBRadialCollectionViewFramework; 504 | PRODUCT_NAME = ACBRadialCollectionView; 505 | SKIP_INSTALL = YES; 506 | SWIFT_VERSION = 5.0; 507 | TARGETED_DEVICE_FAMILY = "1,2"; 508 | VERSIONING_SYSTEM = "apple-generic"; 509 | VERSION_INFO_PREFIX = ""; 510 | }; 511 | name = Debug; 512 | }; 513 | E930117820035D9B00E454A6 /* Release */ = { 514 | isa = XCBuildConfiguration; 515 | buildSettings = { 516 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; 517 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 518 | CLANG_WARN_COMMA = YES; 519 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 520 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 521 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 522 | CLANG_WARN_STRICT_PROTOTYPES = YES; 523 | CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; 524 | CODE_SIGN_IDENTITY = ""; 525 | CODE_SIGN_STYLE = Automatic; 526 | CURRENT_PROJECT_VERSION = 1; 527 | DEFINES_MODULE = YES; 528 | DEVELOPMENT_TEAM = ""; 529 | DYLIB_COMPATIBILITY_VERSION = 1; 530 | DYLIB_CURRENT_VERSION = 1; 531 | DYLIB_INSTALL_NAME_BASE = "@rpath"; 532 | ENABLE_MODULE_VERIFIER = YES; 533 | GCC_C_LANGUAGE_STANDARD = gnu11; 534 | INFOPLIST_FILE = ACBRadialCollectionViewFramework/Info.plist; 535 | INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; 536 | IPHONEOS_DEPLOYMENT_TARGET = 14.0; 537 | LD_RUNPATH_SEARCH_PATHS = ( 538 | "$(inherited)", 539 | "@executable_path/Frameworks", 540 | "@loader_path/Frameworks", 541 | ); 542 | MODULE_VERIFIER_SUPPORTED_LANGUAGE_STANDARDS = "gnu11 gnu++14"; 543 | PRODUCT_BUNDLE_IDENTIFIER = com.akhil.ACBRadialCollectionViewFramework; 544 | PRODUCT_NAME = ACBRadialCollectionView; 545 | SKIP_INSTALL = YES; 546 | SWIFT_VERSION = 5.0; 547 | TARGETED_DEVICE_FAMILY = "1,2"; 548 | VERSIONING_SYSTEM = "apple-generic"; 549 | VERSION_INFO_PREFIX = ""; 550 | }; 551 | name = Release; 552 | }; 553 | E930117A20035D9B00E454A6 /* Debug */ = { 554 | isa = XCBuildConfiguration; 555 | buildSettings = { 556 | ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; 557 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; 558 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 559 | CLANG_WARN_COMMA = YES; 560 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 561 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 562 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 563 | CLANG_WARN_STRICT_PROTOTYPES = YES; 564 | CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; 565 | CODE_SIGN_IDENTITY = "iPhone Developer"; 566 | CODE_SIGN_STYLE = Automatic; 567 | GCC_C_LANGUAGE_STANDARD = gnu11; 568 | INFOPLIST_FILE = ACBRadialCollectionViewFrameworkTests/Info.plist; 569 | IPHONEOS_DEPLOYMENT_TARGET = 14.0; 570 | LD_RUNPATH_SEARCH_PATHS = ( 571 | "$(inherited)", 572 | "@executable_path/Frameworks", 573 | "@loader_path/Frameworks", 574 | ); 575 | PRODUCT_BUNDLE_IDENTIFIER = com.akhil.ACBRadialCollectionViewFrameworkTests; 576 | PRODUCT_NAME = "$(TARGET_NAME)"; 577 | TARGETED_DEVICE_FAMILY = "1,2"; 578 | TEST_HOST = "$(BUILT_PRODUCTS_DIR)/ACBRadialCollectionView.app/ACBRadialCollectionView"; 579 | }; 580 | name = Debug; 581 | }; 582 | E930117B20035D9B00E454A6 /* Release */ = { 583 | isa = XCBuildConfiguration; 584 | buildSettings = { 585 | ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; 586 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; 587 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 588 | CLANG_WARN_COMMA = YES; 589 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 590 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 591 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 592 | CLANG_WARN_STRICT_PROTOTYPES = YES; 593 | CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; 594 | CODE_SIGN_IDENTITY = "iPhone Developer"; 595 | CODE_SIGN_STYLE = Automatic; 596 | GCC_C_LANGUAGE_STANDARD = gnu11; 597 | INFOPLIST_FILE = ACBRadialCollectionViewFrameworkTests/Info.plist; 598 | IPHONEOS_DEPLOYMENT_TARGET = 14.0; 599 | LD_RUNPATH_SEARCH_PATHS = ( 600 | "$(inherited)", 601 | "@executable_path/Frameworks", 602 | "@loader_path/Frameworks", 603 | ); 604 | PRODUCT_BUNDLE_IDENTIFIER = com.akhil.ACBRadialCollectionViewFrameworkTests; 605 | PRODUCT_NAME = "$(TARGET_NAME)"; 606 | TARGETED_DEVICE_FAMILY = "1,2"; 607 | TEST_HOST = "$(BUILT_PRODUCTS_DIR)/ACBRadialCollectionView.app/ACBRadialCollectionView"; 608 | }; 609 | name = Release; 610 | }; 611 | E9551FDF1ED290B700DCA7C1 /* Debug */ = { 612 | isa = XCBuildConfiguration; 613 | buildSettings = { 614 | ALWAYS_SEARCH_USER_PATHS = NO; 615 | CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES; 616 | CLANG_ANALYZER_NONNULL = YES; 617 | CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; 618 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 619 | CLANG_CXX_LIBRARY = "libc++"; 620 | CLANG_ENABLE_MODULES = YES; 621 | CLANG_ENABLE_OBJC_ARC = YES; 622 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 623 | CLANG_WARN_BOOL_CONVERSION = YES; 624 | CLANG_WARN_COMMA = YES; 625 | CLANG_WARN_CONSTANT_CONVERSION = YES; 626 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; 627 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 628 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES; 629 | CLANG_WARN_EMPTY_BODY = YES; 630 | CLANG_WARN_ENUM_CONVERSION = YES; 631 | CLANG_WARN_INFINITE_RECURSION = YES; 632 | CLANG_WARN_INT_CONVERSION = YES; 633 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 634 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; 635 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 636 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 637 | CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES; 638 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 639 | CLANG_WARN_STRICT_PROTOTYPES = YES; 640 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 641 | CLANG_WARN_UNREACHABLE_CODE = YES; 642 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 643 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 644 | COPY_PHASE_STRIP = NO; 645 | DEBUG_INFORMATION_FORMAT = dwarf; 646 | ENABLE_STRICT_OBJC_MSGSEND = YES; 647 | ENABLE_TESTABILITY = YES; 648 | ENABLE_USER_SCRIPT_SANDBOXING = YES; 649 | GCC_C_LANGUAGE_STANDARD = gnu99; 650 | GCC_DYNAMIC_NO_PIC = NO; 651 | GCC_NO_COMMON_BLOCKS = YES; 652 | GCC_OPTIMIZATION_LEVEL = 0; 653 | GCC_PREPROCESSOR_DEFINITIONS = ( 654 | "DEBUG=1", 655 | "$(inherited)", 656 | ); 657 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 658 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 659 | GCC_WARN_UNDECLARED_SELECTOR = YES; 660 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 661 | GCC_WARN_UNUSED_FUNCTION = YES; 662 | GCC_WARN_UNUSED_VARIABLE = YES; 663 | IPHONEOS_DEPLOYMENT_TARGET = 14.0; 664 | MTL_ENABLE_DEBUG_INFO = YES; 665 | ONLY_ACTIVE_ARCH = YES; 666 | SDKROOT = iphoneos; 667 | SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; 668 | SWIFT_OPTIMIZATION_LEVEL = "-Onone"; 669 | SWIFT_VERSION = 5.0; 670 | TARGETED_DEVICE_FAMILY = "1,2"; 671 | }; 672 | name = Debug; 673 | }; 674 | E9551FE01ED290B700DCA7C1 /* Release */ = { 675 | isa = XCBuildConfiguration; 676 | buildSettings = { 677 | ALWAYS_SEARCH_USER_PATHS = NO; 678 | CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES; 679 | CLANG_ANALYZER_NONNULL = YES; 680 | CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; 681 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 682 | CLANG_CXX_LIBRARY = "libc++"; 683 | CLANG_ENABLE_MODULES = YES; 684 | CLANG_ENABLE_OBJC_ARC = YES; 685 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 686 | CLANG_WARN_BOOL_CONVERSION = YES; 687 | CLANG_WARN_COMMA = YES; 688 | CLANG_WARN_CONSTANT_CONVERSION = YES; 689 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; 690 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 691 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES; 692 | CLANG_WARN_EMPTY_BODY = YES; 693 | CLANG_WARN_ENUM_CONVERSION = YES; 694 | CLANG_WARN_INFINITE_RECURSION = YES; 695 | CLANG_WARN_INT_CONVERSION = YES; 696 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 697 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; 698 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 699 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 700 | CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES; 701 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 702 | CLANG_WARN_STRICT_PROTOTYPES = YES; 703 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 704 | CLANG_WARN_UNREACHABLE_CODE = YES; 705 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 706 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 707 | COPY_PHASE_STRIP = NO; 708 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 709 | ENABLE_NS_ASSERTIONS = NO; 710 | ENABLE_STRICT_OBJC_MSGSEND = YES; 711 | ENABLE_USER_SCRIPT_SANDBOXING = YES; 712 | GCC_C_LANGUAGE_STANDARD = gnu99; 713 | GCC_NO_COMMON_BLOCKS = YES; 714 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 715 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 716 | GCC_WARN_UNDECLARED_SELECTOR = YES; 717 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 718 | GCC_WARN_UNUSED_FUNCTION = YES; 719 | GCC_WARN_UNUSED_VARIABLE = YES; 720 | IPHONEOS_DEPLOYMENT_TARGET = 14.0; 721 | MTL_ENABLE_DEBUG_INFO = NO; 722 | SDKROOT = iphoneos; 723 | SWIFT_COMPILATION_MODE = wholemodule; 724 | SWIFT_OPTIMIZATION_LEVEL = "-O"; 725 | SWIFT_VERSION = 5.0; 726 | TARGETED_DEVICE_FAMILY = "1,2"; 727 | VALIDATE_PRODUCT = YES; 728 | }; 729 | name = Release; 730 | }; 731 | E9551FE21ED290B700DCA7C1 /* Debug */ = { 732 | isa = XCBuildConfiguration; 733 | buildSettings = { 734 | ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; 735 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 736 | CODE_SIGN_IDENTITY = "iPhone Developer"; 737 | DEVELOPMENT_TEAM = ""; 738 | INFOPLIST_FILE = ACBRadialCollectionView/Info.plist; 739 | LD_RUNPATH_SEARCH_PATHS = ( 740 | "$(inherited)", 741 | "@executable_path/Frameworks", 742 | ); 743 | PRODUCT_BUNDLE_IDENTIFIER = com.akhil.ACBRadialCollectionView; 744 | PRODUCT_NAME = "$(TARGET_NAME)"; 745 | SWIFT_VERSION = 5.0; 746 | }; 747 | name = Debug; 748 | }; 749 | E9551FE31ED290B700DCA7C1 /* Release */ = { 750 | isa = XCBuildConfiguration; 751 | buildSettings = { 752 | ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; 753 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 754 | CODE_SIGN_IDENTITY = "iPhone Developer"; 755 | DEVELOPMENT_TEAM = ""; 756 | INFOPLIST_FILE = ACBRadialCollectionView/Info.plist; 757 | LD_RUNPATH_SEARCH_PATHS = ( 758 | "$(inherited)", 759 | "@executable_path/Frameworks", 760 | ); 761 | PRODUCT_BUNDLE_IDENTIFIER = com.akhil.ACBRadialCollectionView; 762 | PRODUCT_NAME = "$(TARGET_NAME)"; 763 | SWIFT_VERSION = 5.0; 764 | }; 765 | name = Release; 766 | }; 767 | /* End XCBuildConfiguration section */ 768 | 769 | /* Begin XCConfigurationList section */ 770 | E930117620035D9B00E454A6 /* Build configuration list for PBXNativeTarget "ACBRadialCollectionViewFramework" */ = { 771 | isa = XCConfigurationList; 772 | buildConfigurations = ( 773 | E930117720035D9B00E454A6 /* Debug */, 774 | E930117820035D9B00E454A6 /* Release */, 775 | ); 776 | defaultConfigurationIsVisible = 0; 777 | defaultConfigurationName = Release; 778 | }; 779 | E930117920035D9B00E454A6 /* Build configuration list for PBXNativeTarget "ACBRadialCollectionViewFrameworkTests" */ = { 780 | isa = XCConfigurationList; 781 | buildConfigurations = ( 782 | E930117A20035D9B00E454A6 /* Debug */, 783 | E930117B20035D9B00E454A6 /* Release */, 784 | ); 785 | defaultConfigurationIsVisible = 0; 786 | defaultConfigurationName = Release; 787 | }; 788 | E9551FCA1ED290B700DCA7C1 /* Build configuration list for PBXProject "ACBRadialCollectionView" */ = { 789 | isa = XCConfigurationList; 790 | buildConfigurations = ( 791 | E9551FDF1ED290B700DCA7C1 /* Debug */, 792 | E9551FE01ED290B700DCA7C1 /* Release */, 793 | ); 794 | defaultConfigurationIsVisible = 0; 795 | defaultConfigurationName = Release; 796 | }; 797 | E9551FE11ED290B700DCA7C1 /* Build configuration list for PBXNativeTarget "ACBRadialCollectionView" */ = { 798 | isa = XCConfigurationList; 799 | buildConfigurations = ( 800 | E9551FE21ED290B700DCA7C1 /* Debug */, 801 | E9551FE31ED290B700DCA7C1 /* Release */, 802 | ); 803 | defaultConfigurationIsVisible = 0; 804 | defaultConfigurationName = Release; 805 | }; 806 | /* End XCConfigurationList section */ 807 | }; 808 | rootObject = E9551FC71ED290B700DCA7C1 /* Project object */; 809 | } 810 | -------------------------------------------------------------------------------- /ACBRadialCollectionView.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /ACBRadialCollectionView.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /ACBRadialCollectionView.xcodeproj/xcshareddata/xcschemes/ACBRadialCollectionView.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 30 | 31 | 37 | 38 | 39 | 40 | 42 | 48 | 49 | 50 | 51 | 52 | 62 | 64 | 70 | 71 | 72 | 73 | 79 | 81 | 87 | 88 | 89 | 90 | 92 | 93 | 96 | 97 | 98 | -------------------------------------------------------------------------------- /ACBRadialCollectionView.xcodeproj/xcshareddata/xcschemes/ACBRadialCollectionViewFramework.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 30 | 31 | 32 | 33 | 43 | 44 | 50 | 51 | 52 | 53 | 59 | 60 | 66 | 67 | 68 | 69 | 71 | 72 | 75 | 76 | 77 | -------------------------------------------------------------------------------- /ACBRadialCollectionView/Assets.xcassets/AppIcon.appiconset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "filename" : "Icon-App-20x20@2x.png", 5 | "idiom" : "iphone", 6 | "scale" : "2x", 7 | "size" : "20x20" 8 | }, 9 | { 10 | "filename" : "Icon-App-20x20@3x.png", 11 | "idiom" : "iphone", 12 | "scale" : "3x", 13 | "size" : "20x20" 14 | }, 15 | { 16 | "filename" : "Icon-App-29x29@1x.png", 17 | "idiom" : "iphone", 18 | "scale" : "1x", 19 | "size" : "29x29" 20 | }, 21 | { 22 | "filename" : "Icon-App-29x29@2x.png", 23 | "idiom" : "iphone", 24 | "scale" : "2x", 25 | "size" : "29x29" 26 | }, 27 | { 28 | "filename" : "Icon-App-29x29@3x.png", 29 | "idiom" : "iphone", 30 | "scale" : "3x", 31 | "size" : "29x29" 32 | }, 33 | { 34 | "filename" : "Icon-App-40x40@2x.png", 35 | "idiom" : "iphone", 36 | "scale" : "2x", 37 | "size" : "40x40" 38 | }, 39 | { 40 | "filename" : "Icon-App-40x40@3x.png", 41 | "idiom" : "iphone", 42 | "scale" : "3x", 43 | "size" : "40x40" 44 | }, 45 | { 46 | "filename" : "Icon-App-57x57@1x.png", 47 | "idiom" : "iphone", 48 | "scale" : "1x", 49 | "size" : "57x57" 50 | }, 51 | { 52 | "filename" : "Icon-App-57x57@2x.png", 53 | "idiom" : "iphone", 54 | "scale" : "2x", 55 | "size" : "57x57" 56 | }, 57 | { 58 | "filename" : "Icon-App-60x60@2x.png", 59 | "idiom" : "iphone", 60 | "scale" : "2x", 61 | "size" : "60x60" 62 | }, 63 | { 64 | "filename" : "Icon-App-60x60@3x.png", 65 | "idiom" : "iphone", 66 | "scale" : "3x", 67 | "size" : "60x60" 68 | }, 69 | { 70 | "filename" : "Icon-App-20x20@1x.png", 71 | "idiom" : "ipad", 72 | "scale" : "1x", 73 | "size" : "20x20" 74 | }, 75 | { 76 | "filename" : "Icon-App-20x20@2x.png", 77 | "idiom" : "ipad", 78 | "scale" : "2x", 79 | "size" : "20x20" 80 | }, 81 | { 82 | "filename" : "Icon-App-29x29@1x.png", 83 | "idiom" : "ipad", 84 | "scale" : "1x", 85 | "size" : "29x29" 86 | }, 87 | { 88 | "filename" : "Icon-App-29x29@2x.png", 89 | "idiom" : "ipad", 90 | "scale" : "2x", 91 | "size" : "29x29" 92 | }, 93 | { 94 | "filename" : "Icon-App-40x40@1x.png", 95 | "idiom" : "ipad", 96 | "scale" : "1x", 97 | "size" : "40x40" 98 | }, 99 | { 100 | "filename" : "Icon-App-40x40@2x.png", 101 | "idiom" : "ipad", 102 | "scale" : "2x", 103 | "size" : "40x40" 104 | }, 105 | { 106 | "filename" : "Icon-App-76x76@1x.png", 107 | "idiom" : "ipad", 108 | "scale" : "1x", 109 | "size" : "76x76" 110 | }, 111 | { 112 | "filename" : "Icon-App-76x76@2x.png", 113 | "idiom" : "ipad", 114 | "scale" : "2x", 115 | "size" : "76x76" 116 | }, 117 | { 118 | "filename" : "Icon-App-83.5x83.5@2x.png", 119 | "idiom" : "ipad", 120 | "scale" : "2x", 121 | "size" : "83.5x83.5" 122 | }, 123 | { 124 | "filename" : "ItunesArtwork@2x.png", 125 | "idiom" : "ios-marketing", 126 | "scale" : "1x", 127 | "size" : "1024x1024" 128 | } 129 | ], 130 | "info" : { 131 | "author" : "xcode", 132 | "version" : 1 133 | } 134 | } 135 | -------------------------------------------------------------------------------- /ACBRadialCollectionView/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/akhilcb/ACBRadialCollectionView/cd9994d195866342cc029dece8853842c7bd067d/ACBRadialCollectionView/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png -------------------------------------------------------------------------------- /ACBRadialCollectionView/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/akhilcb/ACBRadialCollectionView/cd9994d195866342cc029dece8853842c7bd067d/ACBRadialCollectionView/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png -------------------------------------------------------------------------------- /ACBRadialCollectionView/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/akhilcb/ACBRadialCollectionView/cd9994d195866342cc029dece8853842c7bd067d/ACBRadialCollectionView/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png -------------------------------------------------------------------------------- /ACBRadialCollectionView/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/akhilcb/ACBRadialCollectionView/cd9994d195866342cc029dece8853842c7bd067d/ACBRadialCollectionView/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png -------------------------------------------------------------------------------- /ACBRadialCollectionView/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/akhilcb/ACBRadialCollectionView/cd9994d195866342cc029dece8853842c7bd067d/ACBRadialCollectionView/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png -------------------------------------------------------------------------------- /ACBRadialCollectionView/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/akhilcb/ACBRadialCollectionView/cd9994d195866342cc029dece8853842c7bd067d/ACBRadialCollectionView/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png -------------------------------------------------------------------------------- /ACBRadialCollectionView/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/akhilcb/ACBRadialCollectionView/cd9994d195866342cc029dece8853842c7bd067d/ACBRadialCollectionView/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png -------------------------------------------------------------------------------- /ACBRadialCollectionView/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/akhilcb/ACBRadialCollectionView/cd9994d195866342cc029dece8853842c7bd067d/ACBRadialCollectionView/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png -------------------------------------------------------------------------------- /ACBRadialCollectionView/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/akhilcb/ACBRadialCollectionView/cd9994d195866342cc029dece8853842c7bd067d/ACBRadialCollectionView/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png -------------------------------------------------------------------------------- /ACBRadialCollectionView/Assets.xcassets/AppIcon.appiconset/Icon-App-57x57@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/akhilcb/ACBRadialCollectionView/cd9994d195866342cc029dece8853842c7bd067d/ACBRadialCollectionView/Assets.xcassets/AppIcon.appiconset/Icon-App-57x57@1x.png -------------------------------------------------------------------------------- /ACBRadialCollectionView/Assets.xcassets/AppIcon.appiconset/Icon-App-57x57@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/akhilcb/ACBRadialCollectionView/cd9994d195866342cc029dece8853842c7bd067d/ACBRadialCollectionView/Assets.xcassets/AppIcon.appiconset/Icon-App-57x57@2x.png -------------------------------------------------------------------------------- /ACBRadialCollectionView/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/akhilcb/ACBRadialCollectionView/cd9994d195866342cc029dece8853842c7bd067d/ACBRadialCollectionView/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png -------------------------------------------------------------------------------- /ACBRadialCollectionView/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/akhilcb/ACBRadialCollectionView/cd9994d195866342cc029dece8853842c7bd067d/ACBRadialCollectionView/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png -------------------------------------------------------------------------------- /ACBRadialCollectionView/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/akhilcb/ACBRadialCollectionView/cd9994d195866342cc029dece8853842c7bd067d/ACBRadialCollectionView/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png -------------------------------------------------------------------------------- /ACBRadialCollectionView/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/akhilcb/ACBRadialCollectionView/cd9994d195866342cc029dece8853842c7bd067d/ACBRadialCollectionView/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png -------------------------------------------------------------------------------- /ACBRadialCollectionView/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/akhilcb/ACBRadialCollectionView/cd9994d195866342cc029dece8853842c7bd067d/ACBRadialCollectionView/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png -------------------------------------------------------------------------------- /ACBRadialCollectionView/Assets.xcassets/AppIcon.appiconset/ItunesArtwork@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/akhilcb/ACBRadialCollectionView/cd9994d195866342cc029dece8853842c7bd067d/ACBRadialCollectionView/Assets.xcassets/AppIcon.appiconset/ItunesArtwork@2x.png -------------------------------------------------------------------------------- /ACBRadialCollectionView/Assets.xcassets/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "info" : { 3 | "version" : 1, 4 | "author" : "xcode" 5 | } 6 | } -------------------------------------------------------------------------------- /ACBRadialCollectionView/Assets.xcassets/Icon-60.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "filename" : "Icon-60.png", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "scale" : "2x" 11 | }, 12 | { 13 | "idiom" : "universal", 14 | "scale" : "3x" 15 | } 16 | ], 17 | "info" : { 18 | "version" : 1, 19 | "author" : "xcode" 20 | } 21 | } -------------------------------------------------------------------------------- /ACBRadialCollectionView/Assets.xcassets/Icon-60.imageset/Icon-60.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/akhilcb/ACBRadialCollectionView/cd9994d195866342cc029dece8853842c7bd067d/ACBRadialCollectionView/Assets.xcassets/Icon-60.imageset/Icon-60.png -------------------------------------------------------------------------------- /ACBRadialCollectionView/Assets.xcassets/Icon-72.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "filename" : "Icon-72.png", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "filename" : "Icon-72@2x.png", 11 | "scale" : "2x" 12 | }, 13 | { 14 | "idiom" : "universal", 15 | "scale" : "3x" 16 | } 17 | ], 18 | "info" : { 19 | "version" : 1, 20 | "author" : "xcode" 21 | } 22 | } -------------------------------------------------------------------------------- /ACBRadialCollectionView/Assets.xcassets/Icon-72.imageset/Icon-72.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/akhilcb/ACBRadialCollectionView/cd9994d195866342cc029dece8853842c7bd067d/ACBRadialCollectionView/Assets.xcassets/Icon-72.imageset/Icon-72.png -------------------------------------------------------------------------------- /ACBRadialCollectionView/Assets.xcassets/Icon-72.imageset/Icon-72@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/akhilcb/ACBRadialCollectionView/cd9994d195866342cc029dece8853842c7bd067d/ACBRadialCollectionView/Assets.xcassets/Icon-72.imageset/Icon-72@2x.png -------------------------------------------------------------------------------- /ACBRadialCollectionView/Assets.xcassets/Icon-Small-50.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "filename" : "Icon-Small-50.png", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "filename" : "Icon-Small-50@2x.png", 11 | "scale" : "2x" 12 | }, 13 | { 14 | "idiom" : "universal", 15 | "scale" : "3x" 16 | } 17 | ], 18 | "info" : { 19 | "version" : 1, 20 | "author" : "xcode" 21 | } 22 | } -------------------------------------------------------------------------------- /ACBRadialCollectionView/Assets.xcassets/Icon-Small-50.imageset/Icon-Small-50.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/akhilcb/ACBRadialCollectionView/cd9994d195866342cc029dece8853842c7bd067d/ACBRadialCollectionView/Assets.xcassets/Icon-Small-50.imageset/Icon-Small-50.png -------------------------------------------------------------------------------- /ACBRadialCollectionView/Assets.xcassets/Icon-Small-50.imageset/Icon-Small-50@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/akhilcb/ACBRadialCollectionView/cd9994d195866342cc029dece8853842c7bd067d/ACBRadialCollectionView/Assets.xcassets/Icon-Small-50.imageset/Icon-Small-50@2x.png -------------------------------------------------------------------------------- /ACBRadialCollectionView/Assets.xcassets/Icon.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "filename" : "Icon.png", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "filename" : "Icon@2x.png", 11 | "scale" : "2x" 12 | }, 13 | { 14 | "idiom" : "universal", 15 | "scale" : "3x" 16 | } 17 | ], 18 | "info" : { 19 | "version" : 1, 20 | "author" : "xcode" 21 | } 22 | } -------------------------------------------------------------------------------- /ACBRadialCollectionView/Assets.xcassets/Icon.imageset/Icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/akhilcb/ACBRadialCollectionView/cd9994d195866342cc029dece8853842c7bd067d/ACBRadialCollectionView/Assets.xcassets/Icon.imageset/Icon.png -------------------------------------------------------------------------------- /ACBRadialCollectionView/Assets.xcassets/Icon.imageset/Icon@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/akhilcb/ACBRadialCollectionView/cd9994d195866342cc029dece8853842c7bd067d/ACBRadialCollectionView/Assets.xcassets/Icon.imageset/Icon@2x.png -------------------------------------------------------------------------------- /ACBRadialCollectionView/Assets.xcassets/ItunesArtwork.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "filename" : "ItunesArtwork.png", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "filename" : "ItunesArtwork@2x.png", 11 | "scale" : "2x" 12 | }, 13 | { 14 | "idiom" : "universal", 15 | "scale" : "3x" 16 | } 17 | ], 18 | "info" : { 19 | "version" : 1, 20 | "author" : "xcode" 21 | } 22 | } -------------------------------------------------------------------------------- /ACBRadialCollectionView/Assets.xcassets/ItunesArtwork.imageset/ItunesArtwork.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/akhilcb/ACBRadialCollectionView/cd9994d195866342cc029dece8853842c7bd067d/ACBRadialCollectionView/Assets.xcassets/ItunesArtwork.imageset/ItunesArtwork.png -------------------------------------------------------------------------------- /ACBRadialCollectionView/Assets.xcassets/ItunesArtwork.imageset/ItunesArtwork@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/akhilcb/ACBRadialCollectionView/cd9994d195866342cc029dece8853842c7bd067d/ACBRadialCollectionView/Assets.xcassets/ItunesArtwork.imageset/ItunesArtwork@2x.png -------------------------------------------------------------------------------- /ACBRadialCollectionView/Base.lproj/LaunchScreen.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | -------------------------------------------------------------------------------- /ACBRadialCollectionView/Base.lproj/Main.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | 110 | 111 | 112 | 113 | 114 | 115 | 116 | 117 | 118 | 119 | 120 | 121 | 122 | 123 | 124 | 125 | 126 | 133 | 134 | 135 | 136 | 137 | 138 | 139 | 140 | 141 | 142 | 143 | 144 | 145 | 146 | 147 | 148 | 149 | 150 | 151 | 152 | 153 | 154 | 164 | 165 | 166 | 167 | 168 | 169 | 170 | 171 | 172 | 173 | 174 | 184 | 185 | 186 | 187 | 188 | 189 | 190 | 191 | 192 | 193 | 194 | 204 | 214 | 215 | 216 | 217 | 218 | 219 | 220 | 221 | 222 | 223 | 224 | 225 | 226 | 227 | 228 | 229 | 230 | 231 | 232 | 233 | 234 | 235 | 236 | 237 | 238 | 239 | 240 | 241 | 242 | 243 | 244 | 245 | 246 | 247 | 248 | 249 | 250 | 251 | 252 | 253 | 254 | 255 | 256 | 257 | 258 | 259 | 260 | 261 | 262 | 263 | 264 | 265 | 266 | 267 | 268 | 269 | 270 | 271 | 272 | 273 | 274 | 275 | 276 | 277 | 278 | 279 | 280 | 281 | 282 | 283 | 284 | 285 | 286 | 287 | 288 | 289 | 290 | 291 | 292 | -------------------------------------------------------------------------------- /ACBRadialCollectionView/Classes/General/AppDelegate.swift: -------------------------------------------------------------------------------- 1 | // 2 | // AppDelegate.swift 3 | // ACBRadialCollectionView 4 | // 5 | // Created by Akhil on 5/21/17. 6 | // Copyright © 2017 akhil. All rights reserved. 7 | // 8 | 9 | import UIKit 10 | 11 | @UIApplicationMain 12 | class AppDelegate: UIResponder, UIApplicationDelegate { 13 | 14 | var window: UIWindow? 15 | 16 | 17 | func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool { 18 | // Override point for customization after application launch. 19 | return true 20 | } 21 | 22 | func applicationWillResignActive(_ application: UIApplication) { 23 | // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. 24 | // Use this method to pause ongoing tasks, disable timers, and invalidate graphics rendering callbacks. Games should use this method to pause the game. 25 | } 26 | 27 | func applicationDidEnterBackground(_ application: UIApplication) { 28 | // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. 29 | // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. 30 | } 31 | 32 | func applicationWillEnterForeground(_ application: UIApplication) { 33 | // Called as part of the transition from the background to the active state; here you can undo many of the changes made on entering the background. 34 | } 35 | 36 | func applicationDidBecomeActive(_ application: UIApplication) { 37 | // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. 38 | } 39 | 40 | func applicationWillTerminate(_ application: UIApplication) { 41 | // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. 42 | } 43 | 44 | 45 | } 46 | 47 | -------------------------------------------------------------------------------- /ACBRadialCollectionView/Classes/Source/Extensions/UICollectionView+ACBRadialCollectionView.swift: -------------------------------------------------------------------------------- 1 | // 2 | // UICollectionView+ACBRadialCollectionView.swift 3 | // RadialCollectionView 4 | // 5 | // Created by Akhil on 1/2/17. 6 | // Copyright © 2017 Akhil. All rights reserved. 7 | // 8 | 9 | import UIKit 10 | 11 | private protocol ACBRadialCollectionViewProtocol { 12 | func enableRadialLayout(WithCenter center: CGPoint, 13 | radius: CGFloat, 14 | cellSize : CGSize, 15 | angularSpacing : CGFloat, 16 | scrollDirection : ACBRadialCollectionViewScrollDirection, 17 | startAngle : CGFloat, 18 | endAngle : CGFloat) 19 | } 20 | 21 | 22 | extension UICollectionView : ACBRadialCollectionViewProtocol { 23 | 24 | public var applyRotationToCells: Bool { 25 | get { 26 | if let circularLayout = self.collectionViewLayout as? ACBRadialCollectionViewLayout { 27 | 28 | return circularLayout.rotateCells 29 | } 30 | 31 | return false 32 | } 33 | 34 | set { 35 | if let circularLayout = self.collectionViewLayout as? ACBRadialCollectionViewLayout { 36 | 37 | circularLayout.rotateCells = newValue 38 | } 39 | } 40 | } 41 | 42 | 43 | public func enableRadialLayout(WithCenter center: CGPoint, 44 | radius: CGFloat, 45 | cellSize : CGSize, 46 | angularSpacing : CGFloat, 47 | scrollDirection : ACBRadialCollectionViewScrollDirection, 48 | startAngle : CGFloat, 49 | endAngle : CGFloat) { 50 | 51 | 52 | let circularLayout = ACBRadialCollectionViewLayout(center: center, radius: radius, cellSize: cellSize, angularSpacing: angularSpacing) 53 | circularLayout.setAngle(startAngle: startAngle, endAngle: endAngle, radialScrollDirection: scrollDirection) 54 | circularLayout.rotateCells = true 55 | 56 | self.collectionViewLayout = circularLayout 57 | self.backgroundColor = UIColor.clear 58 | 59 | let offset : CGFloat = 10.0 60 | let arcRadius = radius + cellSize.width / 2 + offset 61 | let clockwise = (scrollDirection == .clockwise) 62 | 63 | self.enableRadialScrollBar(WithScrollBarViewFrame: self.frame, arcCenter: center, radius: arcRadius, scrollDirectionClockwise : clockwise, startAngle : startAngle, endAngle : endAngle) 64 | } 65 | 66 | 67 | override open func point(inside point: CGPoint, with event: UIEvent?) -> Bool { 68 | 69 | if let collectionlayout : ACBRadialCollectionViewLayout = self.collectionViewLayout as? ACBRadialCollectionViewLayout { 70 | let p1 = collectionlayout.center 71 | var p2 = point 72 | p2 = self.convert(p2, to: nil) 73 | 74 | let xDist = (p2.x - p1.x) 75 | let yDist = (p2.y - p1.y) 76 | 77 | let distance = sqrt((xDist * xDist) + (yDist * yDist)) 78 | 79 | let outerRadius = (collectionlayout.radius + (collectionlayout.cellSize.width) + 5) 80 | let innerRadius = (collectionlayout.radius - (collectionlayout.cellSize.width) - 5) 81 | 82 | let angle = p1.angleToPoint(toPoint: p2) 83 | 84 | let distFlag : Bool = (distance <= outerRadius && distance >= innerRadius) 85 | let clockwise = true 86 | let angleFlag: Bool = angle.isWithInRadianAngleRange(start: collectionlayout.layoutStartAngle, end: collectionlayout.layoutEndAngle, clockwise: clockwise) 87 | 88 | return (distFlag && angleFlag) 89 | } 90 | 91 | return true 92 | } 93 | 94 | } 95 | 96 | 97 | fileprivate extension CGPoint { 98 | 99 | func angleToPoint(toPoint: CGPoint) -> CGFloat { 100 | 101 | let originX = toPoint.x - self.x 102 | let originY = toPoint.y - self.y 103 | var bearingRadians : CGFloat = CGFloat(atan2f(Float(originY), Float(originX))) 104 | while bearingRadians < 0 { 105 | bearingRadians += (2 * CGFloat.pi) 106 | } 107 | return bearingRadians 108 | } 109 | } 110 | 111 | 112 | fileprivate extension CGFloat { 113 | var degrees: CGFloat { 114 | return self * CGFloat(180.0 / CGFloat.pi) 115 | } 116 | 117 | func isWithInRadianAngleRange(start: CGFloat, end: CGFloat, clockwise: Bool) -> Bool { 118 | let startAngle = start.roundedAngle() 119 | let endAngle = end.roundedAngle() 120 | 121 | if (clockwise && (endAngle < startAngle)) { 122 | return (self.isWithInRadianAngleRange(start: startAngle, 123 | end: CGFloat(2 * Double.pi), 124 | clockwise: clockwise)) 125 | || (self.isWithInRadianAngleRange(start: CGFloat(0), 126 | end: endAngle, 127 | clockwise: clockwise)) 128 | } else if (!clockwise && (startAngle < endAngle)) { 129 | return (self.isWithInRadianAngleRange(start: startAngle, 130 | end: CGFloat(0), 131 | clockwise: clockwise)) 132 | || (self.isWithInRadianAngleRange(start: CGFloat(2 * Double.pi), 133 | end: endAngle, 134 | clockwise: clockwise)) 135 | } 136 | 137 | var range: ClosedRange 138 | 139 | if clockwise { 140 | range = (startAngle...endAngle) 141 | } else { 142 | range = (endAngle...startAngle) 143 | } 144 | 145 | if range.contains(self.roundedAngle()) { 146 | return true 147 | } 148 | 149 | return false 150 | } 151 | 152 | func roundedAngle() -> CGFloat { 153 | var angle = self 154 | 155 | while angle < 0 { 156 | angle += CGFloat(2 * Double.pi) 157 | } 158 | 159 | while angle > CGFloat(2 * Double.pi) { 160 | angle -= CGFloat(2 * Double.pi) 161 | } 162 | 163 | return angle 164 | } 165 | 166 | } 167 | 168 | -------------------------------------------------------------------------------- /ACBRadialCollectionView/Classes/Source/Extensions/UIScrollView+ACBRadialScrollBar.swift: -------------------------------------------------------------------------------- 1 | // 2 | // UIScrollView+ACBRadialScrollBar.swift 3 | // RadialCollectionView 4 | // 5 | // Created by Akhil on 1/2/17. 6 | // Copyright © 2017 Akhil. All rights reserved. 7 | // 8 | 9 | import UIKit 10 | 11 | private protocol ACBRadialScrollBarProtocol { 12 | func enableRadialScrollBar(WithScrollBarViewFrame frame: CGRect, 13 | arcCenter : CGPoint, 14 | radius : CGFloat, 15 | scrollDirectionClockwise : Bool, 16 | startAngle : CGFloat, 17 | endAngle : CGFloat) 18 | } 19 | 20 | 21 | extension UIScrollView : ACBRadialScrollBarProtocol { 22 | 23 | //scrollview must be added to superview before invoking enableRadialScrollBar() 24 | //clockwise is true for vertical scrolling and false for horizonal scrolling 25 | public func enableRadialScrollBar(WithScrollBarViewFrame frame: CGRect, 26 | arcCenter: CGPoint, 27 | radius: CGFloat, 28 | scrollDirectionClockwise: Bool, 29 | startAngle: CGFloat = 0, 30 | endAngle: CGFloat = .pi / 2) { 31 | 32 | if let scrollSuperView = self.superview { 33 | 34 | self.scrollBar?.removeFromSuperview() 35 | self.scrollBar = ACBRadialScrollBar(frame : frame, 36 | arcCenter : arcCenter, 37 | radius: radius, 38 | startAngle : startAngle, 39 | endAngle : endAngle, 40 | targetScrollView : self) 41 | 42 | if let scrollBar = self.scrollBar { 43 | scrollSuperView.addSubview(scrollBar) 44 | scrollBar.layer.zPosition = 1000 45 | self.showsVerticalScrollIndicator = false 46 | self.showsHorizontalScrollIndicator = false 47 | self.isScrollEnabled = true 48 | scrollBar.scrollBarDirectionClockwise = scrollDirectionClockwise 49 | } 50 | } else { 51 | print("ScrollView should be added to superView before invoking enableRadialScrollBar().") 52 | } 53 | } 54 | 55 | private struct AssociatedKeys { 56 | static var scrollBar = malloc(1)! 57 | } 58 | 59 | var scrollBar : ACBRadialScrollBar? { 60 | get { 61 | return objc_getAssociatedObject(self, &AssociatedKeys.scrollBar) as? ACBRadialScrollBar 62 | } 63 | 64 | set(newValue) { 65 | objc_setAssociatedObject(self, &AssociatedKeys.scrollBar, newValue, objc_AssociationPolicy.OBJC_ASSOCIATION_RETAIN_NONATOMIC) 66 | } 67 | } 68 | } 69 | -------------------------------------------------------------------------------- /ACBRadialCollectionView/Classes/Source/Helper/ACBRadialCollectionViewLayout.swift: -------------------------------------------------------------------------------- 1 | // 2 | // ACBRadialCollectionViewLayout.swift 3 | // RadialCollectionView 4 | // 5 | // Created by Akhil on 11/26/16. 6 | // Copyright © 2016 Akhil. All rights reserved. 7 | // 8 | 9 | 10 | import UIKit 11 | 12 | public enum ACBRadialCollectionViewScrollDirection : Int { 13 | case clockwise 14 | case anticlockwise 15 | } 16 | 17 | 18 | class ACBRadialCollectionViewLayout: UICollectionViewLayout { 19 | 20 | var center: CGPoint = CGPoint.zero 21 | var radius: CGFloat = 0.0 22 | var rotateCells: Bool = false 23 | 24 | fileprivate(set) var cellSize : CGSize = CGSize.zero 25 | fileprivate(set) var radialScrollDirection : ACBRadialCollectionViewScrollDirection = .anticlockwise 26 | 27 | fileprivate var angularSpacing: CGFloat = 0.0 28 | fileprivate var angleOfEachCell: CGFloat = 0.0 29 | fileprivate var angleForSpacing: CGFloat = 0.0 30 | fileprivate var totalCircleLength: CGFloat = 0.0 31 | fileprivate var numberOfCells: Int = 0 32 | fileprivate var maxNoOfCellsInCircle: CGFloat = 0.0 33 | 34 | fileprivate var startAnglePrivate: CGFloat = 0.0 35 | fileprivate var endAnglePrivate: CGFloat = 0.0 36 | 37 | fileprivate(set) var layoutStartAngle: CGFloat = 0.0 38 | fileprivate(set) var layoutEndAngle: CGFloat = 0.0 39 | 40 | 41 | required override init() { 42 | super.init() 43 | } 44 | 45 | required init?(coder aDecoder: NSCoder) { 46 | super.init(coder: aDecoder) 47 | } 48 | 49 | convenience init(center : CGPoint, radius : CGFloat, cellSize : CGSize, angularSpacing : CGFloat) { 50 | self.init() 51 | self.center = center 52 | self.radius = radius 53 | self.cellSize = cellSize 54 | self.angularSpacing = angularSpacing 55 | } 56 | 57 | 58 | func setAngle(startAngle : CGFloat, endAngle : CGFloat, radialScrollDirection : ACBRadialCollectionViewScrollDirection) -> Void { 59 | self.radialScrollDirection = radialScrollDirection 60 | self.layoutStartAngle = startAngle 61 | self.layoutEndAngle = endAngle 62 | 63 | var tempEndAngle = endAngle 64 | 65 | if endAngle == 0.0 { 66 | tempEndAngle = 2 * .pi 67 | } else if startAngle != 0.0 && endAngle < startAngle { 68 | tempEndAngle = endAngle + 2 * .pi 69 | } 70 | 71 | if radialScrollDirection == .anticlockwise {//reverse start and end 72 | startAnglePrivate = tempEndAngle 73 | endAnglePrivate = startAngle 74 | } else { 75 | startAnglePrivate = startAngle * -1 76 | endAnglePrivate = tempEndAngle * -1 77 | } 78 | 79 | if startAnglePrivate == 2 * .pi { 80 | startAnglePrivate = 2 * .pi - .pi / 180 81 | } 82 | 83 | if endAnglePrivate == 2 * .pi { 84 | endAnglePrivate = 2 * .pi - .pi / 180 85 | } 86 | } 87 | 88 | override func prepare() { 89 | super.prepare() 90 | numberOfCells = (self.collectionView?.numberOfItems(inSection: 0))! 91 | totalCircleLength = abs(startAnglePrivate - endAnglePrivate) * radius 92 | maxNoOfCellsInCircle = totalCircleLength / (max(cellSize.width, cellSize.height) + angularSpacing / 2) 93 | angleOfEachCell = abs(startAnglePrivate - endAnglePrivate) / maxNoOfCellsInCircle 94 | } 95 | 96 | 97 | override var collectionViewContentSize: CGSize { 98 | 99 | let visibleAngle = abs(startAnglePrivate - endAnglePrivate) 100 | let remainingCellsCount = numberOfCells > Int(ceil(maxNoOfCellsInCircle)) ? numberOfCells - Int(ceil(maxNoOfCellsInCircle)) : 0 101 | let scrollableContentWidth = (CGFloat(remainingCellsCount) + 0.5) * angleOfEachCell * radius / (2 * .pi / visibleAngle) 102 | let height = radius + max(cellSize.width, cellSize.height / 2) 103 | 104 | if radialScrollDirection == ACBRadialCollectionViewScrollDirection.clockwise { 105 | return CGSize(width: height, height: scrollableContentWidth + (self.collectionView?.bounds.size.height)!) 106 | } 107 | 108 | return CGSize(width: scrollableContentWidth + (self.collectionView?.bounds.size.width)!, height: height) 109 | } 110 | 111 | override func layoutAttributesForItem(at indexPath: IndexPath) -> UICollectionViewLayoutAttributes? { 112 | 113 | if (radialScrollDirection == .clockwise) { 114 | return layoutAttributesForClockwiseScrollForItem(at: indexPath) 115 | } 116 | 117 | return layoutAttributesForAntiClockwiseScrollForItem(at: indexPath) 118 | } 119 | 120 | fileprivate func layoutAttributesForAntiClockwiseScrollForItem(at indexPath : IndexPath) -> UICollectionViewLayoutAttributes { 121 | 122 | let attributes = UICollectionViewLayoutAttributes(forCellWith: indexPath) 123 | var offset : CGFloat = (self.collectionView?.contentOffset.x)! 124 | offset = (offset != 0) ? offset : 1 125 | 126 | let offsetInAngle = offset / totalCircleLength 127 | let angle = 2 * .pi * offsetInAngle 128 | attributes.size = cellSize 129 | 130 | let deltaX = (radius * cos(CGFloat(indexPath.item) * angleOfEachCell - angle + angleOfEachCell / 2 - startAnglePrivate)) 131 | let deltaY = (radius * sin(CGFloat(indexPath.item) * angleOfEachCell - angle + angleOfEachCell/2 - startAnglePrivate)) 132 | let x = center.x + offset + deltaX 133 | let y = center.y - deltaY 134 | 135 | let cellAngle = CGFloat(indexPath.item) * angleOfEachCell + angleOfEachCell / 2 - angle 136 | 137 | if cellAngle >= -angleOfEachCell/2 && cellAngle <= (abs(startAnglePrivate - endAnglePrivate) + angleOfEachCell / 2) { 138 | attributes.alpha = 1 139 | } else { 140 | attributes.alpha = 0 141 | } 142 | 143 | attributes.center = CGPoint(x: x, y: y) 144 | attributes.zIndex = numberOfCells - indexPath.item 145 | 146 | if rotateCells { 147 | attributes.transform = CGAffineTransform(rotationAngle: -1 * cellAngle ) 148 | } 149 | 150 | return attributes 151 | } 152 | 153 | fileprivate func layoutAttributesForClockwiseScrollForItem(at indexPath : IndexPath) -> UICollectionViewLayoutAttributes { 154 | 155 | let attributes = UICollectionViewLayoutAttributes(forCellWith: indexPath) 156 | 157 | var offset: CGFloat = (self.collectionView?.contentOffset.y)! 158 | offset = (offset != 0) ? offset : 1 159 | 160 | let offsetInAngle = offset / totalCircleLength 161 | let angle = 2 * .pi * offsetInAngle 162 | attributes.size = cellSize 163 | 164 | let deltaX = (radius * cos(CGFloat(indexPath.item) * angleOfEachCell - angle + angleOfEachCell / 2 - startAnglePrivate)) 165 | let deltaY = (radius * sin(CGFloat(indexPath.item) * angleOfEachCell - angle + angleOfEachCell / 2 - startAnglePrivate)) 166 | let x = center.x + deltaX 167 | let y = center.y + offset + deltaY 168 | 169 | let cellAngle = CGFloat(indexPath.item) * angleOfEachCell + angleOfEachCell / 2 - angle 170 | 171 | if cellAngle >= -angleOfEachCell/2 && cellAngle <= (abs(startAnglePrivate - endAnglePrivate) + angleOfEachCell / 2) { 172 | attributes.alpha = 1 173 | } else { 174 | attributes.alpha = 0 175 | } 176 | 177 | attributes.center = CGPoint(x: x, y: y) 178 | attributes.zIndex = numberOfCells - indexPath.item 179 | 180 | if rotateCells { 181 | attributes.transform = CGAffineTransform(rotationAngle: cellAngle - (.pi / 2)) 182 | } 183 | 184 | return attributes 185 | } 186 | 187 | 188 | override func layoutAttributesForElements(in rect: CGRect) -> [UICollectionViewLayoutAttributes]? { 189 | 190 | var attributes = [UICollectionViewLayoutAttributes]() 191 | 192 | for i in 0.. UICollectionViewLayoutAttributes? { 204 | let attributes = super.initialLayoutAttributesForAppearingItem(at: itemIndexPath) 205 | attributes?.center = CGPoint(x: center.x + (self.collectionView?.contentOffset.x)!, y: center.y + (self.collectionView?.contentOffset.y)!) 206 | attributes?.alpha = 0.2 207 | attributes?.transform = CGAffineTransform(scaleX: 0.5, y: 0.5) 208 | 209 | return attributes 210 | } 211 | 212 | override func finalLayoutAttributesForDisappearingItem(at itemIndexPath: IndexPath) -> UICollectionViewLayoutAttributes? { 213 | let attributes = super.finalLayoutAttributesForDisappearingItem(at: itemIndexPath) 214 | attributes?.center = CGPoint(x: center.x + (self.collectionView?.contentOffset.x)!, y: center.y + (self.collectionView?.contentOffset.y)!) 215 | attributes?.alpha = 0.2 216 | attributes?.transform = CGAffineTransform(scaleX: 0.5, y: 0.5) 217 | 218 | return attributes 219 | } 220 | 221 | 222 | override func shouldInvalidateLayout(forBoundsChange newBounds: CGRect) -> Bool { 223 | return true 224 | } 225 | 226 | } 227 | -------------------------------------------------------------------------------- /ACBRadialCollectionView/Classes/Source/Views/ACBInternalRadialScrollBar.swift: -------------------------------------------------------------------------------- 1 | // 2 | // ACBInternalRadialScrollBar.swift 3 | // RadialCollectionView 4 | // 5 | // Created by Akhil on 1/1/17. 6 | // Copyright © 2017 Akhil. All rights reserved. 7 | // 8 | 9 | import UIKit 10 | 11 | class ACBInternalRadialScrollBar: UIView { 12 | 13 | var scrollBarBackgroundColor = UIColor.lightGray 14 | var scrollBarThumbColor = UIColor.black 15 | var arcCenter : CGPoint = CGPoint.zero 16 | var radius : CGFloat = 0.0 17 | var scrollBarDirectionClockwise : Bool = true 18 | var scrollBarBackgroundWidth : CGFloat = 8.0 19 | var scrollBarThumbWidth: CGFloat = 6.0 20 | var thumbMinimumLengthAngle: CGFloat = .pi / 50 21 | 22 | let arcDrawDirectionClockwise : Bool = false 23 | 24 | fileprivate(set) var _scrollBarThumbStartAngle : CGFloat = .pi / 20 25 | fileprivate(set) var _scrollBarThumbLengthAngle : CGFloat = .pi / 20 26 | 27 | fileprivate(set) var _scrollBarThumbEndAngle : CGFloat { 28 | get { 29 | return _scrollBarThumbStartAngle + _scrollBarThumbLengthAngle 30 | } 31 | 32 | set(newValue) { 33 | _scrollBarThumbLengthAngle = newValue - _scrollBarThumbStartAngle 34 | } 35 | } 36 | 37 | fileprivate(set) var _startAngle : CGFloat = 0.0 38 | fileprivate(set) var _endAngle : CGFloat = .pi / 2 39 | 40 | var isScrollBarVisible : Bool { 41 | return !self.isHidden 42 | } 43 | 44 | override init(frame: CGRect) { 45 | super.init(frame: frame) 46 | self.setup() 47 | } 48 | 49 | required init?(coder aDecoder: NSCoder) { 50 | super.init(coder: aDecoder) 51 | self.setup() 52 | } 53 | 54 | init(frame: CGRect, arcCenter : CGPoint, radius : CGFloat) { 55 | super.init(frame: frame) 56 | self.arcCenter = arcCenter 57 | self.radius = radius 58 | self.setup() 59 | } 60 | 61 | fileprivate func setup () { 62 | self.backgroundColor = UIColor.clear 63 | self.radius = (self.radius != 0.0 ? self.radius : self.sliderRadius()) 64 | self.isUserInteractionEnabled = false 65 | 66 | self.alpha = 0.5 67 | } 68 | 69 | func setScrollBarBackgroundAngle(startAngle : CGFloat, endAngle : CGFloat) -> Void { 70 | _startAngle = startAngle 71 | _endAngle = endAngle 72 | 73 | if _startAngle == 2 * .pi { 74 | _startAngle = 2 * .pi - .pi / 180 75 | } 76 | 77 | if _endAngle == 2 * .pi { 78 | _endAngle = 2 * .pi - .pi / 180 79 | } 80 | 81 | //reset scroll bar thumb angles and redraw 82 | if _scrollBarThumbStartAngle < _startAngle { 83 | _scrollBarThumbStartAngle = _startAngle 84 | } 85 | 86 | if _endAngle < _scrollBarThumbEndAngle { 87 | _scrollBarThumbEndAngle = _endAngle 88 | } 89 | //forces redraw 90 | setScrollBarThumbAngle(thumbStartAngle: _scrollBarThumbStartAngle, thumbLengthAngle: _scrollBarThumbLengthAngle) 91 | } 92 | 93 | 94 | func setScrollBarThumbAngle(thumbStartAngle : CGFloat, thumbLengthAngle : CGFloat) -> Void { 95 | 96 | guard thumbStartAngle >= _startAngle && _endAngle >= thumbStartAngle + thumbLengthAngle else { 97 | return 98 | } 99 | 100 | _scrollBarThumbStartAngle = thumbStartAngle 101 | _scrollBarThumbLengthAngle = thumbLengthAngle 102 | 103 | if _scrollBarThumbStartAngle == 2 * .pi { 104 | _scrollBarThumbStartAngle = 2 * .pi - .pi / 180 105 | } 106 | 107 | if _scrollBarThumbLengthAngle == 2 * .pi { 108 | _scrollBarThumbLengthAngle = 2 * .pi - .pi / 180 109 | } 110 | 111 | self.setNeedsDisplay() 112 | } 113 | 114 | 115 | override func draw(_ rect: CGRect) { 116 | 117 | // Drawing code 118 | guard let context = UIGraphicsGetCurrentContext() else { return } 119 | context.setLineWidth(scrollBarBackgroundWidth) 120 | context.setLineCap(CGLineCap.round) 121 | context.setLineJoin(CGLineJoin.round) 122 | if radius == 0.0 { 123 | radius = sliderRadius() 124 | } 125 | 126 | context.setStrokeColor(scrollBarBackgroundColor.cgColor) 127 | drawBackground(withRadius: radius, inContext: context) 128 | 129 | context.setLineWidth(scrollBarThumbWidth) 130 | context.setStrokeColor(scrollBarThumbColor.cgColor) 131 | drawScrollBarThumb(withRadius: radius, inContext: context) 132 | } 133 | 134 | fileprivate func drawBackground(withRadius radius : CGFloat, inContext context : CGContext) { 135 | drawScrollBar(withRadius: radius, startAngle: _startAngle, endAngle: _endAngle, clockwise: arcDrawDirectionClockwise, inContext: context) 136 | } 137 | 138 | fileprivate func drawScrollBarThumb(withRadius radius : CGFloat, inContext context : CGContext) { 139 | let (scrollBarThumbStartAngle, scrollBarThumbEndAngle) = calculateThumbAngle() 140 | drawScrollBar(withRadius: radius, startAngle: scrollBarThumbStartAngle, endAngle: scrollBarThumbEndAngle, clockwise: arcDrawDirectionClockwise, inContext: context) 141 | } 142 | 143 | 144 | fileprivate func drawScrollBar(withRadius radius : CGFloat, startAngle: CGFloat, endAngle : CGFloat, clockwise : Bool, inContext context : CGContext) { 145 | UIGraphicsPushContext(context) 146 | context.beginPath() 147 | context.addArc(center: arcCenter, radius: radius, startAngle: startAngle, endAngle: endAngle, clockwise: clockwise) 148 | context.strokePath() 149 | UIGraphicsPopContext() 150 | } 151 | 152 | fileprivate func sliderRadius() -> CGFloat { 153 | var radius = min(self.bounds.size.width / 2, self.bounds.size.height / 2) 154 | radius -= max(scrollBarBackgroundWidth, scrollBarThumbWidth) 155 | return radius 156 | } 157 | 158 | fileprivate func calculateThumbAngle() -> (scrollBarThumbStartAngle : CGFloat, scrollBarThumbEndAngle : CGFloat) { 159 | var scrollBarThumbStartAngle = _scrollBarThumbStartAngle 160 | var scrollBarThumbEndAngle = _scrollBarThumbEndAngle 161 | 162 | if !scrollBarDirectionClockwise { //invert angle 163 | let diff = _scrollBarThumbStartAngle - _startAngle 164 | scrollBarThumbStartAngle = _endAngle - diff - _scrollBarThumbLengthAngle 165 | scrollBarThumbEndAngle = scrollBarThumbStartAngle + _scrollBarThumbLengthAngle 166 | } 167 | 168 | return (scrollBarThumbStartAngle, scrollBarThumbEndAngle) 169 | } 170 | } 171 | -------------------------------------------------------------------------------- /ACBRadialCollectionView/Classes/Source/Views/ACBRadialScrollBar.swift: -------------------------------------------------------------------------------- 1 | // 2 | // ACBRadialScrollBar.swift 3 | // RadialCollectionView 4 | // 5 | // Created by Akhil on 12/29/16. 6 | // Copyright © 2016 Akhil. All rights reserved. 7 | // 8 | 9 | import UIKit 10 | 11 | class ACBRadialScrollBar: ACBInternalRadialScrollBar { 12 | 13 | private(set) var targetScrollView : UIScrollView? 14 | var minScrollBarLinearLength : CGFloat = 30.0 15 | private var fadingScrollBarTimer : Timer? 16 | var shouldHideScrollBar : Bool = true 17 | 18 | var contentHeight : CGFloat { 19 | if !scrollBarDirectionClockwise { 20 | return self.targetScrollView?.contentSize.width ?? 0.0 21 | } 22 | return self.targetScrollView?.contentSize.height ?? 0.0 23 | } 24 | 25 | var frameHeight : CGFloat { 26 | if !scrollBarDirectionClockwise { 27 | return self.targetScrollView?.frame.size.width ?? 0.0 28 | } 29 | return self.targetScrollView?.frame.size.height ?? 0.0 30 | } 31 | 32 | /// Calculate the current scroll value 33 | var currentScrollValue : CGFloat { 34 | guard (self.contentHeight != self.frameHeight) else { 35 | return 0 36 | } 37 | 38 | if !scrollBarDirectionClockwise { 39 | let contentOffsetX = self.targetScrollView?.contentOffset.x ?? 0 40 | return (contentOffsetX / (self.contentHeight - self.frameHeight)) 41 | } 42 | 43 | let contentOffsetY = self.targetScrollView?.contentOffset.y ?? 0 44 | return (contentOffsetY / (self.contentHeight - self.frameHeight)) 45 | } 46 | 47 | //calculated based on scroll view 48 | var handleLengthAngle : CGFloat { 49 | 50 | var angle = ((self.frameHeight / self.contentHeight) * (_endAngle - _startAngle)) 51 | angle = ACBRadialScrollBar.snapToValue(angle, low: thumbMinimumLengthAngle, high: (_endAngle - _startAngle)) 52 | return angle 53 | } 54 | 55 | convenience init(frame: CGRect, arcCenter : CGPoint, radius : CGFloat, targetScrollView : UIScrollView) { 56 | self.init(frame: frame, arcCenter : arcCenter, radius : radius) 57 | self.targetScrollView = targetScrollView 58 | self.setupTargetScrollView() 59 | } 60 | 61 | convenience init(frame: CGRect, arcCenter : CGPoint, radius : CGFloat, startAngle : CGFloat, endAngle : CGFloat, targetScrollView : UIScrollView) { 62 | self.init(frame: frame, arcCenter : arcCenter, radius : radius) 63 | self.targetScrollView = targetScrollView 64 | var tempEndAngle = endAngle 65 | if endAngle == 0.0 { 66 | tempEndAngle = 2 * .pi 67 | } else if startAngle != 0.0 && endAngle < startAngle { 68 | tempEndAngle = endAngle + 2 * .pi 69 | } 70 | 71 | self.setScrollBarBackgroundAngle(startAngle: startAngle, endAngle: tempEndAngle) 72 | self.setupTargetScrollView() 73 | } 74 | 75 | deinit { 76 | self.targetScrollView?.removeObserver(self, Key: .contentOffset) 77 | self.targetScrollView?.removeObserver(self, Key: .contentSize) 78 | } 79 | 80 | override open func observeValue(forKeyPath keyPath: String?, of object: Any?, change: [NSKeyValueChangeKey : Any]?, context: UnsafeMutableRawPointer?) { 81 | 82 | guard (object as? UIScrollView) == self.targetScrollView else { 83 | return 84 | } 85 | 86 | let aKeyPath = UIScrollView.ObserverKeys.contentOffset.rawValue 87 | 88 | if keyPath == aKeyPath { 89 | viewDidScroll() 90 | } else { 91 | reloadScrollBar() 92 | } 93 | } 94 | 95 | fileprivate func setupTargetScrollView() { 96 | self.targetScrollView?.addObserver(self, Key: .contentOffset) 97 | self.targetScrollView?.addObserver(self, Key: .contentSize) 98 | 99 | let arcAngle = minScrollBarLinearLength / radius 100 | thumbMinimumLengthAngle = arcAngle 101 | 102 | self.reloadScrollBar() 103 | } 104 | 105 | fileprivate func reloadScrollBar() { 106 | 107 | guard (self.contentHeight >= self.frameHeight && self.targetScrollView?.isScrollEnabled == true) else { 108 | self.isHidden = true 109 | return 110 | } 111 | 112 | CATransaction.begin() 113 | CATransaction.setDisableActions(true) 114 | 115 | let scrollValue = self.currentScrollValue 116 | var thumbLengthAngle = self.handleLengthAngle 117 | 118 | var thumbAngle = (scrollValue * (_endAngle - _startAngle)) + _startAngle - (scrollValue * thumbLengthAngle) 119 | calculateThumbAngleAndLengthAngleFor(thumbAngle: &thumbAngle, thumbLengthAngle: &thumbLengthAngle) 120 | 121 | //internally will call setNeedsDisplay 122 | self.setScrollBarThumbAngle(thumbStartAngle : thumbAngle, thumbLengthAngle : thumbLengthAngle) 123 | self.isHidden = (thumbLengthAngle == _endAngle - _startAngle) 124 | CATransaction.commit() 125 | } 126 | 127 | fileprivate func calculateThumbAngleAndLengthAngleFor(thumbAngle : inout CGFloat, thumbLengthAngle : inout CGFloat) { 128 | 129 | let diffFactor = ((_endAngle - _startAngle) / thumbLengthAngle) 130 | 131 | if thumbAngle < _startAngle { 132 | let diff = (_startAngle - thumbAngle) * diffFactor 133 | 134 | if thumbLengthAngle <= diff { 135 | thumbLengthAngle = .pi / 100 136 | } else { 137 | thumbLengthAngle = thumbLengthAngle - diff 138 | } 139 | thumbAngle = _startAngle 140 | 141 | } 142 | 143 | if thumbAngle + thumbLengthAngle > _endAngle { 144 | let diff = (thumbAngle + thumbLengthAngle - _endAngle) * diffFactor 145 | 146 | if thumbLengthAngle <= diff { 147 | thumbLengthAngle = .pi / 100 148 | thumbAngle = _endAngle - thumbLengthAngle 149 | } else { 150 | thumbLengthAngle = thumbLengthAngle - diff 151 | thumbAngle = thumbAngle + diff 152 | } 153 | } 154 | 155 | thumbAngle = ACBRadialScrollBar.snapToValue(thumbAngle, low: _startAngle, high: _endAngle - thumbLengthAngle) 156 | } 157 | 158 | fileprivate func viewDidScroll() { 159 | 160 | if shouldHideScrollBar == true { 161 | 162 | fadingScrollBarTimer?.invalidate() 163 | 164 | if self.alpha != 0.5 { 165 | UIView.animate(withDuration: 0.3, animations: { 166 | self.alpha = 0.5 167 | }) 168 | } 169 | 170 | reloadScrollBar() 171 | 172 | fadingScrollBarTimer = Timer(timeInterval: 0.1, repeats: false, block: { (_) in 173 | UIView.animate(withDuration: 0.3, animations: { 174 | self.alpha = 0.0 175 | }) 176 | }) 177 | RunLoop.main.add(fadingScrollBarTimer!, forMode: .common) 178 | } else { 179 | reloadScrollBar() 180 | } 181 | } 182 | } 183 | 184 | 185 | private extension ACBRadialScrollBar { 186 | 187 | static func snapToValue(_ value:CGFloat, low:CGFloat, high:CGFloat) -> CGFloat { 188 | if value > high { 189 | return high 190 | } else if low > value { 191 | return low 192 | } else { 193 | return value 194 | } 195 | } 196 | 197 | static func translateValueFromSourceIntervalToDestinationInterval(sourceValue : CGFloat, 198 | sourceIntervalMinimum : CGFloat, 199 | sourceIntervalMaximum : CGFloat, 200 | destinationIntervalMinimum : CGFloat, 201 | destinationIntervalMaximum : CGFloat) -> CGFloat { 202 | 203 | var a, b, destinationValue : CGFloat 204 | 205 | a = (destinationIntervalMaximum - destinationIntervalMinimum) / (sourceIntervalMaximum - sourceIntervalMinimum) 206 | b = destinationIntervalMaximum - a * sourceIntervalMaximum 207 | destinationValue = a * sourceValue + b 208 | return destinationValue 209 | } 210 | 211 | static func angleBetweenThreePoints(centerPoint : CGPoint, p1 : CGPoint, p2 : CGPoint) -> CGFloat { 212 | 213 | let v1 = CGPoint(x: p1.x - centerPoint.x, y: p1.y - centerPoint.y) 214 | let v2 = CGPoint(x: p2.x - centerPoint.x, y: p2.y - centerPoint.y) 215 | 216 | let angle : CGFloat = atan2(v2.x * v1.y - v1.x * v2.y, v1.x * v2.x + v1.y * v2.y) 217 | return angle 218 | } 219 | } 220 | 221 | 222 | protocol ACBKeycodable { 223 | associatedtype ObserverKeys : RawRepresentable 224 | } 225 | 226 | 227 | extension UIScrollView : ACBKeycodable { 228 | 229 | var KVOOptions : NSKeyValueObservingOptions { 230 | return NSKeyValueObservingOptions([.new, .old, .prior]) 231 | } 232 | 233 | enum ObserverKeys : String { 234 | case contentOffset 235 | case contentSize 236 | } 237 | 238 | func addObserver(_ observer: NSObject, Key key: ObserverKeys) { 239 | self.addObserver(observer, forKeyPath: key.rawValue , options: KVOOptions, context: nil) 240 | } 241 | 242 | func removeObserver(_ observer: NSObject, Key key: ObserverKeys) { 243 | self.removeObserver(observer, forKeyPath: key.rawValue, context: nil) 244 | } 245 | } 246 | -------------------------------------------------------------------------------- /ACBRadialCollectionView/Classes/Viewcontrollers/ACBViewController.swift: -------------------------------------------------------------------------------- 1 | // 2 | // ACBViewController.swift 3 | // ACBRadialCollectionView 4 | // 5 | // Created by Akhil on 5/21/17. 6 | // Copyright © 2017 akhil. All rights reserved. 7 | // 8 | 9 | import UIKit 10 | 11 | class ACBViewController: UIViewController { 12 | 13 | let reuseIdentifier1 = "cell1" 14 | let reuseIdentifier2 = "cell2" 15 | let reuseIdentifier3 = "cell3" 16 | 17 | fileprivate var datasourceArray1: [String] = [] 18 | fileprivate var datasourceArray2: [String] = [] 19 | fileprivate var datasourceArray3: [String] = [] 20 | 21 | fileprivate var itemRadius: CGFloat = 50 22 | fileprivate var arcRadius: CGFloat = 100 23 | fileprivate var center = CGPoint(x: 50, y: 100) 24 | fileprivate var startAngle = CGFloat(0) 25 | fileprivate var endAngle = CGFloat.pi / 2 26 | fileprivate var rotateCells = true 27 | 28 | @IBOutlet weak var collectionView1: UICollectionView? 29 | @IBOutlet weak var collectionView2: UICollectionView? 30 | @IBOutlet weak var collectionView3: UICollectionView? 31 | 32 | @IBOutlet weak var rotateFirstCVSwitch: UISwitch? 33 | @IBOutlet weak var rotateSecondCVSwitch: UISwitch? 34 | @IBOutlet weak var rotateThirdCVSwitch: UISwitch? 35 | 36 | @IBOutlet weak var changeAngleSegmentedControl: UISegmentedControl? 37 | 38 | 39 | override func viewDidLoad() { 40 | super.viewDidLoad() 41 | 42 | for i in 1...1000 { 43 | datasourceArray1.append(String(i)) 44 | } 45 | datasourceArray2 = datasourceArray1 46 | datasourceArray3 = datasourceArray1 47 | 48 | setupCollectionView1() 49 | setupCollectionView2() 50 | setupCollectionView3() 51 | 52 | updateSwitches() 53 | } 54 | 55 | 56 | fileprivate func setupCollectionView1() { 57 | let center = self.center 58 | let radius = self.arcRadius 59 | let cellSize = CGSize(width: itemRadius, height: itemRadius) 60 | let startAngle = self.startAngle 61 | let endAngle = self.endAngle 62 | let direction = ACBRadialCollectionViewScrollDirection.clockwise 63 | 64 | self.collectionView1?.enableRadialLayout(WithCenter: center, radius: radius, cellSize: cellSize, angularSpacing: 20.0, scrollDirection: direction, startAngle: startAngle, endAngle: endAngle) 65 | 66 | self.collectionView1?.applyRotationToCells = rotateCells 67 | } 68 | 69 | 70 | fileprivate func setupCollectionView2() { 71 | let center = self.center 72 | let radius = self.arcRadius + CGFloat(20.0) + itemRadius 73 | let cellSize = CGSize(width: itemRadius, height: itemRadius) 74 | let startAngle = self.startAngle 75 | let endAngle = self.endAngle 76 | let direction = ACBRadialCollectionViewScrollDirection.anticlockwise 77 | 78 | self.collectionView2?.enableRadialLayout(WithCenter: center, radius: radius, cellSize: cellSize, angularSpacing: 20.0, scrollDirection: direction, startAngle: startAngle, endAngle: endAngle) 79 | 80 | self.collectionView2?.applyRotationToCells = rotateCells 81 | } 82 | 83 | fileprivate func setupCollectionView3() { 84 | let center = self.center 85 | let radius = self.arcRadius + CGFloat(2 * 20) + (2 * itemRadius) 86 | let cellSize = CGSize(width: itemRadius, height: itemRadius) 87 | let startAngle = self.startAngle 88 | let endAngle = self.endAngle 89 | let direction = ACBRadialCollectionViewScrollDirection.clockwise 90 | 91 | self.collectionView3?.enableRadialLayout(WithCenter: center, radius: radius, cellSize: cellSize, angularSpacing: 20.0, scrollDirection: direction, startAngle: startAngle, endAngle: endAngle) 92 | 93 | self.collectionView3?.applyRotationToCells = rotateCells 94 | } 95 | 96 | 97 | fileprivate func setupDefaultCenterRadius() { 98 | center = CGPoint(x: 50, y: 100) 99 | startAngle = CGFloat(0) 100 | endAngle = CGFloat.pi / 2 101 | rotateCells = true 102 | } 103 | 104 | 105 | fileprivate func setupSecondCenterRadius() { 106 | center = CGPoint(x: 90, y: 350) 107 | startAngle = 3 * CGFloat.pi / 2 108 | endAngle = 2 * CGFloat.pi 109 | rotateCells = false 110 | } 111 | 112 | fileprivate func setupThirdCenterRadius() { 113 | center = CGPoint(x: 330, y: 350) 114 | startAngle = CGFloat.pi 115 | endAngle = 3 * CGFloat.pi / 2 116 | rotateCells = true 117 | } 118 | 119 | 120 | fileprivate func setupFourthCenterRadius() { 121 | center = CGPoint(x: 330, y: 100) 122 | startAngle = CGFloat.pi / 2 123 | endAngle = CGFloat.pi 124 | rotateCells = false 125 | } 126 | 127 | 128 | fileprivate func setupFifthCenterRadius() { 129 | center = CGPoint(x: 135, y: 450) 130 | startAngle = 4 * CGFloat.pi / 3 131 | endAngle = 11 * CGFloat.pi / 6 132 | rotateCells = false 133 | } 134 | 135 | 136 | fileprivate func updateSwitches() { 137 | self.rotateFirstCVSwitch?.isOn = (self.collectionView1?.applyRotationToCells)! 138 | self.rotateSecondCVSwitch?.isOn = (self.collectionView2?.applyRotationToCells)! 139 | self.rotateThirdCVSwitch?.isOn = (self.collectionView3?.applyRotationToCells)! 140 | } 141 | 142 | @IBAction fileprivate func segmentChanged(_ sender: Any) { 143 | switch self.changeAngleSegmentedControl!.selectedSegmentIndex { 144 | case 0: 145 | self.setupDefaultCenterRadius() 146 | break 147 | case 1: 148 | self.setupSecondCenterRadius() 149 | break 150 | case 2: 151 | self.setupThirdCenterRadius() 152 | break 153 | case 3: 154 | self.setupFourthCenterRadius() 155 | break 156 | case 4: 157 | self.setupFifthCenterRadius() 158 | break 159 | default: 160 | self.setupDefaultCenterRadius() 161 | } 162 | 163 | self.setupCollectionView1() 164 | self.setupCollectionView2() 165 | self.setupCollectionView3() 166 | 167 | self.collectionView1?.reloadData() 168 | self.collectionView2?.reloadData() 169 | self.collectionView3?.reloadData() 170 | 171 | self.updateSwitches() 172 | } 173 | 174 | 175 | @IBAction fileprivate func firstSwitchChanged(_ sender: Any) { 176 | let isOn = self.rotateFirstCVSwitch!.isOn 177 | self.collectionView1?.applyRotationToCells = isOn 178 | self.collectionView1?.reloadData() 179 | } 180 | 181 | @IBAction fileprivate func secondSwitchChanged(_ sender: Any) { 182 | let isOn = self.rotateSecondCVSwitch!.isOn 183 | self.collectionView2?.applyRotationToCells = isOn 184 | self.collectionView2?.reloadData() 185 | } 186 | 187 | @IBAction fileprivate func thirdSwitchChanged(_ sender: Any) { 188 | let isOn = self.rotateThirdCVSwitch!.isOn 189 | self.collectionView3?.applyRotationToCells = isOn 190 | self.collectionView3?.reloadData() 191 | } 192 | 193 | override func didReceiveMemoryWarning() { 194 | super.didReceiveMemoryWarning() 195 | // Dispose of any resources that can be recreated. 196 | } 197 | 198 | } 199 | 200 | 201 | extension ACBViewController : UICollectionViewDataSource { 202 | 203 | // MARK: UICollectionViewDataSource 204 | 205 | func collectionView(_ collectionView: UICollectionView, 206 | numberOfItemsInSection section: Int) -> Int { 207 | return 100 208 | } 209 | 210 | func collectionView(_ collectionView: UICollectionView, 211 | cellForItemAt indexPath: IndexPath) -> UICollectionViewCell { 212 | if collectionView == self.collectionView1 { 213 | let cell = collectionView.dequeueReusableCell(withReuseIdentifier: reuseIdentifier1, for: indexPath) as! ACBCollectionViewCell 214 | cell.label?.text = datasourceArray1[indexPath.row] 215 | 216 | return cell 217 | } else if collectionView == self.collectionView2 { 218 | let cell = collectionView.dequeueReusableCell(withReuseIdentifier: reuseIdentifier2, for: indexPath) as! ACBCollectionViewCell 219 | cell.label?.text = datasourceArray2[indexPath.row] 220 | 221 | return cell 222 | } else { 223 | let cell = collectionView.dequeueReusableCell(withReuseIdentifier: reuseIdentifier3, for: indexPath) as! ACBCollectionViewCell 224 | cell.label?.text = datasourceArray3[indexPath.row] 225 | 226 | return cell 227 | } 228 | 229 | 230 | } 231 | } 232 | 233 | 234 | extension ACBViewController: UICollectionViewDelegate { 235 | 236 | func collectionView(_ collectionView: UICollectionView, didSelectItemAt indexPath: IndexPath) { 237 | print("Tapped on \(indexPath)") 238 | } 239 | } 240 | -------------------------------------------------------------------------------- /ACBRadialCollectionView/Classes/Views/ACBCollectionViewCell.swift: -------------------------------------------------------------------------------- 1 | // 2 | // ACBCollectionViewCell.swift 3 | // RadialCollectionView 4 | // 5 | // Created by Akhil on 11/26/16. 6 | // Copyright © 2016 Akhil. All rights reserved. 7 | // 8 | 9 | import UIKit 10 | 11 | class ACBCollectionViewCell: UICollectionViewCell { 12 | 13 | @IBOutlet weak var label: UILabel! 14 | 15 | override var bounds : CGRect { 16 | didSet { 17 | self.layoutIfNeeded() 18 | } 19 | } 20 | 21 | override func layoutSubviews() { 22 | super.layoutSubviews() 23 | 24 | self.makeItCircle() 25 | } 26 | 27 | func makeItCircle() { 28 | self.label.layer.masksToBounds = true 29 | self.label.layer.cornerRadius = CGFloat(round(self.label.frame.size.width / 2.0)) 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /ACBRadialCollectionView/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | $(PRODUCT_BUNDLE_IDENTIFIER) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | $(PRODUCT_NAME) 15 | CFBundlePackageType 16 | APPL 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleVersion 20 | 1 21 | LSRequiresIPhoneOS 22 | 23 | UILaunchStoryboardName 24 | LaunchScreen 25 | UIMainStoryboardFile 26 | Main 27 | UIRequiredDeviceCapabilities 28 | 29 | armv7 30 | 31 | UISupportedInterfaceOrientations 32 | 33 | UIInterfaceOrientationPortrait 34 | UIInterfaceOrientationLandscapeLeft 35 | UIInterfaceOrientationLandscapeRight 36 | 37 | UISupportedInterfaceOrientations~ipad 38 | 39 | UIInterfaceOrientationPortrait 40 | UIInterfaceOrientationPortraitUpsideDown 41 | UIInterfaceOrientationLandscapeLeft 42 | UIInterfaceOrientationLandscapeRight 43 | 44 | 45 | 46 | -------------------------------------------------------------------------------- /ACBRadialCollectionView/Screenshots/ACBRadialCVgif1.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/akhilcb/ACBRadialCollectionView/cd9994d195866342cc029dece8853842c7bd067d/ACBRadialCollectionView/Screenshots/ACBRadialCVgif1.gif -------------------------------------------------------------------------------- /ACBRadialCollectionView/Screenshots/ACBRadialCVgif2.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/akhilcb/ACBRadialCollectionView/cd9994d195866342cc029dece8853842c7bd067d/ACBRadialCollectionView/Screenshots/ACBRadialCVgif2.gif -------------------------------------------------------------------------------- /ACBRadialCollectionView/Screenshots/ACBRadialCVgif3.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/akhilcb/ACBRadialCollectionView/cd9994d195866342cc029dece8853842c7bd067d/ACBRadialCollectionView/Screenshots/ACBRadialCVgif3.gif -------------------------------------------------------------------------------- /ACBRadialCollectionView/Screenshots/ACBRadialCollectionViewFirst.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/akhilcb/ACBRadialCollectionView/cd9994d195866342cc029dece8853842c7bd067d/ACBRadialCollectionView/Screenshots/ACBRadialCollectionViewFirst.png -------------------------------------------------------------------------------- /ACBRadialCollectionView/Screenshots/ACBRadialCollectionViewSecond.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/akhilcb/ACBRadialCollectionView/cd9994d195866342cc029dece8853842c7bd067d/ACBRadialCollectionView/Screenshots/ACBRadialCollectionViewSecond.png -------------------------------------------------------------------------------- /ACBRadialCollectionView/Screenshots/ACBRadialCollectionViewThird.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/akhilcb/ACBRadialCollectionView/cd9994d195866342cc029dece8853842c7bd067d/ACBRadialCollectionView/Screenshots/ACBRadialCollectionViewThird.png -------------------------------------------------------------------------------- /ACBRadialCollectionViewFramework/ACBRadialCollectionViewFramework.h: -------------------------------------------------------------------------------- 1 | // 2 | // ACBRadialCollectionViewFramework.h 3 | // ACBRadialCollectionViewFramework 4 | // 5 | // Created by Akhil C Balan on 1/8/18. 6 | // Copyright © 2018 akhil. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | //! Project version number for ACBRadialCollectionViewFramework. 12 | FOUNDATION_EXPORT double ACBRadialCollectionViewFrameworkVersionNumber; 13 | 14 | //! Project version string for ACBRadialCollectionViewFramework. 15 | FOUNDATION_EXPORT const unsigned char ACBRadialCollectionViewFrameworkVersionString[]; 16 | 17 | 18 | -------------------------------------------------------------------------------- /ACBRadialCollectionViewFramework/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | $(DEVELOPMENT_LANGUAGE) 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | $(PRODUCT_BUNDLE_IDENTIFIER) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | $(PRODUCT_NAME) 15 | CFBundlePackageType 16 | FMWK 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleVersion 20 | $(CURRENT_PROJECT_VERSION) 21 | NSPrincipalClass 22 | 23 | 24 | 25 | -------------------------------------------------------------------------------- /ACBRadialCollectionViewFrameworkTests/ACBRadialCollectionViewFrameworkTests.m: -------------------------------------------------------------------------------- 1 | // 2 | // ACBRadialCollectionViewFrameworkTests.m 3 | // ACBRadialCollectionViewFrameworkTests 4 | // 5 | // Created by Akhil C Balan on 1/8/18. 6 | // Copyright © 2018 akhil. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface ACBRadialCollectionViewFrameworkTests : XCTestCase 12 | 13 | @end 14 | 15 | @implementation ACBRadialCollectionViewFrameworkTests 16 | 17 | - (void)setUp { 18 | [super setUp]; 19 | // Put setup code here. This method is called before the invocation of each test method in the class. 20 | } 21 | 22 | - (void)tearDown { 23 | // Put teardown code here. This method is called after the invocation of each test method in the class. 24 | [super tearDown]; 25 | } 26 | 27 | - (void)testExample { 28 | // This is an example of a functional test case. 29 | // Use XCTAssert and related functions to verify your tests produce the correct results. 30 | } 31 | 32 | - (void)testPerformanceExample { 33 | // This is an example of a performance test case. 34 | [self measureBlock:^{ 35 | // Put the code you want to measure the time of here. 36 | }]; 37 | } 38 | 39 | @end 40 | -------------------------------------------------------------------------------- /ACBRadialCollectionViewFrameworkTests/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | $(DEVELOPMENT_LANGUAGE) 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | $(PRODUCT_BUNDLE_IDENTIFIER) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | $(PRODUCT_NAME) 15 | CFBundlePackageType 16 | BNDL 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleVersion 20 | 1 21 | 22 | 23 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2017, Akhil C Balan(https://github.com/akhilcb) 4 | 5 | All rights reserved 6 | 7 | Permission is hereby granted, free of charge, to any person obtaining a copy 8 | of this software and associated documentation files (the "Software"), to deal 9 | in the Software without restriction, including without limitation the rights 10 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 11 | copies of the Software, and to permit persons to whom the Software is 12 | furnished to do so, subject to the following conditions: 13 | 14 | The above copyright notice and this permission notice shall be included in all 15 | copies or substantial portions of the Software. 16 | 17 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 18 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 19 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 20 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 21 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 22 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 23 | SOFTWARE. 24 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # ACBRadialCollectionView 2 | 3 | [![CocoaPods Compatible](https://img.shields.io/cocoapods/v/ACBRadialCollectionView.svg)](https://img.shields.io/cocoapods/v/ACBRadialCollectionView.svg) 4 | [![Carthage Compatible](https://img.shields.io/badge/Carthage-compatible-4BC51D.svg?style=flat)](https://github.com/Carthage/Carthage) 5 | [![Platform](https://img.shields.io/cocoapods/p/ACBRadialCollectionView.svg?style=flat)](https://github.com/akhilcb/ACBRadialCollectionView) 6 | [![License](https://img.shields.io/cocoapods/l/ACBRadialCollectionView.svg?style=flat)](http://cocoapods.org/pods/ACBRadialCollectionView) 7 | 8 | 9 | This is an extension on UICollectionView which automatically transforms collection view cells to a radial path with minimal code. 10 | This is written in Swift language. No need to subclass UICollectionView for this. CollectionView will also display an arc shaped scroll bar next to the cells which acts similar to the normal scroll bar. 11 | 12 | Using this approach, we can support multiple collectionviews on one screen as shown below(_Note: number of sections should be 1 for all collection views_). Each will have its own scrolling and scroll direction can also be changed for each of them separately. 13 | 14 | ## Demo 15 | 16 |
17 | 18 | 19 | 20 |
21 |
22 | 23 |

24 | 25 | ## Setup 26 | 27 | Carthage or Cocoapods can be used to integrate this to a project. 28 | 29 | ### Carthage 30 | 31 | ``` 32 | github "akhilcb/ACBRadialCollectionView" ~> 2.0 33 | 34 | ``` 35 | 36 | ### Cocoapods 37 | 38 | ``` 39 | pod 'ACBRadialCollectionView' 40 | 41 | ``` 42 | 43 | This can be manually integrated to the project by following the code in __ACBViewController__. 44 | 45 | 1. Copy all files to your Xcode project. "UICollectionView+ACBRadialCollectionView" is the extension class file. 46 | 2. Invoke the method "enableRadialLayout" on your UICollectionView with required input params. 47 | 48 | For eg:- 49 | 50 | let center = CGPoint(x: 50, y: 100) 51 | let radius: CGFloat = 100 52 | let cellSize = CGSize(width: 50, height: 50) 53 | let startAngle = CGFloat(0) 54 | let endAngle = CGFloat.pi / 2 55 | let direction = ACBRadialCollectionViewScrollDirection.clockwise 56 | 57 | self.collectionView.enableRadialLayout(WithCenter: center, radius: radius, cellSize: cellSize, angularSpacing: 20.0, scrollDirection: direction, startAngle: startAngle, endAngle: endAngle) //repeat this for other collectionviews too 58 | 59 | You can also control whether the cells needs to be rotated to an angle(_Note: This works only if you have called enableRadialLayout before setting this, default value is true_). 60 | 61 | self.collectionView.applyRotationToCells = false 62 | 63 | ## Screenshots 64 | 65 |
66 | 67 | 68 | 69 |
70 |
71 | 72 | ## License 73 | 74 | MIT License 75 | 76 | Copyright (c) 2017, Akhil C Balan(https://github.com/akhilcb) 77 | 78 | All rights reserved. 79 | --------------------------------------------------------------------------------