Skip to content

Commit

Permalink
Update projects (syntax and demo)
Browse files Browse the repository at this point in the history
  • Loading branch information
Jérôme Morissard committed Apr 26, 2017
1 parent 32a6777 commit 05d97e7
Show file tree
Hide file tree
Showing 24 changed files with 323 additions and 36 deletions.
4 changes: 2 additions & 2 deletions JMHoledView.podspec
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Pod::Spec.new do |s|

s.name = "JMHoledView"
s.version = "0.1.1"
s.version = "0.1.2"
s.summary = "UIView subclass designed to be filled with holes"
s.requires_arc = true

Expand All @@ -15,7 +15,7 @@ Pod::Spec.new do |s|
s.license = 'MIT'
s.author = { "jerome Morissard" => "[email protected]" }
s.platform = :ios, '5.0'
s.source = { :git => "https://github.com/leverdeterre/JMHoledView.git", :tag => "0.1.1" }
s.source = { :git => "https://github.com/leverdeterre/JMHoledView.git", :tag => "0.1.2" }
s.source_files = 'Classes', 'JMHoledView/JMHoledView/*.{h,m}'
s.public_header_files = 'JMHoledView/JMHoledView/*.h'
end
10 changes: 8 additions & 2 deletions JMHoledView.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@
objects = {

/* Begin PBXBuildFile section */
C22E69B41EB0C02B00BD0D41 /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = C22E69B31EB0C02B00BD0D41 /* LaunchScreen.storyboard */; };
C22E69B61EB0C24200BD0D41 /* JMHoledView.podspec in Resources */ = {isa = PBXBuildFile; fileRef = C22E69B51EB0C24200BD0D41 /* JMHoledView.podspec */; };
C252CA5D1A7E02EC00145A39 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = C252CA5C1A7E02EC00145A39 /* Foundation.framework */; };
C252CA5F1A7E02EC00145A39 /* CoreGraphics.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = C252CA5E1A7E02EC00145A39 /* CoreGraphics.framework */; };
C252CA611A7E02EC00145A39 /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = C252CA601A7E02EC00145A39 /* UIKit.framework */; };
Expand Down Expand Up @@ -35,6 +37,8 @@
/* End PBXContainerItemProxy section */

/* Begin PBXFileReference section */
C22E69B31EB0C02B00BD0D41 /* LaunchScreen.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; path = LaunchScreen.storyboard; sourceTree = "<group>"; };
C22E69B51EB0C24200BD0D41 /* JMHoledView.podspec */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = JMHoledView.podspec; sourceTree = SOURCE_ROOT; };
C252CA591A7E02EC00145A39 /* JMHoledView.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = JMHoledView.app; sourceTree = BUILT_PRODUCTS_DIR; };
C252CA5C1A7E02EC00145A39 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; };
C252CA5E1A7E02EC00145A39 /* CoreGraphics.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreGraphics.framework; path = System/Library/Frameworks/CoreGraphics.framework; sourceTree = SDKROOT; };
Expand Down Expand Up @@ -116,11 +120,13 @@
C252CA621A7E02EC00145A39 /* JMHoledView */ = {
isa = PBXGroup;
children = (
C22E69B51EB0C24200BD0D41 /* JMHoledView.podspec */,
C252CA6B1A7E02EC00145A39 /* JMAppDelegate.h */,
C252CA6C1A7E02EC00145A39 /* JMAppDelegate.m */,
C252CA6E1A7E02EC00145A39 /* Main_iPhone.storyboard */,
C252CA741A7E02EC00145A39 /* JMViewController.h */,
C252CA751A7E02EC00145A39 /* JMViewController.m */,
C22E69B31EB0C02B00BD0D41 /* LaunchScreen.storyboard */,
C252CA771A7E02EC00145A39 /* Images.xcassets */,
C252CA631A7E02EC00145A39 /* Supporting Files */,
);
Expand Down Expand Up @@ -244,6 +250,8 @@
buildActionMask = 2147483647;
files = (
C252CA781A7E02EC00145A39 /* Images.xcassets in Resources */,
C22E69B41EB0C02B00BD0D41 /* LaunchScreen.storyboard in Resources */,
C22E69B61EB0C24200BD0D41 /* JMHoledView.podspec in Resources */,
C252CA701A7E02EC00145A39 /* Main_iPhone.storyboard in Resources */,
C252CA671A7E02EC00145A39 /* InfoPlist.strings in Resources */,
);
Expand Down Expand Up @@ -393,7 +401,6 @@
isa = XCBuildConfiguration;
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = "JMHoledView/JMHoledView-Prefix.pch";
INFOPLIST_FILE = "JMHoledView/JMHoledView-Info.plist";
Expand All @@ -407,7 +414,6 @@
isa = XCBuildConfiguration;
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = "JMHoledView/JMHoledView-Prefix.pch";
INFOPLIST_FILE = "JMHoledView/JMHoledView-Info.plist";
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>IDESourceControlProjectFavoriteDictionaryKey</key>
<false/>
<key>IDESourceControlProjectIdentifier</key>
<string>6D0F41E4-FD97-41C4-B7E6-FAB43E1812D3</string>
<key>IDESourceControlProjectName</key>
<string>JMHoledView</string>
<key>IDESourceControlProjectOriginsDictionary</key>
<dict>
<key>F680B4650B3E340418B15DE0C6215573DDB0C76C</key>
<string>https://github.com/leverdeterre/JMHoledView.git</string>
</dict>
<key>IDESourceControlProjectPath</key>
<string>JMHoledView.xcodeproj</string>
<key>IDESourceControlProjectRelativeInstallPathDictionary</key>
<dict>
<key>F680B4650B3E340418B15DE0C6215573DDB0C76C</key>
<string>../..</string>
</dict>
<key>IDESourceControlProjectURL</key>
<string>https://github.com/leverdeterre/JMHoledView.git</string>
<key>IDESourceControlProjectVersion</key>
<integer>111</integer>
<key>IDESourceControlProjectWCCIdentifier</key>
<string>F680B4650B3E340418B15DE0C6215573DDB0C76C</string>
<key>IDESourceControlProjectWCConfigurations</key>
<array>
<dict>
<key>IDESourceControlRepositoryExtensionIdentifierKey</key>
<string>public.vcs.git</string>
<key>IDESourceControlWCCIdentifierKey</key>
<string>F680B4650B3E340418B15DE0C6215573DDB0C76C</string>
<key>IDESourceControlWCCName</key>
<string>JMHoledView</string>
</dict>
</array>
</dict>
</plist>
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
<Bucket
type = "1"
version = "2.0">
</Bucket>
137 changes: 136 additions & 1 deletion JMHoledView/Images.xcassets/AppIcon.appiconset/Contents.json
Original file line number Diff line number Diff line change
@@ -1,23 +1,78 @@
{
"images" : [
{
"idiom" : "iphone",
"size" : "20x20",
"scale" : "2x"
},
{
"idiom" : "iphone",
"size" : "20x20",
"scale" : "3x"
},
{
"idiom" : "iphone",
"size" : "29x29",
"scale" : "1x"
},
{
"idiom" : "iphone",
"size" : "29x29",
"scale" : "2x"
},
{
"idiom" : "iphone",
"size" : "29x29",
"scale" : "3x"
},
{
"idiom" : "iphone",
"size" : "40x40",
"scale" : "2x"
},
{
"idiom" : "iphone",
"size" : "40x40",
"scale" : "3x"
},
{
"size" : "57x57",
"idiom" : "iphone",
"filename" : "Icon.png",
"scale" : "1x"
},
{
"size" : "57x57",
"idiom" : "iphone",
"filename" : "[email protected]",
"scale" : "2x"
},
{
"size" : "60x60",
"idiom" : "iphone",
"filename" : "Icon-120.png",
"scale" : "2x"
},
{
"idiom" : "iphone",
"size" : "60x60",
"scale" : "3x"
},
{
"idiom" : "ipad",
"size" : "20x20",
"scale" : "1x"
},
{
"size" : "20x20",
"idiom" : "ipad",
"filename" : "Icon-Spotlight-iOS7.png",
"scale" : "2x"
},
{
"size" : "29x29",
"idiom" : "ipad",
"filename" : "Icon-Small.png",
"scale" : "1x"
},
{
Expand All @@ -36,14 +91,94 @@
"scale" : "2x"
},
{
"size" : "50x50",
"idiom" : "ipad",
"size" : "76x76",
"filename" : "Icon-Small-50.png",
"scale" : "1x"
},
{
"size" : "50x50",
"idiom" : "ipad",
"filename" : "[email protected]",
"scale" : "2x"
},
{
"size" : "72x72",
"idiom" : "ipad",
"filename" : "Icon-72.png",
"scale" : "1x"
},
{
"size" : "72x72",
"idiom" : "ipad",
"filename" : "[email protected]",
"scale" : "2x"
},
{
"size" : "76x76",
"idiom" : "ipad",
"filename" : "Icon-76.png",
"scale" : "1x"
},
{
"size" : "76x76",
"idiom" : "ipad",
"filename" : "[email protected]",
"scale" : "2x"
},
{
"idiom" : "ipad",
"size" : "83.5x83.5",
"scale" : "2x"
},
{
"size" : "24x24",
"idiom" : "watch",
"scale" : "2x",
"role" : "notificationCenter",
"subtype" : "38mm"
},
{
"size" : "27.5x27.5",
"idiom" : "watch",
"scale" : "2x",
"role" : "notificationCenter",
"subtype" : "42mm"
},
{
"size" : "29x29",
"idiom" : "watch",
"filename" : "[email protected]",
"role" : "companionSettings",
"scale" : "2x"
},
{
"size" : "29x29",
"idiom" : "watch",
"role" : "companionSettings",
"scale" : "3x"
},
{
"size" : "40x40",
"idiom" : "watch",
"filename" : "[email protected]",
"scale" : "2x",
"role" : "appLauncher",
"subtype" : "38mm"
},
{
"size" : "86x86",
"idiom" : "watch",
"scale" : "2x",
"role" : "quickLook",
"subtype" : "38mm"
},
{
"size" : "98x98",
"idiom" : "watch",
"scale" : "2x",
"role" : "quickLook",
"subtype" : "42mm"
}
],
"info" : {
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 2 additions & 0 deletions JMHoledView/JMHoledView-Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@
<key>NSAllowsArbitraryLoads</key>
<true/>
</dict>
<key>UILaunchStoryboardName</key>
<string>LaunchScreen</string>
<key>UIMainStoryboardFile</key>
<string>Main_iPhone</string>
<key>UIMainStoryboardFile~ipad</key>
Expand Down
32 changes: 26 additions & 6 deletions JMHoledView/JMHoledView/JMHoledView.h
Original file line number Diff line number Diff line change
Expand Up @@ -40,16 +40,36 @@ typedef NS_ENUM(NSInteger, JMHolePosition)
@property (strong, nonatomic) UIColor *dimingColor;
@property (weak, nonatomic) id <JMHoledViewDelegate> holeViewDelegate;

- (NSInteger)addHoleCircleCenteredOnPosition:(CGPoint)centerPoint andDiameter:(CGFloat)diamter;
- (NSInteger)addHoleCircleCenteredOnPosition:(CGPoint)centerPoint andDiameter:(CGFloat)diameter WithHScale:(CGFloat)hScale;
- (NSInteger)addHoleCircleCenteredOnPosition:(CGPoint)centerPoint
diameter:(CGFloat)diamter;

- (NSInteger)addHoleCircleCenteredOnPosition:(CGPoint)centerPoint
diameter:(CGFloat)diameter
hScale:(CGFloat)hScale;

- (NSInteger)addHoleRectOnRect:(CGRect)rect;
- (NSInteger)addHoleRoundedRectOnRect:(CGRect)rect withCornerRadius:(CGFloat)cornerRadius;

- (NSInteger)addHoleRoundedRectOnRect:(CGRect)rect
cornerRadius:(CGFloat)cornerRadius;

- (NSInteger)addHCustomView:(UIView *)customView onRect:(CGRect)rect;

- (void) addHoleCircleCenteredOnPosition:(CGPoint)centerPoint andDiameter:(CGFloat)diameter withText:(NSString *)text onPosition:(JMHolePosition)position withMargin:(CGFloat) margin;
- (void) addHoleRectOnRect:(CGRect)rect withText:(NSString *)text onPosition:(JMHolePosition)position withMargin:(CGFloat) margin;
- (void) addHoleRoundedRectOnRect:(CGRect)rect withCornerRadius:(CGFloat)cornerRadius withText:(NSString *)text onPosition:(JMHolePosition)position withMargin:(CGFloat) margin;
- (void)addHoleCircleCenteredOnPosition:(CGPoint)centerPoint
diameter:(CGFloat)diameter
text:(NSString *)text
onPosition:(JMHolePosition)position
margin:(CGFloat)margin;

- (void)addHoleRectOnRect:(CGRect)rect
text:(NSString *)text
onPosition:(JMHolePosition)position
margin:(CGFloat)margin;

- (void)addHoleRoundedRectOnRect:(CGRect)rect
cornerRadius:(CGFloat)cornerRadius
text:(NSString *)text
onPosition:(JMHolePosition)position
margin:(CGFloat)margin;

- (void)removeHoles;

Expand Down
Loading

0 comments on commit 05d97e7

Please sign in to comment.