├── README.md └── TableviewFlip ├── 0.jpg ├── 0.png ├── 1.jpg ├── 1.png ├── 3.jpg ├── 4.jpg ├── TableviewFlip.xcodeproj ├── project.pbxproj ├── project.xcworkspace │ ├── contents.xcworkspacedata │ └── xcuserdata │ │ └── jimmy.xcuserdatad │ │ └── UserInterfaceState.xcuserstate └── xcuserdata │ └── jimmy.xcuserdatad │ └── xcschemes │ ├── TableviewFlip.xcscheme │ └── xcschememanagement.plist ├── TableviewFlip ├── AppDelegate.h ├── AppDelegate.m ├── Images.xcassets │ ├── AppIcon.appiconset │ │ └── Contents.json │ └── LaunchImage.launchimage │ │ └── Contents.json ├── TableviewFlip-Info.plist ├── TableviewFlip-Prefix.pch ├── en.lproj │ └── InfoPlist.strings └── main.m ├── TableviewFlipTests ├── TableviewFlipTests-Info.plist ├── TableviewFlipTests.m └── en.lproj │ └── InfoPlist.strings ├── ViewController.h ├── ViewController.m └── ViewController.xib /README.md: -------------------------------------------------------------------------------- 1 | TableViewCellFlip 2 | ===================== 3 | 4 | Vertical and Horizontal flip animation for table view cell 5 | 6 | 7 | ---------- 8 | 9 | Screenshots 10 | --------- 11 | 12 | 13 | ![TableViewCellFlip Screenshot](http://i61.tinypic.com/sqh9n8.gif) 14 | 15 | ---------- 16 | 17 | Sample code 18 | --------- 19 | 20 | Demo project added to get you started 21 | 22 | 23 | ---------- 24 | 25 | 26 | Contact Us 27 | --------------- 28 | 29 | Have any questions or suggestions feel free to write at jimmy@varshyl.com (Jimmy Jose) 30 | http://www.varshylmobile.com/ -------------------------------------------------------------------------------- /TableviewFlip/0.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jimmyjose-dev/TableViewCellFlip/ff11140dcdfa3499cc43b4501b5353c42ceafc00/TableviewFlip/0.jpg -------------------------------------------------------------------------------- /TableviewFlip/0.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jimmyjose-dev/TableViewCellFlip/ff11140dcdfa3499cc43b4501b5353c42ceafc00/TableviewFlip/0.png -------------------------------------------------------------------------------- /TableviewFlip/1.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jimmyjose-dev/TableViewCellFlip/ff11140dcdfa3499cc43b4501b5353c42ceafc00/TableviewFlip/1.jpg -------------------------------------------------------------------------------- /TableviewFlip/1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jimmyjose-dev/TableViewCellFlip/ff11140dcdfa3499cc43b4501b5353c42ceafc00/TableviewFlip/1.png -------------------------------------------------------------------------------- /TableviewFlip/3.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jimmyjose-dev/TableViewCellFlip/ff11140dcdfa3499cc43b4501b5353c42ceafc00/TableviewFlip/3.jpg -------------------------------------------------------------------------------- /TableviewFlip/4.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jimmyjose-dev/TableViewCellFlip/ff11140dcdfa3499cc43b4501b5353c42ceafc00/TableviewFlip/4.jpg -------------------------------------------------------------------------------- /TableviewFlip/TableviewFlip.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 46; 7 | objects = { 8 | 9 | /* Begin PBXBuildFile section */ 10 | BF317DE91992119000E3240E /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = BF317DE81992119000E3240E /* Foundation.framework */; }; 11 | BF317DEB1992119000E3240E /* CoreGraphics.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = BF317DEA1992119000E3240E /* CoreGraphics.framework */; }; 12 | BF317DED1992119000E3240E /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = BF317DEC1992119000E3240E /* UIKit.framework */; }; 13 | BF317DF31992119000E3240E /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = BF317DF11992119000E3240E /* InfoPlist.strings */; }; 14 | BF317DF51992119000E3240E /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = BF317DF41992119000E3240E /* main.m */; }; 15 | BF317DF91992119000E3240E /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = BF317DF81992119000E3240E /* AppDelegate.m */; }; 16 | BF317DFB1992119000E3240E /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = BF317DFA1992119000E3240E /* Images.xcassets */; }; 17 | BF317E021992119100E3240E /* XCTest.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = BF317E011992119100E3240E /* XCTest.framework */; }; 18 | BF317E031992119100E3240E /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = BF317DE81992119000E3240E /* Foundation.framework */; }; 19 | BF317E041992119100E3240E /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = BF317DEC1992119000E3240E /* UIKit.framework */; }; 20 | BF317E0C1992119100E3240E /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = BF317E0A1992119100E3240E /* InfoPlist.strings */; }; 21 | BF317E0E1992119100E3240E /* TableviewFlipTests.m in Sources */ = {isa = PBXBuildFile; fileRef = BF317E0D1992119100E3240E /* TableviewFlipTests.m */; }; 22 | BF317E1A199211C300E3240E /* ViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = BF317E18199211C300E3240E /* ViewController.m */; }; 23 | BF317E1B199211C300E3240E /* ViewController.xib in Resources */ = {isa = PBXBuildFile; fileRef = BF317E19199211C300E3240E /* ViewController.xib */; }; 24 | BF317E1D199214C100E3240E /* QuartzCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = BF317E1C199214C100E3240E /* QuartzCore.framework */; }; 25 | BFFC31C2199365F50066E95C /* 1.png in Resources */ = {isa = PBXBuildFile; fileRef = BFFC31C1199365F50066E95C /* 1.png */; }; 26 | BFFC31C4199366050066E95C /* 0.png in Resources */ = {isa = PBXBuildFile; fileRef = BFFC31C3199366050066E95C /* 0.png */; }; 27 | BFFC31C919936B6A0066E95C /* 0.jpg in Resources */ = {isa = PBXBuildFile; fileRef = BFFC31C519936B6A0066E95C /* 0.jpg */; }; 28 | BFFC31CA19936B6A0066E95C /* 3.jpg in Resources */ = {isa = PBXBuildFile; fileRef = BFFC31C619936B6A0066E95C /* 3.jpg */; }; 29 | BFFC31CB19936B6A0066E95C /* 1.jpg in Resources */ = {isa = PBXBuildFile; fileRef = BFFC31C719936B6A0066E95C /* 1.jpg */; }; 30 | BFFC31CC19936B6A0066E95C /* 4.jpg in Resources */ = {isa = PBXBuildFile; fileRef = BFFC31C819936B6A0066E95C /* 4.jpg */; }; 31 | /* End PBXBuildFile section */ 32 | 33 | /* Begin PBXContainerItemProxy section */ 34 | BF317E051992119100E3240E /* PBXContainerItemProxy */ = { 35 | isa = PBXContainerItemProxy; 36 | containerPortal = BF317DDD1992118F00E3240E /* Project object */; 37 | proxyType = 1; 38 | remoteGlobalIDString = BF317DE41992119000E3240E; 39 | remoteInfo = TableviewFlip; 40 | }; 41 | /* End PBXContainerItemProxy section */ 42 | 43 | /* Begin PBXFileReference section */ 44 | BF317DE51992119000E3240E /* TableviewFlip.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = TableviewFlip.app; sourceTree = BUILT_PRODUCTS_DIR; }; 45 | BF317DE81992119000E3240E /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; }; 46 | BF317DEA1992119000E3240E /* CoreGraphics.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreGraphics.framework; path = System/Library/Frameworks/CoreGraphics.framework; sourceTree = SDKROOT; }; 47 | BF317DEC1992119000E3240E /* UIKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UIKit.framework; path = System/Library/Frameworks/UIKit.framework; sourceTree = SDKROOT; }; 48 | BF317DF01992119000E3240E /* TableviewFlip-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = "TableviewFlip-Info.plist"; sourceTree = ""; }; 49 | BF317DF21992119000E3240E /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/InfoPlist.strings; sourceTree = ""; }; 50 | BF317DF41992119000E3240E /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = ""; }; 51 | BF317DF61992119000E3240E /* TableviewFlip-Prefix.pch */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "TableviewFlip-Prefix.pch"; sourceTree = ""; }; 52 | BF317DF71992119000E3240E /* AppDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = AppDelegate.h; sourceTree = ""; }; 53 | BF317DF81992119000E3240E /* AppDelegate.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = AppDelegate.m; sourceTree = ""; }; 54 | BF317DFA1992119000E3240E /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Images.xcassets; sourceTree = ""; }; 55 | BF317E001992119100E3240E /* TableviewFlipTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = TableviewFlipTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; 56 | BF317E011992119100E3240E /* XCTest.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = XCTest.framework; path = Library/Frameworks/XCTest.framework; sourceTree = DEVELOPER_DIR; }; 57 | BF317E091992119100E3240E /* TableviewFlipTests-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = "TableviewFlipTests-Info.plist"; sourceTree = ""; }; 58 | BF317E0B1992119100E3240E /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/InfoPlist.strings; sourceTree = ""; }; 59 | BF317E0D1992119100E3240E /* TableviewFlipTests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = TableviewFlipTests.m; sourceTree = ""; }; 60 | BF317E17199211C200E3240E /* ViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ViewController.h; sourceTree = ""; }; 61 | BF317E18199211C300E3240E /* ViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = ViewController.m; sourceTree = ""; }; 62 | BF317E19199211C300E3240E /* ViewController.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = ViewController.xib; sourceTree = ""; }; 63 | BF317E1C199214C100E3240E /* QuartzCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = QuartzCore.framework; path = System/Library/Frameworks/QuartzCore.framework; sourceTree = SDKROOT; }; 64 | BFFC31C1199365F50066E95C /* 1.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = 1.png; sourceTree = ""; }; 65 | BFFC31C3199366050066E95C /* 0.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = 0.png; sourceTree = ""; }; 66 | BFFC31C519936B6A0066E95C /* 0.jpg */ = {isa = PBXFileReference; lastKnownFileType = image.jpeg; path = 0.jpg; sourceTree = ""; }; 67 | BFFC31C619936B6A0066E95C /* 3.jpg */ = {isa = PBXFileReference; lastKnownFileType = image.jpeg; path = 3.jpg; sourceTree = ""; }; 68 | BFFC31C719936B6A0066E95C /* 1.jpg */ = {isa = PBXFileReference; lastKnownFileType = image.jpeg; path = 1.jpg; sourceTree = ""; }; 69 | BFFC31C819936B6A0066E95C /* 4.jpg */ = {isa = PBXFileReference; lastKnownFileType = image.jpeg; path = 4.jpg; sourceTree = ""; }; 70 | /* End PBXFileReference section */ 71 | 72 | /* Begin PBXFrameworksBuildPhase section */ 73 | BF317DE21992119000E3240E /* Frameworks */ = { 74 | isa = PBXFrameworksBuildPhase; 75 | buildActionMask = 2147483647; 76 | files = ( 77 | BF317E1D199214C100E3240E /* QuartzCore.framework in Frameworks */, 78 | BF317DEB1992119000E3240E /* CoreGraphics.framework in Frameworks */, 79 | BF317DED1992119000E3240E /* UIKit.framework in Frameworks */, 80 | BF317DE91992119000E3240E /* Foundation.framework in Frameworks */, 81 | ); 82 | runOnlyForDeploymentPostprocessing = 0; 83 | }; 84 | BF317DFD1992119100E3240E /* Frameworks */ = { 85 | isa = PBXFrameworksBuildPhase; 86 | buildActionMask = 2147483647; 87 | files = ( 88 | BF317E021992119100E3240E /* XCTest.framework in Frameworks */, 89 | BF317E041992119100E3240E /* UIKit.framework in Frameworks */, 90 | BF317E031992119100E3240E /* Foundation.framework in Frameworks */, 91 | ); 92 | runOnlyForDeploymentPostprocessing = 0; 93 | }; 94 | /* End PBXFrameworksBuildPhase section */ 95 | 96 | /* Begin PBXGroup section */ 97 | BF317DDC1992118F00E3240E = { 98 | isa = PBXGroup; 99 | children = ( 100 | BFFC31C519936B6A0066E95C /* 0.jpg */, 101 | BFFC31C619936B6A0066E95C /* 3.jpg */, 102 | BFFC31C719936B6A0066E95C /* 1.jpg */, 103 | BFFC31C819936B6A0066E95C /* 4.jpg */, 104 | BFFC31C3199366050066E95C /* 0.png */, 105 | BFFC31C1199365F50066E95C /* 1.png */, 106 | BF317E17199211C200E3240E /* ViewController.h */, 107 | BF317E18199211C300E3240E /* ViewController.m */, 108 | BF317E19199211C300E3240E /* ViewController.xib */, 109 | BF317DEE1992119000E3240E /* TableviewFlip */, 110 | BF317E071992119100E3240E /* TableviewFlipTests */, 111 | BF317DE71992119000E3240E /* Frameworks */, 112 | BF317DE61992119000E3240E /* Products */, 113 | ); 114 | sourceTree = ""; 115 | }; 116 | BF317DE61992119000E3240E /* Products */ = { 117 | isa = PBXGroup; 118 | children = ( 119 | BF317DE51992119000E3240E /* TableviewFlip.app */, 120 | BF317E001992119100E3240E /* TableviewFlipTests.xctest */, 121 | ); 122 | name = Products; 123 | sourceTree = ""; 124 | }; 125 | BF317DE71992119000E3240E /* Frameworks */ = { 126 | isa = PBXGroup; 127 | children = ( 128 | BF317E1C199214C100E3240E /* QuartzCore.framework */, 129 | BF317DE81992119000E3240E /* Foundation.framework */, 130 | BF317DEA1992119000E3240E /* CoreGraphics.framework */, 131 | BF317DEC1992119000E3240E /* UIKit.framework */, 132 | BF317E011992119100E3240E /* XCTest.framework */, 133 | ); 134 | name = Frameworks; 135 | sourceTree = ""; 136 | }; 137 | BF317DEE1992119000E3240E /* TableviewFlip */ = { 138 | isa = PBXGroup; 139 | children = ( 140 | BF317DF71992119000E3240E /* AppDelegate.h */, 141 | BF317DF81992119000E3240E /* AppDelegate.m */, 142 | BF317DFA1992119000E3240E /* Images.xcassets */, 143 | BF317DEF1992119000E3240E /* Supporting Files */, 144 | ); 145 | path = TableviewFlip; 146 | sourceTree = ""; 147 | }; 148 | BF317DEF1992119000E3240E /* Supporting Files */ = { 149 | isa = PBXGroup; 150 | children = ( 151 | BF317DF01992119000E3240E /* TableviewFlip-Info.plist */, 152 | BF317DF11992119000E3240E /* InfoPlist.strings */, 153 | BF317DF41992119000E3240E /* main.m */, 154 | BF317DF61992119000E3240E /* TableviewFlip-Prefix.pch */, 155 | ); 156 | name = "Supporting Files"; 157 | sourceTree = ""; 158 | }; 159 | BF317E071992119100E3240E /* TableviewFlipTests */ = { 160 | isa = PBXGroup; 161 | children = ( 162 | BF317E0D1992119100E3240E /* TableviewFlipTests.m */, 163 | BF317E081992119100E3240E /* Supporting Files */, 164 | ); 165 | path = TableviewFlipTests; 166 | sourceTree = ""; 167 | }; 168 | BF317E081992119100E3240E /* Supporting Files */ = { 169 | isa = PBXGroup; 170 | children = ( 171 | BF317E091992119100E3240E /* TableviewFlipTests-Info.plist */, 172 | BF317E0A1992119100E3240E /* InfoPlist.strings */, 173 | ); 174 | name = "Supporting Files"; 175 | sourceTree = ""; 176 | }; 177 | /* End PBXGroup section */ 178 | 179 | /* Begin PBXNativeTarget section */ 180 | BF317DE41992119000E3240E /* TableviewFlip */ = { 181 | isa = PBXNativeTarget; 182 | buildConfigurationList = BF317E111992119100E3240E /* Build configuration list for PBXNativeTarget "TableviewFlip" */; 183 | buildPhases = ( 184 | BF317DE11992119000E3240E /* Sources */, 185 | BF317DE21992119000E3240E /* Frameworks */, 186 | BF317DE31992119000E3240E /* Resources */, 187 | ); 188 | buildRules = ( 189 | ); 190 | dependencies = ( 191 | ); 192 | name = TableviewFlip; 193 | productName = TableviewFlip; 194 | productReference = BF317DE51992119000E3240E /* TableviewFlip.app */; 195 | productType = "com.apple.product-type.application"; 196 | }; 197 | BF317DFF1992119100E3240E /* TableviewFlipTests */ = { 198 | isa = PBXNativeTarget; 199 | buildConfigurationList = BF317E141992119100E3240E /* Build configuration list for PBXNativeTarget "TableviewFlipTests" */; 200 | buildPhases = ( 201 | BF317DFC1992119100E3240E /* Sources */, 202 | BF317DFD1992119100E3240E /* Frameworks */, 203 | BF317DFE1992119100E3240E /* Resources */, 204 | ); 205 | buildRules = ( 206 | ); 207 | dependencies = ( 208 | BF317E061992119100E3240E /* PBXTargetDependency */, 209 | ); 210 | name = TableviewFlipTests; 211 | productName = TableviewFlipTests; 212 | productReference = BF317E001992119100E3240E /* TableviewFlipTests.xctest */; 213 | productType = "com.apple.product-type.bundle.unit-test"; 214 | }; 215 | /* End PBXNativeTarget section */ 216 | 217 | /* Begin PBXProject section */ 218 | BF317DDD1992118F00E3240E /* Project object */ = { 219 | isa = PBXProject; 220 | attributes = { 221 | LastUpgradeCheck = 0510; 222 | ORGANIZATIONNAME = "Varshyl Mobile Pvt. Ltd."; 223 | TargetAttributes = { 224 | BF317DFF1992119100E3240E = { 225 | TestTargetID = BF317DE41992119000E3240E; 226 | }; 227 | }; 228 | }; 229 | buildConfigurationList = BF317DE01992119000E3240E /* Build configuration list for PBXProject "TableviewFlip" */; 230 | compatibilityVersion = "Xcode 3.2"; 231 | developmentRegion = English; 232 | hasScannedForEncodings = 0; 233 | knownRegions = ( 234 | en, 235 | ); 236 | mainGroup = BF317DDC1992118F00E3240E; 237 | productRefGroup = BF317DE61992119000E3240E /* Products */; 238 | projectDirPath = ""; 239 | projectRoot = ""; 240 | targets = ( 241 | BF317DE41992119000E3240E /* TableviewFlip */, 242 | BF317DFF1992119100E3240E /* TableviewFlipTests */, 243 | ); 244 | }; 245 | /* End PBXProject section */ 246 | 247 | /* Begin PBXResourcesBuildPhase section */ 248 | BF317DE31992119000E3240E /* Resources */ = { 249 | isa = PBXResourcesBuildPhase; 250 | buildActionMask = 2147483647; 251 | files = ( 252 | BFFC31C919936B6A0066E95C /* 0.jpg in Resources */, 253 | BF317DF31992119000E3240E /* InfoPlist.strings in Resources */, 254 | BFFC31C2199365F50066E95C /* 1.png in Resources */, 255 | BFFC31C4199366050066E95C /* 0.png in Resources */, 256 | BF317E1B199211C300E3240E /* ViewController.xib in Resources */, 257 | BFFC31CB19936B6A0066E95C /* 1.jpg in Resources */, 258 | BFFC31CC19936B6A0066E95C /* 4.jpg in Resources */, 259 | BFFC31CA19936B6A0066E95C /* 3.jpg in Resources */, 260 | BF317DFB1992119000E3240E /* Images.xcassets in Resources */, 261 | ); 262 | runOnlyForDeploymentPostprocessing = 0; 263 | }; 264 | BF317DFE1992119100E3240E /* Resources */ = { 265 | isa = PBXResourcesBuildPhase; 266 | buildActionMask = 2147483647; 267 | files = ( 268 | BF317E0C1992119100E3240E /* InfoPlist.strings in Resources */, 269 | ); 270 | runOnlyForDeploymentPostprocessing = 0; 271 | }; 272 | /* End PBXResourcesBuildPhase section */ 273 | 274 | /* Begin PBXSourcesBuildPhase section */ 275 | BF317DE11992119000E3240E /* Sources */ = { 276 | isa = PBXSourcesBuildPhase; 277 | buildActionMask = 2147483647; 278 | files = ( 279 | BF317E1A199211C300E3240E /* ViewController.m in Sources */, 280 | BF317DF91992119000E3240E /* AppDelegate.m in Sources */, 281 | BF317DF51992119000E3240E /* main.m in Sources */, 282 | ); 283 | runOnlyForDeploymentPostprocessing = 0; 284 | }; 285 | BF317DFC1992119100E3240E /* Sources */ = { 286 | isa = PBXSourcesBuildPhase; 287 | buildActionMask = 2147483647; 288 | files = ( 289 | BF317E0E1992119100E3240E /* TableviewFlipTests.m in Sources */, 290 | ); 291 | runOnlyForDeploymentPostprocessing = 0; 292 | }; 293 | /* End PBXSourcesBuildPhase section */ 294 | 295 | /* Begin PBXTargetDependency section */ 296 | BF317E061992119100E3240E /* PBXTargetDependency */ = { 297 | isa = PBXTargetDependency; 298 | target = BF317DE41992119000E3240E /* TableviewFlip */; 299 | targetProxy = BF317E051992119100E3240E /* PBXContainerItemProxy */; 300 | }; 301 | /* End PBXTargetDependency section */ 302 | 303 | /* Begin PBXVariantGroup section */ 304 | BF317DF11992119000E3240E /* InfoPlist.strings */ = { 305 | isa = PBXVariantGroup; 306 | children = ( 307 | BF317DF21992119000E3240E /* en */, 308 | ); 309 | name = InfoPlist.strings; 310 | sourceTree = ""; 311 | }; 312 | BF317E0A1992119100E3240E /* InfoPlist.strings */ = { 313 | isa = PBXVariantGroup; 314 | children = ( 315 | BF317E0B1992119100E3240E /* en */, 316 | ); 317 | name = InfoPlist.strings; 318 | sourceTree = ""; 319 | }; 320 | /* End PBXVariantGroup section */ 321 | 322 | /* Begin XCBuildConfiguration section */ 323 | BF317E0F1992119100E3240E /* Debug */ = { 324 | isa = XCBuildConfiguration; 325 | buildSettings = { 326 | ALWAYS_SEARCH_USER_PATHS = NO; 327 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 328 | CLANG_CXX_LIBRARY = "libc++"; 329 | CLANG_ENABLE_MODULES = YES; 330 | CLANG_ENABLE_OBJC_ARC = YES; 331 | CLANG_WARN_BOOL_CONVERSION = YES; 332 | CLANG_WARN_CONSTANT_CONVERSION = YES; 333 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 334 | CLANG_WARN_EMPTY_BODY = YES; 335 | CLANG_WARN_ENUM_CONVERSION = YES; 336 | CLANG_WARN_INT_CONVERSION = YES; 337 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 338 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 339 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 340 | COPY_PHASE_STRIP = NO; 341 | GCC_C_LANGUAGE_STANDARD = gnu99; 342 | GCC_DYNAMIC_NO_PIC = NO; 343 | GCC_OPTIMIZATION_LEVEL = 0; 344 | GCC_PREPROCESSOR_DEFINITIONS = ( 345 | "DEBUG=1", 346 | "$(inherited)", 347 | ); 348 | GCC_SYMBOLS_PRIVATE_EXTERN = NO; 349 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 350 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 351 | GCC_WARN_UNDECLARED_SELECTOR = YES; 352 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 353 | GCC_WARN_UNUSED_FUNCTION = YES; 354 | GCC_WARN_UNUSED_VARIABLE = YES; 355 | IPHONEOS_DEPLOYMENT_TARGET = 7.1; 356 | ONLY_ACTIVE_ARCH = YES; 357 | SDKROOT = iphoneos; 358 | }; 359 | name = Debug; 360 | }; 361 | BF317E101992119100E3240E /* Release */ = { 362 | isa = XCBuildConfiguration; 363 | buildSettings = { 364 | ALWAYS_SEARCH_USER_PATHS = NO; 365 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 366 | CLANG_CXX_LIBRARY = "libc++"; 367 | CLANG_ENABLE_MODULES = YES; 368 | CLANG_ENABLE_OBJC_ARC = YES; 369 | CLANG_WARN_BOOL_CONVERSION = YES; 370 | CLANG_WARN_CONSTANT_CONVERSION = YES; 371 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 372 | CLANG_WARN_EMPTY_BODY = YES; 373 | CLANG_WARN_ENUM_CONVERSION = YES; 374 | CLANG_WARN_INT_CONVERSION = YES; 375 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 376 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 377 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 378 | COPY_PHASE_STRIP = YES; 379 | ENABLE_NS_ASSERTIONS = NO; 380 | GCC_C_LANGUAGE_STANDARD = gnu99; 381 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 382 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 383 | GCC_WARN_UNDECLARED_SELECTOR = YES; 384 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 385 | GCC_WARN_UNUSED_FUNCTION = YES; 386 | GCC_WARN_UNUSED_VARIABLE = YES; 387 | IPHONEOS_DEPLOYMENT_TARGET = 7.1; 388 | SDKROOT = iphoneos; 389 | VALIDATE_PRODUCT = YES; 390 | }; 391 | name = Release; 392 | }; 393 | BF317E121992119100E3240E /* Debug */ = { 394 | isa = XCBuildConfiguration; 395 | buildSettings = { 396 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 397 | ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage; 398 | GCC_PRECOMPILE_PREFIX_HEADER = YES; 399 | GCC_PREFIX_HEADER = "TableviewFlip/TableviewFlip-Prefix.pch"; 400 | INFOPLIST_FILE = "TableviewFlip/TableviewFlip-Info.plist"; 401 | PRODUCT_NAME = "$(TARGET_NAME)"; 402 | WRAPPER_EXTENSION = app; 403 | }; 404 | name = Debug; 405 | }; 406 | BF317E131992119100E3240E /* Release */ = { 407 | isa = XCBuildConfiguration; 408 | buildSettings = { 409 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 410 | ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage; 411 | GCC_PRECOMPILE_PREFIX_HEADER = YES; 412 | GCC_PREFIX_HEADER = "TableviewFlip/TableviewFlip-Prefix.pch"; 413 | INFOPLIST_FILE = "TableviewFlip/TableviewFlip-Info.plist"; 414 | PRODUCT_NAME = "$(TARGET_NAME)"; 415 | WRAPPER_EXTENSION = app; 416 | }; 417 | name = Release; 418 | }; 419 | BF317E151992119100E3240E /* Debug */ = { 420 | isa = XCBuildConfiguration; 421 | buildSettings = { 422 | BUNDLE_LOADER = "$(BUILT_PRODUCTS_DIR)/TableviewFlip.app/TableviewFlip"; 423 | FRAMEWORK_SEARCH_PATHS = ( 424 | "$(SDKROOT)/Developer/Library/Frameworks", 425 | "$(inherited)", 426 | "$(DEVELOPER_FRAMEWORKS_DIR)", 427 | ); 428 | GCC_PRECOMPILE_PREFIX_HEADER = YES; 429 | GCC_PREFIX_HEADER = "TableviewFlip/TableviewFlip-Prefix.pch"; 430 | GCC_PREPROCESSOR_DEFINITIONS = ( 431 | "DEBUG=1", 432 | "$(inherited)", 433 | ); 434 | INFOPLIST_FILE = "TableviewFlipTests/TableviewFlipTests-Info.plist"; 435 | PRODUCT_NAME = "$(TARGET_NAME)"; 436 | TEST_HOST = "$(BUNDLE_LOADER)"; 437 | WRAPPER_EXTENSION = xctest; 438 | }; 439 | name = Debug; 440 | }; 441 | BF317E161992119100E3240E /* Release */ = { 442 | isa = XCBuildConfiguration; 443 | buildSettings = { 444 | BUNDLE_LOADER = "$(BUILT_PRODUCTS_DIR)/TableviewFlip.app/TableviewFlip"; 445 | FRAMEWORK_SEARCH_PATHS = ( 446 | "$(SDKROOT)/Developer/Library/Frameworks", 447 | "$(inherited)", 448 | "$(DEVELOPER_FRAMEWORKS_DIR)", 449 | ); 450 | GCC_PRECOMPILE_PREFIX_HEADER = YES; 451 | GCC_PREFIX_HEADER = "TableviewFlip/TableviewFlip-Prefix.pch"; 452 | INFOPLIST_FILE = "TableviewFlipTests/TableviewFlipTests-Info.plist"; 453 | PRODUCT_NAME = "$(TARGET_NAME)"; 454 | TEST_HOST = "$(BUNDLE_LOADER)"; 455 | WRAPPER_EXTENSION = xctest; 456 | }; 457 | name = Release; 458 | }; 459 | /* End XCBuildConfiguration section */ 460 | 461 | /* Begin XCConfigurationList section */ 462 | BF317DE01992119000E3240E /* Build configuration list for PBXProject "TableviewFlip" */ = { 463 | isa = XCConfigurationList; 464 | buildConfigurations = ( 465 | BF317E0F1992119100E3240E /* Debug */, 466 | BF317E101992119100E3240E /* Release */, 467 | ); 468 | defaultConfigurationIsVisible = 0; 469 | defaultConfigurationName = Release; 470 | }; 471 | BF317E111992119100E3240E /* Build configuration list for PBXNativeTarget "TableviewFlip" */ = { 472 | isa = XCConfigurationList; 473 | buildConfigurations = ( 474 | BF317E121992119100E3240E /* Debug */, 475 | BF317E131992119100E3240E /* Release */, 476 | ); 477 | defaultConfigurationIsVisible = 0; 478 | defaultConfigurationName = Release; 479 | }; 480 | BF317E141992119100E3240E /* Build configuration list for PBXNativeTarget "TableviewFlipTests" */ = { 481 | isa = XCConfigurationList; 482 | buildConfigurations = ( 483 | BF317E151992119100E3240E /* Debug */, 484 | BF317E161992119100E3240E /* Release */, 485 | ); 486 | defaultConfigurationIsVisible = 0; 487 | defaultConfigurationName = Release; 488 | }; 489 | /* End XCConfigurationList section */ 490 | }; 491 | rootObject = BF317DDD1992118F00E3240E /* Project object */; 492 | } 493 | -------------------------------------------------------------------------------- /TableviewFlip/TableviewFlip.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /TableviewFlip/TableviewFlip.xcodeproj/project.xcworkspace/xcuserdata/jimmy.xcuserdatad/UserInterfaceState.xcuserstate: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jimmyjose-dev/TableViewCellFlip/ff11140dcdfa3499cc43b4501b5353c42ceafc00/TableviewFlip/TableviewFlip.xcodeproj/project.xcworkspace/xcuserdata/jimmy.xcuserdatad/UserInterfaceState.xcuserstate -------------------------------------------------------------------------------- /TableviewFlip/TableviewFlip.xcodeproj/xcuserdata/jimmy.xcuserdatad/xcschemes/TableviewFlip.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 30 | 31 | 33 | 39 | 40 | 41 | 42 | 43 | 49 | 50 | 51 | 52 | 61 | 62 | 68 | 69 | 70 | 71 | 72 | 73 | 79 | 80 | 86 | 87 | 88 | 89 | 91 | 92 | 95 | 96 | 97 | -------------------------------------------------------------------------------- /TableviewFlip/TableviewFlip.xcodeproj/xcuserdata/jimmy.xcuserdatad/xcschemes/xcschememanagement.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | SchemeUserState 6 | 7 | TableviewFlip.xcscheme 8 | 9 | orderHint 10 | 0 11 | 12 | 13 | SuppressBuildableAutocreation 14 | 15 | BF317DE41992119000E3240E 16 | 17 | primary 18 | 19 | 20 | BF317DFF1992119100E3240E 21 | 22 | primary 23 | 24 | 25 | 26 | 27 | 28 | -------------------------------------------------------------------------------- /TableviewFlip/TableviewFlip/AppDelegate.h: -------------------------------------------------------------------------------- 1 | // 2 | // AppDelegate.h 3 | // TableviewFlip 4 | // 5 | // Created by Jimmy Jose on 06/08/14. 6 | // Copyright (c) 2014 Varshyl Mobile Pvt. Ltd. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface AppDelegate : UIResponder 12 | 13 | @property (strong, nonatomic) UIWindow *window; 14 | @property (strong, nonatomic) UINavigationController *navigationController; 15 | 16 | @end 17 | -------------------------------------------------------------------------------- /TableviewFlip/TableviewFlip/AppDelegate.m: -------------------------------------------------------------------------------- 1 | // 2 | // AppDelegate.m 3 | // TableviewFlip 4 | // 5 | // Created by Jimmy Jose on 06/08/14. 6 | // Copyright (c) 2014 Varshyl Mobile Pvt. Ltd. All rights reserved. 7 | // 8 | 9 | #import "AppDelegate.h" 10 | #import "ViewController.h" 11 | 12 | @implementation AppDelegate 13 | 14 | - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions 15 | { 16 | 17 | ViewController *vc = [[ViewController alloc] initWithNibName:@"ViewController" bundle:nil]; 18 | 19 | _navigationController = [[UINavigationController alloc] initWithRootViewController:vc]; 20 | 21 | self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]]; 22 | // Override point for customization after application launch. 23 | self.window.backgroundColor = [UIColor whiteColor]; 24 | 25 | self.window.rootViewController = _navigationController; 26 | [self.window makeKeyAndVisible]; 27 | return YES; 28 | } 29 | 30 | - (void)applicationWillResignActive:(UIApplication *)application 31 | { 32 | // 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. 33 | // Use this method to pause ongoing tasks, disable timers, and throttle down OpenGL ES frame rates. Games should use this method to pause the game. 34 | } 35 | 36 | - (void)applicationDidEnterBackground:(UIApplication *)application 37 | { 38 | // 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. 39 | // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. 40 | } 41 | 42 | - (void)applicationWillEnterForeground:(UIApplication *)application 43 | { 44 | // Called as part of the transition from the background to the inactive state; here you can undo many of the changes made on entering the background. 45 | } 46 | 47 | - (void)applicationDidBecomeActive:(UIApplication *)application 48 | { 49 | // 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. 50 | } 51 | 52 | - (void)applicationWillTerminate:(UIApplication *)application 53 | { 54 | // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. 55 | } 56 | 57 | @end 58 | -------------------------------------------------------------------------------- /TableviewFlip/TableviewFlip/Images.xcassets/AppIcon.appiconset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "iphone", 5 | "size" : "29x29", 6 | "scale" : "2x" 7 | }, 8 | { 9 | "idiom" : "iphone", 10 | "size" : "40x40", 11 | "scale" : "2x" 12 | }, 13 | { 14 | "idiom" : "iphone", 15 | "size" : "60x60", 16 | "scale" : "2x" 17 | } 18 | ], 19 | "info" : { 20 | "version" : 1, 21 | "author" : "xcode" 22 | } 23 | } -------------------------------------------------------------------------------- /TableviewFlip/TableviewFlip/Images.xcassets/LaunchImage.launchimage/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "orientation" : "portrait", 5 | "idiom" : "iphone", 6 | "extent" : "full-screen", 7 | "minimum-system-version" : "7.0", 8 | "scale" : "2x" 9 | }, 10 | { 11 | "orientation" : "portrait", 12 | "idiom" : "iphone", 13 | "subtype" : "retina4", 14 | "extent" : "full-screen", 15 | "minimum-system-version" : "7.0", 16 | "scale" : "2x" 17 | } 18 | ], 19 | "info" : { 20 | "version" : 1, 21 | "author" : "xcode" 22 | } 23 | } -------------------------------------------------------------------------------- /TableviewFlip/TableviewFlip/TableviewFlip-Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleDisplayName 8 | ${PRODUCT_NAME} 9 | CFBundleExecutable 10 | ${EXECUTABLE_NAME} 11 | CFBundleIdentifier 12 | com.varshylmobile.${PRODUCT_NAME:rfc1034identifier} 13 | CFBundleInfoDictionaryVersion 14 | 6.0 15 | CFBundleName 16 | ${PRODUCT_NAME} 17 | CFBundlePackageType 18 | APPL 19 | CFBundleShortVersionString 20 | 1.0 21 | CFBundleSignature 22 | ???? 23 | CFBundleVersion 24 | 1.0 25 | LSRequiresIPhoneOS 26 | 27 | UIRequiredDeviceCapabilities 28 | 29 | armv7 30 | 31 | UISupportedInterfaceOrientations 32 | 33 | UIInterfaceOrientationPortrait 34 | UIInterfaceOrientationLandscapeLeft 35 | UIInterfaceOrientationLandscapeRight 36 | 37 | 38 | 39 | -------------------------------------------------------------------------------- /TableviewFlip/TableviewFlip/TableviewFlip-Prefix.pch: -------------------------------------------------------------------------------- 1 | // 2 | // Prefix header 3 | // 4 | // The contents of this file are implicitly included at the beginning of every source file. 5 | // 6 | 7 | #import 8 | 9 | #ifndef __IPHONE_3_0 10 | #warning "This project uses features only available in iOS SDK 3.0 and later." 11 | #endif 12 | 13 | #ifdef __OBJC__ 14 | #import 15 | #import 16 | #endif 17 | -------------------------------------------------------------------------------- /TableviewFlip/TableviewFlip/en.lproj/InfoPlist.strings: -------------------------------------------------------------------------------- 1 | /* Localized versions of Info.plist keys */ 2 | 3 | -------------------------------------------------------------------------------- /TableviewFlip/TableviewFlip/main.m: -------------------------------------------------------------------------------- 1 | // 2 | // main.m 3 | // TableviewFlip 4 | // 5 | // Created by Jimmy Jose on 06/08/14. 6 | // Copyright (c) 2014 Varshyl Mobile Pvt. Ltd. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | #import "AppDelegate.h" 12 | 13 | int main(int argc, char * argv[]) 14 | { 15 | @autoreleasepool { 16 | return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class])); 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /TableviewFlip/TableviewFlipTests/TableviewFlipTests-Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | ${EXECUTABLE_NAME} 9 | CFBundleIdentifier 10 | com.varshylmobile.${PRODUCT_NAME:rfc1034identifier} 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundlePackageType 14 | BNDL 15 | CFBundleShortVersionString 16 | 1.0 17 | CFBundleSignature 18 | ???? 19 | CFBundleVersion 20 | 1 21 | 22 | 23 | -------------------------------------------------------------------------------- /TableviewFlip/TableviewFlipTests/TableviewFlipTests.m: -------------------------------------------------------------------------------- 1 | // 2 | // TableviewFlipTests.m 3 | // TableviewFlipTests 4 | // 5 | // Created by Jimmy Jose on 06/08/14. 6 | // Copyright (c) 2014 Varshyl Mobile Pvt. Ltd. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface TableviewFlipTests : XCTestCase 12 | 13 | @end 14 | 15 | @implementation TableviewFlipTests 16 | 17 | - (void)setUp 18 | { 19 | [super setUp]; 20 | // Put setup code here. This method is called before the invocation of each test method in the class. 21 | } 22 | 23 | - (void)tearDown 24 | { 25 | // Put teardown code here. This method is called after the invocation of each test method in the class. 26 | [super tearDown]; 27 | } 28 | 29 | - (void)testExample 30 | { 31 | XCTFail(@"No implementation for \"%s\"", __PRETTY_FUNCTION__); 32 | } 33 | 34 | @end 35 | -------------------------------------------------------------------------------- /TableviewFlip/TableviewFlipTests/en.lproj/InfoPlist.strings: -------------------------------------------------------------------------------- 1 | /* Localized versions of Info.plist keys */ 2 | 3 | -------------------------------------------------------------------------------- /TableviewFlip/ViewController.h: -------------------------------------------------------------------------------- 1 | // 2 | // ViewController.h 3 | // TableviewFlip 4 | // 5 | // Created by Jimmy Jose on 06/08/14. 6 | // Copyright (c) 2014 Varshyl Mobile Pvt. Ltd. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface ViewController : UIViewController 12 | 13 | @end 14 | -------------------------------------------------------------------------------- /TableviewFlip/ViewController.m: -------------------------------------------------------------------------------- 1 | // 2 | // ViewController.m 3 | // TableviewFlip 4 | // 5 | // Created by Jimmy Jose on 06/08/14. 6 | // Copyright (c) 2014 Varshyl Mobile Pvt. Ltd. All rights reserved. 7 | // 8 | 9 | #import "ViewController.h" 10 | #import 11 | 12 | #define kFlipVerticalTime 0.5 13 | #define kFlipHorizontalTime 0.6 14 | #define kDelayTime 0.0 15 | #define kAnimationEasingType UIViewAnimationOptionCurveEaseInOut 16 | 17 | @interface ViewController () 18 | @property IBOutlet UITableView *tableView; 19 | @property NSArray *tableViewDataSource; 20 | @end 21 | 22 | 23 | @implementation ViewController 24 | 25 | - (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil { 26 | self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil]; 27 | if (self) { 28 | // Custom initialization 29 | } 30 | return self; 31 | } 32 | 33 | - (void)viewDidLoad { 34 | [super viewDidLoad]; 35 | // Do any additional setup after loading the view from its nib. 36 | _tableViewDataSource = @[@"Hello", @"World"]; 37 | 38 | _tableView.delegate = self; 39 | _tableView.dataSource = self; 40 | 41 | [_tableView reloadData]; 42 | } 43 | 44 | - (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section { 45 | return [_tableViewDataSource count]; 46 | } 47 | 48 | - (UITableViewCell *)tableView:(UITableView *)tableview cellForRowAtIndexPath:(NSIndexPath *)indexPath { 49 | UITableViewCell *cell = nil; 50 | cell = [tableview dequeueReusableCellWithIdentifier:@"Cell"]; 51 | 52 | if (!cell) { 53 | cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleSubtitle reuseIdentifier:@"Cell"]; 54 | } 55 | 56 | //cell.textLabel.text = [_tableViewDataSource objectAtIndex:indexPath.row]; 57 | cell.textLabel.textColor = [UIColor whiteColor]; 58 | 59 | UIButton *button = [UIButton buttonWithType:UIButtonTypeInfoDark]; 60 | button.tag = indexPath.row; 61 | 62 | [button addTarget:self action:@selector(buttonPressed:) forControlEvents:UIControlEventTouchUpInside]; 63 | 64 | cell.accessoryView = button; 65 | 66 | NSString *imageName = [NSString stringWithFormat:@"%d.jpg", indexPath.row]; 67 | 68 | 69 | cell.backgroundView = [[UIImageView alloc] initWithImage:[[UIImage imageNamed:imageName] stretchableImageWithLeftCapWidth:0.0 topCapHeight:5.0]]; 70 | cell.selectedBackgroundView = [[UIImageView alloc] initWithImage:[[UIImage imageNamed:imageName] stretchableImageWithLeftCapWidth:0.0 topCapHeight:5.0]]; 71 | 72 | return cell; 73 | } 74 | 75 | - (void)buttonPressed:(UIButton *)sender { 76 | UITableViewCell *cell = [_tableView cellForRowAtIndexPath:[NSIndexPath indexPathForRow:sender.tag inSection:0]]; 77 | 78 | NSTimeInterval timeInterval = kFlipHorizontalTime; 79 | NSString *msg = @"Hello is now changed"; 80 | int tag = 3; 81 | cell.layer.transform = [self performHorizontalFlipInClockwiseDirection:YES]; 82 | if (sender.tag) { 83 | tag = 4; 84 | timeInterval = kFlipVerticalTime; 85 | msg = @"World is now changed"; 86 | cell.layer.transform = [self performVerticalFlipInClockwiseDirection:YES]; 87 | } 88 | 89 | 90 | UIButton *button = (UIButton *)[cell accessoryView]; 91 | 92 | [button removeTarget:nil 93 | action:NULL 94 | forControlEvents:UIControlEventAllEvents]; 95 | 96 | [button addTarget:self action:@selector(revert:) forControlEvents:UIControlEventTouchUpInside]; 97 | 98 | NSString *imageName = [NSString stringWithFormat:@"%d.jpg", tag]; 99 | 100 | [UIView animateWithDuration:timeInterval 101 | delay:kDelayTime 102 | options:kAnimationEasingType 103 | animations: ^{ 104 | cell.layer.transform = CATransform3DIdentity; 105 | cell.textLabel.textColor = [UIColor whiteColor]; 106 | // cell.textLabel.text = msg; 107 | [cell.textLabel sizeToFit]; 108 | //cell.imageView.image = [UIImage imageNamed:@"0"]; 109 | cell.backgroundView = [[UIImageView alloc] initWithImage:[[UIImage imageNamed:imageName] stretchableImageWithLeftCapWidth:0.0 topCapHeight:5.0]]; 110 | cell.selectedBackgroundView = [[UIImageView alloc] initWithImage:[[UIImage imageNamed:imageName] stretchableImageWithLeftCapWidth:0.0 topCapHeight:5.0]]; 111 | } 112 | 113 | completion: ^(BOOL finished) { 114 | 115 | }]; 116 | } 117 | 118 | - (void)revert:(UIButton *)sender { 119 | UITableViewCell *cell = [_tableView cellForRowAtIndexPath:[NSIndexPath indexPathForRow:sender.tag inSection:0]]; 120 | 121 | NSString *msg = @"Hello"; 122 | NSTimeInterval timeInterval = kFlipHorizontalTime; 123 | cell.layer.transform = [self performHorizontalFlipInClockwiseDirection:YES]; 124 | if (sender.tag) { 125 | timeInterval = kFlipVerticalTime; 126 | msg = @"World"; 127 | cell.layer.transform = [self performVerticalFlipInClockwiseDirection:YES]; 128 | 129 | } 130 | 131 | NSString *imageName = [NSString stringWithFormat:@"%d.jpg", sender.tag]; 132 | 133 | 134 | UIButton *button = (UIButton *)[cell accessoryView]; 135 | 136 | [button removeTarget:nil 137 | action:NULL 138 | forControlEvents:UIControlEventAllEvents]; 139 | 140 | [button addTarget:self action:@selector(buttonPressed:) forControlEvents:UIControlEventTouchUpInside]; 141 | 142 | [UIView animateWithDuration:timeInterval 143 | delay:kDelayTime 144 | options:kAnimationEasingType 145 | animations: ^{ 146 | cell.layer.transform = CATransform3DIdentity; 147 | cell.textLabel.textColor = [UIColor whiteColor]; 148 | // cell.textLabel.text = msg; 149 | [cell.textLabel sizeToFit]; 150 | //cell.imageView.image = [UIImage imageNamed:@"0"]; 151 | cell.backgroundView = [[UIImageView alloc] initWithImage:[[UIImage imageNamed:imageName] stretchableImageWithLeftCapWidth:0.0 topCapHeight:5.0]]; 152 | cell.selectedBackgroundView = [[UIImageView alloc] initWithImage:[[UIImage imageNamed:imageName] stretchableImageWithLeftCapWidth:0.0 topCapHeight:5.0]]; 153 | } 154 | 155 | completion: ^(BOOL finished) { 156 | 157 | }]; 158 | } 159 | 160 | - (CATransform3D)performVerticalFlipInClockwiseDirection:(BOOL)clockwise { 161 | return [self getTransformForIndex:1 inClockwiseDirection:clockwise]; 162 | } 163 | 164 | - (CATransform3D)performHorizontalFlipInClockwiseDirection:(BOOL)clockwise { 165 | return [self getTransformForIndex:0 inClockwiseDirection:clockwise]; 166 | } 167 | 168 | - (CATransform3D)getTransformForIndex:(int)index inClockwiseDirection:(BOOL)clockwise { 169 | 170 | int direction = clockwise ? -1 : 1; 171 | 172 | float xCord = index ? 1.0 : 0.0; 173 | float yCord = index ? 0.0 : 1.0; 174 | float zCord = 0.0; 175 | 176 | //float angle = (180 * direction) * (M_PI / 180); 177 | float angle = direction * M_PI; 178 | 179 | CGPoint offset = CGPointMake(0, 0); 180 | 181 | CATransform3D transform = CATransform3DIdentity; 182 | 183 | transform = CATransform3DRotate(transform, angle, xCord, yCord, zCord); 184 | 185 | transform = CATransform3DTranslate(transform, offset.x, offset.y, 0.0); 186 | 187 | 188 | return transform; 189 | } 190 | 191 | - (void)didReceiveMemoryWarning { 192 | [super didReceiveMemoryWarning]; 193 | // Dispose of any resources that can be recreated. 194 | } 195 | 196 | @end 197 | -------------------------------------------------------------------------------- /TableviewFlip/ViewController.xib: -------------------------------------------------------------------------------- 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 | --------------------------------------------------------------------------------