├── .gitattributes ├── .gitignore ├── Custom UIButtons.xcodeproj └── project.pbxproj ├── Custom UIButtons ├── CBAppDelegate.h ├── CBAppDelegate.m ├── CBLayer.h ├── CBLayer.m ├── CBViewController.h ├── CBViewController.m ├── Custom UIButtons-Info.plist ├── Custom UIButtons-Prefix.pch ├── Default-568h@2x.png ├── Default.png ├── Default@2x.png ├── button.png ├── button@2x.png ├── buttonHighlighted.png ├── buttonHighlighted@2x.png ├── en.lproj │ ├── InfoPlist.strings │ └── MainStoryboard.storyboard ├── main.m ├── resizableButton.png ├── resizableButton@2x.png ├── resizableButtonHighlighted.png └── resizableButtonHighlighted@2x.png └── Custom UIButtonsTests ├── Custom UIButtonsTests-Info.plist ├── Custom_UIButtonsTests.h ├── Custom_UIButtonsTests.m └── en.lproj └── InfoPlist.strings /.gitattributes: -------------------------------------------------------------------------------- 1 | *.pbxproj binary merge=union 2 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | build/ 3 | *.pbxuser 4 | *.mode1v3 5 | *.mode2v3 6 | *.perspectivev3 7 | profile 8 | xcuserdata 9 | *.swp 10 | *~.nib 11 | project.xcworkspace/ 12 | -------------------------------------------------------------------------------- /Custom UIButtons.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 46; 7 | objects = { 8 | 9 | /* Begin PBXBuildFile section */ 10 | 9D5AAD8B1618F5F90000EF26 /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 9D5AAD8A1618F5F90000EF26 /* UIKit.framework */; }; 11 | 9D5AAD8D1618F5F90000EF26 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 9D5AAD8C1618F5F90000EF26 /* Foundation.framework */; }; 12 | 9D5AAD8F1618F5F90000EF26 /* CoreGraphics.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 9D5AAD8E1618F5F90000EF26 /* CoreGraphics.framework */; }; 13 | 9D5AAD951618F5F90000EF26 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 9D5AAD931618F5F90000EF26 /* InfoPlist.strings */; }; 14 | 9D5AAD971618F5F90000EF26 /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 9D5AAD961618F5F90000EF26 /* main.m */; }; 15 | 9D5AAD9B1618F5F90000EF26 /* CBAppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 9D5AAD9A1618F5F90000EF26 /* CBAppDelegate.m */; }; 16 | 9D5AAD9D1618F5F90000EF26 /* Default.png in Resources */ = {isa = PBXBuildFile; fileRef = 9D5AAD9C1618F5F90000EF26 /* Default.png */; }; 17 | 9D5AAD9F1618F5F90000EF26 /* Default@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 9D5AAD9E1618F5F90000EF26 /* Default@2x.png */; }; 18 | 9D5AADA11618F5F90000EF26 /* Default-568h@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 9D5AADA01618F5F90000EF26 /* Default-568h@2x.png */; }; 19 | 9D5AADA41618F5F90000EF26 /* MainStoryboard.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 9D5AADA21618F5F90000EF26 /* MainStoryboard.storyboard */; }; 20 | 9D5AADA71618F5F90000EF26 /* CBViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 9D5AADA61618F5F90000EF26 /* CBViewController.m */; }; 21 | 9D5AADAF1618F5F90000EF26 /* SenTestingKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 9D5AADAE1618F5F90000EF26 /* SenTestingKit.framework */; }; 22 | 9D5AADB01618F5F90000EF26 /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 9D5AAD8A1618F5F90000EF26 /* UIKit.framework */; }; 23 | 9D5AADB11618F5F90000EF26 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 9D5AAD8C1618F5F90000EF26 /* Foundation.framework */; }; 24 | 9D5AADB91618F5F90000EF26 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 9D5AADB71618F5F90000EF26 /* InfoPlist.strings */; }; 25 | 9D5AADBC1618F5F90000EF26 /* Custom_UIButtonsTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 9D5AADBB1618F5F90000EF26 /* Custom_UIButtonsTests.m */; }; 26 | 9D5AADCD161904190000EF26 /* button.png in Resources */ = {isa = PBXBuildFile; fileRef = 9D5AADC9161904190000EF26 /* button.png */; }; 27 | 9D5AADCE161904190000EF26 /* button@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 9D5AADCA161904190000EF26 /* button@2x.png */; }; 28 | 9D5AADCF161904190000EF26 /* buttonHighlighted.png in Resources */ = {isa = PBXBuildFile; fileRef = 9D5AADCB161904190000EF26 /* buttonHighlighted.png */; }; 29 | 9D5AADD0161904190000EF26 /* buttonHighlighted@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 9D5AADCC161904190000EF26 /* buttonHighlighted@2x.png */; }; 30 | 9D5AADD51619BB250000EF26 /* resizableButton.png in Resources */ = {isa = PBXBuildFile; fileRef = 9D5AADD11619BB250000EF26 /* resizableButton.png */; }; 31 | 9D5AADD61619BB250000EF26 /* resizableButton@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 9D5AADD21619BB250000EF26 /* resizableButton@2x.png */; }; 32 | 9D5AADD71619BB250000EF26 /* resizableButtonHighlighted.png in Resources */ = {isa = PBXBuildFile; fileRef = 9D5AADD31619BB250000EF26 /* resizableButtonHighlighted.png */; }; 33 | 9D5AADD81619BB250000EF26 /* resizableButtonHighlighted@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 9D5AADD41619BB250000EF26 /* resizableButtonHighlighted@2x.png */; }; 34 | 9DDA94DF161F4B0F0099D9C3 /* QuartzCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 9DDA94DE161F4B0F0099D9C3 /* QuartzCore.framework */; }; 35 | 9DDA94F5161F68C90099D9C3 /* CBLayer.m in Sources */ = {isa = PBXBuildFile; fileRef = 9DDA94F4161F68C90099D9C3 /* CBLayer.m */; }; 36 | /* End PBXBuildFile section */ 37 | 38 | /* Begin PBXContainerItemProxy section */ 39 | 9D5AADB21618F5F90000EF26 /* PBXContainerItemProxy */ = { 40 | isa = PBXContainerItemProxy; 41 | containerPortal = 9D5AAD7D1618F5F90000EF26 /* Project object */; 42 | proxyType = 1; 43 | remoteGlobalIDString = 9D5AAD851618F5F90000EF26; 44 | remoteInfo = "Custom UIButtons"; 45 | }; 46 | /* End PBXContainerItemProxy section */ 47 | 48 | /* Begin PBXFileReference section */ 49 | 9D5AAD861618F5F90000EF26 /* Custom UIButtons.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = "Custom UIButtons.app"; sourceTree = BUILT_PRODUCTS_DIR; }; 50 | 9D5AAD8A1618F5F90000EF26 /* UIKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UIKit.framework; path = System/Library/Frameworks/UIKit.framework; sourceTree = SDKROOT; }; 51 | 9D5AAD8C1618F5F90000EF26 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; }; 52 | 9D5AAD8E1618F5F90000EF26 /* CoreGraphics.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreGraphics.framework; path = System/Library/Frameworks/CoreGraphics.framework; sourceTree = SDKROOT; }; 53 | 9D5AAD921618F5F90000EF26 /* Custom UIButtons-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = "Custom UIButtons-Info.plist"; sourceTree = ""; }; 54 | 9D5AAD941618F5F90000EF26 /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/InfoPlist.strings; sourceTree = ""; }; 55 | 9D5AAD961618F5F90000EF26 /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = ""; }; 56 | 9D5AAD981618F5F90000EF26 /* Custom UIButtons-Prefix.pch */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "Custom UIButtons-Prefix.pch"; sourceTree = ""; }; 57 | 9D5AAD991618F5F90000EF26 /* CBAppDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = CBAppDelegate.h; sourceTree = ""; }; 58 | 9D5AAD9A1618F5F90000EF26 /* CBAppDelegate.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = CBAppDelegate.m; sourceTree = ""; }; 59 | 9D5AAD9C1618F5F90000EF26 /* Default.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = Default.png; sourceTree = ""; }; 60 | 9D5AAD9E1618F5F90000EF26 /* Default@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default@2x.png"; sourceTree = ""; }; 61 | 9D5AADA01618F5F90000EF26 /* Default-568h@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default-568h@2x.png"; sourceTree = ""; }; 62 | 9D5AADA31618F5F90000EF26 /* en */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = en; path = en.lproj/MainStoryboard.storyboard; sourceTree = ""; }; 63 | 9D5AADA51618F5F90000EF26 /* CBViewController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = CBViewController.h; sourceTree = ""; }; 64 | 9D5AADA61618F5F90000EF26 /* CBViewController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = CBViewController.m; sourceTree = ""; }; 65 | 9D5AADAD1618F5F90000EF26 /* Custom UIButtonsTests.octest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = "Custom UIButtonsTests.octest"; sourceTree = BUILT_PRODUCTS_DIR; }; 66 | 9D5AADAE1618F5F90000EF26 /* SenTestingKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = SenTestingKit.framework; path = Library/Frameworks/SenTestingKit.framework; sourceTree = DEVELOPER_DIR; }; 67 | 9D5AADB61618F5F90000EF26 /* Custom UIButtonsTests-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = "Custom UIButtonsTests-Info.plist"; sourceTree = ""; }; 68 | 9D5AADB81618F5F90000EF26 /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/InfoPlist.strings; sourceTree = ""; }; 69 | 9D5AADBA1618F5F90000EF26 /* Custom_UIButtonsTests.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = Custom_UIButtonsTests.h; sourceTree = ""; }; 70 | 9D5AADBB1618F5F90000EF26 /* Custom_UIButtonsTests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = Custom_UIButtonsTests.m; sourceTree = ""; }; 71 | 9D5AADC9161904190000EF26 /* button.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = button.png; sourceTree = ""; }; 72 | 9D5AADCA161904190000EF26 /* button@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "button@2x.png"; sourceTree = ""; }; 73 | 9D5AADCB161904190000EF26 /* buttonHighlighted.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = buttonHighlighted.png; sourceTree = ""; }; 74 | 9D5AADCC161904190000EF26 /* buttonHighlighted@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "buttonHighlighted@2x.png"; sourceTree = ""; }; 75 | 9D5AADD11619BB250000EF26 /* resizableButton.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = resizableButton.png; sourceTree = ""; }; 76 | 9D5AADD21619BB250000EF26 /* resizableButton@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "resizableButton@2x.png"; sourceTree = ""; }; 77 | 9D5AADD31619BB250000EF26 /* resizableButtonHighlighted.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = resizableButtonHighlighted.png; sourceTree = ""; }; 78 | 9D5AADD41619BB250000EF26 /* resizableButtonHighlighted@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "resizableButtonHighlighted@2x.png"; sourceTree = ""; }; 79 | 9DDA94DE161F4B0F0099D9C3 /* QuartzCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = QuartzCore.framework; path = System/Library/Frameworks/QuartzCore.framework; sourceTree = SDKROOT; }; 80 | 9DDA94F3161F68C90099D9C3 /* CBLayer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CBLayer.h; sourceTree = ""; }; 81 | 9DDA94F4161F68C90099D9C3 /* CBLayer.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CBLayer.m; sourceTree = ""; }; 82 | /* End PBXFileReference section */ 83 | 84 | /* Begin PBXFrameworksBuildPhase section */ 85 | 9D5AAD831618F5F90000EF26 /* Frameworks */ = { 86 | isa = PBXFrameworksBuildPhase; 87 | buildActionMask = 2147483647; 88 | files = ( 89 | 9DDA94DF161F4B0F0099D9C3 /* QuartzCore.framework in Frameworks */, 90 | 9D5AAD8B1618F5F90000EF26 /* UIKit.framework in Frameworks */, 91 | 9D5AAD8D1618F5F90000EF26 /* Foundation.framework in Frameworks */, 92 | 9D5AAD8F1618F5F90000EF26 /* CoreGraphics.framework in Frameworks */, 93 | ); 94 | runOnlyForDeploymentPostprocessing = 0; 95 | }; 96 | 9D5AADA91618F5F90000EF26 /* Frameworks */ = { 97 | isa = PBXFrameworksBuildPhase; 98 | buildActionMask = 2147483647; 99 | files = ( 100 | 9D5AADAF1618F5F90000EF26 /* SenTestingKit.framework in Frameworks */, 101 | 9D5AADB01618F5F90000EF26 /* UIKit.framework in Frameworks */, 102 | 9D5AADB11618F5F90000EF26 /* Foundation.framework in Frameworks */, 103 | ); 104 | runOnlyForDeploymentPostprocessing = 0; 105 | }; 106 | /* End PBXFrameworksBuildPhase section */ 107 | 108 | /* Begin PBXGroup section */ 109 | 9D5AAD7B1618F5F90000EF26 = { 110 | isa = PBXGroup; 111 | children = ( 112 | 9D5AAD901618F5F90000EF26 /* Custom UIButtons */, 113 | 9D5AADB41618F5F90000EF26 /* Custom UIButtonsTests */, 114 | 9D5AAD891618F5F90000EF26 /* Frameworks */, 115 | 9D5AAD871618F5F90000EF26 /* Products */, 116 | ); 117 | sourceTree = ""; 118 | }; 119 | 9D5AAD871618F5F90000EF26 /* Products */ = { 120 | isa = PBXGroup; 121 | children = ( 122 | 9D5AAD861618F5F90000EF26 /* Custom UIButtons.app */, 123 | 9D5AADAD1618F5F90000EF26 /* Custom UIButtonsTests.octest */, 124 | ); 125 | name = Products; 126 | sourceTree = ""; 127 | }; 128 | 9D5AAD891618F5F90000EF26 /* Frameworks */ = { 129 | isa = PBXGroup; 130 | children = ( 131 | 9DDA94DE161F4B0F0099D9C3 /* QuartzCore.framework */, 132 | 9D5AAD8A1618F5F90000EF26 /* UIKit.framework */, 133 | 9D5AAD8C1618F5F90000EF26 /* Foundation.framework */, 134 | 9D5AAD8E1618F5F90000EF26 /* CoreGraphics.framework */, 135 | 9D5AADAE1618F5F90000EF26 /* SenTestingKit.framework */, 136 | ); 137 | name = Frameworks; 138 | sourceTree = ""; 139 | }; 140 | 9D5AAD901618F5F90000EF26 /* Custom UIButtons */ = { 141 | isa = PBXGroup; 142 | children = ( 143 | 9D5AAD991618F5F90000EF26 /* CBAppDelegate.h */, 144 | 9D5AAD9A1618F5F90000EF26 /* CBAppDelegate.m */, 145 | 9D5AADA21618F5F90000EF26 /* MainStoryboard.storyboard */, 146 | 9DDA94F3161F68C90099D9C3 /* CBLayer.h */, 147 | 9DDA94F4161F68C90099D9C3 /* CBLayer.m */, 148 | 9D5AADA51618F5F90000EF26 /* CBViewController.h */, 149 | 9D5AADA61618F5F90000EF26 /* CBViewController.m */, 150 | 9D5AAD911618F5F90000EF26 /* Supporting Files */, 151 | ); 152 | path = "Custom UIButtons"; 153 | sourceTree = ""; 154 | }; 155 | 9D5AAD911618F5F90000EF26 /* Supporting Files */ = { 156 | isa = PBXGroup; 157 | children = ( 158 | 9D5AADD11619BB250000EF26 /* resizableButton.png */, 159 | 9D5AADD21619BB250000EF26 /* resizableButton@2x.png */, 160 | 9D5AADD31619BB250000EF26 /* resizableButtonHighlighted.png */, 161 | 9D5AADD41619BB250000EF26 /* resizableButtonHighlighted@2x.png */, 162 | 9D5AADC9161904190000EF26 /* button.png */, 163 | 9D5AADCA161904190000EF26 /* button@2x.png */, 164 | 9D5AADCB161904190000EF26 /* buttonHighlighted.png */, 165 | 9D5AADCC161904190000EF26 /* buttonHighlighted@2x.png */, 166 | 9D5AAD921618F5F90000EF26 /* Custom UIButtons-Info.plist */, 167 | 9D5AAD931618F5F90000EF26 /* InfoPlist.strings */, 168 | 9D5AAD961618F5F90000EF26 /* main.m */, 169 | 9D5AAD981618F5F90000EF26 /* Custom UIButtons-Prefix.pch */, 170 | 9D5AAD9C1618F5F90000EF26 /* Default.png */, 171 | 9D5AAD9E1618F5F90000EF26 /* Default@2x.png */, 172 | 9D5AADA01618F5F90000EF26 /* Default-568h@2x.png */, 173 | ); 174 | name = "Supporting Files"; 175 | sourceTree = ""; 176 | }; 177 | 9D5AADB41618F5F90000EF26 /* Custom UIButtonsTests */ = { 178 | isa = PBXGroup; 179 | children = ( 180 | 9D5AADBA1618F5F90000EF26 /* Custom_UIButtonsTests.h */, 181 | 9D5AADBB1618F5F90000EF26 /* Custom_UIButtonsTests.m */, 182 | 9D5AADB51618F5F90000EF26 /* Supporting Files */, 183 | ); 184 | path = "Custom UIButtonsTests"; 185 | sourceTree = ""; 186 | }; 187 | 9D5AADB51618F5F90000EF26 /* Supporting Files */ = { 188 | isa = PBXGroup; 189 | children = ( 190 | 9D5AADB61618F5F90000EF26 /* Custom UIButtonsTests-Info.plist */, 191 | 9D5AADB71618F5F90000EF26 /* InfoPlist.strings */, 192 | ); 193 | name = "Supporting Files"; 194 | sourceTree = ""; 195 | }; 196 | /* End PBXGroup section */ 197 | 198 | /* Begin PBXNativeTarget section */ 199 | 9D5AAD851618F5F90000EF26 /* Custom UIButtons */ = { 200 | isa = PBXNativeTarget; 201 | buildConfigurationList = 9D5AADBF1618F5F90000EF26 /* Build configuration list for PBXNativeTarget "Custom UIButtons" */; 202 | buildPhases = ( 203 | 9D5AAD821618F5F90000EF26 /* Sources */, 204 | 9D5AAD831618F5F90000EF26 /* Frameworks */, 205 | 9D5AAD841618F5F90000EF26 /* Resources */, 206 | ); 207 | buildRules = ( 208 | ); 209 | dependencies = ( 210 | ); 211 | name = "Custom UIButtons"; 212 | productName = "Custom UIButtons"; 213 | productReference = 9D5AAD861618F5F90000EF26 /* Custom UIButtons.app */; 214 | productType = "com.apple.product-type.application"; 215 | }; 216 | 9D5AADAC1618F5F90000EF26 /* Custom UIButtonsTests */ = { 217 | isa = PBXNativeTarget; 218 | buildConfigurationList = 9D5AADC21618F5F90000EF26 /* Build configuration list for PBXNativeTarget "Custom UIButtonsTests" */; 219 | buildPhases = ( 220 | 9D5AADA81618F5F90000EF26 /* Sources */, 221 | 9D5AADA91618F5F90000EF26 /* Frameworks */, 222 | 9D5AADAA1618F5F90000EF26 /* Resources */, 223 | 9D5AADAB1618F5F90000EF26 /* ShellScript */, 224 | ); 225 | buildRules = ( 226 | ); 227 | dependencies = ( 228 | 9D5AADB31618F5F90000EF26 /* PBXTargetDependency */, 229 | ); 230 | name = "Custom UIButtonsTests"; 231 | productName = "Custom UIButtonsTests"; 232 | productReference = 9D5AADAD1618F5F90000EF26 /* Custom UIButtonsTests.octest */; 233 | productType = "com.apple.product-type.bundle"; 234 | }; 235 | /* End PBXNativeTarget section */ 236 | 237 | /* Begin PBXProject section */ 238 | 9D5AAD7D1618F5F90000EF26 /* Project object */ = { 239 | isa = PBXProject; 240 | attributes = { 241 | CLASSPREFIX = CB; 242 | LastUpgradeCheck = 0450; 243 | ORGANIZATIONNAME = thoughtbot; 244 | }; 245 | buildConfigurationList = 9D5AAD801618F5F90000EF26 /* Build configuration list for PBXProject "Custom UIButtons" */; 246 | compatibilityVersion = "Xcode 3.2"; 247 | developmentRegion = English; 248 | hasScannedForEncodings = 0; 249 | knownRegions = ( 250 | en, 251 | ); 252 | mainGroup = 9D5AAD7B1618F5F90000EF26; 253 | productRefGroup = 9D5AAD871618F5F90000EF26 /* Products */; 254 | projectDirPath = ""; 255 | projectRoot = ""; 256 | targets = ( 257 | 9D5AAD851618F5F90000EF26 /* Custom UIButtons */, 258 | 9D5AADAC1618F5F90000EF26 /* Custom UIButtonsTests */, 259 | ); 260 | }; 261 | /* End PBXProject section */ 262 | 263 | /* Begin PBXResourcesBuildPhase section */ 264 | 9D5AAD841618F5F90000EF26 /* Resources */ = { 265 | isa = PBXResourcesBuildPhase; 266 | buildActionMask = 2147483647; 267 | files = ( 268 | 9D5AAD951618F5F90000EF26 /* InfoPlist.strings in Resources */, 269 | 9D5AAD9D1618F5F90000EF26 /* Default.png in Resources */, 270 | 9D5AAD9F1618F5F90000EF26 /* Default@2x.png in Resources */, 271 | 9D5AADA11618F5F90000EF26 /* Default-568h@2x.png in Resources */, 272 | 9D5AADA41618F5F90000EF26 /* MainStoryboard.storyboard in Resources */, 273 | 9D5AADCD161904190000EF26 /* button.png in Resources */, 274 | 9D5AADCE161904190000EF26 /* button@2x.png in Resources */, 275 | 9D5AADCF161904190000EF26 /* buttonHighlighted.png in Resources */, 276 | 9D5AADD0161904190000EF26 /* buttonHighlighted@2x.png in Resources */, 277 | 9D5AADD51619BB250000EF26 /* resizableButton.png in Resources */, 278 | 9D5AADD61619BB250000EF26 /* resizableButton@2x.png in Resources */, 279 | 9D5AADD71619BB250000EF26 /* resizableButtonHighlighted.png in Resources */, 280 | 9D5AADD81619BB250000EF26 /* resizableButtonHighlighted@2x.png in Resources */, 281 | ); 282 | runOnlyForDeploymentPostprocessing = 0; 283 | }; 284 | 9D5AADAA1618F5F90000EF26 /* Resources */ = { 285 | isa = PBXResourcesBuildPhase; 286 | buildActionMask = 2147483647; 287 | files = ( 288 | 9D5AADB91618F5F90000EF26 /* InfoPlist.strings in Resources */, 289 | ); 290 | runOnlyForDeploymentPostprocessing = 0; 291 | }; 292 | /* End PBXResourcesBuildPhase section */ 293 | 294 | /* Begin PBXShellScriptBuildPhase section */ 295 | 9D5AADAB1618F5F90000EF26 /* ShellScript */ = { 296 | isa = PBXShellScriptBuildPhase; 297 | buildActionMask = 2147483647; 298 | files = ( 299 | ); 300 | inputPaths = ( 301 | ); 302 | outputPaths = ( 303 | ); 304 | runOnlyForDeploymentPostprocessing = 0; 305 | shellPath = /bin/sh; 306 | shellScript = "# Run the unit tests in this test bundle.\n\"${SYSTEM_DEVELOPER_DIR}/Tools/RunUnitTests\"\n"; 307 | }; 308 | /* End PBXShellScriptBuildPhase section */ 309 | 310 | /* Begin PBXSourcesBuildPhase section */ 311 | 9D5AAD821618F5F90000EF26 /* Sources */ = { 312 | isa = PBXSourcesBuildPhase; 313 | buildActionMask = 2147483647; 314 | files = ( 315 | 9D5AAD971618F5F90000EF26 /* main.m in Sources */, 316 | 9D5AAD9B1618F5F90000EF26 /* CBAppDelegate.m in Sources */, 317 | 9D5AADA71618F5F90000EF26 /* CBViewController.m in Sources */, 318 | 9DDA94F5161F68C90099D9C3 /* CBLayer.m in Sources */, 319 | ); 320 | runOnlyForDeploymentPostprocessing = 0; 321 | }; 322 | 9D5AADA81618F5F90000EF26 /* Sources */ = { 323 | isa = PBXSourcesBuildPhase; 324 | buildActionMask = 2147483647; 325 | files = ( 326 | 9D5AADBC1618F5F90000EF26 /* Custom_UIButtonsTests.m in Sources */, 327 | ); 328 | runOnlyForDeploymentPostprocessing = 0; 329 | }; 330 | /* End PBXSourcesBuildPhase section */ 331 | 332 | /* Begin PBXTargetDependency section */ 333 | 9D5AADB31618F5F90000EF26 /* PBXTargetDependency */ = { 334 | isa = PBXTargetDependency; 335 | target = 9D5AAD851618F5F90000EF26 /* Custom UIButtons */; 336 | targetProxy = 9D5AADB21618F5F90000EF26 /* PBXContainerItemProxy */; 337 | }; 338 | /* End PBXTargetDependency section */ 339 | 340 | /* Begin PBXVariantGroup section */ 341 | 9D5AAD931618F5F90000EF26 /* InfoPlist.strings */ = { 342 | isa = PBXVariantGroup; 343 | children = ( 344 | 9D5AAD941618F5F90000EF26 /* en */, 345 | ); 346 | name = InfoPlist.strings; 347 | sourceTree = ""; 348 | }; 349 | 9D5AADA21618F5F90000EF26 /* MainStoryboard.storyboard */ = { 350 | isa = PBXVariantGroup; 351 | children = ( 352 | 9D5AADA31618F5F90000EF26 /* en */, 353 | ); 354 | name = MainStoryboard.storyboard; 355 | sourceTree = ""; 356 | }; 357 | 9D5AADB71618F5F90000EF26 /* InfoPlist.strings */ = { 358 | isa = PBXVariantGroup; 359 | children = ( 360 | 9D5AADB81618F5F90000EF26 /* en */, 361 | ); 362 | name = InfoPlist.strings; 363 | sourceTree = ""; 364 | }; 365 | /* End PBXVariantGroup section */ 366 | 367 | /* Begin XCBuildConfiguration section */ 368 | 9D5AADBD1618F5F90000EF26 /* Debug */ = { 369 | isa = XCBuildConfiguration; 370 | buildSettings = { 371 | ALWAYS_SEARCH_USER_PATHS = NO; 372 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 373 | CLANG_CXX_LIBRARY = "libc++"; 374 | CLANG_ENABLE_OBJC_ARC = YES; 375 | CLANG_WARN_EMPTY_BODY = YES; 376 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 377 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 378 | COPY_PHASE_STRIP = NO; 379 | GCC_C_LANGUAGE_STANDARD = gnu99; 380 | GCC_DYNAMIC_NO_PIC = NO; 381 | GCC_OPTIMIZATION_LEVEL = 0; 382 | GCC_PREPROCESSOR_DEFINITIONS = ( 383 | "DEBUG=1", 384 | "$(inherited)", 385 | ); 386 | GCC_SYMBOLS_PRIVATE_EXTERN = NO; 387 | GCC_WARN_ABOUT_RETURN_TYPE = YES; 388 | GCC_WARN_UNINITIALIZED_AUTOS = YES; 389 | GCC_WARN_UNUSED_VARIABLE = YES; 390 | IPHONEOS_DEPLOYMENT_TARGET = 6.0; 391 | SDKROOT = iphoneos; 392 | }; 393 | name = Debug; 394 | }; 395 | 9D5AADBE1618F5F90000EF26 /* Release */ = { 396 | isa = XCBuildConfiguration; 397 | buildSettings = { 398 | ALWAYS_SEARCH_USER_PATHS = NO; 399 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 400 | CLANG_CXX_LIBRARY = "libc++"; 401 | CLANG_ENABLE_OBJC_ARC = YES; 402 | CLANG_WARN_EMPTY_BODY = YES; 403 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 404 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 405 | COPY_PHASE_STRIP = YES; 406 | GCC_C_LANGUAGE_STANDARD = gnu99; 407 | GCC_WARN_ABOUT_RETURN_TYPE = YES; 408 | GCC_WARN_UNINITIALIZED_AUTOS = YES; 409 | GCC_WARN_UNUSED_VARIABLE = YES; 410 | IPHONEOS_DEPLOYMENT_TARGET = 6.0; 411 | OTHER_CFLAGS = "-DNS_BLOCK_ASSERTIONS=1"; 412 | SDKROOT = iphoneos; 413 | VALIDATE_PRODUCT = YES; 414 | }; 415 | name = Release; 416 | }; 417 | 9D5AADC01618F5F90000EF26 /* Debug */ = { 418 | isa = XCBuildConfiguration; 419 | buildSettings = { 420 | GCC_PRECOMPILE_PREFIX_HEADER = YES; 421 | GCC_PREFIX_HEADER = "Custom UIButtons/Custom UIButtons-Prefix.pch"; 422 | INFOPLIST_FILE = "Custom UIButtons/Custom UIButtons-Info.plist"; 423 | PRODUCT_NAME = "$(TARGET_NAME)"; 424 | WRAPPER_EXTENSION = app; 425 | }; 426 | name = Debug; 427 | }; 428 | 9D5AADC11618F5F90000EF26 /* Release */ = { 429 | isa = XCBuildConfiguration; 430 | buildSettings = { 431 | GCC_PRECOMPILE_PREFIX_HEADER = YES; 432 | GCC_PREFIX_HEADER = "Custom UIButtons/Custom UIButtons-Prefix.pch"; 433 | INFOPLIST_FILE = "Custom UIButtons/Custom UIButtons-Info.plist"; 434 | PRODUCT_NAME = "$(TARGET_NAME)"; 435 | WRAPPER_EXTENSION = app; 436 | }; 437 | name = Release; 438 | }; 439 | 9D5AADC31618F5F90000EF26 /* Debug */ = { 440 | isa = XCBuildConfiguration; 441 | buildSettings = { 442 | BUNDLE_LOADER = "$(BUILT_PRODUCTS_DIR)/Custom UIButtons.app/Custom UIButtons"; 443 | FRAMEWORK_SEARCH_PATHS = ( 444 | "\"$(SDKROOT)/Developer/Library/Frameworks\"", 445 | "\"$(DEVELOPER_LIBRARY_DIR)/Frameworks\"", 446 | ); 447 | GCC_PRECOMPILE_PREFIX_HEADER = YES; 448 | GCC_PREFIX_HEADER = "Custom UIButtons/Custom UIButtons-Prefix.pch"; 449 | INFOPLIST_FILE = "Custom UIButtonsTests/Custom UIButtonsTests-Info.plist"; 450 | PRODUCT_NAME = "$(TARGET_NAME)"; 451 | TEST_HOST = "$(BUNDLE_LOADER)"; 452 | WRAPPER_EXTENSION = octest; 453 | }; 454 | name = Debug; 455 | }; 456 | 9D5AADC41618F5F90000EF26 /* Release */ = { 457 | isa = XCBuildConfiguration; 458 | buildSettings = { 459 | BUNDLE_LOADER = "$(BUILT_PRODUCTS_DIR)/Custom UIButtons.app/Custom UIButtons"; 460 | FRAMEWORK_SEARCH_PATHS = ( 461 | "\"$(SDKROOT)/Developer/Library/Frameworks\"", 462 | "\"$(DEVELOPER_LIBRARY_DIR)/Frameworks\"", 463 | ); 464 | GCC_PRECOMPILE_PREFIX_HEADER = YES; 465 | GCC_PREFIX_HEADER = "Custom UIButtons/Custom UIButtons-Prefix.pch"; 466 | INFOPLIST_FILE = "Custom UIButtonsTests/Custom UIButtonsTests-Info.plist"; 467 | PRODUCT_NAME = "$(TARGET_NAME)"; 468 | TEST_HOST = "$(BUNDLE_LOADER)"; 469 | WRAPPER_EXTENSION = octest; 470 | }; 471 | name = Release; 472 | }; 473 | /* End XCBuildConfiguration section */ 474 | 475 | /* Begin XCConfigurationList section */ 476 | 9D5AAD801618F5F90000EF26 /* Build configuration list for PBXProject "Custom UIButtons" */ = { 477 | isa = XCConfigurationList; 478 | buildConfigurations = ( 479 | 9D5AADBD1618F5F90000EF26 /* Debug */, 480 | 9D5AADBE1618F5F90000EF26 /* Release */, 481 | ); 482 | defaultConfigurationIsVisible = 0; 483 | defaultConfigurationName = Release; 484 | }; 485 | 9D5AADBF1618F5F90000EF26 /* Build configuration list for PBXNativeTarget "Custom UIButtons" */ = { 486 | isa = XCConfigurationList; 487 | buildConfigurations = ( 488 | 9D5AADC01618F5F90000EF26 /* Debug */, 489 | 9D5AADC11618F5F90000EF26 /* Release */, 490 | ); 491 | defaultConfigurationIsVisible = 0; 492 | defaultConfigurationName = Release; 493 | }; 494 | 9D5AADC21618F5F90000EF26 /* Build configuration list for PBXNativeTarget "Custom UIButtonsTests" */ = { 495 | isa = XCConfigurationList; 496 | buildConfigurations = ( 497 | 9D5AADC31618F5F90000EF26 /* Debug */, 498 | 9D5AADC41618F5F90000EF26 /* Release */, 499 | ); 500 | defaultConfigurationIsVisible = 0; 501 | defaultConfigurationName = Release; 502 | }; 503 | /* End XCConfigurationList section */ 504 | }; 505 | rootObject = 9D5AAD7D1618F5F90000EF26 /* Project object */; 506 | } 507 | -------------------------------------------------------------------------------- /Custom UIButtons/CBAppDelegate.h: -------------------------------------------------------------------------------- 1 | // 2 | // CBAppDelegate.h 3 | // Custom UIButtons 4 | // 5 | // Created by Reda Lemeden on 9/30/12. 6 | // Copyright (c) 2012 thoughtbot. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface CBAppDelegate : UIResponder 12 | 13 | @property (strong, nonatomic) UIWindow *window; 14 | 15 | @end 16 | -------------------------------------------------------------------------------- /Custom UIButtons/CBAppDelegate.m: -------------------------------------------------------------------------------- 1 | // 2 | // CBAppDelegate.m 3 | // Custom UIButtons 4 | // 5 | // Created by Reda Lemeden on 9/30/12. 6 | // Copyright (c) 2012 thoughtbot. All rights reserved. 7 | // 8 | 9 | #import "CBAppDelegate.h" 10 | 11 | @implementation CBAppDelegate 12 | 13 | - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions 14 | { 15 | // Override point for customization after application launch. 16 | return YES; 17 | } 18 | 19 | - (void)applicationWillResignActive:(UIApplication *)application 20 | { 21 | // 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. 22 | // 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. 23 | } 24 | 25 | - (void)applicationDidEnterBackground:(UIApplication *)application 26 | { 27 | // 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. 28 | // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. 29 | } 30 | 31 | - (void)applicationWillEnterForeground:(UIApplication *)application 32 | { 33 | // 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. 34 | } 35 | 36 | - (void)applicationDidBecomeActive:(UIApplication *)application 37 | { 38 | // 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. 39 | } 40 | 41 | - (void)applicationWillTerminate:(UIApplication *)application 42 | { 43 | // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. 44 | } 45 | 46 | @end 47 | -------------------------------------------------------------------------------- /Custom UIButtons/CBLayer.h: -------------------------------------------------------------------------------- 1 | #import 2 | #import 3 | 4 | @interface CBLayer : UIButton 5 | 6 | @end 7 | -------------------------------------------------------------------------------- /Custom UIButtons/CBLayer.m: -------------------------------------------------------------------------------- 1 | #import "CBLayer.h" 2 | 3 | @interface CBLayer () 4 | 5 | @property (assign, nonatomic) BOOL tapped, setupLayers; 6 | @property (strong, nonatomic) CAGradientLayer *backgroundLayer, *highlightBackgroundLayer; 7 | @property (strong,nonatomic) CALayer *innerGlow; 8 | 9 | @end 10 | 11 | @implementation CBLayer 12 | 13 | #pragma mark - 14 | 15 | - (void)drawRect:(CGRect)rect 16 | { 17 | if (!_setupLayers) 18 | { 19 | self.layer.cornerRadius = 4.5f; 20 | self.layer.masksToBounds = YES; 21 | self.layer.borderWidth = 1; 22 | self.layer.borderColor = [UIColor colorWithRed:0.77f green:0.43f blue:0.00f alpha:1.00f].CGColor; 23 | 24 | [self setInnerGlow]; 25 | [self setBackgroundLayer]; 26 | [self setHighlightBackgroundLayer]; 27 | } 28 | 29 | 30 | if (_tapped) 31 | { 32 | _highlightBackgroundLayer.hidden = NO; 33 | } 34 | 35 | else 36 | { 37 | _highlightBackgroundLayer.hidden = YES; 38 | } 39 | 40 | _setupLayers = YES; 41 | } 42 | 43 | #pragma mark - Layer setters 44 | 45 | - (void)setBackgroundLayer 46 | { 47 | if (!_backgroundLayer) 48 | { 49 | _backgroundLayer = [CAGradientLayer layer]; 50 | _backgroundLayer.frame = self.bounds; 51 | _backgroundLayer.colors = (@[ 52 | (id)[UIColor colorWithRed:0.94f green:0.82f blue:0.52f alpha:1.00f].CGColor, 53 | (id)[UIColor colorWithRed:0.91f green:0.58f blue:0.00f alpha:1.00f].CGColor 54 | ]); 55 | _backgroundLayer.locations = (@[ 56 | @0.0f, 57 | @1.0f 58 | ]); 59 | 60 | [self.layer insertSublayer:_backgroundLayer atIndex:0]; 61 | } 62 | } 63 | 64 | - (void)setHighlightBackgroundLayer 65 | { 66 | if (!_highlightBackgroundLayer) 67 | { 68 | _highlightBackgroundLayer = [CAGradientLayer layer]; 69 | _highlightBackgroundLayer.frame = self.bounds; 70 | _highlightBackgroundLayer.colors = (@[ 71 | (id)[UIColor colorWithRed:0.91f green:0.58f blue:0.00f alpha:1.00f].CGColor, 72 | (id)[UIColor colorWithRed:0.94f green:0.82f blue:0.52f alpha:1.00f].CGColor 73 | ]); 74 | _highlightBackgroundLayer.locations = (@[ 75 | @0.0f, 76 | @1.0f 77 | ]); 78 | [self.layer insertSublayer:_highlightBackgroundLayer atIndex:1]; 79 | } 80 | } 81 | 82 | - (void)setInnerGlow 83 | { 84 | if (!_innerGlow) 85 | { 86 | _innerGlow = [CALayer layer]; 87 | CGRect innerGlowFrame = CGRectMake(self.bounds.origin.x+1, self.bounds.origin.y+1, self.bounds.size.width-2, self.bounds.size.height-2); 88 | _innerGlow.frame = innerGlowFrame; 89 | _innerGlow.cornerRadius= 4.5f; 90 | _innerGlow.borderWidth = 1; 91 | _innerGlow.borderColor = [[UIColor whiteColor] CGColor]; 92 | _innerGlow.opacity = 0.5; 93 | 94 | [self.layer insertSublayer:_innerGlow atIndex:2]; 95 | } 96 | } 97 | 98 | #pragma mark - Touch event overrides 99 | 100 | -(void)touchesBegan:(NSSet *)touches withEvent:(UIEvent *)event 101 | { 102 | _tapped = YES; 103 | [self setNeedsDisplay]; 104 | [super touchesBegan:touches withEvent:event]; 105 | } 106 | 107 | -(void)touchesEnded:(NSSet *)touches withEvent:(UIEvent *)event 108 | { 109 | _tapped = NO; 110 | [self setNeedsDisplay]; 111 | [super touchesEnded:touches withEvent:event]; 112 | } 113 | 114 | -(void)touchesMoved:(NSSet *)touches withEvent:(UIEvent *)event 115 | { 116 | CGPoint touchPoint = [[touches anyObject] locationInView:self]; 117 | CGRect testRect = CGRectMake(0, 0, self.frame.size.width, self.frame.size.height); 118 | 119 | if (CGRectContainsPoint(testRect, touchPoint)) 120 | { 121 | _tapped = YES; 122 | [self setNeedsDisplay]; 123 | } 124 | 125 | else 126 | { 127 | _tapped = NO; 128 | [self setNeedsDisplay]; 129 | } 130 | 131 | [super touchesMoved:touches withEvent:event]; 132 | } 133 | 134 | @end 135 | -------------------------------------------------------------------------------- /Custom UIButtons/CBViewController.h: -------------------------------------------------------------------------------- 1 | #import 2 | 3 | @interface CBViewController : UIViewController 4 | 5 | @end 6 | -------------------------------------------------------------------------------- /Custom UIButtons/CBViewController.m: -------------------------------------------------------------------------------- 1 | #import "CBViewController.h" 2 | 3 | @interface CBViewController () 4 | 5 | @property (weak, nonatomic) IBOutlet UIButton *fullSizeImage; 6 | @property (weak, nonatomic) IBOutlet UIButton *resizableImage; 7 | 8 | @end 9 | 10 | @implementation CBViewController 11 | 12 | - (void)viewDidLoad 13 | { 14 | [super viewDidLoad]; 15 | 16 | // Set full-sized background image 17 | [self.fullSizeImage setBackgroundImage:[UIImage imageNamed:@"button.png"] forState:UIControlStateNormal]; 18 | [self.fullSizeImage setBackgroundImage:[UIImage imageNamed:@"buttonHighlighted.png"] forState:UIControlStateHighlighted]; 19 | 20 | // Define resizable images 21 | UIImage *resizableButton = [[UIImage imageNamed:@"resizableButton.png" ] resizableImageWithCapInsets:UIEdgeInsetsMake(17, 5, 17, 5)]; 22 | UIImage *resizableButtonHighlighted = [[UIImage imageNamed:@"resizableButtonHighlighted.png" ] resizableImageWithCapInsets:UIEdgeInsetsMake(17, 5, 17, 5)]; 23 | 24 | // Set resizable background image 25 | [self.resizableImage setBackgroundImage:resizableButton forState:UIControlStateNormal]; 26 | [self.resizableImage setBackgroundImage:resizableButtonHighlighted forState:UIControlStateHighlighted]; 27 | } 28 | 29 | - (void)didReceiveMemoryWarning 30 | { 31 | [super didReceiveMemoryWarning]; 32 | // Dispose of any resources that can be recreated. 33 | } 34 | 35 | @end 36 | -------------------------------------------------------------------------------- /Custom UIButtons/Custom UIButtons-Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleDisplayName 8 | ${PRODUCT_NAME} 9 | CFBundleExecutable 10 | ${EXECUTABLE_NAME} 11 | CFBundleIdentifier 12 | com.thoughtbot.${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 | UIMainStoryboardFile 28 | MainStoryboard 29 | UIRequiredDeviceCapabilities 30 | 31 | armv7 32 | 33 | UISupportedInterfaceOrientations 34 | 35 | UIInterfaceOrientationPortrait 36 | UIInterfaceOrientationLandscapeLeft 37 | UIInterfaceOrientationLandscapeRight 38 | 39 | 40 | 41 | -------------------------------------------------------------------------------- /Custom UIButtons/Custom UIButtons-Prefix.pch: -------------------------------------------------------------------------------- 1 | // 2 | // Prefix header for all source files of the 'Custom UIButtons' target in the 'Custom UIButtons' project 3 | // 4 | 5 | #import 6 | 7 | #ifndef __IPHONE_5_0 8 | #warning "This project uses features only available in iOS SDK 5.0 and later." 9 | #endif 10 | 11 | #ifdef __OBJC__ 12 | #import 13 | #import 14 | #endif 15 | -------------------------------------------------------------------------------- /Custom UIButtons/Default-568h@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaishin/custom-UIButton/657ad60cdfc0cb14935a64ea177bfe3146e8d142/Custom UIButtons/Default-568h@2x.png -------------------------------------------------------------------------------- /Custom UIButtons/Default.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaishin/custom-UIButton/657ad60cdfc0cb14935a64ea177bfe3146e8d142/Custom UIButtons/Default.png -------------------------------------------------------------------------------- /Custom UIButtons/Default@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaishin/custom-UIButton/657ad60cdfc0cb14935a64ea177bfe3146e8d142/Custom UIButtons/Default@2x.png -------------------------------------------------------------------------------- /Custom UIButtons/button.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaishin/custom-UIButton/657ad60cdfc0cb14935a64ea177bfe3146e8d142/Custom UIButtons/button.png -------------------------------------------------------------------------------- /Custom UIButtons/button@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaishin/custom-UIButton/657ad60cdfc0cb14935a64ea177bfe3146e8d142/Custom UIButtons/button@2x.png -------------------------------------------------------------------------------- /Custom UIButtons/buttonHighlighted.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaishin/custom-UIButton/657ad60cdfc0cb14935a64ea177bfe3146e8d142/Custom UIButtons/buttonHighlighted.png -------------------------------------------------------------------------------- /Custom UIButtons/buttonHighlighted@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaishin/custom-UIButton/657ad60cdfc0cb14935a64ea177bfe3146e8d142/Custom UIButtons/buttonHighlighted@2x.png -------------------------------------------------------------------------------- /Custom UIButtons/en.lproj/InfoPlist.strings: -------------------------------------------------------------------------------- 1 | /* Localized versions of Info.plist keys */ 2 | 3 | -------------------------------------------------------------------------------- /Custom UIButtons/en.lproj/MainStoryboard.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 30 | 39 | 53 | 67 | 80 | 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 | 127 | 128 | 129 | 130 | 131 | 132 | 133 | 134 | 135 | -------------------------------------------------------------------------------- /Custom UIButtons/main.m: -------------------------------------------------------------------------------- 1 | // 2 | // main.m 3 | // Custom UIButtons 4 | // 5 | // Created by Reda Lemeden on 9/30/12. 6 | // Copyright (c) 2012 thoughtbot. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | #import "CBAppDelegate.h" 12 | 13 | int main(int argc, char *argv[]) 14 | { 15 | @autoreleasepool { 16 | return UIApplicationMain(argc, argv, nil, NSStringFromClass([CBAppDelegate class])); 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /Custom UIButtons/resizableButton.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaishin/custom-UIButton/657ad60cdfc0cb14935a64ea177bfe3146e8d142/Custom UIButtons/resizableButton.png -------------------------------------------------------------------------------- /Custom UIButtons/resizableButton@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaishin/custom-UIButton/657ad60cdfc0cb14935a64ea177bfe3146e8d142/Custom UIButtons/resizableButton@2x.png -------------------------------------------------------------------------------- /Custom UIButtons/resizableButtonHighlighted.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaishin/custom-UIButton/657ad60cdfc0cb14935a64ea177bfe3146e8d142/Custom UIButtons/resizableButtonHighlighted.png -------------------------------------------------------------------------------- /Custom UIButtons/resizableButtonHighlighted@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaishin/custom-UIButton/657ad60cdfc0cb14935a64ea177bfe3146e8d142/Custom UIButtons/resizableButtonHighlighted@2x.png -------------------------------------------------------------------------------- /Custom UIButtonsTests/Custom UIButtonsTests-Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | ${EXECUTABLE_NAME} 9 | CFBundleIdentifier 10 | com.thoughtbot.${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 | -------------------------------------------------------------------------------- /Custom UIButtonsTests/Custom_UIButtonsTests.h: -------------------------------------------------------------------------------- 1 | // 2 | // Custom_UIButtonsTests.h 3 | // Custom UIButtonsTests 4 | // 5 | // Created by Reda Lemeden on 9/30/12. 6 | // Copyright (c) 2012 thoughtbot. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface Custom_UIButtonsTests : SenTestCase 12 | 13 | @end 14 | -------------------------------------------------------------------------------- /Custom UIButtonsTests/Custom_UIButtonsTests.m: -------------------------------------------------------------------------------- 1 | // 2 | // Custom_UIButtonsTests.m 3 | // Custom UIButtonsTests 4 | // 5 | // Created by Reda Lemeden on 9/30/12. 6 | // Copyright (c) 2012 thoughtbot. All rights reserved. 7 | // 8 | 9 | #import "Custom_UIButtonsTests.h" 10 | 11 | @implementation Custom_UIButtonsTests 12 | 13 | - (void)setUp 14 | { 15 | [super setUp]; 16 | 17 | // Set-up code here. 18 | } 19 | 20 | - (void)tearDown 21 | { 22 | // Tear-down code here. 23 | 24 | [super tearDown]; 25 | } 26 | 27 | - (void)testExample 28 | { 29 | STFail(@"Unit tests are not implemented yet in Custom UIButtonsTests"); 30 | } 31 | 32 | @end 33 | -------------------------------------------------------------------------------- /Custom UIButtonsTests/en.lproj/InfoPlist.strings: -------------------------------------------------------------------------------- 1 | /* Localized versions of Info.plist keys */ 2 | 3 | --------------------------------------------------------------------------------